sdl: Directly use Windows DPI scaling hint, not SDL (#2730)

Co-authored-by: ManDude <7569514+ManDude@users.noreply.github.com>
This commit is contained in:
BreakPoints 2023-06-17 17:40:25 +01:00 committed by GitHub
parent d8cca2bf83
commit 1512c6bd9c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,8 +7,10 @@
DisplayManager::DisplayManager(SDL_Window* window)
: m_window(window), m_selected_fullscreen_display_id(0) {
// SDL hint to disable OS level forced scaling and allow native resolution at non 100% scales
SDL_SetHint("SDL_WINDOWS_DPI_SCALING", "true");
#ifdef _WIN32
// Windows hint to disable OS level forced scaling and allow native resolution at non 100% scales
SetProcessDPIAware();
#endif
update_curr_display_info();
update_video_modes();
// Load display settings from a file