From Roger James, "I have been going through my modified osg files and came across this fix to the Tesselator. From memory it handles a problem with per primitive normal binding. I must have forgotten to submit it."

This commit is contained in:
Robert Osfield
2006-08-28 19:01:03 +00:00
parent 19f3d975dd
commit 70470bc84a
2 changed files with 26 additions and 7 deletions

View File

@@ -120,7 +120,7 @@ class OSGUTIL_EXPORT Tesselator : public osg::Referenced
* these will leak memory if not removed when retesselating. */
void reduceArray(osg::Array * cold, const unsigned int nnu);
void collectTesselation(osg::Geometry &cxgeom);
void collectTesselation(osg::Geometry &cxgeom, unsigned int originalIndex);
typedef std::map<osg::Vec3*,unsigned int> VertexPtrToIndexMap;
void addContour(GLenum mode, unsigned int first, unsigned int last, osg::Vec3Array* vertices);
@@ -236,6 +236,9 @@ class OSGUTIL_EXPORT Tesselator : public osg::Referenced
/** the gluTessNormal for tesselation hint */
osg::Vec3 tessNormal;
/** count of number of extra primitives added */
unsigned int _extraPrimitives;
};
}