NAME

cvt2pic, dumppic, ega2pic, face2pic, gif2pic, jpg2pic, nasa2pic, pcx2pic, picopic, sgi2pic, targa2pic, tiff2pic, utah2pic, xbm2pic - convert other formats to picture files

SYNOPSIS

fb/cvt2pic [ file ]

fb/dumppic input xsize ysize channels

fb/ega2pic [ file ]

fb/face2pic [ facefile ]

fb/gif2pic [ -m ] [ -s image ] [ file ]

fb/jpg2pic file

fb/nasa2pic file

fb/pcx2pic [ -r ] [ file ]

fb/picopic red green blue xsize ysize

fb/sgi2pic file

fb/targa2pic [ file ]

fb/tiff2pic file

fb/utah2pic file

fb/xbm2pic [ file ]

DESCRIPTION

Cvt2pic examines the given file (default standard input), and tries to convert it to a picfile(9.6). It can recognize TIFF, xbm, CompuServe GIF, Usenix facesaver, NASA, Utah rle, SGI, JPEG, pcx, and picfile(9.6) images. The actual conversion is done by calling out to one of the programs described below. Although we have programs to decipher EGA, Targa, and raw dump images, cvt2pic cannot recognize them.

Dumppic copies input to its standard output, adding a TYPE=dump picture file header. Xsize and ysize are the width and height of the picture. Channels is the value of the output's CHAN= attribute. Face2pic reads facefile (default standard input), a file in the Usenix face-saver format, and converts it to picfile(9.6) format, writing the result on standard output.

Picopic creates a TYPE=pico image from the files red, green and blue which must be raw (headerless) dumps in scan line order of size xsize&215;ysize.

Ega2pic reads an EGA `enhanced color mode' image from input and converts it to picfile(9.6) format, written on standard output.

Gif2pic reads a CompuServe GIF format picture from input (default standard input) and converts it to picfile(9.6) format, written on standard output. By default, it converts its input into a 3-channel rgb image. The -m flag causes it to output a single channel image with a color map. GIF files may contain multiple images; the -s flag allows selection of an image other than the first.

Jpg2pic reads a JPEG-coded file in the JFIF format from input (or standard input) and converts it to picfile(9.6) format, written on standard output. It generates TYPE=dump.

Nasa2pic reads a NASA satellite image and converts it to picfile(9.6) format, written on standard output. It can decipher only images with a single 8-bit channel. NASA images typically have copious annotations in their headers; these are mostly lost.

Sgi2pic converts SGI-format images to picfiles.

Targa2pic reads a Targa format file and converts it to picfile(9.6) format, written on standard output. It cannot convert compressed or color-mapped files.

Tiff2pic converts TIFF images to picfiles. It cannot handle images with more than 8 bits per color component, nor images of more than 8 channels. It uses a version of Sam Leffler's TIFF library that purports to toe to TIFF 6.0.

Utah2pic reads a Utah rle (run-length encoded) image and converts it to picfile(9.6) format, written on standard output.

Pcx2pic reads a Paintbrush PCX format picture from input (or standard input) and converts it to picfile(9.6) format, written on standard output. TYPE=dump is generated by default; the -r flag selects TYPE=runcode.

Xbm2pic reads an X window-system bitmap file from file (or standard input) and converts it to picfile(9.6) format, written on standard output.

SEE ALSO

picfile(9.6)
Pic2gif contains code that is Copyright © 1988, 1989 by Patrick J. Naughton.

SOURCE

/sys/src/fb

BUGS

The world is awash with raster image file formats, many of which spawn new versions from time to time, possibly making these programs obsolete. On the other hand, we guarantee unconditionally that picfile(9.6) will never change.

Copyright © 1995 Lucent Technologies. All rights reserved.