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

nvtraverser::DrawableUnifyTraverser Class Reference

Traverser that combines Drawables under one GeoNode. More...

#include <DrawableUnifyTraverser.h>

Inheritance diagram for nvtraverser::DrawableUnifyTraverser:

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

Collaboration graph
[legend]
List of all members.

Public Member Functions

NVSG_API DrawableUnifyTraverser (void)
 Constructor.
NVSG_API bool getIgnoreNames (void) const
 Get the 'ignore names' flag.
NVSG_API void setIgnoreNames (bool ignore)
 Set the 'ignore names' flags.

Protected Member Functions

virtual NVSG_API ~DrawableUnifyTraverser (void)
 Protected destructor to prevent instantiation of a DrawableUnifyTraverser on stack.
virtual NVSG_API void handleGeoNode (const nvsg::GeoNode *p)
 Routine to handle a GeoNode while traversing the scene graph.
virtual NVSG_API void handleStateSet (const nvsg::StateSet *p)
 Routine to handle a StateSet object while traversing the scene graph.
virtual NVSG_API void handleQuads (const nvsg::Quads *p)
 Routine to handle a Quads object 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 handleQuadStrips (const nvsg::QuadStrips *p)
 Routine to handle a QuadStrips object while traversing the scene graph.
virtual NVSG_API void handleTriangles (const nvsg::Triangles *p)
 Routine to handle a Triangles 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 handleTriStrips (const nvsg::TriStrips *p)
 Routine to handle a TriStrips object while traversing the scene graph.
void combine (nvsg::GeoSet *p0, const nvsg::GeoSet *p1)
void combine (nvsg::Quads *p0, const nvsg::Quads *p1)
void combine (nvsg::QuadStrips *p0, const nvsg::QuadStrips *p1)
void combine (nvsg::Triangles *p0, const nvsg::Triangles *p1)
void combine (nvsg::TriStrips *p0, const nvsg::TriStrips *p1)

Detailed Description

Traverser that combines Drawables under one GeoNode.

All Drawables of the same type that are bound to the same StateSet are combined to one Drawable.


Constructor & Destructor Documentation

NVSG_API nvtraverser::DrawableUnifyTraverser::DrawableUnifyTraverser void   ) 
 

Constructor.

virtual NVSG_API nvtraverser::DrawableUnifyTraverser::~DrawableUnifyTraverser void   )  [protected, virtual]
 

Protected destructor to prevent instantiation of a DrawableUnifyTraverser on stack.


Member Function Documentation

bool nvtraverser::DrawableUnifyTraverser::getIgnoreNames void   )  const [inline]
 

Get the 'ignore names' flag.

If the 'ignore names' flag is set, the names of the GeoNodes are ignored.

Returns:
true if the names will be ignored, otherwise false

void nvtraverser::DrawableUnifyTraverser::setIgnoreNames bool  ignore  )  [inline]
 

Set the 'ignore names' flags.

If the 'ignore names' flag is set, the names of the GeoNodes are ignored.

Parameters:
ignore  set true to ignore names on comparison

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

Routine to handle a GeoNode while traversing the scene graph.

After traversing, drawables of the same type bound to the same StateSet are combined.

Parameters:
p  Points to the currently visited GeoNode object.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::DrawableUnifyTraverser::handleStateSet const nvsg::StateSet p  )  [protected, virtual]
 

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

Just holds the StateSet as the current one for subsequent comparisons.

Parameters:
p  Points to the currently visited StateSet object.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::DrawableUnifyTraverser::handleQuads const nvsg::Quads p  )  [protected, virtual]
 

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

If the Quads p is bound to the same StateSet as a previously traversed one, they are marked for combining.

Parameters:
p  Points to the currently visited Quads object.

Reimplemented from nvtraverser::Traverser.

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

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

AnimatedQuads are explicitly ignored here!

Parameters:
p  Points to the currently visited AnimatedQuads object.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::DrawableUnifyTraverser::handleQuadStrips const nvsg::QuadStrips p  )  [protected, virtual]
 

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

If the QuadStrips p is bound to the same StateSet as a previously traversed one, they are marked for combining.

Parameters:
p  Points to the currently visited QuadStrips object.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::DrawableUnifyTraverser::handleTriangles const nvsg::Triangles p  )  [protected, virtual]
 

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

If the Triangles p is bound to the same StateSet as a previously traversed one, they are marked for combining.

Parameters:
p  Points to the currently visited Triangles object.

Reimplemented from nvtraverser::Traverser.

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

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

AnimatedTriangles are explicitly ignored here!

Parameters:
p  Points to the currently visited AnimatedTriangles object.

Reimplemented from nvtraverser::Traverser.

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

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

SkinnedTriangles are explicitly ignored here!

Parameters:
p  Points to the currently visited SkinnedTriangles object.

Reimplemented from nvtraverser::Traverser.

virtual NVSG_API void nvtraverser::DrawableUnifyTraverser::handleTriStrips const nvsg::TriStrips p  )  [protected, virtual]
 

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

If the TriStrips p is bound to the same StateSet as a previously traversed one, they are marked for combining.

Parameters:
p  Points to the currently visited TriStrips object.

Reimplemented from nvtraverser::Traverser.


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