changeset 26622:dacfbcaa91c2

Fix 100l: mpi->height must be used to calculate required memory, not mpi->h.
author reimar
date Sat, 03 May 2008 14:11:19 +0000
parents 853fce906154
children 61f2d6d20c6e
files libvo/vo_gl.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/vo_gl.c	Sat May 03 14:11:08 2008 +0000
+++ b/libvo/vo_gl.c	Sat May 03 14:11:19 2008 +0000
@@ -675,10 +675,10 @@
     GenBuffers(1, &gl_buffer);
   BindBuffer(GL_PIXEL_UNPACK_BUFFER, gl_buffer);
   mpi->stride[0] = mpi->width * mpi->bpp / 8;
-  if (mpi->stride[0] * mpi->h > gl_buffersize) {
-    BufferData(GL_PIXEL_UNPACK_BUFFER, mpi->stride[0] * mpi->h,
+  if (mpi->stride[0] * mpi->height > gl_buffersize) {
+    BufferData(GL_PIXEL_UNPACK_BUFFER, mpi->stride[0] * mpi->height,
                NULL, GL_DYNAMIC_DRAW);
-    gl_buffersize = mpi->stride[0] * mpi->h;
+    gl_buffersize = mpi->stride[0] * mpi->height;
   }
   if (!gl_bufferptr)
     gl_bufferptr = MapBuffer(GL_PIXEL_UNPACK_BUFFER, GL_WRITE_ONLY);