]> git.sesse.net Git - vlc/commitdiff
* use locking on the OpenGL context (using two APIs, but since agl needs the cgl...
authorDerk-Jan Hartman <hartman@videolan.org>
Thu, 8 Mar 2007 02:24:59 +0000 (02:24 +0000)
committerDerk-Jan Hartman <hartman@videolan.org>
Thu, 8 Mar 2007 02:24:59 +0000 (02:24 +0000)
  refs #668
  refs #915

  I'm not sure its fixed, but this seems like a logical way to solve it. Freaking apple with their 5 OpenGL APIs.

modules/gui/macosx/voutgl.m

index da718ff2255624a969cc2304b3d8505352ad08b4..c4830f42e3efcdcc85ff8f626f8d297d7e71b7e0 100644 (file)
@@ -289,11 +289,13 @@ static void Swap( vout_thread_t * p_vout )
 static int Lock( vout_thread_t * p_vout )
 {
     vlc_mutex_lock( &p_vout->p_sys->lock );
+    CGLLockContext( (CGLContextObj)p_vout->p_sys->agl_ctx );
     return 0;
 }
 
 static void Unlock( vout_thread_t * p_vout )
 {
+    CGLUnlockContext( (CGLContextObj)p_vout->p_sys->agl_ctx );
     vlc_mutex_unlock( &p_vout->p_sys->lock );
 }