Main Page | Namespace List | Class Hierarchy | Class List | Namespace Members | Class Members

osgHaptics::HapticRootNode Class Reference

A node that calls HapticDevice::update during update traversal. More...

#include <HapticRootNode.h>

List of all members.

Public Member Functions

 HapticRootNode (osgProducer::Viewer *viewer=0L)
virtual void traverse (osg::NodeVisitor &nv)

Protected Member Functions

virtual ~HapticRootNode ()
 Destructor.
 HapticRootNode (const HapticRootNode &copy, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
 Copy constructor.
HapticRootNodeoperator= (const HapticRootNode &node)
 Assignment operator.


Detailed Description

A node that calls HapticDevice::update during update traversal.

This can be the parent of all haptical renderable nodes. All it does really is to set the already existing "HapticRenderBin" to be the current renderbin for all its children.

It also holds a reference to the HapticDevice which can be handy. So the device is not "lost". that is dereferenced and deleted by ref_ptrīs

It is also possible to keep nodes that are supposed to be rendered into the "HapticRenderBin" in other places in the scenegraph too, just set the stateset->setRenderBinDetails(1, "HapticRenderBin"); for that node/group.

The subgraph of this group will only be rendered once per frame to avoid problems in the Haptic Shape rendering. If a Haptic shape is rendered multiple times during one frame it will cause the application to crash.

If viewer is specified in the constructor the scene will only be rendered in mono.


Constructor & Destructor Documentation

osgHaptics::HapticRootNode::HapticRootNode osgProducer::Viewer *  viewer = 0L  ) 
 

Constructor

Parameters:
viewer - If set, the subgraph will only be rendered in mono using a cullcallback


Member Function Documentation

virtual void osgHaptics::HapticRootNode::traverse osg::NodeVisitor &  nv  )  [virtual]
 

Executed during traversal of the scenegraph. If the NodeVisitor is a Update visitor the internal state of the haptic device is updated.


The documentation for this class was generated from the following file:
Generated on Wed May 10 16:29:46 2006 for osgHaptics by  doxygen 1.4.4