Handle OpenEXR exception and print it, for writeTile. It's sometimes
authorBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 28 Jan 2008 21:28:32 +0000 (21:28 +0000)
committerBrecht Van Lommel <brechtvanlommel@pandora.be>
Mon, 28 Jan 2008 21:28:32 +0000 (21:28 +0000)
crashing there now with FSA, if it crashes again this should give
more info.

source/blender/imbuf/intern/openexr/openexr_api.cpp

index 3cbada812b9da8868c155f55b1f748bd24465544..b124cb2f80cdef9fcc02205e530b63755b86a305 100644 (file)
@@ -547,9 +547,14 @@ void IMB_exrtile_write_channels(void *handle, int partx, int party)
        }
        
        data->tofile->setFrameBuffer (frameBuffer);
-       // printf("write tile %d %d\n", partx/data->tilex, party/data->tiley);
-       data->tofile->writeTile (partx/data->tilex, party/data->tiley); 
-       
+
+       try {
+               // printf("write tile %d %d\n", partx/data->tilex, party/data->tiley);
+               data->tofile->writeTile (partx/data->tilex, party/data->tiley); 
+       }
+       catch (const std::exception &exc) {
+               std::cerr << "OpenEXR-writeTile: ERROR: " << exc.what() << std::endl;
+       }
 }
 
 void IMB_exr_write_channels(void *handle)