[Insight-users] Re: Resizing an Image

Luis Ibanez luis.ibanez at kitware.com
Mon May 1 17:28:47 EDT 2006


Hi Balaji,


The pixel type that you need
for reading 16 bits/pixel images is:


                unsigned short

or

                signed short


depending on the image modality.


Your images seems to be from microscopy,
in which case, you are probably fine with
"unsigned short".



   Regards,



      Luis



=========================
Balaji Gandhi wrote:
> Hi Luis/All,
> 
> I am using the original source code provided in the 
> Insight/Examples/Filtering and Insight/Examples/Registration to read the 
> (16 bit/Gray Scale) images. What is the PixelType for reading and 
> writing 16 bit/Gray Scale Images? Please advise.
> 
> Thanks,
> Balaji
> 
> On 5/1/06, *Luis Ibanez* <luis.ibanez at kitware.com 
> <mailto:luis.ibanez at kitware.com>> wrote:
> 
> 
>     Hi Balaji,
> 
>     What pixel type did you used for instantiating the ImageFileReader
>     in your ITK pipeline ?
> 
>     It is likely that you are using "unsigned char" for that pixel type,
>     and therefore when you read the input image from a 16 bits/pixel file
>     the pixel values get truncated to the highest byte and result in a noisy
>     field.
> 
> 
> 
>     It will be *much easier* to help you if you post the source code
>     of your test to the mailing list....   :-/
> 
> 
>     Please do so,
> 
> 
>        Thanks
> 
> 
>           Luis
> 
> 
> 
>     ========================
>     Balaji Gandhi wrote:
>      > Hi Luis,
>      >
>      > I would like to add to my previous mail. The same noise is added
>     when I
>      > perform Registration on the (16 bit/Gray scale) images. If I
>     convert the
>      > images to (8 bit/Indexed Color) images everything (Registration and
>      > Sampling) is fine.
>      >
>      > Please let me know if there is a workaround for this or if my
>     technique
>      > is wrong.
>      >
>      > Thanks,
>      > Balaji
>      >
> 
> 
> -- 
> ===============================
> Balaji Gandhi
> Research Associate
> Biomolecular Science Center
> University of Central Florida
> Phone: 407-823-3387
> Fax: 407-823-0956
> Project: imgem.ucf.edu <http://imgem.ucf.edu>
> ===============================
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> 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