SO3Engine
|
SO3ShadowLiSPSM.cpp
Go to the documentation of this file.
21 const Ogre::RenderSystemCapabilities* caps = SRoot::getSingleton().GetOgreRenderSystem()->getCapabilities();
45SShadowLiSPSM::SShadowLiSPSM(SShadowManager* sManager) : SShadow(sManager, "LiSPSM", SShadowManager::SO3_SHADOWS_LISPSM)
47 ogreScene->setShadowTechnique(static_cast <Ogre::ShadowTechnique> (Ogre::SHADOWDETAILTYPE_TEXTURE | Ogre::SHADOWDETAILTYPE_INTEGRATED | shadowManager->GetLightingTechnique()));
71 ogreScene->setShadowTextureCasterMaterial(Ogre::MaterialManager::getSingleton().getByName("SO3/LISPSM/ShadowCaster"));
82 StableLISPSMShadowCameraSetup* lispsmSetup = static_cast<StableLISPSMShadowCameraSetup*>(shadowCameraSetup.get());
114 ogreScene->setShadowTechnique(static_cast <Ogre::ShadowTechnique> (Ogre::SHADOWDETAILTYPE_TEXTURE | Ogre::SHADOWDETAILTYPE_INTEGRATED | shadowManager->GetLightingTechnique()));
148 if (!tech || (tech->getParent()->getName() == "Ogre/Debug/LinesMat")/* || ((tech->getSchemeName() != Ogre::MSN_SHADERGEN) &&
157 if (tech->hasColourWriteDisabled() || (!tech->getParent()->getReceiveShadows()) || (tech->getSchemeName() == "SO3/LIGHTSHAFT"))
203 //if (GetShadowManager()->GetLightingTechnique() == SShadowManager::SO3_ADDITIVE_SHADOWS_LIGHTING)
216 if (oPass && !oPass->getPolygonModeOverrideable() && (oPass->getPolygonMode() == Ogre::PM_POINTS))
225 nPass->setAlphaRejectSettings(oPass->getAlphaRejectFunction(), oPass->getAlphaRejectValue(), false);
241 mcaster = Ogre::MaterialManager::getSingleton().getByName("SO3/LISPSM/ShadowCaster")->clone("SO3/LISPSM/ShadowCaster" + tech->getParent()->getName(), tech->getParent()->getGroup());
245 mcaster = Ogre::MaterialManager::getSingleton().getByName("SO3/LISPSM/ShadowCaster" + tech->getParent()->getName());
252 mcaster = Ogre::MaterialManager::getSingleton().getByName("SO3/LISPSM/ShadowCaster/Alpha")->clone("SO3/LISPSM/ShadowCaster/Alpha" + tech->getParent()->getName(), tech->getParent()->getGroup());
256 mcaster = Ogre::MaterialManager::getSingleton().getByName("SO3/LISPSM/ShadowCaster/Alpha" + tech->getParent()->getName());
285 //nPass->setFog(true, Ogre::FOG_LINEAR, Ogre::ColourValue::White, 0, shadowEnd * mFadeStart, shadowEnd * mFadeEnd);
321 Ogre::MaterialPtr caster = Ogre::MaterialManager::getSingleton().getByName("SO3/LISPSM/ShadowCaster");
322 if (caster && (caster->getNumTechniques() > 0) && (caster->getTechnique(0)->getNumPasses() > 0) && (caster->getTechnique(0)->getPass(0)->getNumTextureUnitStates() > 0))
361void StableLISPSMShadowCameraSetup::getShadowCamera(const Ogre::SceneManager *sm, const Ogre::Camera *cam, const Ogre::Viewport *vp, const Ogre::Light *light, Ogre::Camera *texCam, size_t iteration) const
MMechostr(MSKDEBUG, " > Start loading Plugin SO3Engine dll\n")
bool GetRttPixelFormat(Ogre::PixelFormat &format, bool alpha=false, bool floattex=false)
Definition SO3Root.cpp:650
void RemoveGeneratedMaterial(Ogre::Material *mat)
Definition SO3Root.cpp:2343
const SMaterialMap * GetMaterials(const std::string &groupName)
Definition SO3Scene.cpp:1147
Definition SO3Shadow.h:70
void SetCameraSetup(Ogre::ShadowCameraSetupPtr shadowCameraSetup)
Definition SO3Shadow.cpp:57
virtual void RemoveMaterialPass(Ogre::Technique *tech)
Definition SO3ShadowLiSPSM.cpp:125
virtual void UpdateShadowMaterial(Ogre::Technique *tech)
Definition SO3ShadowLiSPSM.cpp:146
virtual void UpdateShadowTechnique()
Definition SO3ShadowLiSPSM.cpp:112
static bool CheckSystemCompatibility()
Definition SO3ShadowLiSPSM.cpp:14
virtual bool IsShadowMaterialPass(Ogre::Pass *pass)
Definition SO3ShadowLiSPSM.cpp:117
Definition SO3ShadowManager.h:43
ShadowLightingType GetLightingTechnique()
Definition SO3ShadowManager.cpp:76
ShadowQuality GetShadowQuality()
Definition SO3ShadowManager.cpp:232
~StableLISPSMShadowCameraSetup()
Definition SO3ShadowLiSPSM.cpp:357
void getShadowCamera(const Ogre::SceneManager *sm, const Ogre::Camera *cam, const Ogre::Viewport *vp, const Ogre::Light *light, Ogre::Camera *texCam, size_t iteration) const override
Definition SO3ShadowLiSPSM.cpp:361
static Ogre::ShadowCameraSetupPtr create()
Definition SO3ShadowLiSPSM.h:42
Definition SO3DataScol.h:38
std::unordered_map< std::string, SMaterial * > SMaterialMap
Definition SO3Prerequisites.h:269
std::unordered_map< std::string, SMaterialMap * > SGroupMaterialMap
Definition SO3Prerequisites.h:270
Generated by 1.9.8