More Windows hackery.
authorCarl Hetherington <cth@carlh.net>
Mon, 3 Jun 2019 22:48:29 +0000 (23:48 +0100)
committerCarl Hetherington <cth@carlh.net>
Mon, 3 Jun 2019 22:48:29 +0000 (23:48 +0100)
src/wx/gl_video_view.cc

index 0e8e459d87b66cc0695f60ae85ef07c98226c0ea..c0c71e965df76819cedd495b9a62956c8cc6e92a 100644 (file)
@@ -70,8 +70,11 @@ GLVideoView::GLVideoView (FilmViewer* viewer, wxWindow *parent)
 #ifdef DCPOMATIC_WINDOWS
        if (_canvas->IsExtensionSupported("WGL_EXT_swap_control")) {
                /* Enable vsync */
-               wglSwapIntervalEXT (1);
-               _vsync_enabled = true;
+               PFNWGLSWAPINTERVALEXTPROC swap = (PFNWGLSWAPINTERVALEXTPROC) wglGetProceAddress("wglSwapIntervalEXT");
+               if (swap) {
+                       swap (1);
+                       _vsync_enabled = true;
+               }
        }
 
 #endif