Catch exception when failing to write image.

Output transformation when writing grid.
This commit is contained in:
mkazhdan
2019-01-27 18:16:08 -05:00
parent f4f47883db
commit 3107d150fb
6 changed files with 83 additions and 59 deletions
+1 -1
View File
@@ -139,7 +139,7 @@ struct RGBPixel
void WriteImage( char* fileName , RGBPixel* pixels , int w , int h )
{
unsigned int _w = w , _h = h , _c = 3;
if( !ImageWriter::Write( fileName , (const unsigned char*)pixels , _w , _h , _c ) ) ERROR_OUT( "Could not write image to: %s" , fileName );
ImageWriter::Write( fileName , (const unsigned char*)pixels , _w , _h , _c );
}
struct Profiler