Introduced CMake build option for compiling double or float versions of osg::BoundingSphere and osg::BoundingBox.

Introduced code in BoundgingSphere, BoundingBox, ProxyNode and LOD to utilise the above settings.

Added Matrix::value_type, Plane::value_type, BoundingSphere::value_type and BoundingBox::value_type command line 
options that report where the types of floats or doubles.
This commit is contained in:
Robert Osfield
2008-04-03 18:36:50 +00:00
parent fe5c019608
commit 2a54ff3e4a
11 changed files with 225 additions and 78 deletions

View File

@@ -105,7 +105,7 @@ void NodeTrackerManipulator::setNode(osg::Node* node)
const osg::BoundingSphere& boundingSphere=_node->getBound();
const float minimumDistanceScale = 0.001f;
_minimumDistance = osg::clampBetween(
boundingSphere._radius * minimumDistanceScale,
float(boundingSphere._radius) * minimumDistanceScale,
0.00001f,1.0f);
osg::notify(osg::INFO)<<"Setting Tracker manipulator _minimumDistance to "<<_minimumDistance<<std::endl;