summaryrefslogtreecommitdiff
path: root/src/skel/glfw
diff options
context:
space:
mode:
authorGreg V <greg@unrelenting.technology>2020-09-28 04:50:57 +0300
committererorcun <erorcunerorcun@hotmail.com.tr>2020-11-18 17:09:10 +0300
commitd05c50ea743f42bc9c426b7b6c2f9598b8bc7f94 (patch)
treefce2cada383dcd6ce92cfb55da6b80197118f477 /src/skel/glfw
parent8963cbcb7cd507485064c44e9f9e226c958d34b6 (diff)
Use glfwSetFramebufferSizeCallback instead of glfwSetWindowSizeCallback
Framebuffer size is scaled by the display scale. This fixes the game being shrunk to the bottom left quarter of the window on Wayland HiDPI setups. Corresponding change in librw: glfwGetWindowSize -> glfwGetFramebufferSize.
Diffstat (limited to 'src/skel/glfw')
-rw-r--r--src/skel/glfw/glfw.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/skel/glfw/glfw.cpp b/src/skel/glfw/glfw.cpp
index 26a3a509..73d6fb05 100644
--- a/src/skel/glfw/glfw.cpp
+++ b/src/skel/glfw/glfw.cpp
@@ -917,7 +917,7 @@ void psPostRWinit(void)
RwEngineGetVideoModeInfo(&vm, GcurSelVM);
glfwSetKeyCallback(PSGLOBAL(window), keypressCB);
- glfwSetWindowSizeCallback(PSGLOBAL(window), resizeCB);
+ glfwSetFramebufferSizeCallback(PSGLOBAL(window), resizeCB);
glfwSetScrollCallback(PSGLOBAL(window), scrollCB);
glfwSetCursorPosCallback(PSGLOBAL(window), cursorCB);
glfwSetCursorEnterCallback(PSGLOBAL(window), cursorEnterCB);