[Insight-users] How to downsample image?

Luis Ibanez luis.ibanez at kitware.com
Mon Feb 9 11:49:55 EST 2009


Hi Huanxiang,

The itkResampleImageFilter works fine for subsampling an image.

It is actually one of the examples in the Insight/Example/Filtering
directory.


Please look at:

     Insight/Examples/Filtering/
                          SubsampleVolume.cxx

You simply need to use the itkIdentityTransform, keep the origin
and orientation, while chanching the output image spacing and the
output image size (in pixels)


That being said,
you could also use the filter

            itkShrinkImageFilter
http://www.itk.org/Insight/Doxygen/html/classitk_1_1ShrinkImageFilter.html



    Regards,


        Luis

---------------
Huanxiang Lu wrote:
> Hello everyone,
> 
>  
> 
> Do you know if there is a simple way in ITK that we can downsample the 
> image? I tried itkResampleImageFilter, but it seems not working in that 
> case.
> 
>  
> 
> Thanks a lot!
> 
> _____________________________________________ 
> 
> Huanxiang Lu
> 
> Ph.D. Student, Medical Image Analysis
> 
>  
> 
> University of Bern
> 
> ARTORG Center for Biomedical Engineering Research 
> 
> Stauffacherstrasse 78
> 
> CH-3014 Bern
> 
> Tel +41 31 631 59 49
> 
> Fax +41 31 631 59 60
> 
> huanxiang.lu at artorg.unibe.ch <mailto:huanxiang.lu at artorg.unibe.ch>
> 
> www.artorg.unibe.ch/ <http://www.artorg.unibe.ch/>
> 
>  
> 
> 
> ------------------------------------------------------------------------
> 
> _____________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
> 
> Please keep messages on-topic and check the ITK FAQ at: http://www.itk.org/Wiki/ITK_FAQ
> 
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users


More information about the Insight-users mailing list