Warning fixes

git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.2@14779 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
Robert Osfield
2015-03-11 17:47:30 +00:00
parent 3461d9e8b5
commit 499e38ff98

View File

@@ -24,7 +24,7 @@ using namespace Imath;
/****************************************************************************
*
* Follows is code written by FOI (www.foi.se)
* it is a wraper of openEXR(www.openexr.com)
* it is a wrapper of openEXR(www.openexr.com)
* to add suport of exr images into osg
*
* Ported to a OSG-plugin, Ragnar Hammarqvist.
@@ -92,7 +92,7 @@ unsigned char *exr_load(std::istream& fin,
unsigned char *buffer=NULL; // returned to sender & as read from the disk
bool inputError = false;
Array2D<Rgba> pixels;
int width,height,numComponents;
int width=0,height=0,numComponents;
try
{
@@ -111,6 +111,7 @@ unsigned char *exr_load(std::istream& fin,
rgbafile.readPixels(dw.min.y, dw.max.y);
}
catch( char * str ) {
OSG_WARN << "exr_load error : " << str << std::endl;
inputError = true;
}
@@ -335,6 +336,7 @@ protected:
}
catch( char * str )
{
OSG_WARN << "writeEXRStream error : " << str << std::endl;
writeOK = false;
}