all: ../about.bmp ../icon.bmp ../smallicon.bmp

../smallicon.bmp:smallicon.pbm
	pbmmake -white 15 9 | pnmpaste -replace $< 1 0 - | ppmtobmp -windows > $@
../icon.bmp:icon.pbm
	pbmmake -white 32 32 | pnmpaste -replace $< 0 0 - | ppmtobmp -windows > $@
../about.bmp:fish.q.pgm
	ppmtobmp -windows $< > $@
fish.q.pgm:fish.pgm map
	ppmquant -map map -fs < fish.pgm | ppmtopgm > $@
fish.pgm:fish.big.pgm
	pnmscale 0.256 < fish.big.pgm > fish.pgm
fish.big.pgm:fish.eps translate.eps
	gs -r200 -DA4 -sDEVICE=pgmraw -dNOPAUSE -sOutputFile="|pnmcrop > fish.big.pgm" translate.eps fish.eps -c showpage -c quit

smallicon.pgm:fish.big.pgm
	pnmscale 0.0206422018 < $< > $@
smallicon.pbm:smallicon.pgm
	pgmtopbm -threshold -value 0.88 $< > $@

icon.pgm:fish.big.pgm
	pnmscale 0.058608 < $< > $@
icon.pbm:icon.pgm
	pgmtopbm -threshold -value 0.88 $< > $@

