diff options
Diffstat (limited to 'backends/graphics/surfacesdl/surfacesdl-graphics.cpp')
-rw-r--r-- | backends/graphics/surfacesdl/surfacesdl-graphics.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/backends/graphics/surfacesdl/surfacesdl-graphics.cpp b/backends/graphics/surfacesdl/surfacesdl-graphics.cpp index 052ae37b9a..3b2e3eaf6f 100644 --- a/backends/graphics/surfacesdl/surfacesdl-graphics.cpp +++ b/backends/graphics/surfacesdl/surfacesdl-graphics.cpp @@ -1021,7 +1021,7 @@ bool SurfaceSdlGraphicsManager::loadGFXMode() { } #if !SDL_VERSION_ATLEAST(2, 0, 0) - handleResize(_videoMode.hardwareWidth, _videoMode.hardwareHeight); + handleResize(_videoMode.hardwareWidth, _videoMode.hardwareHeight, 90, 90); #endif // @@ -2507,8 +2507,8 @@ void SurfaceSdlGraphicsManager::drawOSD() { #endif -void SurfaceSdlGraphicsManager::handleResizeImpl(const int width, const int height) { - SdlGraphicsManager::handleResizeImpl(width, height); +void SurfaceSdlGraphicsManager::handleResizeImpl(const int width, const int height, const int xdpi, const int ydpi) { + SdlGraphicsManager::handleResizeImpl(width, height, xdpi, ydpi); recalculateDisplayAreas(); } @@ -2715,7 +2715,7 @@ void SurfaceSdlGraphicsManager::notifyVideoExpose() { void SurfaceSdlGraphicsManager::notifyResize(const int width, const int height) { #if SDL_VERSION_ATLEAST(2, 0, 0) - handleResize(width, height); + handleResize(width, height, _xdpi, _ydpi); #endif } @@ -2762,8 +2762,9 @@ SDL_Surface *SurfaceSdlGraphicsManager::SDL_SetVideoMode(int width, int height, return nullptr; } + // TODO: Implement high DPI support getWindowSizeFromSdl(&_windowWidth, &_windowHeight); - handleResize(_windowWidth, _windowHeight); + handleResize(_windowWidth, _windowHeight, 90, 90); SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, _videoMode.filtering ? "linear" : "nearest"); |