[Insight-users] How to visualize itk::SpatialObjects in VTK?

David Doria daviddoria at gmail.com
Wed Jul 13 15:57:10 EDT 2011


2011/4/28 Huoling Luo <shuiling119 at hotmail.com>

>  Hi itk experts,
>
> Can anyone tell me how to visualize itk::SpatialObjects in VTK?
>
> For example, the code snip:
> /////////////////////////////////////////////
> typedef itk::CylinderSpatialObject   CylinderType;
> CylinderType::Pointer myCylinder = CylinderType::New();
>
> double radius = 3.0;
> myCylinder->SetRadius(radius);
>
> double height = 12.0;
> myCylinder->SetHeight(height);
> /////////////////////////////////////////////
>
> How can I visualize "myCylinder" in VTK? I've known that we can visualize
> itk::Mesh objects by using class itkMeshTovtkPolyData. What about
> itk::SpatialObject?
>
> Thank you!
>
> Best Regards,
>
> Huoling
>

Apparently this SOViewer (Spatial Object Viewer) is what you should use:

http://www.vtk.org/Wiki/SOViewer

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110713/808708bc/attachment.htm>


More information about the Insight-users mailing list