Remove CheckGeometryVisitor which was a no-op

This commit is contained in:
scrawl 2017-01-20 23:02:15 +01:00
parent 4a05caf4f7
commit f13fbff251
2 changed files with 1 additions and 37 deletions

View File

@ -73,7 +73,7 @@ class OSGUTIL_EXPORT Optimizer
COMBINE_ADJACENT_LODS = (1 << 3),
SHARE_DUPLICATE_STATE = (1 << 4),
MERGE_GEOMETRY = (1 << 5),
CHECK_GEOMETRY = (1 << 6),
CHECK_GEOMETRY = (1 << 6), // deprecated, currently no-op
MAKE_FAST_GEOMETRY = (1 << 7),
SPATIALIZE_GROUPS = (1 << 8),
COPY_SHARED_NODES = (1 << 9),
@ -501,20 +501,6 @@ class OSGUTIL_EXPORT Optimizer
};
class OSGUTIL_EXPORT CheckGeometryVisitor : public BaseOptimizerVisitor
{
public:
/// default to traversing all children.
CheckGeometryVisitor(Optimizer* optimizer=0):
BaseOptimizerVisitor(optimizer, CHECK_GEOMETRY) {}
virtual void apply(osg::Geometry& geom);
void checkGeode(osg::Geode& geode);
};
class OSGUTIL_EXPORT MakeFastGeometryVisitor : public BaseOptimizerVisitor
{
public:

View File

@ -50,8 +50,6 @@
using namespace osgUtil;
// #define GEOMETRYDEPRECATED
void Optimizer::reset()
{
}
@ -290,14 +288,6 @@ void Optimizer::optimize(osg::Node* node, unsigned int options)
OSG_INFO<<"MERGE_GEODES took "<<osg::Timer::instance()->delta_s(startTick,endTick)<<std::endl;
}
if (options & CHECK_GEOMETRY)
{
OSG_INFO<<"Optimizer::optimize() doing CHECK_GEOMETRY"<<std::endl;
CheckGeometryVisitor mgv(this);
node->accept(mgv);
}
if (options & MAKE_FAST_GEOMETRY)
{
OSG_INFO<<"Optimizer::optimize() doing MAKE_FAST_GEOMETRY"<<std::endl;
@ -1732,20 +1722,8 @@ struct LessGeometryPrimitiveType
}
};
void Optimizer::CheckGeometryVisitor::apply(osg::Geometry& geom)
{
if (isOperationPermissibleForObject(&geom))
{
#ifdef GEOMETRYDEPRECATED
geom
.computeCorrectBindingsAndArraySizes();
#endif
}
}
void Optimizer::MakeFastGeometryVisitor::apply(osg::Geometry& geom)
{
// GeometryDeprecated CAN REMOVED
if (isOperationPermissibleForObject(&geom))
{
if (geom.checkForDeprecatedData())