diff --git a/src/osgPlugins/txp/ReaderWriterTXP.cpp b/src/osgPlugins/txp/ReaderWriterTXP.cpp index 554fbb122..f720b4bab 100644 --- a/src/osgPlugins/txp/ReaderWriterTXP.cpp +++ b/src/osgPlugins/txp/ReaderWriterTXP.cpp @@ -66,6 +66,8 @@ osgDB::ReaderWriter::ReadResult ReaderWriterTXP::readNode(const std::string& fil return ReadResult::ERROR_IN_READING_FILE; osg::ref_ptr tileContent = getTileContent(info,x,y,lod,archive); + + tileContent->setName("TileContent"); int numLods = archive->getNumLODs(); if (lod < (numLods-1)) @@ -124,6 +126,8 @@ osgDB::ReaderWriter::ReadResult ReaderWriterTXP::readNode(const std::string& fil osg::ref_ptr tileContent = getTileContent(info,tileX,tileY,tileLOD,archive); + tileContent->setName("TileContent"); + if (tileLOD < (numLods-1)) { char pagedLODfile[1024]; diff --git a/src/osgPlugins/txp/TileMapper.cpp b/src/osgPlugins/txp/TileMapper.cpp index 1fb7f51f8..82ce5bf83 100644 --- a/src/osgPlugins/txp/TileMapper.cpp +++ b/src/osgPlugins/txp/TileMapper.cpp @@ -44,6 +44,12 @@ float TileMapper::getDistanceFromEyePoint(const osg::Vec3& pos, bool withLODScal void TileMapper::apply(osg::Node& node) { + if (node.getName()=="TileContent") + { + _containsGeode = true; + return; + } + if (isCulled(node)) return; // push the culling mode. @@ -57,6 +63,12 @@ void TileMapper::apply(osg::Node& node) void TileMapper::apply(osg::Group& node) { + if (node.getName()=="TileContent") + { + _containsGeode = true; + return; + } + if (isCulled(node)) return; // push the culling mode. @@ -348,7 +360,7 @@ void TileMapper::checkValidityOfAllVisibleTiles() } while (!toRemoveList.empty()); - if (!_blackListedNodeSet.empty()) std::cout<<"********** We have blacked list "<<_blackListedNodeSet.size()<