# HG changeset patch # User Sam Lantinga # Date 1033835276 0 # Node ID 9ff7e90aaa946824455c9fe884243f0538745c36 # Parent 7853b6af595784df65338a358a5f6329a64dafdf Fixed gamma correction in Atari video drivers (thanks Patrice!) diff -r 7853b6af5957 -r 9ff7e90aaa94 src/video/gem/SDL_gemvideo.c --- a/src/video/gem/SDL_gemvideo.c Sat Oct 05 16:27:29 2002 +0000 +++ b/src/video/gem/SDL_gemvideo.c Sat Oct 05 16:27:56 2002 +0000 @@ -600,7 +600,6 @@ Uint32 modeflags, screensize; SDL_bool use_shadow; - modeflags = SDL_HWPALETTE; GEM_FreeBuffers(this); /*--- Verify if asked mode can be used ---*/ @@ -659,6 +658,11 @@ } /*--- Initialize screen ---*/ + modeflags = 0; + if (VDI_bpp == 8) { + modeflags |= SDL_HWPALETTE; + } + if (flags & SDL_FULLSCREEN) { GEM_LockScreen(this); diff -r 7853b6af5957 -r 9ff7e90aaa94 src/video/xbios/SDL_xbios.c --- a/src/video/xbios/SDL_xbios.c Sat Oct 05 16:27:29 2002 +0000 +++ b/src/video/xbios/SDL_xbios.c Sat Oct 05 16:27:56 2002 +0000 @@ -454,7 +454,7 @@ return(NULL); } - modeflags = (SDL_FULLSCREEN|SDL_HWPALETTE); + modeflags = SDL_FULLSCREEN; /* Allocate needed buffers: simple/double buffer and shadow surface */ new_video_mode = XBIOS_videomodes[bpp][mode]; @@ -475,7 +475,7 @@ } else { Atari_C2pConvert = Atari_C2pConvert8; } - modeflags |= SDL_SWSURFACE; + modeflags |= SDL_SWSURFACE|SDL_HWPALETTE; } else { modeflags |= SDL_HWSURFACE; }