[Insight-developers] [GDCM] ITK Origin and coordinate system

Peter Cech pcech at vision.ee.ethz.ch
Wed Jan 18 10:27:35 EST 2006


On Tue, Jan 17, 2006 at 19:40:51 -0700, Gordon Kindlmann wrote:
> So, can someone tell me why the following is not the case with DICOM  
> in ITK:
> 
> * The (0x0020,0x0037) "Image Orientation (Patient)" tag gives you two  
> unit-length vectors which you put in the first two columns of your  
> "M" matrix.
> 
> * The (0x0028,0x0030) "Pixel Spacing" tag gives you two scalars that  
> you put in the first two diagonal entries of "S".
> 
> * You take the difference between the (0x0020,0x0032) "Image Position  
> (Patient)" tags of any two successive slices, call this vector D.   
> Put D/|D| (normalized) in the third column of "M", and put |D| in the  
> third and final diagonal entry of "S".

Current implementation differs from your description. The third column
is a cross product of first and second column. In my opinion, algorithm
for third column you described is the correct one and current ITK
implementation may give wrong direction matrix in two cases:

1. Third base vector of the volume is not perpendicular to other two.
   Technically feasible, but might not be in wide use.

2. Third base vector should point in opposite direction.

> * The (0x0020,0x0032) "Image Position (Patient)" tag of the very  
> first image (of the series) gives you "Origin".

Regards,
Peter


More information about the Insight-developers mailing list