Netpbm Official Docs

http://netpbm.sourceforge.net/doc/

Image Type Descriptions

pbm
Black and white image format
pgm
Grayscale image format
ppm
RGB image format
pnm
Any file of the above formats
pam
Generic two-dimensional grid format

Formats are downwards compatible. For example, any ppm program can deal with pbm image, etc. Pam is downward compatible with any format.

Create thumbnails of a folder of images sized at 50%

ls *.jpg | while read item; do jpegtopnm "$item" | pamscale .50 | pnmtojpeg > `echo file | sed 's|\(.*\)\.jpg|\1-thumb.jpg|'`

Add Drop Shawdow to an Image

jpegtopnm file | pnmmargin -white 10 | ppmshadow | pnmtojpeg > file.done; mv file.done file

Label Images

jpegtopnm file | ppmlabel -text 'hi there!' | pnmtojpeg > `echo file | sed 's|\(.*\)\.jpg|\1-label.jpg|'`

Glue Images Together

images2text

   images/totakeke1.gif converted to ascii text with netpbm 
                  Mo                                        ooo
                  MM  oMo                                   "MMM
                 MMMoMMMM                                     MMMo
                oMMM"MMMM                                      "MMM
               MMM"   MMMooooooo                                 MMMo
                 "    MMMMMMMMMMMo                   oMMMMoo
                      MMMMMMMMMMMMo                oMMMMMMMMM
                      MMMMMMMMMMMMMMo             MMMMMMMM""
                      MMMMMMMMMMMMMMMo            MMMM"" oMMo
                      MMMMMMMMMMMMMMMMo          MM""  oMMM"M"
                       MMMMMMMMMMMMMM           M" oMMMMMMM
                        MMMMMMMMMMMMM             M"""MMMMM
                        "MMMMMMMMMM                  "MMMM "
                          ""MMMMMMMMo
                      o     "MMMMMMMM
                    M"        MMMMMMMM  MMMMMoo
                    M         MMMMMMMMMMMMMMMMMMo
                    "         MMMMMMMMMMMMMMMMMMM      o
                      Mo      MMMMMMMMMMMMMMMMMM    oooM
                      "MM  ooM"MMMMMMMMMMMMMMoooooMMM"             MMM  M
                       "MMMMMM    """MMMMMMMMMMMM""               o"  MM
                          ""MM       MMMMMMMMMMMMoooo  o  oooooM MMoo MMM
                            MM     MMMMMMo  oMoMMoMo   M  MMMMMMMoMMooMM"
                            MM oooo"MMMM"  """""""MMo             ""  M
                            Mo MMMMo  "           MMM
                               MMMMMMMMM            MMM
                  o             "MMM"""       o      MMM
                  "                          "        ""
                   "            oMoMo
                     ooo      oMMMMMMMMo"
                                  """""o oM
                                       " ""
                                      Mo
                                     """