Added an optional use of doubles for computing error metrics to help investigate precision issues seen in VPB when working with small segments of geographic data.

This commit is contained in:
Robert Osfield
2007-12-20 15:50:07 +00:00
parent f8253ca4bd
commit 2c0842c7b7
2 changed files with 35 additions and 22 deletions

View File

@@ -28,7 +28,7 @@ class OSGUTIL_EXPORT Simplifier : public osg::NodeVisitor
{
public:
Simplifier(float sampleRatio=1.0f, float maximumError=FLT_MAX, float maximumLength=0.0);
Simplifier(double sampleRatio=1.0, double maximumError=FLT_MAX, double maximumLength=0.0);
void setSampleRatio(float sampleRatio) { _sampleRatio = sampleRatio; }
@@ -104,9 +104,9 @@ class OSGUTIL_EXPORT Simplifier : public osg::NodeVisitor
protected:
float _sampleRatio;
float _maximumError;
float _maximumLength;
double _sampleRatio;
double _maximumError;
double _maximumLength;
bool _triStrip;
bool _smoothing;