OGRE-Next  2.3
Object-Oriented Graphics Rendering Engine
Ogre::OctreeZone Class Reference

#include <OgreOctreeZone.h>

+ Inheritance diagram for Ogre::OctreeZone:

Public Types

enum  NODE_LIST_TYPE { HOME_NODE_LIST = 1 , VISITOR_NODE_LIST = 2 }
 

Public Member Functions

 OctreeZone (PCZSceneManager *, const String &)
 
virtual ~OctreeZone ()
 
virtual void _addAntiPortal (AntiPortal *newAntiPortal)
 Add an anti portal to the zone. More...
 
virtual void _addNode (PCZSceneNode *)
 Adds an SceneNode to this OctreeZone. More...
 
virtual void _addPortal (Portal *newPortal)
 Add a portal to the zone. More...
 
virtual void _checkLightAgainstPortals (PCZLight *, unsigned long, PCZFrustum *, Portal *)
 (recursive) Check the given light against all portals in the zone More...
 
virtual void _checkNodeAgainstPortals (PCZSceneNode *, Portal *)
 (recursive) Check the given node against all portals in the zone More...
 
virtual void _clearNodeLists (short nodeListTypes)
 Remove all nodes from the node reference list and clear it. More...
 
virtual void _findNodes (const AxisAlignedBox &t, PCZSceneNodeList &list, PortalList &visitedPortals, bool includeVisitors, bool recurseThruPortals, PCZSceneNode *exclude)
 Functions for finding Nodes that intersect various shapes. More...
 
virtual void _findNodes (const PlaneBoundedVolume &t, PCZSceneNodeList &list, PortalList &visitedPortals, bool includeVisitors, bool recurseThruPortals, PCZSceneNode *exclude)
 
virtual void _findNodes (const Ray &t, PCZSceneNodeList &list, PortalList &visitedPortals, bool includeVisitors, bool recurseThruPortals, PCZSceneNode *exclude)
 
virtual void _findNodes (const Sphere &t, PCZSceneNodeList &list, PortalList &visitedPortals, bool includeVisitors, bool recurseThruPortals, PCZSceneNode *exclude)
 
virtual void _removeAntiPortal (AntiPortal *removeAntiPortal)
 Remove an anti portal from the zone. More...
 
virtual void _removePortal (Portal *removePortal)
 Remove a portal from the zone. More...
 
void addNodeToOctree (PCZSceneNode *, Octree *octree, int depth=0)
 Adds the Octree Node, starting at the given octree, and recursing at max to the specified depth. More...
 
virtual void createNodeZoneData (PCZSceneNode *)
 Create zone specific data for a node. More...
 
void dirtyNodeByMovingPortals (void)
 Mark nodes dirty base on moving portals. More...
 
virtual PortalfindMatchingPortal (Portal *)
 Find a matching portal (for connecting portals) More...
 
virtual void findVisibleNodes (PCZCamera *, NodeList &visibleNodeList, RenderQueue *queue, VisibleObjectsBoundsInfo *visibleBounds, bool onlyShadowCasters, bool displayNodes, bool showBoundingBoxes)
 Find and add visible objects to the render queue. More...
 
virtual void getAABB (AxisAlignedBox &)
 Get the world coordinate aabb of the zone. More...
 
SceneNodegetEnclosureNode (void)
 Get a pointer to the enclosure node for this PCZone. More...
 
unsigned long getLastVisibleFrame (void)
 Get the lastVisibleFrame counter value. More...
 
PCZCameragetLastVisibleFromCamera ()
 Get the lastVisibleFromCamera pointer. More...
 
const StringgetName (void) const
 
bool getPortalsUpdated (void)
 
void * getUserData (void)
 Get & set the user data. More...
 
const StringgetZoneTypeName () const
 
bool hasSky (void)
 
void init (AxisAlignedBox &box, int depth)
 Init function carried over from OctreeSceneManager. More...
 
virtual void notifyBeginRenderScene (void)
 Called when a _renderScene is called in the SceneManager. More...
 
virtual void notifyCameraCreated (Camera *c)
 Called when the scene manager creates a camera because some zone managers (like TerrainZone) need the camera info. More...
 
virtual void notifyWorldGeometryRenderQueue (uint8 qid)
 Called by PCZSM during setWorldGeometryRenderQueue() More...
 
void operator delete (void *ptr)
 
void operator delete (void *ptr, const char *, int, const char *)
 
void operator delete (void *ptr, void *)
 
void operator delete[] (void *ptr)
 
void operator delete[] (void *ptr, const char *, int, const char *)
 
void * operator new (size_t sz)
 
