X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FScenery%2FSceneryPager.hxx;h=d8f519a1bc3960255701c0ea058240060efddcb7;hb=f11201d3d93d70d610e32496e363dc7e851e86c5;hp=11bcda889f719414fa1899dd96e2b72e148c19f3;hpb=8d1c97d94b0bc4e8f7f84016c67391c7d6d07e0c;p=flightgear.git diff --git a/src/Scenery/SceneryPager.hxx b/src/Scenery/SceneryPager.hxx index 11bcda889..d8f519a1b 100644 --- a/src/Scenery/SceneryPager.hxx +++ b/src/Scenery/SceneryPager.hxx @@ -19,6 +19,7 @@ // $Id$ #ifndef FLIGHTGEAR_SCENERYPAGERHXX +#define FLIGHTGEAR_SCENERYPAGERHXX 1 #include #include @@ -28,11 +29,6 @@ #include -// Pager request change in OpenSceneGraph 2.5.1 -#if SG_OSG_VERSION >= 25001 -#define FGOSGPAGER25 -#endif - namespace flightgear { class SceneryPager : public osgDB::DatabasePager @@ -42,20 +38,9 @@ public: SceneryPager(const SceneryPager& rhs); // Unhide DatabasePager::requestNodeFile using osgDB::DatabasePager::requestNodeFile; - // reimplement to add readerWriterOptions from SGPagedLOD - virtual void requestNodeFile(const std::string& fileName, osg::Group* group, - float priority, - const osg::FrameStamp* framestamp, -#ifdef FGOSGPAGER25 - osg::ref_ptr& - databaseRequest -#endif - ); void queueRequest(const std::string& fileName, osg::Group* node, float priority, osg::FrameStamp* frameStamp, -#ifdef FGOSGPAGER25 osg::ref_ptr& databaseRequest, -#endif osgDB::ReaderWriter::Options* options); // This is passed a ref_ptr so that it can "take ownership" of the // node to delete and decrement its refcount while holding the @@ -74,30 +59,14 @@ protected: PagerRequest(const std::string& fileName, osg::Group* group, float priority, osg::FrameStamp* frameStamp, -#ifdef FGOSGPAGER25 osg::ref_ptr& databaseRequest, -#endif osgDB::ReaderWriter::Options* options): _fileName(fileName), _group(group), _priority(priority), _frameStamp(frameStamp), _options(options), -#ifdef FGOSGPAGER25 _databaseRequest(&databaseRequest) -#else - _databaseRequest(0) -#endif {} - void doRequest(SceneryPager* pager) - { - if (_group->getNumChildren() == 0) - pager->requestNodeFile(_fileName, _group.get(), _priority, - _frameStamp.get(), -#ifdef FGOSGPAGER25 - *_databaseRequest, -#endif - _options.get()); - } - + void doRequest(SceneryPager* pager); std::string _fileName; osg::ref_ptr _group; float _priority; @@ -112,5 +81,4 @@ protected: virtual ~SceneryPager(); }; } -#define FLIGHTGEAR_SCENERYPAGERHXX 1 #endif