ImageUtil

A command-line image processing tool with multiple filters. These are mainly for pixel-editing, fixing color palettes, and such, and not generally "user-friendly", but developer-friendly.

% java -jar ImageUtil.jar --help
Unknown option '--help'
Usage: ImageUtil [OPTION]... INFILE [OUTFILE]
  OPTIONS:
--autocrop                 Resize image to first non-transparent rows/cols
--clip X Y WIDTH HEIGHT    Clips a sub-image from the image
--debug                    Print to stdout all pixels as hex values
--mask                     Write INFILE.mask with "{x,y}" on first line, then y lines of x chars: ' ' or 'X' for alpha 0.5+
--outline COLOR            Outlines all non-transparent pixels with COLOR
--pad DIR WIDTH HEIGHT     Pads image to new canvas size width * height, DIR=n,ne,e,se,s,sw,w,nw,c
--recolor IN OUT           Replace all colors #AARRGGBB IN with OUT
--negative IN OUT          Replace all colors #AARRGGBB except IN with OUT
--resize WIDTH HEIGHT      Resize image to width * height
--rotate N                 Rotate image N° clockwise
--verbose                  Show verbose output

% # Example: change a cyan-background bitmap sprite into transparent png & pad it to 96x96
% java -jar ImageUtil.jar bossa1.bmp bossa1.png --recolor "#ff002f2f" "#00000000" --pad c 96 96