[Insight-users] cannot return vtkImageData from itkImageToVTKImageFilter

Prathamesh Kulkarni prathameshmkulkarni at gmail.com
Wed Sep 21 23:38:11 EDT 2011


Hello,

I am trying to implement a pipeline looking like this:

Foo1(){

// ITK filters.....

vtkSmartPointer<vtkImageData> vtk_image = Foo2(ITK_data_ptr);

Render(vtk_image);
}

vtkSmartPointer<vtkImageData> Foo2(ITK_data_ptr){

//Process ITK data

// Convert ITK image to VTK image

// Process VTK image data

return VTK image data;
}


However, using the above pipeline, I can only render inside Foo2. Rendering
inside Foo1 (as shown above) always crashes pointing to itkVTKImageExport.h.
Is there a better way of dealing this while still following the above
pipeline?

Thanks,
Prathamesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110921/621445ce/attachment.htm>


More information about the Insight-users mailing list