Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!apple!well!pokey From: pokey@well.UUCP (Jef Poskanzer) Newsgroups: alt.sources Subject: PBMPLUS, part 1 of 18 Message-ID: <13607@well.UUCP> Date: 14 Sep 89 11:24:16 GMT Reply-To: Jef Poskanzer Organization: Paratheo-Anametamystikhood Of Eris Esoteric, Ada Lovelace Cabal Lines: 913 #! /bin/sh # This is a shell archive, meaning: # 1. Remove everything above the #! /bin/sh line. # 2. Save the resulting text in a file. # 3. Execute the file with /bin/sh (not csh) to create the files: # README # CHANGES # FORMATS # OTHER.SYSTEMS # TIPS # Makefile # Imakefile # pbmplus.h # compataliases # This archive created: Thu Sep 14 03:43:23 1989 # By: Jef Poskanzer (Paratheo-Anametamystikhood Of Eris Esoteric, Ada Lovelace Cabal) export PATH; PATH=/bin:$PATH echo shar: extracting "'README'" '(8727 characters)' if test -f 'README' then echo shar: will not over-write existing file "'README'" else sed 's/^X//' << \SHAR_EOF > 'README' X Extended Portable Bitmap Toolkit X Distribution of 13sep89 X Previous distribution 06sep89 X X XIncluded are a number of programs for converting various image formats Xto and from portable formats; plus some tools for manipulating the Xportable formats. The package is broken up into four parts (five parts Xif you count this one, the zeroth part). First is PBM, for bitmaps (1 Xbit per pixel). Then there is PGM, for grayscale images. Next is PPM, Xfor full-color images. Last, there is PNM, which does content-independent Xmanipulations on any of the three formats. X XThese parts are semi-independent; if you're only going to deal with Xbitmaps, you don't have to install PGM and PPM, and this makes PNM run Xfaster; if you want PGM, you must install PBM but can leave PPM out; Xbut if you want PPM, you must install both PGM and PBM. PNM is optional Xbut recommended. X X XTo install: X X Unpack the files. X Decide whether you want to use Imakefiles or Makefiles. If you want X to use Makefiles: X X Edit the top-level Makefile, find each line with the string X "CONFIGURE", and follow the directions for setting configuration X options. X Likewise edit pbmplus.h. X Likewise edit pbm/Makefile, ppm/Makefile, and pnm/Makefile; X pgm/Makefile does not currently have any configuration options. X Make. X When you're happy that things work ok, make install. X X If you want to use Imakefiles instead: X X Edit the top-level Imakefile, find each line with the string X "CONFIGURE", and follow the directions for setting configuration X options. X Likewise edit pbmplus.h. X Likewise edit pbm/Imakefile, ppm/Imakefile, and pnm/Imakefile; X pgm/Imakefile does not currently have any configuration options. X Edit Makefile and */Makefile, look towards the end for the X definition of TOP, and change it to point to your X11 tree. X Save the original Makefiles, in case you later want to switch back X to using them. X Touch Imakefile, since you just editted Makefile. X Make Makefile, make Makefiles, make depend, then make. X When you're happy that things work ok, make install. X X XI've tested this stuff under 4.2 BSD, 4.3 BSD, on Sun 3's, Sun 386's, on XSequents and Vaxen. Nevertheless, I'm sure bugs remain. Feedback is welcome; Xsend bug reports, enhancements, checks, money orders, etc. to the addresses Xbelow. Be sure to mention what version you have when sending bug reports! X X Jef Poskanzer X pokey@well.sf.ca.us X {ucbvax, lll-crg, sun!pacbell, apple, hplabs}!well!pokey X X XFiles in pbmplus.shar: X X README this X CHANGES list of changes between the various versions of PBM X FORMATS list of the formats supported X OTHER.SYSTEMS list of other free image-processing software X TIPS useful techniques and rules of thumb for PBM X Makefile guess X Imakefile for X11-type installations X pbmplus.h header file for PBM, PGM, PPM, and PNM X X compataliases csh script for compatibility with old versions X X XFiles in pbm.shar?: X X Makefile guess X Imakefile for X11-type installations X X brushtopbm.c convert Xerox doodle brushes to portable bitmap X cmuwmtopbm.c convert CMU window manager format to portable bitmap X g3topbm.c convert Group 3 FAX to portable bitmap X icontopbm.c convert Sun icon to portable bitmap X gemtopbm.c convert GEM .img format to portable bitmap X macptopbm.c convert MacPaint to portable bitmap X mgrtopbm.c convert MGR format to portable bitmap X pcxtopbm.c convert PC paintbrush format to portable bitmap X rasttopbm.c convert Sun raster to portable bitmap X tifftopbm.c convert TIFF format to portable bitmap X xbmtopbm.c convert X10 or X11 bitmap to portable bitmap X xwdtopbm.c convert X10 or X11 window dump to portable bitmap X X pbmtoascii.c convert portable bitmap to ASCII graphic form X pbmtobbnbg.c convert portable bitmap to BBN BitGraph graphics X pbmtocmuwm.c convert portable bitmap to CMU window manager format X pbmtogo.c convert portable bitmap to GraphOn graphics X pbmtoicon.c convert portable bitmap to Sun icon X pbmtolj.c convert portable bitmap to HP LaserJet X pbmtomacp.c convert portable bitmap to MacPaint X pbmtomgr.c convert portable bitmap to MGR format X pbmtoptx.c convert portable bitmap to Printronix X pbmtorast.c convert portable bitmap to Sun raster X pbmtoxbm.c convert portable bitmap to X11 bitmap X pbmtox10bm.c convert portable bitmap to X10 bitmap X pbmtoxwd.c convert portable bitmap to X11 window dump X X pbmlife.c apply Conway's rules of Life to a portable bitmap X pbmmake.c create a blank bitmap of a specified size X pbmmask.c create a mask bitmap from a regular bitmap X pbmpaste.c paste a rectangle into a portable bitmap X pbmreduce.c reduce a portable bitmap N times, using Floyd-Steinberg X pbmupc.c create a Universal Product Code bitmap X X libpbm[1-4].c a few utility routines X pbm.h header file for libpbm X libpbm.h internal header file for libpbm X macp.h definitions for MacPaint files X tiff.h definitions for TIFF files X x10wd.h definitions for X10 window dumps X x11wd.h definitions for X11 window dumps X bitreverse.h useful include file X *.1 manual entries for all of the tools X pbm.5 manual entry for the pbm format X X XFiles in pgm.shar?: X X Makefile guess X Imakefile for X11-type installations X X fitstopgm.c convert FITS format to portable graymap X fstopgm.c convert Usenix FaceSaver file to portable graymap X hipstopgm.c convert HIPS format to portable graymap X psidtopgm.c convert PostScript "image" data to portable graymap X X pgmtopbm.c convert portable graymap to portable bitmap X pgmtops.c convert portable graymap to Encapsulated PostScript X X pgmenhance.c edge-enhance a portable graymap X pgmhist.c print a histogram of the values in a portable graymap X pgmnorm.c normalize contrast in a portable graymap X X libpgm[1-3].c a few utility routines X pgm.h header file for libpgm X libpgm.h internal header file for libpgm X dithers.h useful include file X *.1 manual entries for all of the tools X pgm.5 manual entry for the pgm format X X XFiles in ppm.shar?: X X Makefile guess X Imakefile for X11-type installations X X giftoppm.c convert GIF to portable pixmap X ilbmtoppm.c convert Amiga IFF ILBM to portable pixmap X imgtoppm.c convert Img-whatnot to portable pixmap X mtvtoppm.c convert MTV ray-tracer output to portable pixmap X qrttoppm.c convert QRT ray-tracer output to portable pixmap X rasttoppm.c convert Sun raster file to portable pixmap X tgatoppm.c convert TrueVision Targa file to portable pixmap X xwdtoppm.c convert color X10 or X11 window dump to portable pixmap X X ppmtogif.c convert portable pixmap to GIF X ppmtoilbm.c convert portable pixmap to Amiga IFF ILBM X ppmtopgm.c convert portable pixmap to portable graymap X ppmtops.c convert portable pixmap to color Encapsulated PostScript X ppmtorast.c convert portable pixmap to Sun raster file X ppmtoxwd.c convert portable pixmap to color X11 window dump X X ppmarith.c perform arithmetic on two portable pixmaps X ppmconvol.c general MxN convolution on a portable pixmap X ppmcscale.c scale the colors in a portable pixmap X ppmpat.c create a pretty pixmap X ppmquant.c quantize colors down to a specified number X ppmrotate.c rotate a portable pixmap X ppmscale.c scale a portable pixmap X ppmshear.c shear a portable pixmap X ppmhist.c print a histogram of a portable pixmap X X convolscripts/* ppmconvol scripts X X libppm[1-5].c a few utility routines X ppm.h header file for libppm X ppmcmap.h header file for colormap routines in libppm X ppmdraw.h header file for simple drawing routines in libppm X libppm.h internal header file for libppm X tga.h definitions for TrueVision Targa files X *.1 manual entries for all of the tools X ppm.5 manual entry for the ppm format X X XFiles in pnm.shar?: X X Makefile guess X Imakefile for X11-type installations X X pnmcat.c concatenate portable anymaps X pnmcrop.c crop all like-colored borders off a portable anymap X pnmcut.c select a rectangular region from a portable anymap X pnmenlarge.c enlarge a portable anymap N times X pnmflip.c perform one or more flip operations on a portable anymap X pnminvert.c invert a portable anymap X pnmpaste.c paste a rectangle into a portable anymap X pnmtile.c replicate a portable anymap into a specified size X X libpnm[1-4].c a few utility routines X pnm.h header file for libpnm X *.1 manual entries for all of the tools X pnm.5 manual entry for the pnm format SHAR_EOF if test 8727 -ne "`wc -c < 'README'`" then echo shar: error transmitting "'README'" '(should have been 8727 characters)' fi fi # end of overwriting check echo shar: extracting "'CHANGES'" '(2786 characters)' if test -f 'CHANGES' then echo shar: will not over-write existing file "'CHANGES'" else sed 's/^X//' << \SHAR_EOF > 'CHANGES' XChanges since the expo.lcs.mit.edu FTP release of 06sep89: X X Added #ifdefs to pnm/libpnm3.c to allow the PBM-PNM-only configuration. X Small corrections to TIPS, pnm/Makefile, pnm/Imakefile, ppm/ppmrotate.1, X ppm/ppmshear.1, ppm/ppmtoilbm.c, pbm/xwdtopbm.c, ppm/xwdtoppm.c, X ppm/ppmtoxwd.c, ppm/ppmtoxwd.1, pbm/x11wd.h. X XChanges since the comp.sources.misc distribution of 31oct88: X X Added pbmreduce, pbmlife, pbmmask, and pbmupc. X Added gemtopbm, tifftopbm, pcxtopbm, pbmtogo, mgrtopbm, pbmtomgr, X cmuwmtopbm, pbmtocmuwm, g3topbm, and pbmtobg. X Minor bugfix to pbmtolj. X Slight restructuring of most of the programs to use vastly less memory. X Various other minor optimizations. X Fixed pbmtorast and rasttopbm to handle byte-swapped big-endian 386 boxes. X Slight changes to argument syntax of pbmcrop, pbmmake, pbmreduce. X Moved to the new PGM package: pbmtops (which now produces Conforming PS). X Moved to the new PPM package: giftopbm. X Moved to the new PNM package: pbmcrop pbmcut pbmenlarge pbminvert. X Consolidated into a single pnmflip tool: pbmfliplr pbmfliptb pbmtrnspos. X Consolidated into a single pnmcat tool: pbmcatlr pbmcattb. X Added compataliases script for upward compatability with changed tools. X Removed xxxtopbm. X Added a -headersize flag to macptopbm, to help get around annoying X problems in MacPaint file format. X Added the RAWBITS compilation-time option, to use a more compact and X much faster (but less portable) external format. X Removed the CBM format - use compress(1) and / or RAWBITS instead. X Pbmpaste (and the new pnmpaste) now accepts negative x and y coords, X which are interpreted relative to the right and bottom sides. X Changed all programs to accept a "-" file argument as meaning standard X input. X Removed pbmtox10wd, since it was never very useful (X10 doesn't have xwud). X Added Imakefiles, for X11 types to use. X XChanges since the X.V11R3 distribution of 31aug88: X X The cbm format has been revised to support run-length encoding. X Pbmtops now does run-length encoding. X XMajor changes since the X.V11R2 distribution of 28mar88: X X The pbm format now has a "magic number". X New conversion filters: brushtopbm, giftopbm, pbmtolj, pbmtomacp, X pbmtoxwd, and pbmtox10wd. X Icontopbm converter has a better parser -- it knows to skip over X any extraneous comments at the beginning of the icon file. X Pbmtops generates a different PostScript wrapper program -- it should X handle huge bitmaps better. X Xwdtopbm now handles byte-swapping correctly. X Pbmmake takes a flag to specify the color of the new bitmap. X Pbmpaste now implements 'or', 'and', and 'xor' operations as well X as the default 'replace'. SHAR_EOF if test 2786 -ne "`wc -c < 'CHANGES'`" then echo shar: error transmitting "'CHANGES'" '(should have been 2786 characters)' fi fi # end of overwriting check echo shar: extracting "'FORMATS'" '(1293 characters)' if test -f 'FORMATS' then echo shar: will not over-write existing file "'FORMATS'" else sed 's/^X//' << \SHAR_EOF > 'FORMATS' XPBM handles the following formats: X X Sun icon file reading writing X Sun raster file reading writing X X10 and X11 bitmap file reading writing X MacPaint reading writing X CMU window manager format reading writing X MGR format reading writing X X11 window dump file reading writing X X10 window dump file reading X Xerox doodle brushes reading X Group 3 FAX reading X GEM .img format reading X PC paintbrush (.pcx) format reading X TIFF reading X ASCII graphics writing X HP LaserJet format writing X GraphOn graphics writing X BBN BitGraph graphics writing X Printronix format writing X XPGM handles the following formats: X X Usenix FaceSaver file reading X HIPS reading X FITS reading X PostScript "image" data reading X Encapsulated PostScript writing X XPPM handles the following formats: X X color Sun raster file reading writing X GIF reading writing X Amiga IFF ILBM reading writing X color X11 window dump file reading writing X color X10 window dump file reading X MTV ray-tracer output reading X QRT ray-tracer output reading X TrueVision Targa file reading X Img-whatnot file reading X color Encapsulated PostScript writing SHAR_EOF if test 1293 -ne "`wc -c < 'FORMATS'`" then echo shar: error transmitting "'FORMATS'" '(should have been 1293 characters)' fi fi # end of overwriting check echo shar: extracting "'OTHER.SYSTEMS'" '(724 characters)' if test -f 'OTHER.SYSTEMS' then echo shar: will not over-write existing file "'OTHER.SYSTEMS'" else sed 's/^X//' << \SHAR_EOF > 'OTHER.SYSTEMS' X List of Other Image-Processing Software X XUtah RLE Toolkit. Available via FTP on cs.utah.edu. X XHIPS, from the Human Information Processing Laboratory at NYU. For Xavailability contact Michael Landy, Psychology Dept., NYU, 6 Washington XPlace, Room 980, New York NY 10003. This package is *not* free. X XFuzzy Pixmap Manipulation, by Michael Maulding. Available via FTP in Xnl.cs.cmu.edu:/usr/mlm/ftp, and also in your nearest comp.sources.unix Xarchive. X XALV Toolkit, available via email to alv-users-request@cs.bris.ac.uk. X XImg-whatnot, by Paul Raveling. Available via FTP on venera.isi.edu. X XXim, by Philip R. Thompson. Available via FTP in expo.lcs.mit.edu:contrib. SHAR_EOF if test 724 -ne "`wc -c < 'OTHER.SYSTEMS'`" then echo shar: error transmitting "'OTHER.SYSTEMS'" '(should have been 724 characters)' fi fi # end of overwriting check echo shar: extracting "'TIPS'" '(3228 characters)' if test -f 'TIPS' then echo shar: will not over-write existing file "'TIPS'" else sed 's/^X//' << \SHAR_EOF > 'TIPS' XSome notes and rules of thumb on using PBM, PGM, PPM, and PNM: X X XTo make a full-screen version of an image, or as close to it as you can Xget, compute the ratio x/y for your image and for your screen. If the Xratio is higher for your image, do a ppmscale -xsize ; if Xyour image's ratio is lower, do a ppmscale -ysize . X XEven margins: an easy way to get nice equal-sized margins on all sides Xof a non-full-screen image is to pnmcrop it, get the size and add 10% Xor so, pbmmake a bitmap of that size, and pnmpaste the image into the Xbitmap. X XSmoothing when enlarging: if you pnmenlarge or ppmscale up by a factor Xof three or more, you should add a ppmsmooth step. Otherwise you can Xsee the original pixels in the resulting image. X XRotating: as mentioned in their manual entries, pnmtrnspos and Xpnmfliptb / pnmfliplr can be used for 90 degree rotations. Ppmrotate Xcan be used for other angles between -90 and 90. To go all the way Xaround the circle, combine these two techniques. X XWhen using pbmpaste's logical operations to do masking, it is important Xto remember that while the PBM file format represents black as 1 and Xwhite as 0, pbmpaste acts as if the reverse is true: black is 0 and Xwhite is 1. See the pbmmask manual entry for examples. X XEnhancing contrast in a grayscale image: do a pgmhist, and look for Xlikely values of -bvalue and -wvalue to use with pgmnorm. If you just Xwant to enhance the contrast, then choose values at elbows in the Xhistogram; e.g. if value 29 represents 3% of the image but value 30 Xrepresents 20%, choose 30 for bvalue. If you want to lighten the Ximage, then set bvalue to 0 and just fiddle with wvalue; similarly, to Xdarken the image, set wvalue to maxval and play with bvalue. X XAvoid odd-numbered widths. Displaying them causes problems on some machines. X XTo turn a Usenix FaceSaver image into PBM, first do an "fstopgm > /dev/null". XThis will tell you whether you need to use ppmscale. Then use one of the Xfollowing pipelines: X fstopgm | pnmenlarge -3 | ppmtopgm | pgmnorm | pgmtopbm X fstopgm | pnmenlarge -3 | ppmscale -whatever | ppmtopgm | pgmnorm | pgmtopbm XEnlarging by more than 3 does not look good. X XRe-halftoning with pbmreduce: Let's say you have a scanner that only Xproduces black&white, not grayscale, and it does a terrible job of Xhalftoning (most scanners fit this description). One way to fix the Xhalftoning is to scan at the highest possible resolution, say 300 dpi, Xand then reduce by a factor of three or so using pbmreduce. Pbmreduce Xduplicates a lot of the functionality of pgmtopbm -- you could do Xsomething like ppmscale | ppmtopgm | pgmtopbm, but pbmreduce is a lot Xfaster and doesn't use as much memory. You can even correct the Xbrightness of an image with pbmreduce, by using the -value flag. X XIf you compiled with the RAWBITS option, you may sometimes want some Xnon-raw output. Maybe you want to use sed to change one color to Xanother, or something. Here's one way to get this conversion: unset XRAWBITS; choose one of the PNM programs that can be used like "cat", Xfor instance, pnmflip; compile the libraries, compile pnmflip; rename Xyour non-raw pnmflip to something like pnmunraw; set RAWBITS again, and Xrecompile things. SHAR_EOF if test 3228 -ne "`wc -c < 'TIPS'`" then echo shar: error transmitting "'TIPS'" '(should have been 3228 characters)' fi fi # end of overwriting check echo shar: extracting "'Makefile'" '(10058 characters)' if test -f 'Makefile' then echo shar: will not over-write existing file "'Makefile'" else sed 's/^X//' << \SHAR_EOF > 'Makefile' X# Makefile for pbmplus tools. X# X# Copyright (C) 1989 by Jef Poskanzer. X# X# Permission to use, copy, modify, and distribute this software and its X# documentation for any purpose and without fee is hereby granted, provided X# that the above copyright notice appear in all copies and that both that X# copyright notice and this permission notice appear in supporting X# documentation. This software is provided "as is" without express or X# implied warranty. X X# CONFIGURE: define which of the four sub-packages you want to make. PBM X# is required; PNM is recommended; and if you want PPM you must have PGM X# too. This means there are only six possibilities: XSUBDIRS = pbm pgm ppm pnm X# SUBDIRS = pbm pgm ppm X# SUBDIRS = pbm pgm pnm X# SUBDIRS = pbm pgm X# SUBDIRS = pbm pnm X# SUBDIRS = pbm X X# CONFIGURE: gcc makes things go about 20% faster, but not everyone has it. X# Warning: do not use gcc's -finline-functions flag, it can produce incorrect X# code. (This is with gcc version 1.35, later versions may fix this.) X# CC = cc XCC = gcc -fstrength-reduce -fcombine-regs X X# CONFIGURE: cc flags go here. Warning: do not use -O with gcc, it can X# produce incorrect code. (Again version 1.35. Yes, this is a separate X# bug from the -finline-functions bug.) X# CFLAGS = -O XCFLAGS = -g X# CFLAGS = X X# CONFIGURE: ld flags go here. X# LDFLAGS = -s XLDFLAGS = X X# CONFIGURE: Define the directory that you want the binaries copied to. XINSTALLBINARIES = /usr/new/pbm X X# CONFIGURE: Define the _section_ that you want the manual sources copied to. XINSTALLMANUALS = l X Xall: X for i in $(SUBDIRS) ; do \ X ( cd $$i ; make $(MFLAGS) 'CC=$(CC)' 'CFLAGS=$(CFLAGS)' 'LDFLAGS=$(LDFLAGS)' 'INSTALLBINARIES=$(INSTALLBINARIES)' 'INSTALLMANUALS=$(INSTALLMANUALS)' all ); \ X done X Xinstall: X for i in $(SUBDIRS) ; do \ X ( cd $$i ; make $(MFLAGS) 'CC=$(CC)' 'CFLAGS=$(CFLAGS)' 'LDFLAGS=$(LDFLAGS)' 'INSTALLBINARIES=$(INSTALLBINARIES)' 'INSTALLMANUALS=$(INSTALLMANUALS)' install ); \ X done X Xclean: X for i in $(SUBDIRS) ; do \ X ( cd $$i ; make $(MFLAGS) clean ); \ X done X X X# Sharchive stuff. X Xshar: pbmplus.shar pbm.shar pgm.shar ppm.shar pnm.shar X Xpbmplus.shar: README CHANGES FORMATS OTHER.SYSTEMS TIPS Imakefile \ X pbmplus.h compataliases X shar -v -c -p X README CHANGES FORMATS OTHER.SYSTEMS TIPS Makefile Imakefile pbmplus.h compataliases > $@ X Xpbm.shar: pbm.shar1 pbm.shar2 pbm.shar3 pbm.shar4 pbm.shar5 pbm.shar6 Xpbm.shar1: pbm/Makefile pbm/Imakefile pbm/pbm.h pbm/icontopbm.c \ X pbm/icontopbm.1 pbm/macptopbm.c pbm/macptopbm.1 \ X pbm/rasttopbm.c pbm/rasttopbm.1 pbm/xbmtopbm.c \ X pbm/xbmtopbm.1 pbm/xwdtopbm.c X shar -v -c -p X pbm/Makefile pbm/Imakefile pbm/pbm.h pbm/icontopbm.c pbm/icontopbm.1 pbm/macptopbm.c pbm/macptopbm.1 pbm/rasttopbm.c pbm/rasttopbm.1 pbm/xbmtopbm.c pbm/xbmtopbm.1 pbm/xwdtopbm.c > $@ Xpbm.shar2: pbm/xwdtopbm.1 pbm/pbmtoicon.c pbm/pbmtoicon.1 \ X pbm/pbmtoptx.c pbm/pbmtoptx.1 pbm/pbmtorast.c pbm/pbmtorast.1 \ X pbm/pbmtoxbm.c pbm/pbmtoxbm.1 pbm/pbmtox10bm.c \ X pbm/pbmtox10bm.1 pbm/pbmtoascii.c pbm/pbmtoascii.1 \ X pbm/pbmpaste.c pbm/pbmpaste.1 pbm/g3topbm.c pbm/g3topbm.1 X shar -v -c -p X pbm/xwdtopbm.1 pbm/pbmtoicon.c pbm/pbmtoicon.1 pbm/pbmtoptx.c pbm/pbmtoptx.1 pbm/pbmtorast.c pbm/pbmtorast.1 pbm/pbmtoxbm.c pbm/pbmtoxbm.1 pbm/pbmtox10bm.c pbm/pbmtox10bm.1 pbm/pbmtoascii.c pbm/pbmtoascii.1 pbm/pbmpaste.c pbm/pbmpaste.1 pbm/g3topbm.c pbm/g3topbm.1 > $@ Xpbm.shar3: pbm/pbmmake.c pbm/pbmmake.1 pbm/pbmtolj.c \ X pbm/pbmtolj.1 pbm/pbmtomacp.c pbm/pbmtomacp.1 \ X pbm/pbmtoxwd.c \ X pbm/pbmtoxwd.1 pbm/brushtopbm.c pbm/brushtopbm.1 \ X pbm/libpbm1.c pbm/libpbm2.c pbm/libpbm3.c pbm/libpbm4.c X shar -v -c -p X pbm/pbmmake.c pbm/pbmmake.1 pbm/pbmtolj.c pbm/pbmtolj.1 pbm/pbmtomacp.c pbm/pbmtomacp.1 pbm/pbmtoxwd.c pbm/pbmtoxwd.1 pbm/brushtopbm.c pbm/brushtopbm.1 pbm/libpbm1.c pbm/libpbm2.c pbm/libpbm3.c pbm/libpbm4.c > $@ Xpbm.shar4: pbm/pbm.5 pbm/libpbm.h pbm/macp.h pbm/x10wd.h \ X pbm/x11wd.h pbm/tiff.h pbm/bitreverse.h pbm/pbmreduce.c \ X pbm/pbmreduce.1 pbm/gemtopbm.c pbm/gemtopbm.1 pbm/pbmtogo.c \ X pbm/pbmtogo.1 pbm/pbmlife.c pbm/pbmlife.1 pbm/pcxtopbm.c X shar -v -c -p X pbm/pbm.5 pbm/libpbm.h pbm/macp.h pbm/x10wd.h pbm/x11wd.h pbm/tiff.h pbm/bitreverse.h pbm/pbmreduce.c pbm/pbmreduce.1 pbm/gemtopbm.c pbm/gemtopbm.1 pbm/pbmtogo.c pbm/pbmtogo.1 pbm/pbmlife.c pbm/pbmlife.1 pbm/pcxtopbm.c > $@ Xpbm.shar5: pbm/pcxtopbm.1 pbm/pbmupc.c pbm/pbmupc.1 \ X pbm/tifftopbm.c pbm/tifftopbm.1 pbm/mgr.h pbm/mgrtopbm.c \ X pbm/mgrtopbm.1 X shar -v -c -p X pbm/pcxtopbm.1 pbm/pbmupc.c pbm/pbmupc.1 pbm/tifftopbm.c pbm/tifftopbm.1 pbm/mgr.h pbm/mgrtopbm.c pbm/mgrtopbm.1 > $@ Xpbm.shar6: pbm/cmuwm.h pbm/cmuwmtopbm.c pbm/cmuwmtopbm.1 \ X pbm/pbmtocmuwm.c pbm/pbmtocmuwm.1 pbm/pbmmask.c pbm/pbmmask.1 \ X pbm/pbmtobbnbg.c pbm/pbmtobbnbg.1 pbm/pbmtomgr.c pbm/pbmtomgr.1 X shar -v -c -p X pbm/cmuwm.h pbm/cmuwmtopbm.c pbm/cmuwmtopbm.1 pbm/pbmtocmuwm.c pbm/pbmtocmuwm.1 pbm/pbmmask.c pbm/pbmmask.1 pbm/pbmtobbnbg.c pbm/pbmtobbnbg.1 pbm/pbmtomgr.c pbm/pbmtomgr.1 > $@ X Xpgm.shar: pgm.shar1 pgm.shar2 Xpgm.shar1: pgm/Makefile pgm/Imakefile pgm/pgm.5 pgm/libpgm1.c \ X pgm/libpgm2.c pgm/pgm.h pgm/libpgm.h pgm/fstopgm.c \ X pgm/fstopgm.1 pgm/hipstopgm.c pgm/hipstopgm.1 pgm/pgmenhance.c \ X pgm/pgmenhance.1 pgm/pgmhist.c pgm/pgmhist.1 pgm/pgmnorm.c \ X pgm/pgmnorm.1 X shar -v -c -p X pgm/Makefile pgm/Imakefile pgm/pgm.5 pgm/libpgm1.c pgm/libpgm2.c pgm/pgm.h pgm/libpgm.h pgm/fstopgm.c pgm/fstopgm.1 pgm/hipstopgm.c pgm/hipstopgm.1 pgm/pgmenhance.c pgm/pgmenhance.1 pgm/pgmhist.c pgm/pgmhist.1 pgm/pgmnorm.c pgm/pgmnorm.1 > $@ Xpgm.shar2: pgm/pgmtopbm.c pgm/pgmtopbm.1 pgm/dithers.h \ X pgm/pgmtops.c pgm/pgmtops.1 pgm/psidtopgm.c pgm/psidtopgm.1 \ X pgm/fitstopgm.c pgm/fitstopgm.1 X shar -v -c -p X pgm/pgmtopbm.c pgm/pgmtopbm.1 pgm/dithers.h pgm/pgmtops.c pgm/pgmtops.1 pgm/psidtopgm.c pgm/psidtopgm.1 pgm/fitstopgm.c pgm/fitstopgm.1 > $@ X Xppm.shar: ppm.shar1 ppm.shar2 ppm.shar3 ppm.shar4 ppm.shar5 ppm.shar6 \ X ppm.shar7 Xppm.shar1: ppm/Makefile ppm/Imakefile ppm/ppm.5 ppm/libppm1.c \ X ppm/libppm2.c ppm/libppm3.c ppm/libppm4.c ppm/libppm5.c \ X ppm/convolscripts/ppmsmooth X shar -v -c -p X ppm/Makefile ppm/Imakefile ppm/ppm.5 ppm/libppm1.c ppm/libppm2.c ppm/libppm3.c ppm/libppm4.c ppm/libppm5.c ppm/convolscripts/ppmsmooth > $@ Xppm.shar2: ppm/ppm.h ppm/ppmcmap.h ppm/ppmdraw.h ppm/libppm.h \ X ppm/tga.h ppm/mtvtoppm.c ppm/mtvtoppm.1 ppm/giftoppm.c \ X ppm/giftoppm.1 ppm/ppmrotate.c ppm/ppmrotate.1 X shar -v -c -p X ppm/ppm.h ppm/ppmcmap.h ppm/ppmdraw.h ppm/libppm.h ppm/tga.h ppm/mtvtoppm.c ppm/mtvtoppm.1 ppm/giftoppm.c ppm/giftoppm.1 ppm/ppmrotate.c ppm/ppmrotate.1 > $@ Xppm.shar3: ppm/ppmscale.c ppm/ppmscale.1 ppm/ppmshear.c \ X ppm/ppmshear.1 ppm/ppmpat.c X shar -v -c -p X ppm/ppmscale.c ppm/ppmscale.1 ppm/ppmshear.c ppm/ppmshear.1 ppm/ppmpat.c > $@ Xppm.shar4: ppm/ppmpat.1 ppm/ppmconvol.c ppm/ppmconvol.1 \ X ppm/ppmtopgm.c ppm/ppmtopgm.1 ppm/ppmtorast.c ppm/ppmtorast.1 \ X ppm/rasttoppm.c ppm/rasttoppm.1 X shar -v -c -p X ppm/ppmpat.1 ppm/ppmconvol.c ppm/ppmconvol.1 ppm/ppmtopgm.c ppm/ppmtopgm.1 ppm/ppmtorast.c ppm/ppmtorast.1 ppm/rasttoppm.c ppm/rasttoppm.1 > $@ Xppm.shar5: ppm/ppmcscale.c ppm/ppmcscale.1 ppm/ilbmtoppm.c \ X ppm/ilbm.h ppm/ilbmtoppm.1 ppm/ppmquant.c ppm/ppmquant.1 \ X ppm/ppmarith.c ppm/ppmarith.1 X shar -v -c -p X ppm/ppmcscale.c ppm/ppmcscale.1 ppm/ilbmtoppm.c ppm/ilbm.h ppm/ilbmtoppm.1 ppm/ppmquant.c ppm/ppmquant.1 ppm/ppmarith.c ppm/ppmarith.1 > $@ Xppm.shar6: ppm/qrttoppm.c ppm/qrttoppm.1 ppm/ppmtops.c \ X ppm/ppmtops.1 ppm/ppmtogif.c ppm/ppmtogif.1 ppm/ppmtoilbm.c \ X ppm/ppmtoilbm.1 X shar -v -c -p X ppm/qrttoppm.c ppm/qrttoppm.1 ppm/ppmtops.c ppm/ppmtops.1 ppm/ppmtogif.c ppm/ppmtogif.1 ppm/ppmtoilbm.c ppm/ppmtoilbm.1 > $@ Xppm.shar7: ppm/tgatoppm.c ppm/tgatoppm.1 ppm/ppmhist.c \ X ppm/ppmhist.1 ppm/xwdtoppm.c ppm/xwdtoppm.1 ppm/ppmtoxwd.c \ X ppm/ppmtoxwd.1 ppm/imgtoppm.c ppm/imgtoppm.1 X shar -v -c -p X ppm/tgatoppm.c ppm/tgatoppm.1 ppm/ppmhist.c ppm/ppmhist.1 ppm/xwdtoppm.c ppm/xwdtoppm.1 ppm/ppmtoxwd.c ppm/ppmtoxwd.1 ppm/imgtoppm.c ppm/imgtoppm.1 > $@ X Xpnm.shar: pnm.shar1 pnm.shar2 Xpnm.shar1: pnm/Makefile pnm/Imakefile pnm/pnm.5 pnm/libpnm1.c \ X pnm/libpnm2.c pnm/libpnm3.c pnm/pnm.h pnm/pnmcat.c \ X pnm/pnmcat.1 pnm/pnmcrop.c pnm/pnmcrop.1 pnm/pnmcut.c \ X pnm/pnmcut.1 pnm/pnmenlarge.c pnm/pnmenlarge.1 X shar -v -c -p X pnm/Makefile pnm/Imakefile pnm/pnm.5 pnm/libpnm1.c pnm/libpnm2.c pnm/libpnm3.c pnm/pnm.h pnm/pnmcat.c pnm/pnmcat.1 pnm/pnmcrop.c pnm/pnmcrop.1 pnm/pnmcut.c pnm/pnmcut.1 pnm/pnmenlarge.c pnm/pnmenlarge.1 > $@ Xpnm.shar2: pnm/pnmflip.c pnm/pnmflip.1 pnm/pnminvert.c pnm/pnminvert.1 \ X pnm/pnmpaste.c pnm/pnmpaste.1 pnm/pnmtile.c pnm/pnmtile.1 X shar -v -c -p X pnm/pnmflip.c pnm/pnmflip.1 pnm/pnminvert.c pnm/pnminvert.1 pnm/pnmpaste.c pnm/pnmpaste.1 pnm/pnmtile.c pnm/pnmtile.1 > $@ X X X# Imakefile stuff. Ignore if you're not an X11 type. X X TOP = ../../../../../usr/src/new/X11 X X RM = rm -f X MV = mv X UTILSRC = $(TOP)/util X IMAKESRC = $(UTILSRC)/imake X IRULESRC = $(UTILSRC)/imake.includes X IMAKE = $(IMAKESRC)/imake X IMAKE_DEFINES = X IMAKE_CMD = $(NEWTOP)$(IMAKE) -TImake.tmpl -I$(NEWTOP)$(IRULESRC) \ X -s Makefile $(IMAKE_DEFINES) XMakefile: Imakefile \ X $(IRULESRC)/Imake.tmpl \ X $(IRULESRC)/Imake.rules \ X $(IRULESRC)/site.def \ X $(IRULESRC)/$(MACROFILE) X -@if [ -f Makefile ]; then \ X echo "$(RM) Makefile.bak; $(MV) Makefile Makefile.bak"; \ X $(RM) Makefile.bak; $(MV) Makefile Makefile.bak; \ X else exit 0; fi X $(IMAKE_CMD) -DTOPDIR=$(TOP) X XMakefiles: X @case '${MFLAGS}' in *[ik]*) set +e;; esac; \ X for i in $(SUBDIRS) ;\ X do \ X echo "Making Makefiles in $$i..."; \ X $(MAKE) subdirMakefiles NEWTOP=../ MAKEFILE_SUBDIR=$$i;\ X done X XsubdirMakefiles: X $(RM) $(MAKEFILE_SUBDIR)/Makefile.bak X -@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then \ X echo "$(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak"; \ X $(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ X else exit 0; fi X cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=../$(TOP); \ X $(MAKE) $(MFLAGS) Makefiles SHAR_EOF if test 10058 -ne "`wc -c < 'Makefile'`" then echo shar: error transmitting "'Makefile'" '(should have been 10058 characters)' fi fi # end of overwriting check echo shar: extracting "'Imakefile'" '(7640 characters)' if test -f 'Imakefile' then echo shar: will not over-write existing file "'Imakefile'" else sed 's/^X//' << \SHAR_EOF > 'Imakefile' X# Imakefile for pbmplus tools. X# X# Copyright (C) 1989 by Jef Poskanzer. X# X# Permission to use, copy, modify, and distribute this software and its X# documentation for any purpose and without fee is hereby granted, provided X# that the above copyright notice appear in all copies and that both that X# copyright notice and this permission notice appear in supporting X# documentation. This software is provided "as is" without express or X# implied warranty. X X#define IHaveSubdirs X#define PassCDebugFlags 'CDEBUGFLAGS=$(CDEBUGFLAGS)' X X# CONFIGURE: define which of the four sub-packages you want to make. PBM X# is required; PNM is recommended; and if you want PPM you must have PGM X# too. This means there are only six possibilities: XSUBDIRS = pbm pgm ppm pnm X# SUBDIRS = pbm pgm ppm X# SUBDIRS = pbm pgm pnm X# SUBDIRS = pbm pgm X# SUBDIRS = pbm pnm X# SUBDIRS = pbm X XMakeSubdirs($(SUBDIRS)) XDependSubdirs($(SUBDIRS)) X X X# Sharchive stuff. X Xshar: pbmplus.shar pbm.shar pgm.shar ppm.shar pnm.shar X Xpbmplus.shar: README CHANGES FORMATS OTHER.SYSTEMS TIPS Imakefile \ X pbmplus.h compataliases X shar -v -c -p X README CHANGES FORMATS OTHER.SYSTEMS TIPS Makefile Imakefile pbmplus.h compataliases > $@ X Xpbm.shar: pbm.shar1 pbm.shar2 pbm.shar3 pbm.shar4 pbm.shar5 pbm.shar6 Xpbm.shar1: pbm/Makefile pbm/Imakefile pbm/pbm.h pbm/icontopbm.c \ X pbm/icontopbm.1 pbm/macptopbm.c pbm/macptopbm.1 \ X pbm/rasttopbm.c pbm/rasttopbm.1 pbm/xbmtopbm.c \ X pbm/xbmtopbm.1 pbm/xwdtopbm.c X shar -v -c -p X pbm/Makefile pbm/Imakefile pbm/pbm.h pbm/icontopbm.c pbm/icontopbm.1 pbm/macptopbm.c pbm/macptopbm.1 pbm/rasttopbm.c pbm/rasttopbm.1 pbm/xbmtopbm.c pbm/xbmtopbm.1 pbm/xwdtopbm.c > $@ Xpbm.shar2: pbm/xwdtopbm.1 pbm/pbmtoicon.c pbm/pbmtoicon.1 \ X pbm/pbmtoptx.c pbm/pbmtoptx.1 pbm/pbmtorast.c pbm/pbmtorast.1 \ X pbm/pbmtoxbm.c pbm/pbmtoxbm.1 pbm/pbmtox10bm.c \ X pbm/pbmtox10bm.1 pbm/pbmtoascii.c pbm/pbmtoascii.1 \ X pbm/pbmpaste.c pbm/pbmpaste.1 pbm/g3topbm.c pbm/g3topbm.1 X shar -v -c -p X pbm/xwdtopbm.1 pbm/pbmtoicon.c pbm/pbmtoicon.1 pbm/pbmtoptx.c pbm/pbmtoptx.1 pbm/pbmtorast.c pbm/pbmtorast.1 pbm/pbmtoxbm.c pbm/pbmtoxbm.1 pbm/pbmtox10bm.c pbm/pbmtox10bm.1 pbm/pbmtoascii.c pbm/pbmtoascii.1 pbm/pbmpaste.c pbm/pbmpaste.1 pbm/g3topbm.c pbm/g3topbm.1 > $@ Xpbm.shar3: pbm/pbmmake.c pbm/pbmmake.1 pbm/pbmtolj.c \ X pbm/pbmtolj.1 pbm/pbmtomacp.c pbm/pbmtomacp.1 \ X pbm/pbmtoxwd.c \ X pbm/pbmtoxwd.1 pbm/brushtopbm.c pbm/brushtopbm.1 \ X pbm/libpbm1.c pbm/libpbm2.c pbm/libpbm3.c pbm/libpbm4.c X shar -v -c -p X pbm/pbmmake.c pbm/pbmmake.1 pbm/pbmtolj.c pbm/pbmtolj.1 pbm/pbmtomacp.c pbm/pbmtomacp.1 pbm/pbmtoxwd.c pbm/pbmtoxwd.1 pbm/brushtopbm.c pbm/brushtopbm.1 pbm/libpbm1.c pbm/libpbm2.c pbm/libpbm3.c pbm/libpbm4.c > $@ Xpbm.shar4: pbm/pbm.5 pbm/libpbm.h pbm/macp.h pbm/x10wd.h \ X pbm/x11wd.h pbm/tiff.h pbm/bitreverse.h pbm/pbmreduce.c \ X pbm/pbmreduce.1 pbm/gemtopbm.c pbm/gemtopbm.1 pbm/pbmtogo.c \ X pbm/pbmtogo.1 pbm/pbmlife.c pbm/pbmlife.1 pbm/pcxtopbm.c X shar -v -c -p X pbm/pbm.5 pbm/libpbm.h pbm/macp.h pbm/x10wd.h pbm/x11wd.h pbm/tiff.h pbm/bitreverse.h pbm/pbmreduce.c pbm/pbmreduce.1 pbm/gemtopbm.c pbm/gemtopbm.1 pbm/pbmtogo.c pbm/pbmtogo.1 pbm/pbmlife.c pbm/pbmlife.1 pbm/pcxtopbm.c > $@ Xpbm.shar5: pbm/pcxtopbm.1 pbm/pbmupc.c pbm/pbmupc.1 \ X pbm/tifftopbm.c pbm/tifftopbm.1 pbm/mgr.h pbm/mgrtopbm.c \ X pbm/mgrtopbm.1 X shar -v -c -p X pbm/pcxtopbm.1 pbm/pbmupc.c pbm/pbmupc.1 pbm/tifftopbm.c pbm/tifftopbm.1 pbm/mgr.h pbm/mgrtopbm.c pbm/mgrtopbm.1 > $@ Xpbm.shar6: pbm/cmuwm.h pbm/cmuwmtopbm.c pbm/cmuwmtopbm.1 \ X pbm/pbmtocmuwm.c pbm/pbmtocmuwm.1 pbm/pbmmask.c pbm/pbmmask.1 \ X pbm/pbmtobbnbg.c pbm/pbmtobbnbg.1 pbm/pbmtomgr.c pbm/pbmtomgr.1 X shar -v -c -p X pbm/cmuwm.h pbm/cmuwmtopbm.c pbm/cmuwmtopbm.1 pbm/pbmtocmuwm.c pbm/pbmtocmuwm.1 pbm/pbmmask.c pbm/pbmmask.1 pbm/pbmtobbnbg.c pbm/pbmtobbnbg.1 pbm/pbmtomgr.c pbm/pbmtomgr.1 > $@ X Xpgm.shar: pgm.shar1 pgm.shar2 Xpgm.shar1: pgm/Makefile pgm/Imakefile pgm/pgm.5 pgm/libpgm1.c \ X pgm/libpgm2.c pgm/pgm.h pgm/libpgm.h pgm/fstopgm.c \ X pgm/fstopgm.1 pgm/hipstopgm.c pgm/hipstopgm.1 pgm/pgmenhance.c \ X pgm/pgmenhance.1 pgm/pgmhist.c pgm/pgmhist.1 pgm/pgmnorm.c \ X pgm/pgmnorm.1 X shar -v -c -p X pgm/Makefile pgm/Imakefile pgm/pgm.5 pgm/libpgm1.c pgm/libpgm2.c pgm/pgm.h pgm/libpgm.h pgm/fstopgm.c pgm/fstopgm.1 pgm/hipstopgm.c pgm/hipstopgm.1 pgm/pgmenhance.c pgm/pgmenhance.1 pgm/pgmhist.c pgm/pgmhist.1 pgm/pgmnorm.c pgm/pgmnorm.1 > $@ Xpgm.shar2: pgm/pgmtopbm.c pgm/pgmtopbm.1 pgm/dithers.h \ X pgm/pgmtops.c pgm/pgmtops.1 pgm/psidtopgm.c pgm/psidtopgm.1 \ X pgm/fitstopgm.c pgm/fitstopgm.1 X shar -v -c -p X pgm/pgmtopbm.c pgm/pgmtopbm.1 pgm/dithers.h pgm/pgmtops.c pgm/pgmtops.1 pgm/psidtopgm.c pgm/psidtopgm.1 pgm/fitstopgm.c pgm/fitstopgm.1 > $@ X Xppm.shar: ppm.shar1 ppm.shar2 ppm.shar3 ppm.shar4 ppm.shar5 ppm.shar6 \ X ppm.shar7 Xppm.shar1: ppm/Makefile ppm/Imakefile ppm/ppm.5 ppm/libppm1.c \ X ppm/libppm2.c ppm/libppm3.c ppm/libppm4.c ppm/libppm5.c \ X ppm/convolscripts/ppmsmooth X shar -v -c -p X ppm/Makefile ppm/Imakefile ppm/ppm.5 ppm/libppm1.c ppm/libppm2.c ppm/libppm3.c ppm/libppm4.c ppm/libppm5.c ppm/convolscripts/ppmsmooth > $@ Xppm.shar2: ppm/ppm.h ppm/ppmcmap.h ppm/ppmdraw.h ppm/libppm.h \ X ppm/tga.h ppm/mtvtoppm.c ppm/mtvtoppm.1 ppm/giftoppm.c \ X ppm/giftoppm.1 ppm/ppmrotate.c ppm/ppmrotate.1 X shar -v -c -p X ppm/ppm.h ppm/ppmcmap.h ppm/ppmdraw.h ppm/libppm.h ppm/tga.h ppm/mtvtoppm.c ppm/mtvtoppm.1 ppm/giftoppm.c ppm/giftoppm.1 ppm/ppmrotate.c ppm/ppmrotate.1 > $@ Xppm.shar3: ppm/ppmscale.c ppm/ppmscale.1 ppm/ppmshear.c \ X ppm/ppmshear.1 ppm/ppmpat.c X shar -v -c -p X ppm/ppmscale.c ppm/ppmscale.1 ppm/ppmshear.c ppm/ppmshear.1 ppm/ppmpat.c > $@ Xppm.shar4: ppm/ppmpat.1 ppm/ppmconvol.c ppm/ppmconvol.1 \ X ppm/ppmtopgm.c ppm/ppmtopgm.1 ppm/ppmtorast.c ppm/ppmtorast.1 \ X ppm/rasttoppm.c ppm/rasttoppm.1 X shar -v -c -p X ppm/ppmpat.1 ppm/ppmconvol.c ppm/ppmconvol.1 ppm/ppmtopgm.c ppm/ppmtopgm.1 ppm/ppmtorast.c ppm/ppmtorast.1 ppm/rasttoppm.c ppm/rasttoppm.1 > $@ Xppm.shar5: ppm/ppmcscale.c ppm/ppmcscale.1 ppm/ilbmtoppm.c \ X ppm/ilbm.h ppm/ilbmtoppm.1 ppm/ppmquant.c ppm/ppmquant.1 \ X ppm/ppmarith.c ppm/ppmarith.1 X shar -v -c -p X ppm/ppmcscale.c ppm/ppmcscale.1 ppm/ilbmtoppm.c ppm/ilbm.h ppm/ilbmtoppm.1 ppm/ppmquant.c ppm/ppmquant.1 ppm/ppmarith.c ppm/ppmarith.1 > $@ Xppm.shar6: ppm/qrttoppm.c ppm/qrttoppm.1 ppm/ppmtops.c \ X ppm/ppmtops.1 ppm/ppmtogif.c ppm/ppmtogif.1 ppm/ppmtoilbm.c \ X ppm/ppmtoilbm.1 X shar -v -c -p X ppm/qrttoppm.c ppm/qrttoppm.1 ppm/ppmtops.c ppm/ppmtops.1 ppm/ppmtogif.c ppm/ppmtogif.1 ppm/ppmtoilbm.c ppm/ppmtoilbm.1 > $@ Xppm.shar7: ppm/tgatoppm.c ppm/tgatoppm.1 ppm/ppmhist.c \ X ppm/ppmhist.1 ppm/xwdtoppm.c ppm/xwdtoppm.1 ppm/ppmtoxwd.c \ X ppm/ppmtoxwd.1 ppm/imgtoppm.c ppm/imgtoppm.1 X shar -v -c -p X ppm/tgatoppm.c ppm/tgatoppm.1 ppm/ppmhist.c ppm/ppmhist.1 ppm/xwdtoppm.c ppm/xwdtoppm.1 ppm/ppmtoxwd.c ppm/ppmtoxwd.1 ppm/imgtoppm.c ppm/imgtoppm.1 > $@ X Xpnm.shar: pnm.shar1 pnm.shar2 Xpnm.shar1: pnm/Makefile pnm/Imakefile pnm/pnm.5 pnm/libpnm1.c \ X pnm/libpnm2.c pnm/libpnm3.c pnm/pnm.h pnm/pnmcat.c \ X pnm/pnmcat.1 pnm/pnmcrop.c pnm/pnmcrop.1 pnm/pnmcut.c \ X pnm/pnmcut.1 pnm/pnmenlarge.c pnm/pnmenlarge.1 X shar -v -c -p X pnm/Makefile pnm/Imakefile pnm/pnm.5 pnm/libpnm1.c pnm/libpnm2.c pnm/libpnm3.c pnm/pnm.h pnm/pnmcat.c pnm/pnmcat.1 pnm/pnmcrop.c pnm/pnmcrop.1 pnm/pnmcut.c pnm/pnmcut.1 pnm/pnmenlarge.c pnm/pnmenlarge.1 > $@ Xpnm.shar2: pnm/pnmflip.c pnm/pnmflip.1 pnm/pnminvert.c pnm/pnminvert.1 \ X pnm/pnmpaste.c pnm/pnmpaste.1 pnm/pnmtile.c pnm/pnmtile.1 X shar -v -c -p X pnm/pnmflip.c pnm/pnmflip.1 pnm/pnminvert.c pnm/pnminvert.1 pnm/pnmpaste.c pnm/pnmpaste.1 pnm/pnmtile.c pnm/pnmtile.1 > $@ SHAR_EOF if test 7640 -ne "`wc -c < 'Imakefile'`" then echo shar: error transmitting "'Imakefile'" '(should have been 7640 characters)' fi fi # end of overwriting check echo shar: extracting "'pbmplus.h'" '(2700 characters)' if test -f 'pbmplus.h' then echo shar: will not over-write existing file "'pbmplus.h'" else sed 's/^X//' << \SHAR_EOF > 'pbmplus.h' X/* pbmplus.h - header file for PBM, PGM, PPM, and PNM X*/ X X#ifndef _PBMPLUS_H_ X#define _PBMPLUS_H_ X X#if ! ( defined(BSD) || defined(SYSV) ) X/* CONFIGURE: If your system is >= 4.2BSD, set the BSD option; if you're a X** System V site, set the SYSV option. This mostly has to do with string X** functions. X*/ X#define BSD X/* #define SYSV */ X#endif X X/* CONFIGURE: If you want to enable writing "raw" files, set this option. X** "Raw" files are smaller, and much faster to read and write, but you X** must have a filesystem that allows all 256 ASCII characters to be read X** and written. Also, you will no longer be able to mail P?M files without X** using uuencode or the equivalent. Note that reading "raw" files works X** whether writing is enabled or not. X*/ X#define PBMPLUS_RAWBITS X X/* CONFIGURE: PGM can store gray values as either bytes or shorts. For most X** applications, bytes will be big enough, and the memory savings can be X** substantial. However, if you need more than 8 bits of resolution, then X** define this symbol. X** X** If you are not making PGM, you can ignore this. X*/ X/* #define PGM_BIGGRAYS */ X X/* CONFIGURE: Normally, PPM handles a pixel as a struct of three grays. X** It can also be configured to pack the three values into a single longword, X** 10 bits each. If you have configured PGM with the PGM_BIGGRAYS option X** (store grays as shorts), AND you don't need more than 10 bits for each X** color component, AND you care more about memory use than speed, then X** this option might be a win. Under these circumstances it will make X** some of the programs use 1.5 times less space, but all of the programs X** will run about 1.4 times slower. X** X** If you are not using PGM_BIGGRAYS, then this option is useless -- it X** doesn't save any space, but it still slows things down. X** X** If you are not making PPM, you can ignore this. X*/ X/* #define PPM_PACKCOLORS */ X X/* CONFIGURE: uncomment this to enable debugging checks. */ X/* #define DEBUG */ X X/* End of configurable definitions. */ X X/* Variable-sized arrays definitions. */ X Xchar **pm_allocarray( /* int cols, int rows, size */ ); Xchar *pm_allocrow( /* int cols, size */); Xvoid pm_freearray( /* char **its, int rows */ ); Xvoid pm_freerow( /* char *itrow */ ); X X/* Error handling definitions. */ X Xextern char *pm_progname; /* every main() must assign argv[0] to this */ Xvoid pm_message( /* char *fmt, arg, arg, arg, arg, arg */ ); Xvoid pm_error( /* char *fmt, arg, arg, arg, arg, arg */ ); /* doesn't return */ Xvoid pm_usage( /* char *usage */ ); /* doesn't return */ X X/* File open/close that handles "-" as stdin and checks errors. */ X XFILE *pm_openr( /* char *name */ ); Xvoid pm_close( /* FILE *f */ ); X X#endif _PBMPLUS_H_ SHAR_EOF if test 2700 -ne "`wc -c < 'pbmplus.h'`" then echo shar: error transmitting "'pbmplus.h'" '(should have been 2700 characters)' fi fi # end of overwriting check echo shar: extracting "'compataliases'" '(419 characters)' if test -f 'compataliases' then echo shar: will not over-write existing file "'compataliases'" else sed 's/^X//' << \SHAR_EOF > 'compataliases' X# compataliases - csh aliases to allow users of old versions of PBM to keep X# their habits. X# X# This script must be sourced - it will not work if you run it in a sub-shell. X Xalias pbmcatlr pnmcat -lr Xalias pbmcattb pnmcat -tb Xalias pbmcrop pnmcrop Xalias pbmcut pnmcut Xalias pbmenlarge pnmenlarge Xalias pbmfliplr pnmflip -lr Xalias pbmfliptb pnmflip -tb Xalias pbmtops pgmtops Xalias pbmtrnspos pnmflip -xy SHAR_EOF if test 419 -ne "`wc -c < 'compataliases'`" then echo shar: error transmitting "'compataliases'" '(should have been 419 characters)' fi fi # end of overwriting check # End of shell archive exit 0