[Insight-users] Analyze Binary Bitmap File Loading problem
Yasser Bashir
itk_at_stanford at yahoo.com
Mon, 16 Feb 2004 09:38:41 -0800
Luis,
I believe the test data in testing folder is of type 'float' and
AnalyzeImageIO works fine for basic types.
I am only talking about the case where the input file is in the binary
bitmask format so each byte of data has 8 pixel values.
I believe the DoConvertBuffer in the itkImageFileReader.txx is
intelligent enough to typecast basic types but is not intelligent enough
to take "binary" bit data and convert it to binary byte (or whatever the
output data type is) data.
I had to override itkAnalyzeImageIO and modify the behaviour of the void
Read(void* buffer) to fix my issue but I believe it should be fixed in
the itkImageFileReader.txx
In my next mail I will try to attach some sample data if the mailing
list allows it :-)
Yasser.
-----Original Message-----
From: Luis Ibanez [mailto:luis.ibanez at kitware.com]
Sent: Monday, February 16, 2004 12:44 AM
To: itk_at_stanford at yahoo.com
Cc: insight-users at itk.org
Subject: Re: [Insight-users] Analyze Binary Bitmap File Loading problem
Hi Yasser,
When you said that itkAnalyzeImageIO "fails"
Do you mean:
1) It crashes ?
2) It throws an exception ?
3) It read an image but the data appears corrupted ?
For a simple test you can try reading the
testing Analyzee data sets available at
Insight/Testing/Data/Input
Reading .img files works fine for the test images.
Regards,
Luis
-----------------------------------
itk_at_stanford at yahoo.com wrote:
>
> Hi,
>
> I am trying to load the binary bitmap files in analyze format but
> itkAnalyzeImageIO fails.
>
> In my opinion its because its assuming that the file pixel format is
> "unsigned character".
>
> How can I tell the itkAnalyzeImageIO that the data in the .img file
is
> in the binary format?
>
> Yasser.
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
>