47 return ((i & 0x0F) << 4) | ((i & 0xF0) >> 4);
55 sdlpalinfo.alpha_mask |
65 sdlpalinfo.red_mask = 0xFFU << sdlpalinfo.red_shift;
66 sdlpalinfo.red_revmask = ~sdlpalinfo.red_mask;
68 sdlpalinfo.green_mask = 0xFFU << sdlpalinfo.green_shift;
69 sdlpalinfo.green_revmask = ~sdlpalinfo.green_mask;
71 sdlpalinfo.blue_mask = 0xFFU << sdlpalinfo.blue_shift;
72 sdlpalinfo.blue_revmask = ~sdlpalinfo.blue_mask;
74 sdlpalinfo.alpha_mask = 0xFFU << sdlpalinfo.alpha_shift;
75 sdlpalinfo.alpha_revmask = ~sdlpalinfo.alpha_mask;
83 FATAL(
"SDL palette problem!");
84 #ifdef DO_INIT_PALETTE
87 static const Uint8 def_pal[] = {
131 if (num >= 0x300 && num <= 0x30F)
133 if (num >= 0x10 && num <= 0xFF)
142 if (num >= 0x300 && num <= 0x30F)
144 if (num >= 0x10 && num <= 0xFF)
153 if (num >= 0x300 && num <= 0x30F)
155 if (num >= 0x10 && num <= 0xFF)