Opened 6 years ago
Closed 6 years ago
Last modified 6 years ago
#9971 closed defect (fixed)
SDL2: Fullscreen to RTL launcher resolution
|Reported by:||tsoliman||Owned by:||criezy|
|Version:||Keywords:||osx, sdl2, rtl, macos, launcher|
macOS 10.12.5 rMBP mid 2015
- make sure the launcher is windowed by default (fullscreen=false in the config)
- from the launcher, launch a game that forces scaling off and results in a window that doesn't match the launcher size (more on that below)
- alt-enter to go to fullscreen while the game is running (this is important)
- use GMM to return to launcher
- watch as launcher goes back to windowed mode in the wrong size - usually by keeping the game's size
How the launcher is messed up depends on the the values of gfx_mode and aspect_ratio and the difference between the game's locked resolution and the launcher's resolution.
This can be reproduced with games like sq6/torin/lsl6/comi unless aspect_ratio=true and gfx_mode=2x. This is because this combination puts the launcher into a matching resolution as those games are locked to (640x480).
Just make sure the game's locked resolution is different than the initial launcher by either aspect_ratio=false or gfx_mode=3x .. or picking a game that doesn't lock to 640x480 (hires adventures are great for this)
Change History (10)
comment:1 by , 6 years ago
comment:2 by , 6 years ago
comment:3 by , 6 years ago
comment:4 by , 6 years ago
ignore my last 3 comments - I cannot delete them
comment:5 by , 6 years ago
This doesn't seem to happen in Linux (Tested in a linux VM)
EDIT: The linux was running SDL 2.0.2 which changes behavior. I will retest with SDL 2.0.5
comment:6 by , 6 years ago
Unless I missed something in your explanation, I can't reproduce it on macOS either. Here is what I did:
- I set my launcher to windowed 3x mode with aspect ratio correction. The launcher was at resolution 720x960.
- I started Broken Sword 2. It changed to 640x480 window.
- I used Alt+Enter to switch to full-screen.
- I then returned to the launcher using the GMM.
This resulted in the launcher going back to windowed mode in its previous size (720x960).
Self compiled (a279253)
macOS 10.9.5, iMac late 2013
comment:7 by , 6 years ago
Forget my previous comment; I can actually reproduce it with the exact same steps above after a full recompilation using 87d32c2. And now I also reproduce it with a27925...
comment:8 by , 6 years ago
I've tested this in a Linux VM with SDL 2.0.5 (Debian Stretch 64-bit) . It doesn't happen.
comment:9 by , 6 years ago
|Status:||new → closed|
This is fixed by commit 00bbb73.
comment:10 by , 6 years ago
I took a look at this since the current fix makes the window go back to the top left corner of the screen when exiting fullscreen on Linux/X11.
It looks like a macOS specific SDL2 bug to me. I've opened a bug report upstream:
I'll #ifdef the call to SDL_SetWindowSize added in commit 00bbb73 so that it is for macOS only.
*redacted - don't ask*