- fixed: Desaturation factor was applied incorrectly.

- Also fixed some very strange thing in the shader's desaturate function. For unknown reasons using the 'mix' function there did not work.
- fixed: The fog boundary special shader could not be used.
This commit is contained in:
Christoph Oelckers 2014-05-21 13:40:46 +02:00
commit 54425ee2ef
2 changed files with 9 additions and 4 deletions

View file

@ -125,7 +125,7 @@ bool FRenderState::ApplyShader()
if (gl.hasGLSL())
{
FShader *activeShader;
if (mSpecialEffect > 0)
if (mSpecialEffect > EFF_NONE)
{
activeShader = GLRenderer->mShaderManager->BindEffect(mSpecialEffect);
}
@ -151,7 +151,7 @@ bool FRenderState::ApplyShader()
glColor4fv(mColor.vec);
activeShader->muDesaturation.Set(mDesaturation);
activeShader->muDesaturation.Set(mDesaturation / 255.f);
activeShader->muFogEnabled.Set(fogset);
activeShader->muTextureMode.Set(mTextureMode);
activeShader->muCameraPos.Set(mCameraPos.vec);