Page 1 of 1

mha and mhd support

Posted: 2012-01-24T02:53:49-07:00
by Franz777
Hi

The insight toolkit (ITK) is a famous image processing library but do not support many formats. It's native format is a very easy .mha and .mhd format which stores data rawly and uncompressed. would it be possible to support it, i could post a MatLab code for writing and reading mhd files if necessary.

PS: Only difference between mha and mhd is that mha produces header and image data stuff in same file while mhd makes a seperate .raw file which stores image data, in the mhd only the header and link to raw is stored, so mhd's are readable by simple textreaders

Re: mha and mhd support

Posted: 2012-01-31T21:22:13-07:00
by anthony
Should be posible. Im can generate RAW data outputs. and even without a coder you should be able to get it to generate
both the mha and mhd data files.

see.. note on raw RGB data
http://www.imagemagick.org/Usage/formats/#rgb

also see formatted image output..
http://www.imagemagick.org/Usage/basics/#identify_alt

Both can be generated from the one command, but detailed knowledge of the mha and mhd is needed.

Their is also raw PbmPlus image file formats, whcih sounds pretty close to mha and mhd formats.
http://www.imagemagick.org/Usage/formats/#pbmplus
and the various pbmplus man pages whcih define the image file formats.