This is byte order dependent.
authorSam Lantinga <slouken@libsdl.org>
Sun, 12 Aug 2007 18:53:51 +0000
changeset 2236 741afd8402cf
parent 2235 55a8bebf9ba6
child 2237 e57a883ffa86
This is byte order dependent.
src/video/SDL_renderer_gl.c
--- a/src/video/SDL_renderer_gl.c	Sun Aug 12 18:44:49 2007 +0000
+++ b/src/video/SDL_renderer_gl.c	Sun Aug 12 18:53:51 2007 +0000
@@ -810,7 +810,9 @@
         if (texture->format == SDL_PIXELFORMAT_RGB888) {
             int i;
             Uint8 *p = (Uint8 *) texturedata->pixels;
+#if SDL_BYTEORDER == SDL_LIL_ENDIAN
             p += 3;
+#endif
             for (i = texture->h * pitch / 4; i--;) {
                 *p = 0xff;
                 p += 4;