VR-Forces 4.10 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions
makVrv::DtLightManager Class Reference

LightManager class which allows creation/deletion of lights. More...

Public Member Functions

 DtLightManager (const AxisAlignedBoundingBox_64 &box, size_t depth)
 CTOR. More...
 
virtual ~DtLightManager ()
 DTOR. More...
 
virtual DtLightcreateLight (LightType lightType)
 create a light More...
 
virtual void destroyLight (DtLight *pLight)
 destroy a light More...
 
virtual size_t numLights (void) const
 number of lights More...
 
virtual DtLightlight (size_t index)
 light for an index More...
 
virtual const VectorLights & allLights (void) const
 Get all the lights that have been registered/created. More...
 
virtual bool lightExists (const DtLight *pLight) const
 Find if a light exists in this manager. More...
 
virtual void getClosestLights (VectorLights &closestLights, const Vector3_64 &vPosition, size_t n)
 Get the 'n' closest lights to vPosition. Must be called after LightManager::Update. More...
 
virtual const VectorLights & frustumAffectingLights (void) const
 Get all the lights that affect the view frustum. Must be called after LightManager::Update. More...
 
virtual void setlodDistance (float fDistance)
 set the lod distance More...
 
virtual float lodDistance (void) const
 get the lod distance More...
 
virtual float lodDistanceSquared (void) const
 get the lod distance squared More...
 
virtual void initOctree (const AxisAlignedBoundingBox_64 &box)
 initailize the internal octress with box extens More...
 
virtual void lightUpdated (const DtLight *pLight)
 indicate that this light changed More...
 
virtual void lightBoundsUpdated (const DtLight *pLight)
 indicate that light bounds were updated More...
 
virtual void lightDestroyed (const DtLight *pLight)
 indicate that light was destroyed More...
 
virtual void createOctreeNode (DtLight *pLight)
 create an octree node for this light More...
 
virtual void destroyOctreeNode (DtLight *pLight)
 destroy the octree node for this light More...
 
virtual OctreeNode_64octreeNode (const DtLight *pLight) const
 Get the octree node for this light. More...
 
virtual void update (Camera_64 *pCamera)
 Call these before calling either of the 2 queries below. More...
 
virtual void update (Frustum_64 *pFrustum, const Vector3_64 &vRefPosition)
 

Protected Member Functions

virtual void findVisibleObjects (const Camera_64 *pCamera)
 
virtual void findVisibleObjects (const Frustum_64 *pCamera, const Vector3_64 &vRefPosition)
 

Protected Attributes

ListLights myLights
 
bool mybVectorLightsdirty
 
VectorLights myVectorLights
 
Octree_64myOctree
 
Octree_64::NodeVector myVisibleOctreeNodes
 
VectorLights myFrustumAffectingLights
 
VectorLights myFrustumAffectingLightsSortingScratchPad
 
float myLODDistance
 
tbb::mutex myOctreeMutex
 

Private Member Functions

 DtLightManager ()=delete
 not allowed More...
 
 DtLightManager (const DtLightManager &rhs)=delete
 not allowed More...
 
DtLightManageroperator= (const DtLightManager &rhs)=delete
 not allowed More...
 

Detailed Description

LightManager class which allows creation/deletion of lights.

Constructor & Destructor Documentation

makVrv::DtLightManager::DtLightManager ( const AxisAlignedBoundingBox_64 box,
size_t  depth 
)

CTOR.

virtual makVrv::DtLightManager::~DtLightManager ( )
virtual

DTOR.

makVrv::DtLightManager::DtLightManager ( )
privatedelete

not allowed

makVrv::DtLightManager::DtLightManager ( const DtLightManager rhs)
privatedelete

not allowed

Member Function Documentation

DtLightManager& makVrv::DtLightManager::operator= ( const DtLightManager rhs)
privatedelete

not allowed

virtual DtLight* makVrv::DtLightManager::createLight ( LightType  lightType)
virtual

create a light

virtual void makVrv::DtLightManager::destroyLight ( DtLight pLight)
virtual

destroy a light

virtual size_t makVrv::DtLightManager::numLights ( void  ) const
virtual

number of lights

virtual DtLight* makVrv::DtLightManager::light ( size_t  index)
virtual

light for an index

virtual const VectorLights& makVrv::DtLightManager::allLights ( void  ) const
virtual

Get all the lights that have been registered/created.

virtual bool makVrv::DtLightManager::lightExists ( const DtLight pLight) const
virtual

Find if a light exists in this manager.

virtual void makVrv::DtLightManager::update ( Camera_64 pCamera)
virtual

Call these before calling either of the 2 queries below.

virtual void makVrv::DtLightManager::update ( Frustum_64 pFrustum,
const Vector3_64 vRefPosition 
)
virtual
virtual void makVrv::DtLightManager::getClosestLights ( VectorLights &  closestLights,
const Vector3_64 vPosition,
size_t  n 
)
virtual

Get the 'n' closest lights to vPosition. Must be called after LightManager::Update.

virtual const VectorLights& makVrv::DtLightManager::frustumAffectingLights ( void  ) const
virtual

Get all the lights that affect the view frustum. Must be called after LightManager::Update.

virtual void makVrv::DtLightManager::setlodDistance ( float  fDistance)
virtual

set the lod distance

virtual float makVrv::DtLightManager::lodDistance ( void  ) const
virtual

get the lod distance

virtual float makVrv::DtLightManager::lodDistanceSquared ( void  ) const
virtual

get the lod distance squared

virtual void makVrv::DtLightManager::initOctree ( const AxisAlignedBoundingBox_64 box)
virtual

initailize the internal octress with box extens

virtual void makVrv::DtLightManager::lightUpdated ( const DtLight pLight)
virtual

indicate that this light changed

virtual void makVrv::DtLightManager::lightBoundsUpdated ( const DtLight pLight)
virtual

indicate that light bounds were updated

virtual void makVrv::DtLightManager::lightDestroyed ( const DtLight pLight)
virtual

indicate that light was destroyed

virtual void makVrv::DtLightManager::createOctreeNode ( DtLight pLight)
virtual

create an octree node for this light

virtual void makVrv::DtLightManager::destroyOctreeNode ( DtLight pLight)
virtual

destroy the octree node for this light

virtual OctreeNode_64* makVrv::DtLightManager::octreeNode ( const DtLight pLight) const
virtual

Get the octree node for this light.

virtual void makVrv::DtLightManager::findVisibleObjects ( const Camera_64 pCamera)
protectedvirtual
virtual void makVrv::DtLightManager::findVisibleObjects ( const Frustum_64 pCamera,
const Vector3_64 vRefPosition 
)
protectedvirtual

Member Data Documentation

ListLights makVrv::DtLightManager::myLights
protected
bool makVrv::DtLightManager::mybVectorLightsdirty
mutableprotected
VectorLights makVrv::DtLightManager::myVectorLights
mutableprotected
Octree_64* makVrv::DtLightManager::myOctree
protected
Octree_64::NodeVector makVrv::DtLightManager::myVisibleOctreeNodes
protected
VectorLights makVrv::DtLightManager::myFrustumAffectingLights
protected
VectorLights makVrv::DtLightManager::myFrustumAffectingLightsSortingScratchPad
protected
float makVrv::DtLightManager::myLODDistance
protected
tbb::mutex makVrv::DtLightManager::myOctreeMutex
protected

The documentation for this class was generated from the following file:

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)