Restore the special capability of the btg reader to read compressed files.

Modified Files:
 	scene/tgdb/SGReaderWriterBTG.cxx
 	scene/tgdb/SGReaderWriterBTG.hxx
This commit is contained in:
frohlich
2009-05-19 05:30:16 +00:00
committed by Tim Moore
parent 7cd149a4d8
commit 8f7527ede0
2 changed files with 10 additions and 0 deletions

View File

@@ -45,6 +45,15 @@ const char* SGReaderWriterBTG::className() const
return "BTG Database reader";
}
bool
SGReaderWriterBTG::acceptsExtension(const std::string& extension) const
{
std::string lowercase_ext = osgDB::convertToLowerCase(extension);
if (lowercase_ext == "gz")
return true;
return osgDB::ReaderWriter::acceptsExtension(extension);
}
osgDB::ReaderWriter::ReadResult
SGReaderWriterBTG::readNode(const std::string& fileName,
const osgDB::ReaderWriter::Options* options) const

View File

@@ -28,6 +28,7 @@ public:
virtual const char* className() const;
virtual bool acceptsExtension(const std::string& /*extension*/) const;
virtual ReadResult readNode(const std::string& fileName,
const osgDB::ReaderWriter::Options* options)
const;