stiff2ps(1)

stiff2ps - convert a Stream TIFF (STIFF) image file to PostScript

As shipped in IRIX 6.5.30. Unchanged since IRIX 6.5.

NAME
     stiff2ps - convert a Stream TIFF (STIFF) image file to PostScript

SYNOPSIS
     stiff2ps [-O filename] [-L filename] [-B]
              [-C colorspace] [-F] [-f] [-r angle]
              [-p imageRes] [-z factor] [-n nCopies]
              [-G g0[,g1,g2[,g3]]] [-N nUpX[,nUpY]]
              [-I filename] [-b kbytes] [-h] [-D]
              [STIFFImageFilename ...]

DESCRIPTION
     stiff2ps converts raster files in Stream TIFF (STIFF) image format into
     PostScript code. The program provides a number of image transformation
     capabilities including zooming, rotation and gamma correction. In
     addition, stiff2ps provides the capability to display multiple images on
     a single physical page.

     stiff2ps supports conversion of all standard STIFF image file colorspaces
     (i.e. K, W, RGB, CMY, YMC, CMYK, YMCK, KCMY) and data formats (i.e.
     planar and chunky). stiff2ps supports images with 1, 4, 8 and 16 bits per
     sample. For images with 16 bits per sample, stiff2ps will assume that the
     full bit range is being used (i.e. data values range from 0 thru 65535
     inclusive). If the STIFF tags STMinSampleValue or STMaxSampleValue are
     found in the image file, the values of these tags will be used as the
     image data range. This allows 16 bit images to contain data with
     intermediate ranges (e.g. 12 bits per sample ranging from 0 thru 4095) to
     be processed by stiff2ps. The PostScript image data written by stiff2ps
     will be at the same bits per sample as the input image with the exception
     of 16 bits per sample input images. These images will be scaled to 8 bits
     per sample which is the highest sample depth available on PostScript
     Level 1 interpreters.

   Command Line Options
     Typically, stiff2ps expects at least one STIFF image file to be specified
     as input on the command line after all option switches. If no image file
     is specified on the command line, stiff2ps will read from the standard
     input.  By default, stiff2ps assumes that its output should be written to
     the standard output and messages should be written to standard error.

     -O filename
               Specifies the name of the file to which the PostScript output
               will be sent.  If the -O option is not specified, output will
               be sent to the standard output.

     -L filename
               Specifies the name of the file to which error, warning and
               informational messages are to be written. If the file specified
               already exists, any messages generated by stiff2ps will be
               appended to the end of the file.  If the -L option is not
               specified, message output will be sent to standard error.

     -B        Specifies that binary PostScript should be output where
               applicable. The majority of the output from stiff2ps is bitmap
               image data. By default this data is output as ASCII hexadecimal
               values. Specifying -B will output this image data as binary
               values thereby cutting in half the number of bytes of
               PostScript data output. However, binary data output should only
               be used when the communications channel between stiff2ps and
               the PostScript interpreter can accept 8-bit data. This
               precludes the use of the -B switch when transmitting output
               over serial connections.

     -C colorspace
               Specifies the output data colorspace. The value of colorspace
               may be one of the following: w (black and white), the default,
               cmyk, or rgb. The PostScript produced by cmyk and rgb can only
               be interpreted by a Level 2 PostScript interpreter or a Level 1
               interpreter with the CMYK color extensions (e.g. psrip(1)). The
               PostScript produced by w can be sent to any Level 1
               interpreter. The colorspace conversion equations used by
               stiff2ps are:


               W to RGB: r = g = b = w

               W to CMYK: c = m = y = 0; k = 1 - w

               RGB to W: w = 0.299 r + 0.587 g + 0.114 b

               RGB to CMYK:
               ci = 1 - r; mi = 1 - g; yi = 1 - b
               k = min(ci, mi, yi)
               c = ci - k; m = mi - k: y = yi - k

               CMYK to RGB and to W:
               ri = 1 - c
               gi = 1 - m
               bi = 1 - y
               r = (ri > k)? ri - k: 0
               g = (gi > k)? gi - k: 0
               b = (bi > k)? bi - k: 0
               w = 0.299 r + 0.587 g + 0.114 b

     -F        Specifies that the image should be oriented so that it best
               fits the page.  That is, the image is oriented such that its
               longer dimension is parallel with the longer dimension of the
               paper. If -F is specified, any rotation specified by the -r
               switch is ignored. By default the image is oriented with zero
               degrees of rotation unless the -r switch specifies a different
               rotation.

     -f        Specifies that the output image should be flipped (mirrored)
               about the vertical axis. This flag is useful when creating
               transparencies.  Note that flipping of the image is performed
               after any rotation. Therefore, the image is always flipped
               about the vertical axis.

     -r angle  Specifies that the image is to be rotated by angle degrees.
               angle may be any positive or negative integer value. Positive
               rotations are counter-clockwise measured from the horizontal
               axis. The default rotation angle is 0. Note that rotation is
               performed before any image flipping (-f). The -r switch is
               ignored if the best-fit switch -F is specified.

     -z factor and -p imageRes
               Each of these switches provides scaling of the original image.
               The two switches are mutually exclusive.

               The -z switch provides image zooming.  factor is a positive
               floating point value typically between 0.0 and 1.0. A zoom
               factor of 1.0, the default, indicates that the image should be
               scaled to fit the entire page while preserving the original
               image's aspect ratio. A zoom factor of 0.5 would produce an
               image sized to 50% of that needed to fit the entire page. A
               zoom factor of 0.0 produces no zooming. Instead the image is
               output at its original size.

               If an image must be sized based on a given resolution, the -p
               switch should be specified in place of the -z switch. The
               imageRes argument specifies the resolution used to size the
               image in dots per inch. This resolution is independent of the
               output device resolution. For example, suppose an image is one
               inch by one inch when displayed on a 96 dpi monitor. In order
               to print that image on a 300 dpi printer so that it remains one
               inch by one inch the -p switch would be specified with an
               imageRes of 96.

     -n nCopies
               Specifies the number of copies to produce of each page.
               Specifying this switch simply sets the value of the #copies
               variable in the output PostScript code. The value of this
               variable is used by the PostScript operator showpage to
               determine the number of output copies to produce. By default
               the #copies variable is not specified and the number of copies
               then defaults to one.

     -G g0[,g1,g2[,g3]]
               This switch provides gamma correction of the input image data.
               The gamma function is:

               corrected value = value ^ gamma

               The gamma value (g0, etc.) is typically a value between 0.0 and
               3.0. A gamma value less than 1.0 will tend to lighten the image
               while a value greater than 1.0 will tend to darken the image. A
               gamma of 1.0 will leave the image data unchanged.  The gamma
               value may be specified for each input color channel
               individually or as a group. If g0 is the only gamma value
               specified, this value will be applied to all input channels.
               Note that a black and white image contains one input color
               channel, an RGB image contains three input channels and a CMYK
               image contains four input channels. Note that gamma correction
               of one bit per sample images has no meaning and therefore the
               -G switch has no effect for these images. The default gamma
               value is 1.0 for all channels.

     -N nUpX[,nUpY]
               stiff2ps allows multiple STIFF image files to be specified on
               the command line. By default, each image is output on a
               separate physical page.  The -N switch provides the capability
               to divide up one physical page into multiple virtual pages.
               This is often called n-up display. Using n-up, multiple image
               files can be displayed on the same physical page. If only the
               nUpX value is specified the physical page will be divided into
               nUpX by nUpX virtual pages. If both nUpX and nUpY are
               specified, the physical page will be divided into nUpX by nUpY
               virtual pages.  Images are displayed in row (horizontal) major
               order.  Note that nUpX is measured along the horizontal, x,
               axis. For an 8.5 by 11.0 inch page, the horizontal axis is the
               short dimension in portrait mode and the long dimension in
               landscape mode. Rotation is performed on each image
               individually and best-fit orientation is determined for each
               image individually. Zooming is relative to the virtual page
               size. Note that image replication is not performed. The number
               of images specified on the command line is the number of images
               displayed in the virtual pages.

     -I filename
               stiff2ps places a PostScript code prolog at the start of the
               output file.  By default, this prolog code is read from the
               file /usr/lib/print/data/PSImageProlog.  The -I switch allows a
               different prolog file to be specified. This switch is not
               intended for general use.

     -b kbytes stiff2ps allocates buffers for performing input/output and
               conversion operations. By default, the total size of these
               buffers is limited to 64 KBytes.  The -b switch allows a new
               buffer size to be specified. The buffer size is specified in
               multiples of 1024 (one K) bytes. For example, specifying 128
               KBytes for buffering would permit approximately 21 rows of a
               2048 pixel wide 8 bit per sample RGB image to be buffered. Note
               that internally stiff2ps buffers data in terms of image rows.
               If the kbytes is less than that required to buffer one image
               row, kbytes will be ignored and one row will be buffered.
     -h        Prints a program usage message to the standard error. This
               usage message also lists the currently supported output
               configurations.

     -D        Specifies verbose output for debugging purposes.

