Commit dcfed1dc authored by Patrice Mandin's avatar Patrice Mandin

4bits screen also has hardware palette

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401086
parent d2b5ec92
...@@ -537,7 +537,7 @@ static SDL_Surface *XBIOS_SetVideoMode(_THIS, SDL_Surface *current, ...@@ -537,7 +537,7 @@ static SDL_Surface *XBIOS_SetVideoMode(_THIS, SDL_Surface *current,
if (new_depth == 4) { if (new_depth == 4) {
SDL_Atari_C2pConvert = SDL_Atari_C2pConvert4; SDL_Atari_C2pConvert = SDL_Atari_C2pConvert4;
new_depth=8; new_depth=8;
modeflags |= SDL_SWSURFACE; modeflags |= SDL_SWSURFACE|SDL_HWPALETTE;
} else if (new_depth == 8) { } else if (new_depth == 8) {
SDL_Atari_C2pConvert = SDL_Atari_C2pConvert8; SDL_Atari_C2pConvert = SDL_Atari_C2pConvert8;
modeflags |= SDL_SWSURFACE|SDL_HWPALETTE; modeflags |= SDL_SWSURFACE|SDL_HWPALETTE;
...@@ -646,15 +646,7 @@ static SDL_Surface *XBIOS_SetVideoMode(_THIS, SDL_Surface *current, ...@@ -646,15 +646,7 @@ static SDL_Surface *XBIOS_SetVideoMode(_THIS, SDL_Surface *current,
#endif #endif
/* Reset palette */ /* Reset palette */
for (i=0;i<16;i++) { for (i=0;i<16;i++) {
int c; TT_palette[i]= ((i>>1)<<8) | (((i*8)/17)<<4) | (i>>1);
c = ((i>>1)<<8) | ((i>>1)<<4) | (i>>1);
if ((i & 1) && (i<15))
c += (1<<4);
if (i==14)
c -= 1<<8;
TT_palette[i]= c;
} }
#ifndef DEBUG_VIDEO_XBIOS #ifndef DEBUG_VIDEO_XBIOS
Setpalette(TT_palette); Setpalette(TT_palette);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment