Skip to content

Commit ec0b3d6

Browse files
authored
Added ChangeLog entry for GLFW Hi DPI support (emscripten-core#20862)
1 parent 559e0ef commit ec0b3d6

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

ChangeLog.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,15 @@ See docs/process.md for more on how version tagging works.
2525
ports of native GL renderers from later accidentally attempting to activate
2626
"dormant" features if web browser implementations gain new WebGL extensions in
2727
the future, which `*glGetProcAddress()` is not able to support. (#20802)
28+
- Added Hi DPI support to GLFW. When enabled, GLFW automatically accounts for the
29+
`devicePixelRatio` browser property and changes the size of the canvas accordingly
30+
(including dynamically if the canvas is moved from a 4k screen to a 2k screen and
31+
vice-versa). `glfwGetFramebufferSize` now properly returns the canvas size in pixels,
32+
while `glfwGetWindowSize` returns the canvas size is screen size. By default,
33+
this feature is disabled. You can enable it before creating a window by calling
34+
`glfwWindowHint(GLFW_SCALE_TO_MONITOR, GLFW_TRUE)`. You can also
35+
dynamically change it after the window has been created by calling
36+
`glfwSetWindowAttrib(window, GLFW_SCALE_TO_MONITOR, GLFW_TRUE)`. (#20584)
2837

2938
3.1.50 - 11/29/23
3039
-----------------

0 commit comments

Comments
 (0)