[Insight-users] convering *.img to *.bmp

Luis Ibanez luis.ibanez at kitware.com
Wed Jul 27 11:23:03 EDT 2005


Hi Suresh,

If your input image type is unsigned short,
the values will not fit in the range of the
output pixel type: unsigned char.

In your case, all pixels will take the low
byte of the unsigned short and that will
look as a noisy image.

Please read the ITK Software Guide

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


In particular the chapter:

     "Reading and Writing Images"

and the section on intensity scaling filters,
since the solution for your problem may be
to simply use the

      RescaleIntensityImageFilter



Regards,


    Luis


--------------------
Suresh G N wrote:
> Hi all,
> 
> When I tried to convert *.img 3D volume data set to *.bmp series using   
> ImageReadImageSeriesWrite.cxx  I got a noise image series. I changed o/p 
> image type to
> typedef itk::Image< unsigned char, 2 >     Image2DType;
>  
> input image type is unsigned short. can any one tell me what is 
> happening, I am new to ITK.
> 
> Thanks in advance
> 
> Suresh G N
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> 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