From bd82d2a52d3f791eb562d386f5c5e5ae7bef073b Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Tue, 24 Jun 2014 14:58:13 +0000 Subject: [PATCH] From Farshid Lashkari, "I've attached a small for the osg ReaderWriter. It was performing a case sensitive comparison to the file extension to determine whether to write the file in ascii or binary. This meant that if the filename was "model.OSGT" it would be treated as binary, instead of ascii. I've updated the plugin to ignore case." git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14267 16af8721-9629-0410-8352-f15c8da7e697 --- src/osgPlugins/osg/ReaderWriterOSG2.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/osgPlugins/osg/ReaderWriterOSG2.cpp b/src/osgPlugins/osg/ReaderWriterOSG2.cpp index cdf425551..82f6d533a 100644 --- a/src/osgPlugins/osg/ReaderWriterOSG2.cpp +++ b/src/osgPlugins/osg/ReaderWriterOSG2.cpp @@ -257,7 +257,7 @@ public: Options* prepareWriting( WriteResult& result, const std::string& fileName, std::ios::openmode& mode, const Options* options ) const { - std::string ext = osgDB::getFileExtension( fileName ); + std::string ext = osgDB::getLowerCaseFileExtension( fileName ); if ( !acceptsExtension(ext) ) result = WriteResult::FILE_NOT_HANDLED; osg::ref_ptr local_opt = options ?