NOTES
     1.   The PostScript output produced by stiff2ps conforms to the Adobe
          PostScript Document Structuring Conventions Version 3.0 as specified
          in Appendix G of the "PostScript Language Reference Manual", 2nd
          edition.

     2.   The PostScript output produced by stiff2ps wraps the input bitmap
          image data with PostScript instructions. Therefore, the amount of
          output data can be quit large especially if multiple image files are
          specified or if the images are large. The size of the output file
          should be kept in mind when sending the PostScript output over a
          slow communications channel such as a serial line.

     3.   If stiff2ps is given an unrecognized or incomplete command line
          option switch, it will print a warning message to the standard
          error, ignore the option and continue processing.

     4.   If an image file is specified on the command line, stiff2ps will not
          read its stdin for images.

     5.   Processing a planar STIFF image file requires random seeking within
          the file.  Therefore, when stiff2ps is reading planar STIFF image
          data from a pipe to standard input, a disk based copy of the input
          image must be created.  This temporary image file will be created in
          the directory specified by the TMPDIR environment variable. If that
          variable is not set, the temporary file will be created in /var/tmp.
          There must be sufficient free space in the temporary file directory
          to store a complete copy of the image file or stiff2ps will fail.

     6.   stiff2ps can only process a single image file when reading from
          standard input.

FILES
     /usr/lib/print/stiff2ps              Program file
     /usr/lib/print/data/PSImageProlog    PostScript prolog file

TRADEMARKS
     PostScript is a registered trademark of Adobe Systems, Inc.

SEE ALSO
     psrip(1), sgi2ps(1), PostScript Language Reference Manual - 2nd ed.,
     Adobe Systems, Inc.