From 59f6bdf231382732bfb616cf520c7ff2acbab536 Mon Sep 17 00:00:00 2001 From: Jeff Teunissen Date: Sat, 30 Sep 2000 05:58:40 +0000 Subject: [PATCH] gl_screen.c: Whitespace sbar.c: Simplify Sbar_ColorForMap() gl_view.c: Remove palette shifting code -- we don't do that any more in GL, we alpha blend the screen. Bad to do it twice, plus it messes up texture loads. --- source/gl_screen.c | 3 ++- source/gl_view.c | 60 +++++++--------------------------------------- source/sbar.c | 5 +--- 3 files changed, 12 insertions(+), 56 deletions(-) diff --git a/source/gl_screen.c b/source/gl_screen.c index e4c0ddf..30aef3b 100644 --- a/source/gl_screen.c +++ b/source/gl_screen.c @@ -328,8 +328,9 @@ static void SCR_CalcRefdef (void) if (scr_viewsize->value >= 100.0) { full = true; size = 100.0; - } else + } else { size = scr_viewsize->value; + } if (cl.intermission) { full = true; diff --git a/source/gl_view.c b/source/gl_view.c index 2b73ce4..9acf9c3 100644 --- a/source/gl_view.c +++ b/source/gl_view.c @@ -126,39 +126,33 @@ V_UpdatePalette void V_UpdatePalette (void) { - int i, j; + int i, j; qboolean new; - byte *basepal, *newpal; - byte pal[768]; - float r,g,b,a; - int ir, ig, ib; - qboolean force; + qboolean force; V_CalcPowerupCshift (); new = false; - for (i=0 ; i 13) ? 13 : m); - - m *= 16; - return m < 128 ? m + 8 : m + 8; + return (bound (0, m, 13) * 16) + 8; }