I recently began learning SDL and OpenGL, and I am trying to make a function to toggle fullscreen correctly.
I have tried to initialize my window with SDL_WINDOW_ALLOW_HIGHDPI, but it doesn’t work…
The forum only allows me to upload one picture, So I have to make them all in one picture…sorry
Sorry for my English…
obeah
August 5, 2022, 1:50am
#2
I assume you’re using visual studio? Go to your project properties, Manifest Tool>Input and Output>DPI Awareness>High DPI Aware. That’s how I do it anyways, I haven’t tried the SDL way to do it.
I think I have found a temporary but simple solution for now.
auto dpi = SetProcessDPIAware();
Yes, it is about the DPI things, and this code can disable the DPI scaling of windows…
Put this code before the main()
function and it seems like this win32api old code will do the same things as setting the Manifest manually…
Windows’ old pieces of stuff are really ugly…