emu_window_sdl2: Respect hidpi

Use SDL_GL_GetDrawableSize instead of SDL_GetWindowSize which
will return the true size our swapchain needs to be in even
for hidpi displays.
This commit is contained in:
Alexander Orzechowski 2023-04-03 14:34:45 +03:00 committed by GPUCode
parent 06c426883f
commit aac0e07d1e

View file

@ -84,7 +84,7 @@ void EmuWindow_SDL2::RequestClose() {
void EmuWindow_SDL2::OnResize() {
int width, height;
SDL_GetWindowSize(render_window, &width, &height);
SDL_GL_GetDrawableSize(render_window, &width, &height);
UpdateCurrentFramebufferLayout(width, height);
}