Polygon
Help Contents
Graphics
Drawing filled shapes
Polygon
Polygon commandlist
command to draw a polygon using turtle commands inside the commandlist.
This is cool for drawing shapes, especially in 3D. In perspective mode the polygon will be lighted.
Be careful: the polygon must be simple and convex. For non-convex polygons and polygons with holes use Tesselation!
It is recommended to use the primitive Polygon instead of PolyStart..PolyEnd, because so you cannot forget PolyEnd, when i.e. leaving a loop with break, or leaving a procedure with output or stop.
Example:
Examples:
References:
PolyEnd(3), PolyStart(3), TessStart(3), Tesselation(3), Release Notes for Version 4.7(2), Release Notes for Version 4.65, Release Notes for Version 4.672, TessContour, TessEnd, cngon, fill