[Insight-users] rotating data with in a 3D array

Luis Ibanez luis.ibanez at kitware.com
Fri Sep 9 11:27:45 EDT 2005


Hi Rama,

Please read the ITK Software Guide.

    http://www.itk.org/ItkSoftwareGuide.pdf

In particular, you should read Section 6.9,
"Geometric Transformations" in pdf-page 249.


This section describes in detail how to use the

              itk::ResampleImageFilter<>

in order to apply rotations and translation to images.


Note that for a rotation you probably want to use the
itk::VersorRigid3DTransform, as described in that section,
and you want to initilize the transform using the
itk::CenteredTransformInitializer.


Source code for these examples is available in


      Insight/Examples/Filtering/
            ResampleImageFilter.cxx
            ResampleImageFilter2.cxx
            ResampleImageFilter3.cxx
            ResampleImageFilter4.cxx
            ResampleImageFilter5.cxx
            ResampleImageFilter6.cxx
            ResampleImageFilter7.cxx
            ResampleImageFilter8.cxx
            ResampleImageFilter9.cxx



   Regards,


      Luis



--------------------
rama wrote:
> Hi,
> 
> I am looking for a way to rotate data within a 3D array. I have a 3D 
> array with dimensions X*Y*Z with each value being an integer in the 
> range 0-255 which actually represents a gray scale 3D image.
> Now I want to rotate the image in that array, by this I mean, I want to 
> rotate the data with in that 3D array and store the result in the array 
> of same dimensions.
> 
> I have come accross the MultiResMIRegistration example in ITK 2.0.0 
> distribution. I have seen it rotating a 3D data set (array) to register 
> with another 3D data set. I have seen its code but there is little help 
> in it. I have also seen the Transform class in ITK. But it doesn't give 
> any information about how to trigger the transformation and will it 
> transform the whole 3D array in a single go.
> 
> Can anyone give an idea of how to do rotations on data with in a 3D array.
> 
> thanks,
> Rama.
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
> 
> 



More information about the Insight-users mailing list