home *** CD-ROM | disk | FTP | other *** search
/ Mega A/V / mega_av.zip / mega_av / GRAPHUTL / PBMPLUS.ZIP / PPM.MAN < prev    next >
Text File  |  1991-08-11  |  4KB  |  133 lines

  1.  
  2.  
  3. ppm(5)                     Unix Programmer's Manual                     ppm(5)
  4.  
  5.  
  6. NNNAAAMMMEEE
  7.      ppm - portable pixmap file format
  8.  
  9. DDDEEESSSCCCRRRIIIPPPTTTIIIOOONNN
  10.      The portable pixmap format is a lowest  common  denominator  color  image
  11.      file format.  The definition is as follows:
  12.  
  13.      - A "magic number" for identifying the file type.   A  ppm  file's  magic
  14.        number is the two characters "P3".
  15.  
  16.      - Whitespace (blanks, TABs, CRs, LFs).
  17.  
  18.      - A width, formatted as ASCII characters in decimal.
  19.  
  20.      - Whitespace.
  21.  
  22.      - A height, again in ASCII decimal.
  23.  
  24.      - Whitespace.
  25.  
  26.      - The maximum color-component value, again in ASCII decimal.
  27.  
  28.      - Whitespace.
  29.  
  30.      - Width * height pixels, each three ASCII decimal values  between  0  and
  31.        the  specified  maximum  value,  starting at the top-left corner of the
  32.        pixmap, proceding in normal English reading order.   The  three  values
  33.        for each pixel represent red, green, and blue, respectively; a value of
  34.        0 means that color is off, and the maximum value means  that  color  is
  35.        maxxed out.
  36.  
  37.      - Characters from a "#" to the next end-of-line are ignored (comments).
  38.  
  39.      - No line should be longer than 70 characters.
  40.  
  41.      Here is an example of a small pixmap in this format:
  42.      P3
  43.      # feep.ppm
  44.      4 4
  45.      15
  46.       0  0  0    0  0  0    0  0  0   15  0 15
  47.       0  0  0    0 15  7    0  0  0    0  0  0
  48.       0  0  0    0  0  0    0 15  7    0  0  0
  49.      15  0 15    0  0  0    0  0  0    0  0  0
  50.  
  51.      Programs that  read  this  format  should  be  as  lenient  as  possible,
  52.      accepting anything that looks remotely like a pixmap.
  53.  
  54.      There is also a variant on the format, available by setting  the  RAWBITS
  55.      option at compile time.  This variant is different in the following ways:
  56.  
  57.      - The "magic number" is "P6" instead of "P3".
  58.  
  59.      - The pixel values are stored as plain bytes, instead of ASCII decimal.
  60.  
  61.  
  62.  
  63.  
  64.                               15 September 1990                              1
  65.  
  66.  
  67.  
  68.  
  69. ppm(5)                     Unix Programmer's Manual                     ppm(5)
  70.  
  71.  
  72.      - Whitespace is not allowed  in  the  pixels  area,  and  only  a  single
  73.        character  of  whitespace  (typically  a  newline) is allowed after the
  74.        maxval.
  75.  
  76.      - The files are smaller and many times faster to read and write.
  77.  
  78.      Note that this raw format can only be used for maxvals less than or equal
  79.      to 255.  If you use the _p_p_m library and try to write a file with a larger
  80.      maxval, it will automatically fall back on the slower  but  more  general
  81.      plain format.
  82.  
  83. SSSEEEEEE AAALLLSSSOOO
  84.      giftoppm(1),  gouldtoppm(1),  ilbmtoppm(1),   imgtoppm(1),   mtvtoppm(1),
  85.      pcxtoppm(1),   pgmtoppm(1),   pi1toppm(1),   picttoppm(1),   qrttoppm(1),
  86.      rawtoppm(1),   rgb3toppm(1),   spctoppm(1),   sputoppm(1),   tgatoppm(1),
  87.      ximtoppm(1),   xpmtoppm(1),   ppmtogif(1),   ppmtoicr(1),   ppmtoilbm(1),
  88.      ppmtopcx(1),   ppmtopgm(1),   ppmtopi1(1),   ppmtopict(1),    ppmtops(1),
  89.      ppmtopuzz(1),   ppmtorgb3(1),   ppmtouil(1),   ppmtoxpm(1),   ppmhist(1),
  90.      ppmmake(1), ppmpat(1), ppmquant(1), ppmquantall(1), ppmrelief(1), pnm(5),
  91.      pgm(5), pbm(5)
  92.  
  93. AAAUUUTTTHHHOOORRR
  94.      Copyright (C) 1989, 1991 by Jef Poskanzer.
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.                               15 September 1990                              2
  131.  
  132.  
  133.