OcclusionQueryNode: ensure a valid query geometry

If the query geometry is invalid then don't do any occlusion queries and
never traverse the subgraphs.
This commit is contained in:
Daniel Trstenjak
2019-01-29 11:37:28 +01:00
committed by Robert Osfield
parent 9905b90a18
commit 5624a22fe4
2 changed files with 35 additions and 8 deletions

View File

@@ -198,6 +198,9 @@ protected:
bool _enabled;
// If the box of the query geometry is valid.
mutable bool _validQueryGeometry;
// Tracks the last frame number that we performed a query.
// User can set how many times (See setQueryFrameCount).
typedef std::map< const osg::Camera*, unsigned int > FrameCountMap;