[vtkusers] what's the right way to place a volume in a VTK scene?

Mark Wyszomierski markww at gmail.com
Fri Mar 16 07:22:46 EDT 2007


Hi,

What's the right way to load a DICOM volume and place it into VTK 3d space?

Let's say I have a DICOM volume whose first image has an origin at
(90, 20, 20). The DICOM coordinate system matches the VTK coordinate
system exactly. So should I:

1) allocate a vtkImageData object for the appropriate amount of slices
2) then move the volume to the first image's image position patient location
3) then rotate the volume using the first image's image orientation
patient vectors

If I don't do this, the volume ends up sitting at coordinate (0,0,0)
and is perfectly aligned to the x/y/z axes, but this isn't how the
volume was really acquired! I have to then end up creating a mapper
that maps the default VTK positiion coordinates that the volume is
placed at back to the real DICOM coordinates. This works, but I'm
wondering if it's better to do the translation and then rotation of
the volume - so that the volume is placed in its 'real' location as
was scanned by the scanner.

Thanks for any advice,
Mark



More information about the vtkusers mailing list