From 318162a229e8817c7f0e52159f25d1a9a5ad3204 Mon Sep 17 00:00:00 2001 From: Edward Rudd Date: Fri, 3 Jan 2014 12:33:44 -0500 Subject: [PATCH] fix screen grab crash when in fullscreen - read the FBO size NOT the screen size. --- src/graphics.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/graphics.cpp b/src/graphics.cpp index be293db..22236ff 100644 --- a/src/graphics.cpp +++ b/src/graphics.cpp @@ -521,7 +521,7 @@ struct GraphicsPrivate screen.getPP().bindLastBuffer(); - glReadPixels(0, 0, scSize.x, scSize.y, GL_RGBA, GL_UNSIGNED_BYTE, screenshot->pixels); + glReadPixels(0, 0, scRes.x, scRes.y, GL_RGBA, GL_UNSIGNED_BYTE, screenshot->pixels); IMG_SavePNG(screenshot, filename);