1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-09 21:42:13 +00:00
OpenMW/components/sceneutil/shadow.hpp
2018-02-26 23:52:46 +00:00

35 lines
981 B
C++

#ifndef COMPONENTS_SCENEUTIL_SHADOW_H
#define COMPONENTS_SCENEUTIL_SHADOW_H
#include <osgShadow/ShadowSettings>
#include <components/terrain/quadtreeworld.hpp>
#include <components/shader/shadermanager.hpp>
#include "mwshadowtechnique.hpp"
namespace SceneUtil
{
class ShadowManager
{
public:
static void disableShadowsForStateSet(osg::ref_ptr<osg::StateSet> stateSet);
ShadowManager(osg::ref_ptr<osg::Group> sceneRoot, osg::ref_ptr<osg::Group> rootNode);
virtual void setupShadowSettings(int castsShadowMask);
virtual Shader::ShaderManager::DefineMap getShadowDefines();
virtual Shader::ShaderManager::DefineMap getShadowsDisabledDefines();
protected:
bool mEnableShadows;
osg::ref_ptr<osgShadow::ShadowedScene> mShadowedScene;
osg::ref_ptr<osgShadow::ShadowSettings> mShadowSettings;
osg::ref_ptr<MWShadowTechnique> mShadowTechnique;
};
}
#endif //COMPONENTS_SCENEUTIL_SHADOW_H