mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-09-17 16:36:33 -04:00
Fix fog on water
This commit is contained in:
parent
f93b7ec943
commit
bd279c63f7
@ -306,7 +306,12 @@ public:
|
|||||||
setUpdateCallback(new NoTraverseCallback);
|
setUpdateCallback(new NoTraverseCallback);
|
||||||
|
|
||||||
// No need for fog here, we are already applying fog on the water surface itself as well as underwater fog
|
// No need for fog here, we are already applying fog on the water surface itself as well as underwater fog
|
||||||
getOrCreateStateSet()->setMode(GL_FOG, osg::StateAttribute::OFF|osg::StateAttribute::OVERRIDE);
|
// assign large value to effectively turn off fog
|
||||||
|
// shaders don't respect glDisable(GL_FOG)
|
||||||
|
osg::ref_ptr<osg::Fog> fog (new osg::Fog);
|
||||||
|
fog->setStart(10000000);
|
||||||
|
fog->setEnd(10000000);
|
||||||
|
getOrCreateStateSet()->setAttributeAndModes(fog, osg::StateAttribute::OFF|osg::StateAttribute::OVERRIDE);
|
||||||
|
|
||||||
mClipCullNode = new ClipCullNode;
|
mClipCullNode = new ClipCullNode;
|
||||||
addChild(mClipCullNode);
|
addChild(mClipCullNode);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user