]> git.sesse.net Git - vlc/commitdiff
glx: make context current before setting swap interval (fixes #8738)
authorRémi Denis-Courmont <remi@remlab.net>
Thu, 30 May 2013 15:42:53 +0000 (18:42 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Tue, 4 Jun 2013 17:55:06 +0000 (20:55 +0300)
modules/video_output/glx.c

index e62014f1e36c14331352fec0ac909ef8f04aac51..a1ff22d12e5db6c079f8c2921be160df28859265 100644 (file)
@@ -196,6 +196,8 @@ static int Open (vlc_object_t *obj)
 
 #ifdef GLX_ARB_get_proc_address
     bool is_swap_interval_set = false;
+
+    MakeCurrent (gl);
 # ifdef GLX_SGI_swap_control
     if (!is_swap_interval_set
      && CheckGLXext (dpy, snum, "GLX_SGI_swap_control"))
@@ -217,6 +219,7 @@ static int Open (vlc_object_t *obj)
         is_swap_interval_set = true;
     }
 # endif
+    ReleaseCurrent (gl);
 #endif
 
     return VLC_SUCCESS;