Added osg::CollectOccludersVisitor which is a helper class for finding active
occluder in the view frustum, to be used as pre cull traversal.
This commit is contained in:
@@ -141,6 +141,12 @@ class SG_EXPORT Node : public Object
|
||||
* note, return true only if no children have culling disabled, and the local _cullingActive flag is true.*/
|
||||
inline const bool isCullingActive() const { return _numChildrenWithCullingDisabled==0 && _cullingActive && _bsphere.isValid(); }
|
||||
|
||||
/** Get the number of Children of this node which are or have OccluderNode's.*/
|
||||
inline const int getNumChildrenWithOccluderNodes() const { return _numChildrenWithOccluderNodes; }
|
||||
|
||||
|
||||
/** return true if this node is an OccluderNode or the subgraph below this node are OccluderNodes.*/
|
||||
inline const bool containsOccluderNodes() const;
|
||||
|
||||
/**
|
||||
* Set user data, data must be subclased from Referenced to allow
|
||||
@@ -248,6 +254,9 @@ class SG_EXPORT Node : public Object
|
||||
int _numChildrenWithCullingDisabled;
|
||||
void setNumChildrenWithCullingDisabled(const int num);
|
||||
|
||||
int _numChildrenWithOccluderNodes;
|
||||
void setNumChildrenWithOccluderNodes(const int num);
|
||||
|
||||
osg::ref_ptr<Referenced> _userData;
|
||||
|
||||
NodeMask _nodeMask;
|
||||
|
||||
Reference in New Issue
Block a user