diff --git a/src/sdl/frontend.c b/src/sdl/frontend.c index 1f67926..1aa73b5 100644 --- a/src/sdl/frontend.c +++ b/src/sdl/frontend.c @@ -453,6 +453,16 @@ int main(int argc, char **argv) { window = renderer->get_window(); sdl_resize_window(0, false, false); +#ifdef _WIN32 + { + float dpi = 0.0f; + int display_index = SDL_GetWindowDisplayIndex(window); + if (display_index >= 0 && !SDL_GetDisplayDPI(display_index, &dpi, NULL, NULL)) { + sdl_resize_window((int) ceil(dpi / 96.0f), false, true); + } + } +#endif + SDL_zero(requested_audio_spec); requested_audio_spec.freq = 48000; requested_audio_spec.format = AUDIO_S16;