mirror of
https://github.com/glfw/glfw.git
synced 2026-09-20 16:30:45 +00:00
Use DwmFlush when DWM is enabled.
Use DwmFlush instead of WGL_EXT_swap_control when desktop compositing is enabled, to avoid the jitter of DWM and WGL vsync fighting. Fixes #516.
This commit is contained in:
@@ -96,6 +96,8 @@ static GLboolean initLibraries(void)
|
||||
{
|
||||
_glfw.win32.dwmapi.DwmIsCompositionEnabled = (DWMISCOMPOSITIONENABLED_T)
|
||||
GetProcAddress(_glfw.win32.dwmapi.instance, "DwmIsCompositionEnabled");
|
||||
_glfw.win32.dwmapi.DwmFlush = (DWMFLUSH_T)
|
||||
GetProcAddress(_glfw.win32.dwmapi.instance, "DwmFlush");
|
||||
}
|
||||
|
||||
return GL_TRUE;
|
||||
|
||||
Reference in New Issue
Block a user