mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-20 15:53:54 +00:00
Restore handling of fog depth == 0 values (Bug #1549)
This commit is contained in:
parent
dca08b0b42
commit
681183df31
1 changed files with 11 additions and 2 deletions
|
@ -379,8 +379,17 @@ namespace MWRender
|
|||
else
|
||||
{
|
||||
setFogColor(mFogColor);
|
||||
mStateUpdater->setFogStart(mViewDistance * (1 - mFogDepth));
|
||||
mStateUpdater->setFogEnd(mViewDistance);
|
||||
|
||||
if (mFogDepth == 0.f)
|
||||
{
|
||||
mStateUpdater->setFogStart(0.f);
|
||||
mStateUpdater->setFogEnd(FLT_MAX);
|
||||
}
|
||||
else
|
||||
{
|
||||
mStateUpdater->setFogStart(mViewDistance * (1 - mFogDepth));
|
||||
mStateUpdater->setFogEnd(mViewDistance);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue