diff options
Diffstat (limited to 'backends/graphics/openglsdl/openglsdl-graphics.cpp')
-rw-r--r-- | backends/graphics/openglsdl/openglsdl-graphics.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/backends/graphics/openglsdl/openglsdl-graphics.cpp b/backends/graphics/openglsdl/openglsdl-graphics.cpp index dddf73f3f8..2cfdffa5ac 100644 --- a/backends/graphics/openglsdl/openglsdl-graphics.cpp +++ b/backends/graphics/openglsdl/openglsdl-graphics.cpp @@ -333,9 +333,9 @@ bool OpenGLSdlGraphicsManager::loadGFXMode() { // Do not downscale dimensions, only enlarge them if needed if (screenAspectRatio > desiredAspectRatio) - _videoMode.hardwareHeight = _videoMode.overlayWidth * 10000 / desiredAspectRatio; + _videoMode.hardwareHeight = (_videoMode.overlayWidth * 10000 + 5000) / desiredAspectRatio; else if (screenAspectRatio < desiredAspectRatio) - _videoMode.hardwareWidth = _videoMode.overlayHeight * desiredAspectRatio / 10000; + _videoMode.hardwareWidth = (_videoMode.overlayHeight * desiredAspectRatio + 5000) / 10000; // Only adjust the overlay height if it is bigger than original one. If // the width is modified it can break the overlay. |