[Insight-users] VectorImage Orientation from NRRD

Luis Ibanez luis.ibanez at kitware.com
Thu Oct 16 08:54:50 EDT 2008


Hi Karthk, Gordon,


This problem has been solved since September 13th 2008.


Simply turn on the CMake flag:


           ITK_IMAGE_BEHAVES_AS_ORIENTED_IMAGE


That will make the itk::Image behave like the itk::OrientedImage.


Since the itk::VectorImage derives from the itk::Image, then
the correct behavior will also be inherited.


    Thanks


       Luis



-------------------------
Karthik Krishnan wrote:
> Dan, Gordon:
> 
> As you've already realized Dan, itk::VectorImage provides no more (and 
> no less)
> support for direction cosines than itk::Image. They simply ignore it and 
> do not,
> unlike itk::OrientedImage, take it into account when translating indices 
> into
> world coordinates, or use it when computing derivatives on images.
> 
> NRRD, I believe, allows for encoding both the patient coordinate system
> (represented by space_origin and space_directions) and additional
> coordinate systems pertinent to DWI images (gradient coil's directions).
> Whatever direction cosines it will set on itk::Image or itk::VectorImage 
> are
> ignored.
> 
> In retrospect, I mistakenly derived VectorImage from ImageBase, rather
> than OrientedImage, but both classes came out the same year, when
> OrientedImage was still in its infancy with a CVS log stating
> "It may be removed be before the next release".
> 
> As a solution, the VectorImage class could quite easily be made to
> take into account of the direction cosines exactly as OrientedImage does,
> by just copying the methods over from OrientedImage. Perhaps that
> could be on the list of things ToDo whenever the next lengthy
> discussion on Orientation comes up in ITK. I think we have one
> every month. :)
> 
> Thanks
> 


More information about the Insight-users mailing list