Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

osgUtil::IntersectVisitor Class Reference

Basic visitor for ray based collisions of a scene. More...

Inheritance diagram for osgUtil::IntersectVisitor:

Inheritance graph
[legend]
List of all members.

Public Types

typedef std::vector< HitHitList
typedef std::map< osg::LineSegment *,
HitList
LineSegmentHitListMap

Public Methods

 IntersectVisitor ()
virtual ~IntersectVisitor ()
void reset ()
 Method to call to reset visitor.

void addLineSegment (osg::LineSegment *seg)
 Add a line segment to use for intersection testing during scene traversal.

HitListgetHitList (osg::LineSegment *seg)
int getNumHits (osg::LineSegment *seg)
bool hits ()
virtual void apply (osg::Node &)
virtual void apply (osg::Geode &node)
virtual void apply (osg::Billboard &node)
virtual void apply (osg::Group &node)
virtual void apply (osg::Transform &node)
virtual void apply (osg::Switch &node)
virtual void apply (osg::LOD &node)

Protected Types

typedef std::vector< osg::ref_ptr<
IntersectState > > 
IntersectStateStack

Protected Methods

bool intersect (osg::Drawable &gset)
void pushMatrix (const osg::Matrix &matrix)
void popMatrix ()
bool enterNode (osg::Node &node)
void leaveNode ()

Protected Attributes

IntersectStateStack _intersectStateStack
osg::NodePath _nodePath
LineSegmentHitListMap _segHitList

Detailed Description

Basic visitor for ray based collisions of a scene.


Member Typedef Documentation

typedef std::vector<Hit> osgUtil::IntersectVisitor::HitList
 

typedef std::vector<osg::ref_ptr<IntersectState> > osgUtil::IntersectVisitor::IntersectStateStack [protected]
 

typedef std::map<osg::LineSegment*,HitList > osgUtil::IntersectVisitor::LineSegmentHitListMap
 


Constructor & Destructor Documentation

osgUtil::IntersectVisitor::IntersectVisitor  
 

virtual osgUtil::IntersectVisitor::~IntersectVisitor   [virtual]
 


Member Function Documentation

void osgUtil::IntersectVisitor::addLineSegment osg::LineSegment   seg
 

Add a line segment to use for intersection testing during scene traversal.

virtual void osgUtil::IntersectVisitor::apply osg::LOD   node [virtual]
 

Reimplemented from osg::NodeVisitor.

virtual void osgUtil::IntersectVisitor::apply osg::Switch   node [virtual]
 

Reimplemented from osg::NodeVisitor.

virtual void osgUtil::IntersectVisitor::apply osg::Transform   node [virtual]
 

Reimplemented from osg::NodeVisitor.

virtual void osgUtil::IntersectVisitor::apply osg::Group   node [virtual]
 

Reimplemented from osg::NodeVisitor.

virtual void osgUtil::IntersectVisitor::apply osg::Billboard   node [virtual]
 

Reimplemented from osg::NodeVisitor.

virtual void osgUtil::IntersectVisitor::apply osg::Geode   node [virtual]
 

Reimplemented from osg::NodeVisitor.

virtual void osgUtil::IntersectVisitor::apply osg::Node   [virtual]
 

Reimplemented from osg::NodeVisitor.

bool osgUtil::IntersectVisitor::enterNode osg::Node   node [protected]
 

HitList& osgUtil::IntersectVisitor::getHitList osg::LineSegment   seg [inline]
 

int osgUtil::IntersectVisitor::getNumHits osg::LineSegment   seg [inline]
 

bool osgUtil::IntersectVisitor::hits  
 

bool osgUtil::IntersectVisitor::intersect osg::Drawable   gset [protected]
 

void osgUtil::IntersectVisitor::leaveNode   [protected]
 

void osgUtil::IntersectVisitor::popMatrix   [protected]
 

void osgUtil::IntersectVisitor::pushMatrix const osg::Matrix   matrix [protected]
 

void osgUtil::IntersectVisitor::reset   [virtual]
 

Method to call to reset visitor.

Useful for your visitor accumulates state during a traversal, and you plan to reuse the visitor. To flush that state for the next traversal than call reset() prior to each traversal.

Reimplemented from osg::NodeVisitor.


Member Data Documentation

IntersectStateStack osgUtil::IntersectVisitor::_intersectStateStack [protected]
 

osg::NodePath osgUtil::IntersectVisitor::_nodePath [protected]
 

Reimplemented from osg::NodeVisitor.

LineSegmentHitListMap osgUtil::IntersectVisitor::_segHitList [protected]
 


The documentation for this class was generated from the following file:
Generated at Wed Sep 18 13:55:58 2002 for the Open Scene Graph by doxygen 1.2.16.