summaryrefslogtreecommitdiffstats
path: root/libvo
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2005-08-16 18:27:12 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2005-08-16 18:27:12 +0000
commit7e6c29c530b3298ce3d0f682a5ae536f1f449b83 (patch)
treec0eb88a885c49bda9d96195ea6531cf42381b1ed /libvo
parent085b6f59fad8631cd9595a75bbb711f53a79cd20 (diff)
downloadmpv-7e6c29c530b3298ce3d0f682a5ae536f1f449b83.tar.bz2
mpv-7e6c29c530b3298ce3d0f682a5ae536f1f449b83.tar.xz
Make glFinish optional
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@16236 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r--libvo/vo_gl.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libvo/vo_gl.c b/libvo/vo_gl.c
index d413a48d20..dab44216ab 100644
--- a/libvo/vo_gl.c
+++ b/libvo/vo_gl.c
@@ -61,6 +61,7 @@ static int err_shown;
static uint32_t image_width;
static uint32_t image_height;
static int many_fmts;
+static int use_glFinish;
static GLenum gl_target;
static GLenum gl_texfmt;
static GLenum gl_format;
@@ -403,6 +404,7 @@ flip_page(void)
}
// glFlush();
+ if (use_glFinish)
glFinish();
#ifdef GL_WIN32
SwapBuffers(vo_hdc);
@@ -513,6 +515,7 @@ static opt_t subopts[] = {
{"aspect", OPT_ARG_BOOL, &use_aspect, NULL},
{"slice-height", OPT_ARG_INT, &slice_height, (opt_test_f)int_non_neg},
{"rectangle", OPT_ARG_INT, &use_rectangle,(opt_test_f)int_non_neg},
+ {"glfinish", OPT_ARG_BOOL, &use_glFinish, NULL},
{NULL}
};
@@ -524,6 +527,7 @@ static int preinit(const char *arg)
scaled_osd = 0;
use_aspect = 1;
use_rectangle = 0;
+ use_glFinish = 0;
slice_height = 4;
if (subopt_parse(arg, subopts) != 0) {
mp_msg(MSGT_VO, MSGL_FATAL,
@@ -542,6 +546,8 @@ static int preinit(const char *arg)
" 0: use power-of-two textures\n"
" 1: use texture_rectangle\n"
" 2: use texture_non_power_of_two\n"
+ " glfinish\n"
+ " Call glFinish() before swapping buffers\n"
"\n" );
return -1;
}