changeset 2236:741afd8402cf

This is byte order dependent.
author Sam Lantinga <slouken@libsdl.org>
date Sun, 12 Aug 2007 18:53:51 +0000
parents 55a8bebf9ba6
children e57a883ffa86
files src/video/SDL_renderer_gl.c
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- 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;