ImageProcessor is a CLI program for applying various filters to images (currently only BMP is available).
You should run the program with the following arguments:
./image_processor {input_path.bmp} {output_path.bmp} [-{filter name 1} [params ...]] [-{filter name 2} [params ...]] ...
When run without arguments or with --help argument, the program displays help.
./image_processor input.bmp /tmp/output.bmp -crop 800 600 -gs -blur 0.5
In this example
- Image is loaded from file
input.bmp - Image is cropped to the size of 800x600 starting from the point of upper left corner
- Converted to shades of gray
- Gaussian blur with
sigma = 0.5applied - The resulting image is saved to the file
/tmp/output.bmp
Filters are applied in the order they are listed in the command line arguments.
-crop [int:width] [int:height]crops the image leavingwidthxheightimage counting from upper left corner-gsmakes the image grayscale-sharpslightly increases image sharpness-edge [float:threshold](0 < threshold < 1) highlights image edges-blur [float:sigma]applies Gaussian blur to the image-median [int:size]applies Median blur to the image (sets each pixel to the median of nearestsizexsizepixels)