- Fixed: Memory error when loading BMF palettes.

- Fixed: When locating WhiteIndex and BlackIndex in the palette index 0 was skipped.
- Fixed: When filling an area black for vid_fps or pillarbox/letterbox use GPalette.BlackIndex instead of assuming palette index 0 is black.

SVN r3807 (trunk)
This commit is contained in:
Braden Obrzut 2012-08-06 09:49:15 +00:00
commit cb413c600e
4 changed files with 9 additions and 9 deletions

View file

@ -159,8 +159,8 @@ void FPalette::SetPalette (const BYTE *colors)
// Find white and black from the original palette so that they can be
// used to make an educated guess of the translucency % for a BOOM
// translucency map.
WhiteIndex = BestColor ((DWORD *)BaseColors, 255, 255, 255);
BlackIndex = BestColor ((DWORD *)BaseColors, 0, 0, 0);
WhiteIndex = BestColor ((DWORD *)BaseColors, 255, 255, 255, 0, 255);
BlackIndex = BestColor ((DWORD *)BaseColors, 0, 0, 0, 0, 255);
}
// In ZDoom's new texture system, color 0 is used as the transparent color.