OpenSceneGraph 2.8.3
|
StateGraph - contained in a renderBin, defines the scene to be drawn. More...
Public Types | |
typedef std::map< const osg::StateSet *, osg::ref_ptr < StateGraph > > | ChildList |
typedef std::vector < osg::ref_ptr< RenderLeaf > > | LeafList |
Public Member Functions | |
StateGraph () | |
StateGraph (StateGraph *parent, const osg::StateSet *stateset) | |
~StateGraph () | |
StateGraph * | cloneType () const |
void | setUserData (osg::Referenced *obj) |
osg::Referenced * | getUserData () |
const osg::Referenced * | getUserData () const |
const osg::StateSet * | getStateSet () const |
bool | empty () const |
return true if all of drawables, lights and children are empty. | |
bool | leaves_empty () const |
float | getAverageDistance () const |
float | getMinimumDistance () const |
void | sortFrontToBack () |
void | reset () |
Reset the internal contents of a StateGraph, including deleting all children. | |
void | clean () |
Recursively clean the StateGraph of all its drawables, lights and depths. | |
void | prune () |
Recursively prune the StateGraph of empty children. | |
StateGraph * | find_or_insert (const osg::StateSet *stateset) |
void | addLeaf (RenderLeaf *leaf) |
add a render leaf. | |
Static Public Member Functions | |
static void | moveStateGraph (osg::State &state, StateGraph *sg_curr, StateGraph *sg_new) |
static void | moveToRootStateGraph (osg::State &state, StateGraph *sg_curr) |
static int | numToPop (StateGraph *sg_curr) |
Public Attributes | |
StateGraph * | _parent |
const osg::StateSet * | _stateset |
int | _depth |
ChildList | _children |
LeafList | _leaves |
float | _averageDistance |
float | _minimumDistance |
osg::ref_ptr< osg::Referenced > | _userData |
bool | _dynamic |
StateGraph - contained in a renderBin, defines the scene to be drawn.
typedef std::map< const osg::StateSet*, osg::ref_ptr<StateGraph> > osgUtil::StateGraph::ChildList |
typedef std::vector< osg::ref_ptr<RenderLeaf> > osgUtil::StateGraph::LeafList |
osgUtil::StateGraph::StateGraph | ( | ) | [inline] |
osgUtil::StateGraph::StateGraph | ( | StateGraph * | parent, |
const osg::StateSet * | stateset | ||
) | [inline] |
References osg::Object::DYNAMIC, and osg::Object::getDataVariance().
osgUtil::StateGraph::~StateGraph | ( | ) | [inline] |
void osgUtil::StateGraph::addLeaf | ( | RenderLeaf * | leaf | ) | [inline] |
add a render leaf.
References osgUtil::RenderLeaf::_dynamic, and osgUtil::RenderLeaf::_parent.
Referenced by osgUtil::CullVisitor::addDrawable(), and osgUtil::CullVisitor::addDrawableAndDepth().
void osgUtil::StateGraph::clean | ( | ) |
Recursively clean the StateGraph of all its drawables, lights and depths.
Leaves children intact, and ready to be populated again.
StateGraph* osgUtil::StateGraph::cloneType | ( | ) | const [inline] |
bool osgUtil::StateGraph::empty | ( | ) | const [inline] |
return true if all of drawables, lights and children are empty.
StateGraph* osgUtil::StateGraph::find_or_insert | ( | const osg::StateSet * | stateset | ) | [inline] |
float osgUtil::StateGraph::getAverageDistance | ( | ) | const [inline] |
float osgUtil::StateGraph::getMinimumDistance | ( | ) | const [inline] |
const osg::StateSet* osgUtil::StateGraph::getStateSet | ( | ) | const [inline] |
Referenced by moveStateGraph(), moveToRootStateGraph(), and numToPop().
const osg::Referenced* osgUtil::StateGraph::getUserData | ( | ) | const [inline] |
osg::Referenced* osgUtil::StateGraph::getUserData | ( | ) | [inline] |
bool osgUtil::StateGraph::leaves_empty | ( | ) | const [inline] |
Referenced by osgUtil::CullVisitor::addDrawable(), and osgUtil::CullVisitor::addDrawableAndDepth().
static void osgUtil::StateGraph::moveStateGraph | ( | osg::State & | state, |
StateGraph * | sg_curr, | ||
StateGraph * | sg_new | ||
) | [inline, static] |
References _depth, _parent, getStateSet(), NULL, osg::State::popStateSet(), and osg::State::pushStateSet().
static void osgUtil::StateGraph::moveToRootStateGraph | ( | osg::State & | state, |
StateGraph * | sg_curr | ||
) | [inline, static] |
References _parent, getStateSet(), and osg::State::popStateSet().
static int osgUtil::StateGraph::numToPop | ( | StateGraph * | sg_curr | ) | [inline, static] |
References _parent, and getStateSet().
void osgUtil::StateGraph::prune | ( | ) |
Recursively prune the StateGraph of empty children.
void osgUtil::StateGraph::reset | ( | ) |
Reset the internal contents of a StateGraph, including deleting all children.
void osgUtil::StateGraph::setUserData | ( | osg::Referenced * | obj | ) | [inline] |
void osgUtil::StateGraph::sortFrontToBack | ( | ) | [inline] |
float osgUtil::StateGraph::_averageDistance [mutable] |
Referenced by moveStateGraph().
float osgUtil::StateGraph::_minimumDistance [mutable] |
Referenced by moveStateGraph(), moveToRootStateGraph(), and numToPop().
![]() | Generated at Tue Mar 22 2011 13:20:30 for the OpenSceneGraph by doxygen 1.7.3. |