From Paul Martz, speeling fixes for Tessellator/Tessellation.

This commit is contained in:
Robert Osfield
2007-01-08 21:29:49 +00:00
parent 2bf5f56311
commit 462803fd57
24 changed files with 158 additions and 129 deletions

View File

@@ -23,7 +23,7 @@
namespace osg {
/** Describe several hints that can be passed to a tesselator (like the one used
/** Describe several hints that can be passed to a Tessellator (like the one used
* by \c ShapeDrawable) as a mean to try to influence the way it works.
*/
class TessellationHints : public Object

View File

@@ -38,11 +38,11 @@ class OSGSIM_EXPORT Optimizer
enum OptimizationOptions
{
TESSELATE_POLYGON = 0x001,
TESSELLATE_POLYGON = 0x001,
MERGE_GEODES = 0x002,
MAKE_LIT = 0x004,
DEFAULT_OPTIMIZATIONS = TESSELATE_POLYGON | MERGE_GEODES,
ALL_OPTIMIZATIONS = TESSELATE_POLYGON | MERGE_GEODES
DEFAULT_OPTIMIZATIONS = TESSELLATE_POLYGON | MERGE_GEODES,
ALL_OPTIMIZATIONS = TESSELLATE_POLYGON | MERGE_GEODES
};
@@ -59,12 +59,12 @@ class OSGSIM_EXPORT Optimizer
public:
class OSGSIM_EXPORT TesselateVisitor : public osg::NodeVisitor
class OSGSIM_EXPORT TessellateVisitor : public osg::NodeVisitor
{
public:
/// default to traversing all children.
TesselateVisitor() :
TessellateVisitor() :
osg::NodeVisitor(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN) {}
virtual void apply(osg::Geode& geode);

View File

@@ -73,7 +73,7 @@ public:
/** Add vertices and constraint loops from dco
* Can be used to generate extra vertices where dco crosses 'this' using
* osgUtil::tessellator to insert overlap vertices.
* osgUtil::Tessellator to insert overlap vertices.
*/
void merge(DelaunayConstraint *dco);
@@ -89,7 +89,7 @@ public:
virtual bool contains(const osg::Vec3 testpoint) const;
virtual bool outside(const osg::Vec3 testpoint) const;
/** Tesselate the constraint loops so that the crossing points are interpolated
/** Tessellate the constraint loops so that the crossing points are interpolated
* and added to the contraints for the triangulation. */
void handleOverlaps(void);

View File

@@ -35,7 +35,7 @@ class OSGUTIL_EXPORT Hit
* A Hit is always on a surface as rendered by the Open Scene Graph scene (usually
* a triangle or other primitive, but a special hit handler could return a
* different value perhaps: a sphere shape might return a Hit on the true sphere
* rather than the approximate tesselated sphere rendered.
* rather than the approximate tessellated sphere rendered.
*/
public:

View File

@@ -77,7 +77,7 @@ class OSGUTIL_EXPORT Optimizer
SPATIALIZE_GROUPS = 0x080,
COPY_SHARED_NODES = 0x100,
TRISTRIP_GEOMETRY = 0x200,
TESSELATE_GEOMETRY = 0x400,
TESSELLATE_GEOMETRY = 0x400,
OPTIMIZE_TEXTURE_SETTINGS = 0x800,
MERGE_GEODES = 0x1000,
FLATTEN_BILLBOARDS = 0x2000,
@@ -353,16 +353,16 @@ class OSGUTIL_EXPORT Optimizer
};
/** Tesselate all geodes, to remove POLYGONS.*/
class OSGUTIL_EXPORT TesselateVisitor : public BaseOptimizerVisitor
/** Tessellate all geodes, to remove POLYGONS.*/
class OSGUTIL_EXPORT TessellateVisitor : public BaseOptimizerVisitor
{
public:
typedef std::set<osg::Group*> GroupList;
GroupList _groupList;
TesselateVisitor(Optimizer* optimizer=0):
BaseOptimizerVisitor(optimizer, TESSELATE_GEOMETRY) {}
TessellateVisitor(Optimizer* optimizer=0):
BaseOptimizerVisitor(optimizer, TESSELLATE_GEOMETRY) {}
virtual void apply(osg::Geode& geode);