void * operator new (size_t sz, const char *file, int line, const char *func)
 operator new, with debug line info More...
 
void * operator new (size_t sz, void *ptr)
 placement operator new More...
 
void * operator new[] (size_t sz)
 
void * operator new[] (size_t sz, const char *file, int line, const char *func)
 array operator new, with debug line info More...
 
virtual void removeNode (PCZSceneNode *)
 Removes all references to a SceneNode from this Zone. More...
 
void removeNodeFromOctree (PCZSceneNode *)
 Removes the node from the octree it is in. More...
 
virtual bool requiresZoneSpecificNodeData (void)
 Indicates whether or not this zone requires zone-specific data for each scene node. More...
 
void resize (const AxisAlignedBox &box)
 Resizes the octree to the given size. More...
 
virtual void setEnclosureNode (PCZSceneNode *)
 Set the enclosure node for this OctreeZone. More...
 
void setHasSky (bool yesno)
 If sky should be drawn with this zone. More...
 
void setLastVisibleFrame (unsigned long frameCount)
 Set the lastVisibleFrame counter. More...
 
void setLastVisibleFromCamera (PCZCamera *camera)
 Set the lastVisibleFromCamera pointer. More...
 
virtual bool setOption (const String &, const void *)
 Sets the given option for the Zone. More...
 
void setPortalsUpdated (bool updated)
 
void setUserData (void *userData)
 
virtual void setZoneGeometry (const String &filename, PCZSceneNode *parentNode)
 Called by PCZSM during setZoneGeometry() More...
 
virtual PCZoneupdateNodeHomeZone (PCZSceneNode *pczsn, bool allowBackTouces)
 Update a node's home zone. More...
 
void updateNodeOctant (OctreeZoneData *zoneData)
 Checks the given OctreeNode, and determines if it needs to be moved to a different octant. More...
 
void updatePortalsZoneData (void)
 Update the zone data for each portal. More...
 

Public Attributes

AntiPortalList mAntiPortals
 
PCZSceneManagermPCZSM
 Pointer to the pcz scene manager that created this zone. More...
 
PortalList mPortals
 List of Portals which this zone contains (each portal leads to another zone) More...
 

Member Enumeration Documentation

◆ NODE_LIST_TYPE

Enumerator
HOME_NODE_LIST 
VISITOR_NODE_LIST 

Constructor & Destructor Documentation

◆ OctreeZone()

Ogre::OctreeZone::OctreeZone ( PCZSceneManager ,
const String  
)

◆ ~OctreeZone()

virtual Ogre::OctreeZone::~OctreeZone ( )
virtual

Member Function Documentation

◆ _addAntiPortal()

virtual void Ogre::PCZone::_addAntiPortal ( AntiPortal newAntiPortal)
virtualinherited

Add an anti portal to the zone.

◆ _addNode()

virtual void Ogre::OctreeZone::_addNode ( PCZSceneNode )
virtual

Adds an SceneNode to this OctreeZone.

Remarks
The PCZSceneManager calls this function to add a node to the zone.

Implements Ogre::PCZone.

◆ _addPortal()

virtual void Ogre::PCZone::_addPortal ( Portal newPortal)
virtualinherited

Add a portal to the zone.

◆ _checkLightAgainstPortals()

virtual void Ogre::OctreeZone::_checkLightAgainstPortals ( PCZLight ,
unsigned long  ,
PCZFrustum ,
Portal  
)
virtual

(recursive) Check the given light against all portals in the zone

Implements Ogre::PCZone.

◆ _checkNodeAgainstPortals()

virtual void Ogre::OctreeZone::_checkNodeAgainstPortals ( PCZSceneNode ,
Portal  
)
virtual

(recursive) Check the given node against all portals in the zone

Implements Ogre::PCZone.

◆ _clearNodeLists()

virtual void Ogre::OctreeZone::_clearNodeLists ( short  nodeListTypes)
virtual

Remove all nodes from the node reference list and clear it.

Reimplemented from Ogre::PCZone.

◆ _findNodes() [1/4]

virtual void Ogre::OctreeZone::_findNodes ( const AxisAlignedBox t,
PCZSceneNodeList list,
PortalList visitedPortals,
bool  includeVisitors,
bool  recurseThruPortals,
PCZSceneNode exclude 
)
virtual

Functions for finding Nodes that intersect various shapes.

Implements Ogre::PCZone.

◆ _findNodes() [2/4]

virtual void Ogre::OctreeZone::_findNodes ( const PlaneBoundedVolume t,
PCZSceneNodeList list,
PortalList visitedPortals,
bool  includeVisitors,
bool  recurseThruPortals,
PCZSceneNode exclude 
)
virtual

