[Scummvm-git-logs] scummvm master -> 397ea454baa25523d2ff9ee070172974ac4eea83
rsn8887
rsn8887 at users.noreply.github.com
Thu Feb 18 04:58:58 UTC 2021
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:
397ea454ba SWITCH: Fix wrong zoom on SDL to GL transition
Commit: 397ea454baa25523d2ff9ee070172974ac4eea83
https://github.com/scummvm/scummvm/commit/397ea454baa25523d2ff9ee070172974ac4eea83
Author: rsn8887 (rsn8887 at users.noreply.github.com)
Date: 2021-02-17T22:58:09-06:00
Commit Message:
SWITCH: Fix wrong zoom on SDL to GL transition
Changed paths:
backends/graphics/openglsdl/openglsdl-graphics.cpp
diff --git a/backends/graphics/openglsdl/openglsdl-graphics.cpp b/backends/graphics/openglsdl/openglsdl-graphics.cpp
index 6ae9529ce0..f2c3fd6363 100644
--- a/backends/graphics/openglsdl/openglsdl-graphics.cpp
+++ b/backends/graphics/openglsdl/openglsdl-graphics.cpp
@@ -140,6 +140,11 @@ OpenGLSdlGraphicsManager::OpenGLSdlGraphicsManager(SdlEventSource *eventSource,
// Retrieve a list of working fullscreen modes
#if SDL_VERSION_ATLEAST(2, 0, 0)
+#ifdef NINTENDO_SWITCH
+ // Switch quirk: hardware has built-in 720p screen, but SDL reports 1080p
+ // TODO: Implement dynamic switching to 1080p on handheld->docked transition
+ _fullscreenVideoModes.push_back(VideoMode(1280, 720));
+#else
const int numModes = SDL_GetNumDisplayModes(0);
for (int i = 0; i < numModes; ++i) {
SDL_DisplayMode mode;
@@ -149,6 +154,7 @@ OpenGLSdlGraphicsManager::OpenGLSdlGraphicsManager(SdlEventSource *eventSource,
_fullscreenVideoModes.push_back(VideoMode(mode.w, mode.h));
}
+#endif
#else
const SDL_Rect *const *availableModes = SDL_ListModes(NULL, SDL_OPENGL | SDL_FULLSCREEN);
// TODO: NULL means that there are no fullscreen modes supported. We
More information about the Scummvm-git-logs
mailing list