From 8c4ab92117329fffd6296889c5a866313b14001e Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Mon, 8 Nov 2004 19:56:22 +0000 Subject: [PATCH] Added resolutionSensitivityScale of 0.9 into the DataSet::createDestinationGraph() to prevent overly conservative subdivision of data. --- src/osgTerrain/DataSet.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/osgTerrain/DataSet.cpp b/src/osgTerrain/DataSet.cpp index ba6a34abf..44a370fe7 100644 --- a/src/osgTerrain/DataSet.cpp +++ b/src/osgTerrain/DataSet.cpp @@ -3226,11 +3226,15 @@ DataSet::CompositeDestination* DataSet::createDestinationGraph(CompositeDestinat unsigned int texture_numRows; double texture_dx; double texture_dy; + double resolutionSensitivityScale = 0.9; if (tile->computeImageResolution(texture_numColumns,texture_numRows,texture_dx,texture_dy)) { - if (texture_dx>tile->_imagery_maxSourceResolutionX) needToDivideX = true; - if (texture_dy>tile->_imagery_maxSourceResolutionY) needToDivideY = true; + if (texture_dx*resolutionSensitivityScale>tile->_imagery_maxSourceResolutionX) needToDivideX = true; + if (texture_dy*resolutionSensitivityScale>tile->_imagery_maxSourceResolutionY) needToDivideY = true; } + + osg::notify(osg::NOTICE)<<"texture_dx="<_imagery_maxSourceResolutionX<