DEC VAX vs IA-32 Byte Order

The following is a description of the problem. If you are not interested, you can skip to the bottom line.


I am working with a data file with this description:

MRI dataset with 109 sections of the human head. Full fragments are stored sequentially as a 256 x 256 array. Pixels consist of 2 consecutive bytes containing one binary integer. Data from a Siemens magnet and provided by Siemens Medical Systems, Inc., Iselin, NJ.

and then:

The data sets were written on a VAX Digital Equipment Corporation (DEC) computer. Each file contains only pixels stored in string order with 2 byte integers per pixel. To use images on machines with the usual byte order (DEC use the reverse byte order), you must change the alternative bytes, for example, using the "dd" command on UNIX. An example of a command that does this for a 3dknee dataset:

% dd if=3dknee of=3dknee.new conv=swab

I don’t know what real values ​​are, so I can’t judge by just looking to see if the byte order is set correctly.

Bottom line

Is the DEC VAX byte order the same as in IA-32, or vice versa?

+3
source share
1 answer

, VAX x86 . .

+2

Source: https://habr.com/ru/post/1716028/


All Articles