[vtkusers] vtkVolume16Reader: change order of axial slices

Joeri Nicolaes joeri_vtk at hotmail.com
Wed Aug 25 06:28:00 EDT 2004


Hi all,

I have an application to read in 3D medical image data with vtkVolume16Reader and to show the 3 orthogonal views (A,C,S). My problem is that the CT scanner scanned the body from top to bottom, but I want my z-axis to be oriented from bottom to top! How can I change this with vtkVolume16Reader? 
Here is my "read-in code":

# read in the imagedata (in raw vtk format: converted with dicom2.exe)
# image consists of 75 ,512x512 pixels using 16bpp, slices 
set deltaX 7.105113e-01 
set deltaY 7.105113e-01 
set deltaZ 5 
vtkVolume16Reader reader
  reader SetDataDimensions 512 512  
  reader SetDataByteOrderToLittleEndian  
  reader SetFilePrefix "d:/Image/DATARaw/ct"
  reader SetImageRange 1 75 
  reader SetDataSpacing $deltaX $deltaY $deltaZ 
  reader Update    

Has anyone ever encountered the same problem? How to solve it quickly (as you see, I work in Tcl)? 

Thanks on advance,


Joeri,
Agfa Gevaert, R&D/TI
+ 32 (0) 3 444 6429,
stajn at agfa.com
joeri_vtk at hotmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20040825/c8957fcc/attachment.htm>


More information about the vtkusers mailing list