From d0821fb395eee271db5fe469bb77456e70e3e77f Mon Sep 17 00:00:00 2001 From: srit Date: Wed, 6 Apr 2011 11:28:15 +0000 Subject: [PATCH] Conversion from itk to vtk was catching exceptions for us => update itk pipeline prior to conversion --- common/vvImage.txx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/common/vvImage.txx b/common/vvImage.txx index a84fa76..c3491f8 100755 --- a/common/vvImage.txx +++ b/common/vvImage.txx @@ -4,6 +4,10 @@ template void vvImage::AddItkImage(TItkImageType *input) { + // Update input before conversion to enable exceptions thrown by the ITK pipeline. + // Otherwise, vtkImageImport catches the exception for us. + input->Update(); + // Convert from ITK object to VTK object mImageDimension = TItkImageType::ImageDimension; typedef itk::ImageToVTKImageFilter ConverterType; -- 2.47.1