[Insight-users] Re: Resizing an Image
Luis Ibanez
luis.ibanez at kitware.com
Fri Apr 28 14:53:54 EDT 2006
Hi Balaji,
Yes, the ResampleImageFilter should work for TIF images.
ITK filters are independent of the file format that you use
for storing your images. Once the image is loaded into
memory by a reader, you can apply any ITK filter on it.
The only restrictions are related to the pixel type and
the nature of the processing.
What pixel type are you using ?
How many bits per pixels do your TIF images have ?
Please let us know,
Thanks
Luis
=======================
Balaji Gandhi wrote:
> Hi Luis,
>
> Does the "Resample Image Filter" work for TIF files? It worked fine for
> PNG but for TIF it outputs a blank image.
>
> Please let me know.
>
> Thanks,
> Balaji
>
> On 4/28/06, *Luis Ibanez* <luis.ibanez at kitware.com
> <mailto:luis.ibanez at kitware.com>> wrote:
>
>
> Hi Balaji,
>
> Resizing an image is equivalent to resampling. We prefer the term
> "resampling" because it makes clearer the distinction between working
> in the pixel space of the image or in the physical space of the
> objects that are captured in the image.
>
>
> You will find detailed instructions on how to resample images in
> the ITK Software Guide:
>
> http://www.itk.org/ItkSoftwareGuide.pdf
> <http://www.itk.org/ItkSoftwareGuide.pdf>
>
> In section 6.9.4, "Resample Image Filter", pdf page 254-285.
>
>
> In your case you will need simply an IdentityTransform, and a change
> on the Spacing of the image grid and the size of the Grid. Note that
> you *DON'T* need scaling transform, because your object in physical
> space are still the same, regardless of the resolution of the pixels
> that you use for your image. When you "resize" an image you are only
> changing the sampling grid.
>
>
> If you are just subsampling your image, you may find
> useful to the itkShrinkImageFilter,
>
> http://www.itk.org/Insight/Doxygen/html/classitk_1_1ShrinkImageFilter.html
>
> as an alternative option to the ResampleImageFilter.
>
> http://www.itk.org/Insight/Doxygen/html/classitk_1_1ResampleImageFilter.html
>
>
> Regards,
>
>
>
> Luis
>
>
>
> ------------------------
> Balaji Gandhi wrote:
> > Hi Luis,
> >
> > Pardon me if this is a very basic question. I would like to know the
> > steps to resize a TIFF image. Please let me know if possible.
> >
> > Thanks,
> > BG
> >
> > --
> > =========================
> > Balaji Gandhi
> > Research Associate
> > Biomolecular Science Center
> > University of Central Florida
> > 4000 Central Florida Blvd.
> > BMS building, Room 223
> > Orlando, FL 32816-2364
> > Phone: 407-823-3387
> > Fax: 407-823-0956
> > URL: imgem.ucf.edu <http://imgem.ucf.edu> <http://imgem.ucf.edu>
> > =========================
>
>
>
>
>
> --
> =========================
> Balaji Gandhi
> Research Associate
> Biomolecular Science Center
> University of Central Florida
> 4000 Central Florida Blvd.
> BMS building, Room 223
> Orlando, FL 32816-2364
> Phone: 407-823-3387
> Fax: 407-823-0956
> URL: imgem.ucf.edu <http://imgem.ucf.edu>
> =========================
More information about the Insight-users
mailing list