summaryrefslogtreecommitdiffstats
path: root/libvo/vo_gl.c
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-06-05 11:45:33 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-06-05 11:45:33 +0000
commitfbae2ba72b4d0b34c69d71e98208acd04c639fb5 (patch)
tree517a2a125163990508d98bf07b1b4a5f0ca86c4c /libvo/vo_gl.c
parenta0a494e6f2388c90567c437e9c09366ca95eafb0 (diff)
downloadmpv-fbae2ba72b4d0b34c69d71e98208acd04c639fb5.tar.bz2
mpv-fbae2ba72b4d0b34c69d71e98208acd04c639fb5.tar.xz
Move/add checks to avoid crashes and make error messages less confusing
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18580 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo/vo_gl.c')
-rw-r--r--libvo/vo_gl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libvo/vo_gl.c b/libvo/vo_gl.c
index d026d9deb7..bcb65737b0 100644
--- a/libvo/vo_gl.c
+++ b/libvo/vo_gl.c
@@ -274,6 +274,10 @@ static int initGl(uint32_t d_width, uint32_t d_height) {
glBindTexture(GL_TEXTURE_2D, lookupTex);
case YUV_CONVERSION_FRAGMENT_POW:
case YUV_CONVERSION_FRAGMENT:
+ if (!GenPrograms || !BindProgram) {
+ mp_msg(MSGT_VO, MSGL_ERR, "[gl] fragment program functions missing!\n");
+ break;
+ }
GenPrograms(1, &fragprog);
BindProgram(GL_FRAGMENT_PROGRAM, fragprog);
break;