[osg-users] [osgPlugins] osgDB::readImageFile() chooses ffmpeg over libpng
Paul
aquawicket at hotmail.com
Fri Jun 5 18:35:09 PDT 2015
My fix for this:
Upon inspection of ReaderWriterPNG.cpp
line - 371
Code:
virtual ReadResult readImage(const std::string& file, const osgDB::ReaderWriter::Options* options) const
{
std::string ext = osgDB::getLowerCaseFileExtension(file);
if (!acceptsExtension(ext)) return ReadResult::FILE_NOT_HANDLED;
.
.
.
if (!acceptsExtension(ext)) return ReadResult::FILE_NOT_HANDLED; seems to filter the plugin's accepted extensions.
I've altered ReaderWriterFFmpeg.cpp to include this as well..
Code:
line - 135
virtual ReadResult readImage(const std::string & filename, const osgDB::ReaderWriter::Options* options) const
{
const std::string ext = osgDB::getLowerCaseFileExtension(filename);
if (!acceptsExtension(ext)) return ReadResult::FILE_NOT_HANDLED;
.
.
.
Not sure if this is the proper fix.. but it works for me.
------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=63963#63963
More information about the osg-users
mailing list