mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-10 11:51:52 +00:00
SCI32: Fix bad palette entries when built without USE_RGB_COLOR
This is only a problem for the Windows games that need some palette entries to be ignored.
This commit is contained in:
parent
3f0e061eaa
commit
12d24d5b46
@ -527,6 +527,12 @@ void GfxPalette32::updateHardware() {
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef USE_RGB_COLOR
|
||||
// When creating a raw palette on the stack, any skipped area of the palette
|
||||
// needs to be blacked out or else it will contain garbage memory
|
||||
memset(bpal + (maxIndex + 1) * 3, 0, (255 - maxIndex - 1) * 3);
|
||||
#endif
|
||||
|
||||
if (g_sci->getPlatform() != Common::kPlatformMacintosh) {
|
||||
// The last color must always be white
|
||||
bpal[255 * 3 ] = 255;
|
||||
|
Loading…
Reference in New Issue
Block a user