1Pamendian User Manual(0)                              Pamendian User Manual(0)
2
3
4

NAME

6       pamendian - reverse endianness of a Netpbm image
7
8

SYNOPSIS

10       pamendian
11
12

DESCRIPTION

14       This program is part of Netpbm(1).
15
16       All  Netpbm formats that have samples in pure binary format with multi‐
17       ple bytes are defined to have them in big endian (most significant byte
18       first)  order.   However, there exist variations on these formats, pri‐
19       marily developed before official multibyte Netpbm formats existed, that
20       are  identical  to  Netpbm formats in every respect except that samples
21       are in little endian (least signficant byte first) order.
22
23       pamendian reverses the byte order of the sample to convert between  the
24       two  formats.  If the input is true PAM, PGM, or PPM, the output is the
25       little endian variation on that format, and vice versa.
26
27       Programs that come with the Independent Jpeg Group's JPEG  library  are
28       known to use the little endian variation of PGM and PPM.
29
30       The  reason  some  programs use this variant is that at one time during
31       Netpbm's darkage(1),there was a version of Netpbm around that used  it.
32       But it was never formally specified.
33
34       This  program takes input only on Standard Input.  Its output is always
35       on Standard Output.
36
37       You should never have to use this program with images generated by pro‐
38       grams  in the Netpbm package or programs that use the Netpbm libraries.
39       If you do, that probably means something needs to  be  fixed  in  those
40       programs.  The Netpbm converter for any graphics format that represents
41       numbers in little endian form should properly reverse the bytes to cre‐
42       ate correct Netpbm output.
43
44       If  you  create  a Netpbm image from a generic stream of samples, using
45       rawtopgm or rawtoppm, use options on  those  programs  to  declare  the
46       endianness  of your input, thus creating correct endianness in your PGM
47       or PPM output.
48
49

SEE ALSO

51       pamdepth(1), rawtopgm(1), rawtoppm(1), pnm(1)
52
53
54
55netpbm documentation             16 March 2002        Pamendian User Manual(0)
Impressum