using namespace osg;
using namespace simgear;
+bool SGPagedLOD::_cache = true;
+
SGPagedLOD::SGPagedLOD()
: PagedLOD()
{
{
}
+void
+SGPagedLOD::setReaderWriterOptions(osgDB::ReaderWriter::Options *options)
+{
+ if (_cache)
+ options->setObjectCacheHint(osgDB::ReaderWriter::Options::CACHE_ALL);
+ else
+ options->setObjectCacheHint(osgDB::ReaderWriter::Options::CACHE_NONE);
+#if SG_PAGEDLOD_HAS_OPTIONS
+ setDatabaseOptions(options);
+#else
+ _readerWriterOptions = options;
+#endif
+}
+
bool SGPagedLOD::addChild(osg::Node *child)
{
if (!PagedLOD::addChild(child))