Image::Filter - Apply filters onto images.
use Image::Filter; $image = Image::Filter::newFromJpeg("munich.jpg"); $image = $image->filter("blur"); $image->Jpeg("blurtest.jpg",$quality); #1-100, use negative value for default $image->Destroy;
Image::Filter is a perl module that can apply image filters. A limited number of filters are included (see list below). Image::Filter currently does true color images images. It uses the gd2 lib from Thomas Boutell.
None by default.
Basic, none to fancy, blur routine (truecolor)
Extract Red, Green or Blue channels from an image (truecolor)
Basic, none to fancy, Black and White edge routine
Basic, none to fancy, Black and White emboss routine
Erase every Nth line, with a specific color, thickness, either horizontally or vertically (truecolor)
Dither an image using basic a Floyd-Steinberg Dither algorithm.
Basic, none to fancy, foo routine. Example filter
Oh yeah, this is a dummy filter :)
Gaussian Blur (truecolor)
Basic, weighted average greyscale routine
Basic, none to fancy, invert routine (truecolor)
Basic, none to fancy, level routine. Add a certain value to every RGB value (truecolor)
Oilify algorithm. Quite processor intensive. (truecolor
Basic, none to fancy, pixelize routine (truecolor)
Basic, none to fancy, Black and White posterize routine (truecolor)
Add ripples (truecolor)
Basic, none to fancy, Counter Clockwise Rotation routine (truecolor)
Basic, none to fancy, sharpen routine (truecolor)
Solarize an image (truecolor)
Funny rotation routine (truecolor)
Load data from a JPEG file. Returns an Image::Filter instance
Load data from a PNG file. Returns an Image::Filter instance
Load data from a gd file. Returns an Image::Filter instance
Load data from a gd2 file. Returns an Image::Filter instance
Apply a filter to an Image::Filter instance. Image preferably passed as Instance variable
$image->filter($filter);
Dump image data to JPEG file. Existing file will be overwritten (if possible). Quality is optional. Possible values range from 0 to 100 (Higher value is higher quality). Use negative value for default quality.
Dump image data to PNG file. Existing file will be overwritten (if possible).
Dump image data to gd file. Existing file will be overwritten (if possible).
Dump image data to gd2 file. Existing file will be overwritten (if possible).
Destroy the instance of Image::Filter. (RECOMMENDED USE)
Obviously, I'm no expert in math or C. If you feel like writing some filter code or have a nice algorithm you want to see implemented, give me a shout.
Hendrik Van Belleghem, <beatnik + at + quickndirty + dot + org>
Image::Filter is released under the GNU Public License. See COPYING and COPYRIGHT for more information.
Image::Filter is based on the concepts tought to me by my math professor J. Van Hee. This module wouldn't be possible without the work of Thomas Boutell on his gd library. Inspiration, but no code, was taken from Lincoln D. Steins GD implementation of that same gd lib.
perl.
To install Image::Filter, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Image::Filter
CPAN shell
perl -MCPAN -e shell install Image::Filter
For more information on module installation, please visit the detailed CPAN module installation guide.