mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-23 15:40:42 +00:00
quadtreeworld.cpp (#3174)
Currently, we disable a paging root node that we only need in exterior cells by setting its node mask to 0 when transitioning into an interior cell. Node masks are not ideal for this usage case because Node::getBound is unaware of masks. With this PR we just detach the unused node from the scene graph. _shadowedScene->getBound() in the MWShadowTechnique should return a much better value in interior cells with these changes.
This commit is contained in:
parent
c051298848
commit
01605433cb
@ -498,9 +498,8 @@ void QuadTreeWorld::enable(bool enabled)
|
||||
if (!mRootNode->getNumParents())
|
||||
mTerrainRoot->addChild(mRootNode);
|
||||
}
|
||||
|
||||
if (mRootNode)
|
||||
mRootNode->setNodeMask(enabled ? ~0 : 0);
|
||||
else if (mRootNode)
|
||||
mTerrainRoot->removeChild(mRootNode);
|
||||
}
|
||||
|
||||
View* QuadTreeWorld::createView()
|
||||
|
Loading…
x
Reference in New Issue
Block a user