|
@ -1179,6 +1179,7 @@ void DrawRectangleRoundedLines(Rectangle rec, float roundness, int segments, int |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Draw a triangle |
|
|
// Draw a triangle |
|
|
|
|
|
// NOTE: Vertex must be provided in counter-clockwise order |
|
|
void DrawTriangle(Vector2 v1, Vector2 v2, Vector2 v3, Color color) |
|
|
void DrawTriangle(Vector2 v1, Vector2 v2, Vector2 v3, Color color) |
|
|
{ |
|
|
{ |
|
|
if (rlCheckBufferLimit(4)) rlglDraw(); |
|
|
if (rlCheckBufferLimit(4)) rlglDraw(); |
|
@ -1214,6 +1215,7 @@ void DrawTriangle(Vector2 v1, Vector2 v2, Vector2 v3, Color color) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Draw a triangle using lines |
|
|
// Draw a triangle using lines |
|
|
|
|
|
// NOTE: Vertex must be provided in counter-clockwise order |
|
|
void DrawTriangleLines(Vector2 v1, Vector2 v2, Vector2 v3, Color color) |
|
|
void DrawTriangleLines(Vector2 v1, Vector2 v2, Vector2 v3, Color color) |
|
|
{ |
|
|
{ |
|
|
if (rlCheckBufferLimit(6)) rlglDraw(); |
|
|
if (rlCheckBufferLimit(6)) rlglDraw(); |
|
@ -1232,7 +1234,7 @@ void DrawTriangleLines(Vector2 v1, Vector2 v2, Vector2 v3, Color color) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Draw a triangle fan defined by points |
|
|
// Draw a triangle fan defined by points |
|
|
// NOTE: First point provided is shared by all triangles |
|
|
|
|
|
|
|
|
// NOTE: First vertex provided is the center, shared by all triangles |
|
|
void DrawTriangleFan(Vector2 *points, int pointsCount, Color color) |
|
|
void DrawTriangleFan(Vector2 *points, int pointsCount, Color color) |
|
|
{ |
|
|
{ |
|
|
if (pointsCount >= 3) |
|
|
if (pointsCount >= 3) |
|
@ -1263,7 +1265,7 @@ void DrawTriangleFan(Vector2 *points, int pointsCount, Color color) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// Draw a triangle strip defined by points |
|
|
// Draw a triangle strip defined by points |
|
|
// NOTE: Every new point connects with previous two |
|
|
|
|
|
|
|
|
// NOTE: Every new vertex connects with previous two |
|
|
void DrawTriangleStrip(Vector2 *points, int pointsCount, Color color) |
|
|
void DrawTriangleStrip(Vector2 *points, int pointsCount, Color color) |
|
|
{ |
|
|
{ |
|
|
if (pointsCount >= 3) |
|
|
if (pointsCount >= 3) |
|
|