-
Notifications
You must be signed in to change notification settings - Fork 2
raylib.ImageDrawTriangleFan
JoeStrout edited this page Apr 29, 2026
·
2 revisions
Draw a triangle fan defined by points within an image (first vertex is the center)
| Parameter | Default Value | Note |
|---|---|---|
| dst | ||
| points | ||
| color |
None.
img = raylib.GenImageColor(128, 128, raylib.BLACK)
// Draw a square as a triangle fan (center + 4 corners)
pts = [[64,64], [0,0], [127,0], [127,127], [0,127], [0,0]]
raylib.ImageDrawTriangleFan img, pts, raylib.GREEN
raylib.ExportImage img, "fan.png"
raylib.UnloadImage img