From cdbe1b6190d71b1db4c9d3b31d952c897f188622 Mon Sep 17 00:00:00 2001 From: raysan5 Date: Thu, 21 May 2020 18:57:45 +0200 Subject: [PATCH] Review buffer limits on rectangle drawing --- src/shapes.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/shapes.c b/src/shapes.c index 66e0f55ce..ed1324810 100644 --- a/src/shapes.c +++ b/src/shapes.c @@ -618,6 +618,8 @@ void DrawRectangleRec(Rectangle rec, Color color) // Draw a color-filled rectangle with pro parameters void DrawRectanglePro(Rectangle rec, Vector2 origin, float rotation, Color color) { + if (rlCheckBufferLimit(4)) rlglDraw(); + rlEnableTexture(GetShapesTexture().id); rlPushMatrix();