Merge pull request #918 from LaurensVoerman/proxy-3.6

fix bug in ProxyNode with DEFER_LOADING_TO_DATABASE_PAGER
This commit is contained in:
OpenSceneGraph git repository 2020-03-13 08:46:29 +00:00 committed by GitHub
commit 1bd75f464a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1646,7 +1646,12 @@ void DatabasePager::addLoadedDataToSceneGraph(const osg::FrameStamp &frameStamp)
osg::ProxyNode* proxyNode = dynamic_cast<osg::ProxyNode*>(group.get());
if (proxyNode)
{
proxyNode->getDatabaseRequest(proxyNode->getNumChildren()) = 0;
for (unsigned int i = 0; i < proxyNode->getNumFileNames(); ++i) {
if (proxyNode->getDatabaseRequest(i) == databaseRequest) {
proxyNode->getDatabaseRequest(i) = 0;
break;
}
}
}
}