Explorar o código

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.
Alexander Orzechowski %!s(int64=3) %!d(string=hai) anos
pai
achega
5754456292
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/yuzu_cmd/emu_window/emu_window_sdl2.cpp

+ 1 - 1
src/yuzu_cmd/emu_window/emu_window_sdl2.cpp

@@ -115,7 +115,7 @@ bool EmuWindow_SDL2::IsShown() const {
 
 
 void EmuWindow_SDL2::OnResize() {
 void EmuWindow_SDL2::OnResize() {
     int width, height;
     int width, height;
-    SDL_GetWindowSize(render_window, &width, &height);
+    SDL_GL_GetDrawableSize(render_window, &width, &height);
     UpdateCurrentFramebufferLayout(width, height);
     UpdateCurrentFramebufferLayout(width, height);
 }
 }