[MINC-users] losing bytes when converting to/from minc

Andrew Janke rotor@cmr.uq.edu.au
Mon Sep 6 21:09:04 2004


> On Mon, 6 Sep 2004, Jon Frederick wrote:
>
> > # dd conv=swab if=eih0060t1.al0 | rawtominc -coronal -byte -unsigned
> > -ystep 1 -zstep 1 -xstep 1 -mri -origin 0 0 0 -range 0 255 -real_range 0
> > 255 -clobber temp.mnc 256 256 256

You may also be interested to note that in later releases of MINC 1.x (and 2.x)
you could achieve the same result as above without dd via the -swap_bytes option
in rawtominc.

ie:

   # rawtominc -coronal -byte -unsigned  -ystep 1 -zstep 1 -xstep 1 \
       -mri -origin 0 0 0 -range 0 255 -real_range 0 255 \
       -clobber -swap_bytes -input eih0060t1.al0 \
       temp.mnc 256 256 256

--
Andrew Janke (rotor@cmr.uq.edu DOT au || www.cmr.uq.edu.au/~rotor)
Australia->University of Queensland->Centre for Magnetic Resonance
W: +61 7 3232 7254  ||  H: +61 7 3879 0374  ||  M: +61 4 2138 8581