man sam2p (Commandes) - program to convert raster images to postscript, pdf, and other formats
NAME
sam2p - program to convert raster images to postscript, pdf, and other formats
SYNOPSIS
sam2p
[options] infile outfile
sam2p
[options] jobfile
DESCRIPTION
This manual page documents briefly the sam2p command. It was written for the Debian distribution because the original program does not have a manual page. The complete documentation can be found in /usr/share/doc/sam2p/README.gz
sam2p is a program that converts many raster (bitmap) image formats into Adobe PostScript or PDF files and several other formats. The images are not vectorized. sam2p gives full control to the user to specify standards-compliance, compression, and bit depths.
sam2p can operate in two modes: one-liner mode and job mode. In job mode the user has to write a ``job'' file which specifies the conversion parameters and allows full control of all aspects of the final output. This manpage deals only with one-liner mode, see /usr/share/doc/sam2p/README.gz for details on job mode.
EXAMPLES
To convert an image file to .eps, use:
sam2p infile.gif outfile.eps
The output format is guessed from the file extension. Optionally, the output format also can be specified as option or as prefix to the output file. For example, the following commands produce postscript level 3:
sam2p infile.gif psl3:outfile.ps sam2p -ps:3 infile.gif outfile.ps
sam2p can include its own (zip and lzw) decompression filter in Postscript files, allowing better compression than normally supported by Postscript level 1:
sam2p -1 -c:zip infile.gif outfile.ps
sam2p -1 -c:lzw infile.gif outfile.ps
OPTIONS
- -1, -ps:1, psl1:
- produce Postscript Level 1
- -1c, -ps:1c, pslc:
- produce Postscript Level 1 with the CMYK and `colorimage' extension
- -2, -ps:2, psl2:
- produce Postscript Level 2 (default for postscript)
- -3, -ps:3, psl3:
- produce Postscript Level 3
- -pdf:b0, pdfb1.0:
- produce PDF version 1.0 (BI inline image)
- -pdf:b2, pdfb1.2:
- produce PDF version 1.2 (BI inline image) (default for PDF)
- -pdf:0, pdf1.0:
- produce PDF version 1.0 (XObject image)
- -pdf:2, pdf1.2:
- produce PDF version 1.2 (XObject image)
- -e:0, -e:none
- don't scale
- -e, -e:1, -e:scale
- scale image to fit page
- -e:rot, -e:rotate
- scale and rotate image to fit page (default if output filename has .ps extension)
- -m:dimen
- set all page margins to dimen
dimen can have one of the following units (as in TeX): bp, in, pt, pc, dd, cc, sp, cm, mm - -m:spec:dimen
- set spec margin(s) to dimen (spec can be l, r, t, b, v (top and bottom), h (left and right))
- -m:dpi:res
- set output EPS or PDF to resolution res dpi
- -c:none, -c:lzw, -c:zip, -c:rle, -c:fax, -c:dct, -c:jpeg
- select compression type (support depends on output format)
- -j:quiet
- print only error and fatal error messages, suppress warnings, notices etc. Must be put at the beginning of the command line to suppress initial banners, too.
- --
- If not the last argument:
treat all further arguments as files (required if a filename
contains a colon or starts with a minus)
If the last argument: use input filename as ouput filename (i.e. overwrite input file).
SUPPORTED FILE FORMATS
- Input formats:
- PNM, PBM, PGM, PPM, XPM, GIF, LBM, TGA, PCX,
JPEG (requires djpeg from package libjpeg-progs),
TIFF (requires tifftopnm from package netpbm),
PNG (requires pngtopnm from package netpbm),
PS, EPS, PDF (require ghostscript) - Output formats:
- XWD, BMP, PNG, TIFF6, JPEG, PNM, GIF89a, XPM, PS (levels 1,2,3), EPS (levels 2,3), PDF (1.0 and 1.2) For some formats, sam2p supports transparency. See the README file for more info.
SEE ALSO
The program is documented fully in /usr/share/doc/sam2p/README.gz
AUTHOR
sam2p was written by Szabó Péter <pts@fazekas.hu>.
This manual page was written by Stefan Fritsch <sf@sfritsch.de>, for the Debian project (but may be used by others under the terms of the GNU General Public License, Version 2).