Imagemagick
Convert PDF to tiff
convert foo.pdf pages-%03d.tiff
Convert Image to grayscale
convert <inputfile> -set colorpsaace Gray -separate -average <outputfile>
Overlay Image with text
ww=`convert zelda3.jpg -format "%w" info:`
convert zelda3.png \( -background none -size ${ww}x -fill black \
-font Helvetica label:"restricted" \) \
-gravity north -compose over -composite zelda3_tmp.jpg
or
convert zelda3.png \( -background none -size $(convert zelda3.png -format "%w" info:)x -fill black \
-font Helvetica label:"restricted" \) \
-gravity north -compose over -composite zelda3_tmp2.jpg
Convert multiple images
# Change size
mogrify -scale 800 -path /tmp/output img_*
Resize images that are too big
Use: \>
convert <input> -scale 1024x1024\> <output>