diff options
Diffstat (limited to 'src/resources/openglscreenshothelper.cpp')
-rw-r--r-- | src/resources/openglscreenshothelper.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/resources/openglscreenshothelper.cpp b/src/resources/openglscreenshothelper.cpp index b0d21e81c..975b6bd35 100644 --- a/src/resources/openglscreenshothelper.cpp +++ b/src/resources/openglscreenshothelper.cpp @@ -49,15 +49,17 @@ OpenGLScreenshotHelper::~OpenGLScreenshotHelper() void OpenGLScreenshotHelper::prepare() { if (config.getBoolValue("usefbo")) - graphicsManager.createFBO(mainGraphics->mWidth, - mainGraphics->mHeight, - &mFbo); + graphicsManager.createFBO(mainGraphics->mActualWidth, + mainGraphics->mActualHeight, + &mFbo); } SDL_Surface *OpenGLScreenshotHelper::getScreenshot() { - const int h = mainGraphics->mHeight; - const int w = mainGraphics->mWidth - (mainGraphics->mWidth % 4); + const int h = mainGraphics->mActualHeight; + const int w = mainGraphics->mActualWidth + -(mainGraphics->mActualWidth % 4); + GLint pack = 1; SDL_Surface *const screenshot = MSDL_CreateRGBSurface( |