1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-03-03 16:49:54 +00:00

Disable shadows properly for water reflection/refraction RTT targets, eliminating remaining OpenGL errors.

This commit is contained in:
AnyOldName3 2018-10-30 22:34:53 +00:00
parent 1ca7ea23d1
commit eb44de3e6b

View file

@ -25,6 +25,7 @@
#include <components/resource/imagemanager.hpp>
#include <components/resource/scenemanager.hpp>
#include <components/sceneutil/shadow.hpp>
#include <components/sceneutil/waterutil.hpp>
#include <components/misc/constants.hpp>
@ -263,6 +264,8 @@ public:
mRefractionDepthTexture->setFilter(osg::Texture::MAG_FILTER, osg::Texture::LINEAR);
attach(osg::Camera::DEPTH_BUFFER, mRefractionDepthTexture);
SceneUtil::ShadowManager::disableShadowsForStateSet(getOrCreateStateSet());
}
void setScene(osg::Node* scene)
@ -341,6 +344,8 @@ public:
mClipCullNode = new ClipCullNode;
addChild(mClipCullNode);
SceneUtil::ShadowManager::disableShadowsForStateSet(getOrCreateStateSet());
}
void setWaterLevel(float waterLevel)