ScratchData LogoScratchData
Back to dimmat's profile

Fill triangle with color (simple but slow)

DIdimmat•Created January 7, 2017
Fill triangle with color (simple but slow)
0
0
60 views
View on Scratch

Instructions

A simple method for filling a triangular area with color in real time. The concept is that there are 3 points for drawing a triangle: (x1,y1) (x2,y2) (x3,y3) One of this points, e.g. point (x3,y3), is used as a Reference Point. The algorithm draws constantly lines of a color from the Reference Point (steady point) along the line between the points (x1,y1) and (x2,y2). With this technique, more complex areas, like rectangles, polygons, 3D objects, etc, can be filled with color.

Project Details

Project ID138964441
CreatedJanuary 7, 2017
Last ModifiedJanuary 10, 2017
SharedJanuary 7, 2017
Visibilityvisible
CommentsAllowed