|
|
|
@ -12,6 +12,7 @@
|
|
|
|
|
#include <components/vfs/manager.hpp>
|
|
|
|
|
#include <components/sceneutil/riggeometry.hpp>
|
|
|
|
|
#include <components/sceneutil/morphgeometry.hpp>
|
|
|
|
|
#include <components/settings/settings.hpp>
|
|
|
|
|
|
|
|
|
|
#include "shadermanager.hpp"
|
|
|
|
|
|
|
|
|
@ -138,6 +139,12 @@ namespace Shader
|
|
|
|
|
// Bump maps are off by default as well
|
|
|
|
|
writableStateSet->setTextureMode(unit, GL_TEXTURE_2D, osg::StateAttribute::ON);
|
|
|
|
|
}
|
|
|
|
|
else if (texName == "envMap")
|
|
|
|
|
{
|
|
|
|
|
static const bool preLightEnv = Settings::Manager::getBool("apply lighting to environment maps", "Shaders");
|
|
|
|
|
if (preLightEnv)
|
|
|
|
|
mRequirements.back().mShaderRequired = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
Log(Debug::Error) << "ShaderVisitor encountered unknown texture " << texture;
|
|
|
|
|