pnmtotiff - convert a PNM image to a TIFF file


SYNOPSIS

       pnmtotiff   [-none|-packbits|-lzw|-g3|-g4]  [-2d]  [-fill]
       [-predictor  n]  [-msb2lsb|-lsb2msb]   [-rowsperstrip   n]
       [-minisblack] [pnmfile]

       Minimum  unambiguous  abbreviations of options are accept­
       able.


DESCRIPTION

       Reads a PNM image as input.  Produces a TIFF file as  out­
       put.


OPTIONS

       By default, pnmtotiff creates a TIFF file with no compres­
       sion.  This is your best bet most of  the  time.   If  you
       want  to  try  another compression scheme or tweak some of
       the other even more obscure output options,  there  are  a
       number of flags to play with.

       Actually,  the  best  default would be to use LZW compres­
       sion, which is what pnmtotiff used to do by default.  How­
       ever,  the Tiff library no longer does LZW compression due
       to concerns with violating Unisys's patent on LZW compres­
       sion.

       The  -none, -packbits, -lzw, -g3, and -g4 options are used
       to override the default and  set  the  compression  scheme
       used  in  creating the output file.  The CCITT Group 3 and
       Group 4 compression  algorithms  can  only  be  used  with
       bilevel  data.   -lzw doesn't really work because the Tiff
       library doesn't do LZW compression.  It used to,  but  its
       developers  removed the function out of concern about vio­
       lating Unisys's patent.  This option remains in  case  you
       use  a Tiff library that cooperates, now or in the future.
       The -2d and -fill options are meaningful only with Group 3
       compression:  -2d  requests  2-dimensional encoding, while
       -fill requests that each encoded scanline  be  zero-filled
       to a byte boundry.  The -predictor option is only meaning­
       ful with LZW compression: a predictor value  of  2  causes
       each  scanline  of  the output image to undergo horizontal
       differencing before it is encoded; a  value  of  1  forces
       each scanline to be encoded without differencing.

       By  default, pnmtotiff creates a TIFF file with msb-to-lsb
       fill order.  The -msb2lsb and -lsb2msb options are used to
       override the default and set the fill order used in creat­
       ing the file.

       The -rowsperstrip option can be used to set the number  of

       By default, the output file has the  number  of  rows  per
       strip  set  to  a  value that will ensure each strip is no
       more than 8 kilobytes long.

       The -minisblack option forces the output image to  have  a
       "minimum  is black" photometric even when using Group 3 or
       Group 4 compression, in which case CCITT fax standards say
       the proper photometric is "minimum is white."

       Without  the  -minisblack  option,  pnmtotiff  follows the
       standard.  This usually results in better compression  and
       is generally preferred for bilevel coding.

       Before  February  2001, pnmtotiff always produced "minimum
       is black," due to a bug.  In either case,  pnmtotiff  sets
       the  photometric  interpretation  tag  in  the TIFF output
       according to which photometric is actually used.


NOTES

       There are myriad variations of the TIFF format,  and  this
       program generates only a few of them.  pnmtotiff creates a
       grayscale TIFF file if its input is a PBM (monochrome)  or
       PGM  (grayscale) file.  If the input is a PPM (color) file
       and there are 256 colors or fewer, pnmtotiff  generates  a
       color  palette  TIFF  file.  If there are more colors than
       that, pnmtotiff generates an RGB (not RGBA)  single  plane
       TIFF  file.   Use  pnmtotiffcmyk  to  generate  the  cyan-
       magenta-yellow-black ink color separation TIFF format.


SEE ALSO

       tifftopnm(1), pnmtotiffcmyk(1), pnm(5)


AUTHOR

       Derived by Jef Poskanzer from ras2tiff.c, which  is  Copy­
       right  (c) 1990 by Sun Microsystems, Inc.  Author: Patrick
       J. Naughton (naughton@wind.sun.com).


Man(1) output converted with man2html