Hi all. Please bare with me here…
My monitor is set to 1920 x 1080. Fonts are too small to read. The only way I can find to enlarge everything so it’s big enough to see without my nose pressed against the display is to use Windows 10’s scale open and set it to 150%. It works as expected and I can now read text and see icons clearly.
Now here is a very weird thing. When this scale option is used, SDL_GetDesktopDisplayMode() is giving me 1280 x 720, which is a lie. I can see the display is set to native 1920 x 1080, and I can tell when it’s actually 1280 x 720 because everything’s more blurry. If I turn the scale down to 125%, then the reported desktop resolution is 1536 x 864. It seems as though Windows 10 is lying to apps to get them to scale fonts and everything. So, SDL is working correctly here. If I create a window of size 1280 x 720 when my display is set to 1920 x 1080, it is stretched to the size of the screen. This must have something to do with virtual desktop size.
My question is this: How can I bypass this behaviour and get the actual current screen mode, and not the Windows 10 desktop size after it’s lying to scale everything? The answer isn’t SDL_GetCurrentDisplayMode(), as that reports exactly the same.