To handle thread safe paging and use of the osgDB::Registry ObjectCache, moved the handling of cache into osgDB::DatabasePager.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14472 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
@@ -311,13 +311,19 @@ class OSGDB_EXPORT DatabasePager : public osg::NodeVisitor::DatabaseRequestHandl
|
||||
_timestampLastRequest(0.0),
|
||||
_priorityLastRequest(0.0f),
|
||||
_numOfRequests(0),
|
||||
_groupExpired(false)
|
||||
_groupExpired(false),
|
||||
_insertLoadedSubgraphIntoObjectCache(false)
|
||||
{}
|
||||
|
||||
void invalidate();
|
||||
|
||||
bool valid() const { return _valid; }
|
||||
|
||||
bool isRequestCurrent (int frameNumber) const
|
||||
{
|
||||
return _valid && (frameNumber - _frameNumberLastRequest <= 1);
|
||||
}
|
||||
|
||||
bool _valid;
|
||||
std::string _fileName;
|
||||
unsigned int _frameNumberFirstRequest;
|
||||
@@ -337,10 +343,7 @@ class OSGDB_EXPORT DatabasePager : public osg::NodeVisitor::DatabaseRequestHandl
|
||||
osg::observer_ptr<osgUtil::IncrementalCompileOperation::CompileSet> _compileSet;
|
||||
bool _groupExpired; // flag used only in update thread
|
||||
|
||||
bool isRequestCurrent (int frameNumber) const
|
||||
{
|
||||
return _valid && (frameNumber - _frameNumberLastRequest <= 1);
|
||||
}
|
||||
bool _insertLoadedSubgraphIntoObjectCache;
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user