From f907c4fc957c38598251e0dd7ed38e972d9af909 Mon Sep 17 00:00:00 2001 From: havoc Date: Sat, 5 Jan 2008 23:15:32 +0000 Subject: [PATCH] fix black fog outline bug on quake sprites git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7923 d7cf8633-e32d-0410-b094-e92efae38249 --- palette.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/palette.c b/palette.c index f95c4891..85cd474f 100644 --- a/palette.c +++ b/palette.c @@ -85,6 +85,12 @@ void Palette_SetupSpecialPalettes(void) int transparentcolor; unsigned char *colormap; fs_offset_t filesize; + union + { + int i; + unsigned char b[4]; + } + u; colormap = FS_LoadFile("gfx/colormap.lmp", tempmempool, true, &filesize); if (colormap && filesize >= 16385) @@ -154,7 +160,9 @@ void Palette_SetupSpecialPalettes(void) for (i = 0;i < 256;i++) palette_bgra_alpha[i] = 0xFFFFFFFF; - palette_bgra_alpha[transparentcolor] = 0; + u.i = 0xFFFFFFFF; + u.b[3] = 0; + palette_bgra_alpha[transparentcolor] = u.i; for (i = 0;i < 256;i++) palette_bgra_font[i] = palette_bgra_complete[i]; -- 2.39.2