#!/bin/sh ################################################################################ # WeBWorK Online Homework Delivery System # Copyright © 2000-2003 The WeBWorK Project, http://openwebwork.sf.net/ # $CVSHeader$ # # This program is free software; you can redistribute it and/or modify it under # the terms of either: (a) the GNU General Public License as published by the # Free Software Foundation; either version 2, or (at your option) any later # version, or (b) the "Artistic License" which comes with this package. # # This program is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS # FOR A PARTICULAR PURPOSE. See either the GNU General Public License or the # Artistic License for more details. ################################################################################ # This script wraps system-dependant calls to several netpbm utilities. # In order to use this script, set the NETPBM variable below to the # directory which contains giftopnm, ppmtopgm, and pnmtops. NETPBM=/usr/local/bin # If you wish to set the paths to each utility separately, i.e. if they # are in different locations, do so below: GIFTOPNM=$NETPBM/giftopnm; PPMTOPGM=$NETPBM/ppmtopgm; PNMTOPS=$NETPBM/pnmtops; # There should be no need for customization beyond this point. umask 022 cat $1 | $GIFTOPNM | $PPMTOPGM | $PNMTOPS -noturn 2>/dev/null > $2 # CODER NOTE: # We used to use `pnmdepth 1' instead of ppmtopgm as it creates a # monochrome image (1 bit) rather than a greyscale image (8 bits). # However, this was causing improper display of some sort in PDFs.