[*] osgDB::OutputStream fix

This commit is contained in:
konstantin.matveyev 2017-07-30 20:00:12 +03:00
parent 700dd2b9a7
commit 2c35b63d38

View File

@ -18,7 +18,7 @@
#include <osgDB/FileUtils> #include <osgDB/FileUtils>
#include <osgDB/WriteFile> #include <osgDB/WriteFile>
#include <osgDB/ObjectWrapper> #include <osgDB/ObjectWrapper>
#include <fstream> #include <osgDB/fstream>
#include <sstream> #include <sstream>
#include <stdlib.h> #include <stdlib.h>
@ -559,7 +559,7 @@ void OutputStream::writeImage( const osg::Image* img )
if ( isBinary() ) if ( isBinary() )
{ {
std::string fullPath = osgDB::findDataFile( img->getFileName() ); std::string fullPath = osgDB::findDataFile( img->getFileName() );
std::ifstream infile( fullPath.c_str(), std::ios::in|std::ios::binary ); osgDB::ifstream infile( fullPath.c_str(), std::ios::in|std::ios::binary );
if ( infile ) if ( infile )
{ {
infile.seekg( 0, std::ios::end ); infile.seekg( 0, std::ios::end );