Added support for float or double osg::Plane, and the default osg::Plane to double.

Performance tests on big models did not indicate any performance penalty in using doubles over floats,
so the move to doubles should mainly impact precision improvements for whole earth databases.

Also made improvements to osgUtil::PlaneIntersector and osgSim::ElevationSlice classes
This commit is contained in:
Robert Osfield
2006-11-28 16:00:52 +00:00
parent 5e1c5cd556
commit 345810ef22
14 changed files with 262 additions and 135 deletions

View File

@@ -272,10 +272,10 @@ void DataOutputStream::writeVec4d(const osg::Vec4d& v){
void DataOutputStream::writePlane(const osg::Plane& v)
{
writeFloat(v[0]);
writeFloat(v[1]);
writeFloat(v[2]);
writeFloat(v[3]);
writeDouble(v[0]);
writeDouble(v[1]);
writeDouble(v[2]);
writeDouble(v[3]);
if (_verboseOutput) std::cout<<"read/writePlane() ["<<v<<"]"<<std::endl;
}