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:
@@ -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
|
||||
|
||||
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user