small r_menutint fix

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1402 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
TimeServ 2005-09-30 01:29:27 +00:00
parent 1460649835
commit 11fa1bfbef
2 changed files with 30 additions and 25 deletions

View file

@ -1925,9 +1925,15 @@ void GLDraw_FadeScreen (void)
t = strstr(t+1, " "); t = strstr(t+1, " ");
if (t) if (t)
fadecolor[2] = atof(t+1); fadecolor[2] = atof(t+1);
else
faderender = 0;
} }
else
faderender = 0;
// bounds check and inverse check // bounds check and inverse check
if (faderender)
{
if (fadecolor[0] < 0) if (fadecolor[0] < 0)
{ {
faderender = GL_ONE_MINUS_DST_COLOR; faderender = GL_ONE_MINUS_DST_COLOR;
@ -1951,9 +1957,7 @@ void GLDraw_FadeScreen (void)
} }
if (fadecolor[2] > 1) if (fadecolor[2] > 1)
fadecolor[2] = 1; fadecolor[2] = 1;
}
if (faderender == GL_DST_COLOR && fadecolor[0] == 1 && fadecolor[1] == 1 && fadecolor[2] == 1)
faderender = 0;
fademodified = r_menutint.modified; fademodified = r_menutint.modified;
} }

View file

@ -2407,7 +2407,11 @@ void SWDraw_FadeScreen (void)
t = strstr(t+1, " "); t = strstr(t+1, " ");
if (t) if (t)
b = atof(t+1); b = atof(t+1);
else
fsnodraw = 1;
} }
else
fsnodraw = 1;
// bounds check and inverse check // bounds check and inverse check
if (r < 0) if (r < 0)
@ -2434,9 +2438,6 @@ void SWDraw_FadeScreen (void)
if (b > 1) if (b > 1)
b = 1; b = 1;
if (!invmask && r == 1 && g == 1 && b == 1)
fsnodraw = 1;
// generate colormap // generate colormap
for (x = 0; x < 256; x++) for (x = 0; x < 256; x++)
{ {