changeset 29680:57ed11e0d3ce

Print error instead of crashing when mesa-buffer is used on systems that do not support it.
author reimar
date Sun, 27 Sep 2009 14:31:35 +0000
parents 465247b46e39
children 8b35d8f6b063
files libvo/vo_gl.c
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_gl.c	Sun Sep 27 14:24:15 2009 +0000
+++ b/libvo/vo_gl.c	Sun Sep 27 14:31:35 2009 +0000
@@ -571,6 +571,10 @@
     uninitGl();
   if (setGlWindow(&gl_vinfo, &gl_context, vo_window) == SET_WINDOW_FAILED)
     return -1;
+  if (mesa_buffer && !AllocateMemoryMESA) {
+    mp_msg(MSGT_VO, MSGL_ERR, "Can not enable mesa-buffer because AllocateMemoryMESA was not found\n");
+    mesa_buffer = 0;
+  }
   initGl(vo_dwidth, vo_dheight);
 
   return 0;