Hello everyone,<br><br>I am working on 3D rigid transformation, I basically use the example code ImageRegistration8.cxx. The difference is that I load my dicom data with a loader which returns a vtkImage, then convert it to itk::Image with itk::VTKImageToImageFilter (VTK2ITKconnector). I replaced the output of fixedImageReader (I am no longer using ImageFileReader) with the output of VTK2ITKconnector and I encountered such a problem:<br>
<br>ExceptionObject caught !<br><br>itk::ExceptionObject (0xa9a9490)<br>Location: "void itk::ImageToImageMetric<TFixedImage, TMovingImage>::Initialize() [with TFixedImage = itk::Image<double, 3u>, TMovingImage = itk::Image<double, 3u>]"<br>
File: /usr/local/ITK/ITK/Code/Algorithms/itkImageToImageMetric.txx<br>Line: 93<br>Description: itk::ERROR: MeanSquaresImageToImageMetric(0xa9a9b70): FixedImageRegion is empty<br><br><br>Is this error stemming from the VTK2ITKconnector or the loader? I guess the loader works fine as I checked its output with a renderer. Here is the code for the VTK2ITKconnector:<br>
<br> typedef itk::Image< double, 3 > InputImageType;<br> typedef itk::VTKImageToImageFilter< InputImageType > VTK2ITKConnectorFilterType;<br> VTK2ITKConnectorFilterType::Pointer VTK2ITKconnector = VTK2ITKConnectorFilterType::New();<br>
VTK2ITKconnector->SetInput( CT -> dataScalar -> getImageArray() ); // The expression in the paranthesis is actually a vtkImage.<br><br>I appreciate your answers in advance.<br>
<br clear="all"><br>-- <br>Vural Ozbudak<br>Bogazici University, Istanbul<br><a href="http://vavlab.ee.boun.edu.tr">vavlab.ee.boun.edu.tr</a><br>