Implements Ogre::PCZone.

◆ _findNodes() [3/4]

virtual void Ogre::OctreeZone::_findNodes ( const Ray t,
PCZSceneNodeList list,
PortalList visitedPortals,
bool  includeVisitors,
bool  recurseThruPortals,
PCZSceneNode exclude 
)
virtual

Implements Ogre::PCZone.

◆ _findNodes() [4/4]

virtual void Ogre::OctreeZone::_findNodes ( const Sphere t,
PCZSceneNodeList list,
PortalList visitedPortals,
bool  includeVisitors,
bool  recurseThruPortals,
PCZSceneNode exclude 
)
virtual

Implements Ogre::PCZone.

◆ _removeAntiPortal()

virtual void Ogre::PCZone::_removeAntiPortal ( AntiPortal removeAntiPortal)
virtualinherited

Remove an anti portal from the zone.

◆ _removePortal()

virtual void Ogre::PCZone::_removePortal ( Portal removePortal)
virtualinherited

Remove a portal from the zone.

◆ addNodeToOctree()

void Ogre::OctreeZone::addNodeToOctree ( PCZSceneNode ,
Octree octree,
int  depth = 0 
)

Adds the Octree Node, starting at the given octree, and recursing at max to the specified depth.

◆ createNodeZoneData()

virtual void Ogre::OctreeZone::createNodeZoneData ( PCZSceneNode )
virtual

Create zone specific data for a node.

Reimplemented from Ogre::PCZone.

◆ dirtyNodeByMovingPortals()

void Ogre::OctreeZone::dirtyNodeByMovingPortals ( void  )
virtual

Mark nodes dirty base on moving portals.

Implements Ogre::PCZone.

◆ findMatchingPortal()

virtual Portal* Ogre::PCZone::findMatchingPortal ( Portal )
virtualinherited

Find a matching portal (for connecting portals)

◆ findVisibleNodes()

virtual void Ogre::OctreeZone::findVisibleNodes ( PCZCamera ,
NodeList visibleNodeList,
RenderQueue queue,
VisibleObjectsBoundsInfo *  visibleBounds,
bool  onlyShadowCasters,
bool  displayNodes,
bool  showBoundingBoxes 
)
virtual

Find and add visible objects to the render queue.

Remarks
Starts with objects in the zone and proceeds through visible portals
This is a recursive call (the main call should be to _findVisibleObjects)

Implements Ogre::PCZone.

◆ getAABB()

virtual void Ogre::OctreeZone::getAABB ( AxisAlignedBox )
virtual

Get the world coordinate aabb of the zone.

Reimplemented from Ogre::PCZone.

◆ getEnclosureNode()

SceneNode* Ogre::PCZone::getEnclosureNode ( void  )
inlineinherited

Get a pointer to the enclosure node for this PCZone.

◆ getLastVisibleFrame()

unsigned long Ogre::PCZone::getLastVisibleFrame ( void  )
inlineinherited

Get the lastVisibleFrame counter value.

◆ getLastVisibleFromCamera()

PCZCamera* Ogre::PCZone::getLastVisibleFromCamera ( )
inlineinherited

Get the lastVisibleFromCamera pointer.

◆ getName()

const String& Ogre::PCZone::getName ( void  ) const
inlineinherited
Returns
the name of the zone

◆ getPortalsUpdated()

bool Ogre::PCZone::getPortalsUpdated ( void  )
inlineinherited

◆ getUserData()

void* Ogre::PCZone::getUserData ( void  )
inlineinherited

Get & set the user data.

◆ getZoneTypeName()

const String& Ogre::PCZone::getZoneTypeName ( ) const
inlineinherited
Returns
The zone type name (ex: "ZoneType_Terrain")

◆ hasSky()

bool Ogre::PCZone::hasSky ( void  )
inlineinherited
Returns
Whether or not this zone has sky

◆ init()

void Ogre::OctreeZone::init ( AxisAlignedBox box,
int  depth 
)

Init function carried over from OctreeSceneManager.

◆ notifyBeginRenderScene()

virtual void Ogre::OctreeZone::notifyBeginRenderScene ( void  )
virtual

Called when a _renderScene is called in the SceneManager.

Implements Ogre::PCZone.

◆ notifyCameraCreated()

virtual void Ogre::OctreeZone::notifyCameraCreated ( Camera c)
virtual

Called when the scene manager creates a camera because some zone managers (like TerrainZone) need the camera info.

Implements Ogre::PCZone.

