| Summary: | After a fullscreen toggle and returning to windowed mode, exiting causes a fullscreen close | ||
|---|---|---|---|
| Product: | SDL | Reporter: | ashton.lockey |
| Component: | video | Assignee: | Sam Lantinga <slouken> |
| Status: | ASSIGNED --- | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | CC: | amaranth72 |
| Version: | HG 2.1 | ||
| Hardware: | x86_64 | ||
| OS: | Windows 7 | ||
| Attachments: | Fullscreen Toggle Code | ||
This bug is specific to Windows I think - I can't reproduce it in OS X, but someone else in Windows is having the same problem: https://bitbucket.org/rude/love/issue/835/ (LÖVE uses SDL 2.) |
Created attachment 1542 [details] Fullscreen Toggle Code I noticed this when I implemented a fullscreen toggle to my game engine using the SDL_SetWindowFullscreen() function. If you run SDL in windowed mode and exit the application everything goes fine, but if you toggle SDL_WINDOW_FULLSCREEN mode and then return to windowed mode and exit the application, the entire screen turns black as though it's exiting from a fullscreen context rather than a window before returning to the desktop. The same thing happens even if you initialize the window as fullscreen then toggling back to window mode and exiting. Additionally, if you exit while in fullscreen it seems to work fine but may be causing the same black screen resulting in the application taking longer to close but it's hard to tell. This doesn't happen with SDL_WINDOW_FULLSCREEN_DESKTOP mode toggling. ----- My OS is Windows 7 64bit and I am using an OpenGL 3.3 Core context. Occurs in both the latest SDL 2.0.1 (stable) and Mercurial builds with Visual Studio 2012 express. This also happens on both my NVIDIA Geforce 295 GTX and Geforce 780 TI graphics cards. I've attached the code I use to perform the window / fullscreen toggle.