Mercurial > sdl-ios-xcode
comparison src/video/gem/SDL_gemvideo.c @ 988:24b5c3ad4852
Remove ambiguous/useless code
author | Patrice Mandin <patmandin@gmail.com> |
---|---|
date | Mon, 22 Nov 2004 20:37:41 +0000 |
parents | 952ec1ddcb58 |
children | 475166d13b44 |
comparison
equal
deleted
inserted
replaced
987:d9f3b5bb7870 | 988:24b5c3ad4852 |
---|---|
758 current->pitch = VDI_pitch; | 758 current->pitch = VDI_pitch; |
759 } | 759 } |
760 | 760 |
761 #ifdef HAVE_OPENGL | 761 #ifdef HAVE_OPENGL |
762 if (flags & SDL_OPENGL) { | 762 if (flags & SDL_OPENGL) { |
763 int conversion_needed = 0; | |
764 GLenum format = OSMESA_COLOR_INDEX; /* 8 bits */ | 763 GLenum format = OSMESA_COLOR_INDEX; /* 8 bits */ |
765 | 764 |
766 /* Init OpenGL context using OSMesa */ | 765 /* Init OpenGL context using OSMesa */ |
767 GEM_GL_Convert = GEM_GL_ConvertNull; | 766 GEM_GL_Convert = GEM_GL_ConvertNull; |
768 switch (VDI_bpp) { | 767 switch (VDI_bpp) { |
1511 line = surface->pixels; | 1510 line = surface->pixels; |
1512 pitch = surface->pitch >>1; | 1511 pitch = surface->pitch >>1; |
1513 for (y=0; y<surface->h; y++) { | 1512 for (y=0; y<surface->h; y++) { |
1514 pixel = line; | 1513 pixel = line; |
1515 for (x=0; x<surface->w; x++) { | 1514 for (x=0; x<surface->w; x++) { |
1516 *pixel++ = SDL_Swap16(*pixel); | 1515 unsigned short color = *pixel; |
1516 | |
1517 *pixel++ = SDL_Swap16(color); | |
1517 } | 1518 } |
1518 | 1519 |
1519 line += pitch; | 1520 line += pitch; |
1520 } | 1521 } |
1521 } | 1522 } |