[Insight-users] image pixel type

Luis Ibanez luis.ibanez at kitware.com
Tue Aug 3 12:40:57 EDT 2004


Hi Christpoh,

I see you point better now.

It is a good idea to collect a table of image types
supported by each fileformat.  The place to look in
order to gather this information is the directory

         Insight/Code/IO

You should look at each one of the files

         TIFFImageIO.cxx
         JPEGImageIO.cxx
         PNGImageIO.cxx
         ...etc...

A good place for putting this table could be the Wiki
pages. Probably in the FAQ section.

Please let us know if you find any difficulties collecting
this information.


   Thanks


     Luis


-------------------------
Christoph Palm wrote:
> Hi Luis,
> 
> thanks for your answer. You are absolutely right, that
> I have to use a try/catch block to handle such errors.
> But that was not my real problem. 
> 
> To be more precise:
> I deal internally e.g. with integer values or double
> precision. The user should be free to choose an
> output file format like png or tif. I want to write
> the image with the lowest possible quantization error.
> That means if I know, tif is able to store integer I
> wouldn´t have to cast to unsigned char.
> Or think about vector images: If png cannot store vectors
> I wan`t to tell the user _before_ I try and e.g. give
> him/her hints what file format whould be better.
> 
> Regards
> 
> Christoph
> 
> Am Die, den 03.08.2004 schrieb Luis Ibanez um 06:03:
> 
>>Hi Christoph,
>>
>>The program probably aborts because you are not catching
>>exceptions as is recomented in the ITK Tutorials and in
>>the SoftwareGuide.
>>
>>Please catch exceptions and print out the descriptions
>>they provide regarding the source of the error.
>>
>>You will find many examples on try/catch blocks in the
>>ITK Software Guide.
>>
>>
>>Regards,
>>
>>
>>    Luis
>>
>>
>>
>>-----------------------
>>Christoph Palm wrote:
>>
>>
>>>Hi all,
>>>
>>>we deal with different image storage types for input as well as output,
>>>for example png, tif, jpeg, mhd, analyze7.5,...
>>>
>>>My question: where can I find consistent information about the
>>>different types and their possible storage capabilites according to
>>>pixel type, vectors, color, etc.
>>>
>>>For example png seems only be able to store images of unsigned char,
>>>but it would be very cumbersome to test all combinations out. If
>>>I try to store with the wrong pixel type, the program aborts without
>>>error message.
>>>
>>>Thanks for the help
>>>
>>>Christoph
>>>
>>>
>>>_______________________________________________
>>>Insight-users mailing list
>>>Insight-users at itk.org
>>>http://www.itk.org/mailman/listinfo/insight-users
>>>
>>
>>
>>
>>
>>_______________________________________________
>>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