Parcourir la source

Fix wrong height used when using scissor mode with render texture of different height from window (#1272)

Chang Si Yuan il y a 5 ans
Parent
commit
6264c4901b
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      src/core.c

+ 1 - 1
src/core.c

@@ -1536,7 +1536,7 @@ void BeginScissorMode(int x, int y, int width, int height)
     rlglDraw(); // Force drawing elements
 
     rlEnableScissorTest();
-    rlScissor(x, GetScreenHeight() - (y + height), width, height);
+    rlScissor(x, CORE.Window.currentFbo.height - (y + height), width, height);
 }
 
 // End scissor mode