changeset 35093:627492239a72

gl: Disable double-buffering on OS X, it does not work currently an probably has no benefit anyway.
author reimar
date Thu, 13 Sep 2012 21:45:14 +0000
parents cc8276116e95
children 967b0f13715c
files libvo/vo_gl.c
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_gl.c	Thu Sep 13 20:44:46 2012 +0000
+++ b/libvo/vo_gl.c	Thu Sep 13 21:45:14 2012 +0000
@@ -1370,6 +1370,14 @@
       // rare feature, not worth creating a window to detect
       use_ycbcr = 0;
     }
+    if (glctx.type == GLTYPE_OSX && vo_doublebuffering) {
+      // doublebuffering causes issues when e.g. drawing yuy2 textures
+      // (nothing is draw) unless using glfinish which makes things slow.
+      // This is possibly because we do not actually request a double-buffered
+      // context.
+      mp_msg(MSGT_VO, MSGL_INFO, "[gl] -double not supported on OSX, switching to -nodouble\n");
+      vo_doublebuffering = 0;
+    }
     if (many_fmts)
       mp_msg(MSGT_VO, MSGL_INFO, "[gl] using extended formats. "
                "Use -vo gl:nomanyfmts if playback fails.\n");