12 [ -z "$NEGATIVE" ] && src="Flatbed" || src="Transparency Adapter"
13 [ -z "$NEGATIVE" ] && depth=8 || depth=16
14 [ -z "$NEGATIVE" ] && resolution=800 || resolution=1600
15 if [ "$preview" = "yes" ]; then
24 --resolution=$resolution \
30 [ $rotate -eq 0 ] && rotator=cat || rotator="pamflip -rotate$rotate"
31 [ -z "$NEGATIVE" ] && inverter=cat || inverter=pnminvert
32 $rotator | pnmcrop -closeness=$crop | $inverter
36 process < tmp.ppm | pamdepth 255 | pnmscale -w 600 > preview.ppm
42 [ -z "$NEGATIVE" ] && crop=40 || crop=10
44 cur=`printf "%03d.ppm" $ctr`
50 echo -n "$cur: crop:$crop rotate:$rotate v/r/c/s/p/n> "
54 scan yes --preview=yes
58 scan no --preview=no --high-quality=yes
65 cat tmp.ppm | process > $cur
69 echo -n "Rotate (n/r/l/t):"