| Summary: | SDL_RenderFillRect (and others) broken on OS X full screen retina | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Oliver Collyer <ovcollyer> |
| Component: | render | Assignee: | Alex Szpakowski <amaranth72> |
| Status: | WAITING --- | QA Contact: | Sam Lantinga <slouken> |
| Severity: | blocker | ||
| Priority: | P2 | ||
| Version: | 2.0.5 | ||
| Hardware: | x86_64 | ||
| OS: | macOS 10.12 | ||
| Attachments: | Test project | ||
Ok, just an update. I painstakingly narrowed it down to these two changelists: https://hg.libsdl.org/SDL/rev/553e9f7cd10e (15th June 2014) https://hg.libsdl.org/SDL/rev/413b222c4b64 (26th May 2015) If you revert *both* of these changes in SDL2-2.0.5 source then the bug goes away. Or revert the whole of the code to a snapshot prior to 15th June 2014 (SDL2-2.0.3 era). I hope that is enough of a hint to whoever is knowledgeable in this area to be able to come up with a fix sometime. That's not the end of it though, unfortunately as I've found additional issues with (proper) full screen retina that makes it unusable, but I'll open another bug about that. I know there is a sort of workaround for all of this by using SDL_DESKTOP_FULLSCREEN but the problem with that is you cannot control the refresh rate and in my use-case (a video player) I would like to be able to match the refresh rate to the video framerate for optimum smoothness. Alex, can you look at this regression for the SDL 2.0.6 release? |
Created attachment 2698 [details] Test project Build and run the attached project and it will switch to full screen retina mode. The background will cycle slowly through the primary colours. There is supposed to be a small black rectangle drawn on the screen at position (100,100) but this is not visible. However, if you remove SDL_WINDOW_ALLOW_HIGH_DPI from the create window call you should see that the black rectangle is then drawn correctly. The issue only occurs in SDL_WINDOW_FULLSCREEN mode. SDL_RenderFillRect is just one example of a render call not working - my entire app doesn't work due to this bug, I just created this test project to illustrate it as simply as possible. I've reproduced this on separate MacBook Pros so it's not my machine. I don't have a non-Sierra Mac to try though, so can't comment on whether it is OS-specific. I've only tried it on SDL 2.0.5.