Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

nvtraverser::AppTraverser Class Reference

AppTraverser Class. More...

#include <AppTraverser.h>

Inheritance diagram for nvtraverser::AppTraverser:

Inheritance graph
[legend]
Collaboration diagram for nvtraverser::AppTraverser:

Collaboration graph
[legend]
List of all members.

Public Member Functions

NVSG_API AppTraverser ()
 Default constructor.

Protected Member Functions

virtual NVSG_API ~AppTraverser ()
 Default destructor.
virtual NVSG_API void doApply (const nvsg::ViewState *viewState, const nvsg::Scene *scene)
 doApply override
virtual NVSG_API void handleGeoNode (const nvsg::GeoNode *p)
 Routine to handle a GeoNode while traversing the scene graph.
virtual NVSG_API void handleAnimatedTransform (const nvsg::AnimatedTransform *p)
 Routine to handle a AnimatedTransform node while traversing the scene graph.
virtual NVSG_API void handleAnimatedQuads (const nvsg::AnimatedQuads *p)
 Routine to handle a AnimatedQuads object while traversing the scene graph.
virtual NVSG_API void handleAnimatedTriangles (const nvsg::AnimatedTriangles *p)
 Routine to handle a AnimatedTriangles object while traversing the scene graph.
virtual NVSG_API void handleSkinnedTriangles (const nvsg::SkinnedTriangles *p)
 Routine to handle a SkinnedTriangles object while traversing the scene graph.
virtual NVSG_API void handleCgFx (const nvsg::CgFx *p)
 Routine to handle a CgFx attribute while traversing the scene graph.
virtual NVSG_API void handleHighlightBox (const nvsg::HighlightBox *p, const nvsg::GeoSet *geoSet)
 Routine to handle a HighlightBox object while traversing the scene graph.
virtual NVSG_API void traverseLight (const nvsg::LightSource *p)
 This function will be called from the framework when a LightSource node is visited.

Protected Attributes

bool m_bApplyingCgFx
 Flag that signals if a CgFX effect needs to be handled (tangentspace calculation).
size_t m_animationFrame
 Current animation frame.

Detailed Description

AppTraverser Class.

This class provides the mechanism to apply changes and update the scene graph. (The 'apply' step of the application.) Use an AppTraverser derived class as a unique entry point for manipulating nodes in the scene, such as data from gadgets, animations, and interactions.

Note:
The current implementation takes care of the animation frames, camera clip planes highlighting, etc...


Constructor & Destructor Documentation

NVSG_API nvtraverser::AppTraverser::AppTraverser  ) 
 

Default constructor.

virtual NVSG_API nvtraverser::AppTraverser::~AppTraverser  )  [protected, virtual]
 

Default destructor.


Member Function Documentation

virtual NVSG_API void nvtraverser::AppTraverser::doApply const nvsg::ViewState viewState,
const nvsg::Scene scene
[protected, virtual]
 

doApply override

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleGeoNode const nvsg::GeoNode p  )  [protected, virtual]
 

Routine to handle a GeoNode while traversing the scene graph.

This routine gets called for each GeoNode object that will be visited while traversing the scene graph. The currently visited GeoNode object is pointed to by p. The base implementation ensures that all underlying components will be traversed in a correct way. For derived classes, it is recommended to always call the base implementation for traversing purposes.

Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleAnimatedTransform const nvsg::AnimatedTransform p  )  [protected, virtual]
 

Routine to handle a AnimatedTransform node while traversing the scene graph.

This routine gets called for each AnimatedTransform object that will be visited while traversing the scene graph. The currently visited AnimatedTransform object is pointed to by p. The base implementation ensures that all underlying components will be traversed in a correct way. For derived classes, it is recommended to always call the base implementation for traversing purposes.

Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleAnimatedQuads const nvsg::AnimatedQuads p  )  [protected, virtual]
 

Routine to handle a AnimatedQuads object while traversing the scene graph.

This routine gets called for each AnimatedQuads object that will be visited while traversing the scene graph. The currently visited AnimatedQuads object is pointed to by p. The base implementation ensures that all underlying components will be traversed in a correct way. For derived classes, it is recommended to always call the base implementation for traversing purposes.

Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleAnimatedTriangles const nvsg::AnimatedTriangles p  )  [protected, virtual]
 

Routine to handle a AnimatedTriangles object while traversing the scene graph.

This routine gets called for each AnimatedTriangles object that will be visited while traversing the scene graph. The currently visited AnimatedTriangles object is pointed to by p. The base implementation ensures that all underlying components will be traversed in a correct way. For derived classes, it is recommended to always call the base implementation for traversing purposes.

Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleSkinnedTriangles const nvsg::SkinnedTriangles p  )  [protected, virtual]
 

Routine to handle a SkinnedTriangles object while traversing the scene graph.

This routine gets called for each SkinnedTriangles object that will be visited while traversing the scene graph. The currently visited SkinnedTriangles object is pointed to by p. The base implementation ensures that all underlying components will be traversed in a correct way. For derived classes, it is recommended to always call the base implementation for traversing purposes.

Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleCgFx const nvsg::CgFx p  )  [protected, virtual]
 

Routine to handle a CgFx attribute while traversing the scene graph.

This routine gets called for each CgFx object that will be visited while traversing the scene graph. The currently visited CgFx object is pointed to by p. The base implementation ensures that all underlying components will be traversed in a correct way. For derived classes, it is recommended to always call the base implementation for traversing purposes.

Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::handleHighlightBox const nvsg::HighlightBox p,
const nvsg::GeoSet geoSet
[protected, virtual]
 

Routine to handle a HighlightBox object while traversing the scene graph.

This routine gets called for each HighlightBox object that will be visited while traversing the scene graph. The currently visited Highlight object is pointed to by p.

Remarks:
A HighlighBox always is attached to its corresponding GeoSet object as a HighlightObject .
Note:
: The behavior is undefined if p points to an invalid location.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::AppTraverser::traverseLight const nvsg::LightSource p  )  [protected, virtual]
 

This function will be called from the framework when a LightSource node is visited.

remarks Custom traversers can override this function for special tasks that need to be performed when visiting a LightSource node.

Reimplemented from nvtraverser::Traverser.


Member Data Documentation

bool nvtraverser::AppTraverser::m_bApplyingCgFx [protected]
 

Flag that signals if a CgFX effect needs to be handled (tangentspace calculation).

size_t nvtraverser::AppTraverser::m_animationFrame [protected]
 

Current animation frame.


The documentation for this class was generated from the following file:
Generated on Tue Mar 1 13:21:01 2005 for NVSGSDK by NVIDIA