mirror of
https://github.com/glfw/glfw.git
synced 2026-09-21 16:44:11 +00:00
Added forcing of swap interval on DWM composition.
This commit is contained in:
@@ -600,12 +600,14 @@ void _glfwPlatformSwapInterval(int interval)
|
||||
{
|
||||
_GLFWwindow* window = _glfwPlatformGetCurrentContext();
|
||||
|
||||
#if !defined(_GLFW_USE_DWM_SWAP_INTERVAL)
|
||||
if (_glfwIsCompositionEnabled())
|
||||
{
|
||||
// Don't enabled vsync when desktop compositing is enabled, as it leads
|
||||
// to frame jitter
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (window->wgl.EXT_swap_control)
|
||||
window->wgl.SwapIntervalEXT(interval);
|
||||
|
||||
Reference in New Issue
Block a user