[Insight-users] How to use MetaImageImporter

Mathieu Malaterre Mathieu.Malaterre@creatis.insa-lyon.fr
Mon, 07 Apr 2003 18:55:06 +0200


Haiwen,
	Since ITK 1.2, InsightApplications have moved to there own directory: 
InsigthApplications/ (and not insigth/Applications) that you can 
download either from

http://itk.org/HTML/Download.php

of from CVS, just follow the instructions from:

http://itk.org/HTML/Applications.htm

HTH
mathieu

Haiwen Shi wrote:
> Hi, Luis;
> 
> Thanks for your email. I think it is a good idea to
> use MetaImage header. However, when I looked for the
> directory
> 
> 	Insight/Applications/MetaImageImporter
> 
> I didn't find anything in it except a CVS directory.
> Do you mind to check it out and tell me where I can
> find the MetaImageImporter? 
> 
> Actually, I saw other people use Meta Image header,
> which looks like the following:
> 
> NDims = 3
> DimSize = 181 217 180
> ElementType = MET_UCHAR
> ElementSpacing = 1.0 1.0 1.0
> ElementByteOrderMSB = False
> ElementDataFile = brainweb165a10f17.raw
> 
> 
> However, the data type of my image is double instead
> of unsigned char. Do you know what kind of
> 'ElementType' I should use? Is it a right meta header
> file? 
> 
> I will really appreciate if you give me more
> information about how to write a Mate Image header
> file.
> 
> Thank you very much!
> 
> Haiwen Shi
> 
> 
> --- Luis Ibanez <luis.ibanez@kitware.com> wrote:
> 
>>HI Haiwen,
>>
>>As an alternative to Kent's detailed instructions
>>for
>>using RawImageIO, I would suggest you to consider
>>the
>>option of using a MetaImage header.
>>
>>This short text based header contains information
>>about
>>your binary file. For example: the origin, spacing
>>and
>>dimensions of the data. The header has the filename
>>of
>>the raw file, so it doesn't duplicate any
>>information.
>>
>>The easieast way to create a MetaImage header is to
>>use
>>the small application:
>>
>>               MetaImageImporter
>>
>>available in
>>
>>      InsightApplications/MetaImageImporter
>>
>>
>>Whenever you want to read your file, simply pass the
>>full filename of the MetaImage header to the
>>ImageFileReader.
>>In that way, the information of the raw file is not
>>hard coded in your program. The information is
>>specified in
>>this external file, allowing your program to work
>>with more
>>than one single file.
>>
>>
>>    Luis
>>
>>
>>
>>------------------
>>Haiwen Shi wrote:
>>
>>>Hi, All;
>>>
>>>I want to use itk to read a MR image file that
>>>consists of only binary data(the data type is
>>
>>double),
>>
>>>not any header information in it. Some people
>>>suggested me to use RawImageIO to read the data
>>
>>file.
>>
>>>Can anybody tell me how to use this class? An
>>
>>example
>>
>>>will be perfect. Or if you have any other
>>
>>suggestion,
>>
>>>please let me know. 
>>>
>>>I will really appreciate your help!
>>>
>>>Haiwen Shi
>>>
>>>__________________________________________________
>>>Do you Yahoo!?
>>>Yahoo! Tax Center - File online, calculators,
>>
>>forms, and more
>>
>>>http://tax.yahoo.com
>>>_______________________________________________
>>>Insight-users mailing list
>>>Insight-users@public.kitware.com
>>>
>>
> http://public.kitware.com/mailman/listinfo/insight-users
> 
>>
>>
>>_______________________________________________
>>Insight-users mailing list
>>Insight-users@public.kitware.com
>>
> 
> http://public.kitware.com/mailman/listinfo/insight-users
> 
> 
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Tax Center - File online, calculators, forms, and more
> http://tax.yahoo.com
> _______________________________________________
> Insight-users mailing list
> Insight-users@public.kitware.com
> http://public.kitware.com/mailman/listinfo/insight-users
> 


-- 
Mathieu Malaterre
CREATIS
28 Avenue du Doyen LEPINE
B.P. Lyon-Montchat
69394 Lyon Cedex 03
http://www.creatis.insa-lyon.fr/~malaterre/