◆ notifyWorldGeometryRenderQueue()

virtual void Ogre::OctreeZone::notifyWorldGeometryRenderQueue ( uint8  qid)
virtual

Called by PCZSM during setWorldGeometryRenderQueue()

Implements Ogre::PCZone.

◆ operator delete() [1/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void *  ptr)
inlineinherited

◆ operator delete() [2/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void *  ptr,
const char *  ,
int  ,
const char *   
)
inlineinherited

◆ operator delete() [3/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void *  ptr,
void *   
)
inlineinherited

◆ operator delete[]() [1/2]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete[] ( void *  ptr)
inlineinherited

◆ operator delete[]() [2/2]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete[] ( void *  ptr,
const char *  ,
int  ,
const char *   
)
inlineinherited

◆ operator new() [1/3]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz)
inlineinherited

◆ operator new() [2/3]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz,
const char *  file,
int  line,
const char *  func 
)
inlineinherited

operator new, with debug line info

◆ operator new() [3/3]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz,
void *  ptr 
)
inlineinherited

placement operator new

◆ operator new[]() [1/2]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new[] ( size_t  sz)
inlineinherited

◆ operator new[]() [2/2]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new[] ( size_t  sz,
const char *  file,
int  line,
const char *  func 
)
inlineinherited

array operator new, with debug line info

◆ removeNode()

virtual void Ogre::OctreeZone::removeNode ( PCZSceneNode )
virtual

Removes all references to a SceneNode from this Zone.

Implements Ogre::PCZone.

◆ removeNodeFromOctree()

void Ogre::OctreeZone::removeNodeFromOctree ( PCZSceneNode )

Removes the node from the octree it is in.

◆ requiresZoneSpecificNodeData()

virtual bool Ogre::OctreeZone::requiresZoneSpecificNodeData ( void  )
virtual

Indicates whether or not this zone requires zone-specific data for each scene node.

Implements Ogre::PCZone.

◆ resize()

void Ogre::OctreeZone::resize ( const AxisAlignedBox box)

Resizes the octree to the given size.

◆ setEnclosureNode()

virtual void Ogre::OctreeZone::setEnclosureNode ( PCZSceneNode )
virtual

Set the enclosure node for this OctreeZone.

Implements Ogre::PCZone.

◆ setHasSky()

void Ogre::PCZone::setHasSky ( bool  yesno)
inlineinherited

If sky should be drawn with this zone.

◆ setLastVisibleFrame()

void Ogre::PCZone::setLastVisibleFrame ( unsigned long  frameCount)
inlineinherited

Set the lastVisibleFrame counter.

◆ setLastVisibleFromCamera()

void Ogre::PCZone::setLastVisibleFromCamera ( PCZCamera camera)
inlineinherited

Set the lastVisibleFromCamera pointer.

◆ setOption()

virtual bool Ogre::OctreeZone::setOption ( const String ,
const void *   
)
virtual

Sets the given option for the Zone.

Remarks
Options are: "Size", AxisAlignedBox *; "Depth", int *; "ShowOctree", bool *;

Implements Ogre::PCZone.

◆ setPortalsUpdated()

void Ogre::PCZone::setPortalsUpdated ( bool  updated)
inlineinherited

◆ setUserData()

void Ogre::PCZone::setUserData ( void *  userData)
inlineinherited

◆ setZoneGeometry()

virtual void Ogre::OctreeZone::setZoneGeometry ( const String filename,
PCZSceneNode parentNode 
)
virtual

Called by PCZSM during setZoneGeometry()

Implements Ogre::PCZone.

◆ updateNodeHomeZone()

virtual PCZone* Ogre::OctreeZone::updateNodeHomeZone ( PCZSceneNode pczsn,
bool  allowBackTouces 
)
virtual

Update a node's home zone.

Implements Ogre::PCZone.

◆ updateNodeOctant()

void Ogre::OctreeZone::updateNodeOctant ( OctreeZoneData zoneData)

Checks the given OctreeNode, and determines if it needs to be moved to a different octant.

◆ updatePortalsZoneData()

void Ogre::OctreeZone::updatePortalsZoneData ( void  )
virtual

Update the zone data for each portal.

Implements Ogre::PCZone.

Member Data Documentation

◆ mAntiPortals

AntiPortalList Ogre::PCZone::mAntiPortals
inherited

◆ mPCZSM

PCZSceneManager* Ogre::PCZone::mPCZSM
inherited

Pointer to the pcz scene manager that created this zone.

◆ mPortals

PortalList Ogre::PCZone::mPortals
inherited

List of Portals which this zone contains (each portal leads to another zone)


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