#ifndef COMPONENTS_SCENEUTIL_SHADOW_H #define COMPONENTS_SCENEUTIL_SHADOW_H #include #include namespace SceneUtil { class MWShadow : public osgShadow::ViewDependentShadowMap { public: static const int numberOfShadowMapsPerLight = 3; static const int enableShadows = true; static const bool debugHud = true; MWShadow(); const static int baseShadowTextureUnit = 8 - numberOfShadowMapsPerLight; virtual void cull(osgUtil::CullVisitor& cv); virtual Shader::ShaderManager::DefineMap getShadowDefines(); virtual Shader::ShaderManager::DefineMap getShadowsDisabledDefines(); protected: const int debugTextureUnit; std::vector> debugCameras; osg::ref_ptr debugProgram; std::vector> debugGeometry; }; } #endif //COMPONENTS_SCENEUTIL_SHADOW_H