limit gl_overbright to 1x/2x/4x
git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3783 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
5edcd6c0e8
commit
6d062f1355
1 changed files with 10 additions and 1 deletions
|
@ -2239,7 +2239,16 @@ static void DrawPass(const shaderpass_t *pass)
|
||||||
qglTexEnvi(GL_TEXTURE_ENV, GL_SOURCE0_RGB_ARB, GL_TEXTURE);
|
qglTexEnvi(GL_TEXTURE_ENV, GL_SOURCE0_RGB_ARB, GL_TEXTURE);
|
||||||
qglTexEnvi(GL_TEXTURE_ENV, GL_SOURCE1_RGB_ARB, GL_PREVIOUS_ARB);
|
qglTexEnvi(GL_TEXTURE_ENV, GL_SOURCE1_RGB_ARB, GL_PREVIOUS_ARB);
|
||||||
qglTexEnvi(GL_TEXTURE_ENV, GL_COMBINE_RGB_ARB, GL_MODULATE);
|
qglTexEnvi(GL_TEXTURE_ENV, GL_COMBINE_RGB_ARB, GL_MODULATE);
|
||||||
qglTexEnvf(GL_TEXTURE_ENV, GL_RGB_SCALE_ARB, gl_overbright.value+1);
|
{
|
||||||
|
float o;
|
||||||
|
if (gl_overbright.value >= 2)
|
||||||
|
o = 4.0;
|
||||||
|
else if (gl_overbright.value >= 1)
|
||||||
|
o = 2.0;
|
||||||
|
else
|
||||||
|
o = 1.0;
|
||||||
|
qglTexEnvf(GL_TEXTURE_ENV, GL_RGB_SCALE_ARB, o);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
case PBM_MODULATE:
|
case PBM_MODULATE:
|
||||||
|
|
Loading…
Reference in a new issue