[Scummvm-git-logs] scummvm master -> a1d930209a6452649ab704dbbcf2084c9177936e
criezy
criezy at scummvm.org
Sun Oct 4 20:11:58 UTC 2020
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
a1d930209a SDL: Prefer OpenGL over Metal rendering on macOS
Commit: a1d930209a6452649ab704dbbcf2084c9177936e
https://github.com/scummvm/scummvm/commit/a1d930209a6452649ab704dbbcf2084c9177936e
Author: Donovan Watteau (contrib at dwatteau.fr)
Date: 2020-10-04T21:11:54+01:00
Commit Message:
SDL: Prefer OpenGL over Metal rendering on macOS
SDL 2.0.10 and above favors Metal over OpenGL rendering on macOS, but
this currently causes blurriness issues on Retina displays.
Going back to OpenGL rendering works around this bug for now.
Users can override this with the SDL_RENDER_DRIVER environment variable.
c59bf95ba85b25b1 and 70f79d3df8b4a9d4 are still a requirement to
work around this bug, too.
Bug #11430.
Changed paths:
backends/graphics/surfacesdl/surfacesdl-graphics.cpp
diff --git a/backends/graphics/surfacesdl/surfacesdl-graphics.cpp b/backends/graphics/surfacesdl/surfacesdl-graphics.cpp
index 2ba3cb4e5a..55921767fc 100644
--- a/backends/graphics/surfacesdl/surfacesdl-graphics.cpp
+++ b/backends/graphics/surfacesdl/surfacesdl-graphics.cpp
@@ -2635,6 +2635,14 @@ SDL_Surface *SurfaceSdlGraphicsManager::SDL_SetVideoMode(int width, int height,
return nullptr;
}
+#if defined(MACOSX) && SDL_VERSION_ATLEAST(2, 0, 10)
+ // WORKAROUND: Bug #11430: "macOS: blurry content on Retina displays"
+ // Since SDL 2.0.10, Metal takes priority over OpenGL rendering on macOS,
+ // but this causes blurriness issues on Retina displays. Just switch
+ // back to OpenGL for now.
+ SDL_SetHint(SDL_HINT_RENDER_DRIVER, "opengl");
+#endif
+
_renderer = SDL_CreateRenderer(_window->getSDLWindow(), -1, 0);
if (!_renderer) {
deinitializeRenderer();
More information about the Scummvm-git-logs
mailing list