SO3Engine
|
SO3DeferredLightSpot.cpp
Go to the documentation of this file.
30SDeferredLightSpot::SDeferredLightSpot(Ogre::Light* originalLight, SDeferredLightMaterialGenerator* typeLightMaterialGenerator) : SDeferredLightImpl(originalLight, "Spot", typeLightMaterialGenerator)
46 Ogre::Radian coneRadiusAngle = std::min<Ogre::Radian>(ogreParentLight->getSpotlightOuterAngle(), Ogre::Degree(179.0f)) / 2; // Avoid Pi/2 max angle
78 Ogre::Quaternion quat = Ogre::Vector3::UNIT_Y.getRotationTo(ogreParentLight->getDerivedDirection());
84 // Check if the camera is inside the sphere geometry (small epsilon fix to account for the fact that we aren't a true sphere).
87 Ogre::Radian attAngle = std::min<Ogre::Radian>(ogreParentLight->getSpotlightOuterAngle(), Ogre::Degree(179.0f));
99 if ((distanceFromLight < (ogreParentLight->getAttenuationRange() + clipRangeFix.length())) && (angle <= attAngle))
static Ogre::MeshPtr CreateCone(const Ogre::String &strName, float radius, float height, int nVerticesInBase, Ogre::String groupName=Ogre::RGN_DEFAULT)
Definition SO3BaseMeshsTools.cpp:145
Ogre::Light * ogreParentLight
The light that this SDeferredLight renders.
Definition SO3DeferredLightImpl.h:42
virtual void getWorldTransforms(Ogre::Matrix4 *xform) const
Definition SO3DeferredLightSpot.cpp:76
virtual void SetAttenuation()
Definition SO3DeferredLightSpot.cpp:38
SDeferredLightSpot(Ogre::Light *originalLight, SDeferredLightMaterialGenerator *typeLightMaterialGenerator)
Definition SO3DeferredLightSpot.cpp:30
~SDeferredLightSpot()
Definition SO3DeferredLightSpot.cpp:34
virtual void CheckCullingMode(Ogre::Camera *camera, Ogre::Pass *pass)
Definition SO3DeferredLightSpot.cpp:82
virtual Ogre::Real getBoundingRadius() const
Definition SO3DeferredLightSpot.cpp:64
virtual Ogre::Real getSquaredViewDepth(const Ogre::Camera *) const
Definition SO3DeferredLightSpot.cpp:70
virtual void RebuildGeometry()
Definition SO3DeferredLightSpot.cpp:42
Definition SO3DataScol.h:38
Generated by 1.9.8