diff src/video/SDL_renderer_gl.c @ 2808:368410632f2d

Whoops, we need this for subrect updates (testsprite)
author Sam Lantinga <slouken@libsdl.org>
date Sat, 29 Nov 2008 15:32:14 +0000
parents 7af8c4ad427e
children 7e257c3a3bf0
line wrap: on
line diff
--- a/src/video/SDL_renderer_gl.c	Sat Nov 29 11:26:01 2008 +0000
+++ b/src/video/SDL_renderer_gl.c	Sat Nov 29 15:32:14 2008 +0000
@@ -689,6 +689,8 @@
         renderdata->glPixelStorei(GL_UNPACK_LSB_FIRST, 0);
     }
     renderdata->glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
+    renderdata->glPixelStorei(GL_UNPACK_ROW_LENGTH,
+                              pitch / SDL_BYTESPERPIXEL(texture->format));
 }
 
 static int