From c1e50e9a9cdce207277f42e4049c875c22894780 Mon Sep 17 00:00:00 2001 From: Stuart Buchanan Date: Tue, 8 Nov 2016 20:06:34 +0000 Subject: [PATCH] Correct mesh size correction for building LOD ranges --- simgear/scene/tgdb/ReaderWriterSTG.cxx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/simgear/scene/tgdb/ReaderWriterSTG.cxx b/simgear/scene/tgdb/ReaderWriterSTG.cxx index 49f2532f..ca6f4ef2 100644 --- a/simgear/scene/tgdb/ReaderWriterSTG.cxx +++ b/simgear/scene/tgdb/ReaderWriterSTG.cxx @@ -286,11 +286,10 @@ struct ReaderWriterSTG::_ModelBin { bool read(const std::string& absoluteFileName, const osgDB::Options* options) { - - // Determine object ranges. Mesh size needs to be accounted for. - _object_range_bare = 2000.0f + atof(options->getPluginStringData("SimGear::LOD_RANGE_BARE").c_str()); - _object_range_rough = 2000.0f + atof(options->getPluginStringData("SimGear::LOD_RANGE_ROUGH").c_str()); - _object_range_detailed = 2000.0f + atof(options->getPluginStringData("SimGear::LOD_RANGE_DETAILED").c_str()); + // Determine object ranges. Mesh size of 2000mx2000m needs to be accounted for. + _object_range_bare = 1414.0f + atof(options->getPluginStringData("SimGear::LOD_RANGE_BARE").c_str()); + _object_range_rough = 1414.0f + atof(options->getPluginStringData("SimGear::LOD_RANGE_ROUGH").c_str()); + _object_range_detailed = 1414.0f + atof(options->getPluginStringData("SimGear::LOD_RANGE_DETAILED").c_str()); _building_mesh_enabled = (options->getPluginStringData("SimGear::RENDER_BUILDING_MESH") == "true"); if (absoluteFileName.empty())