The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Imager::Filter::Statistic - Provide statistica-based pixel filters.

VERSION

version 0.001

SYNOPSIS

    use Imager;
    use Imager::Filter::Statistic;

    my $img = Imager->new(file => $file) or die Imager->errstr;
    $img->filter(
        type => "statistic",
        method => "gradient",
        geometry => "3x3"
    );
    $img->write(file => "filtered-by-gradient.png");

DESCRIPTION

This module provide a "statistic" type of image filter to work with Imager. The filter does a sliding window scan. For each pixel in the image, the pixel value is replaced by the summerizing its surroundings with a statistic method. The parameter "geometry" means the size of sliding window, with format ${width}x${height}. The parameter "method" means the summerizing method. Here's the full list of them:

gradient (max - min)
variance
mean
min
max
mode

AUTHOR

Kang-min Liu <gugod@gugod.org>

COPYRIGHT AND LICENSE

Kang-min Liu has dedicated the work to the Commons by waiving all of his or her rights to the work worldwide under copyright law and all related or neighboring legal rights he or she had in the work, to the extent allowable by law.

Works under CC0 do not require attribution. When citing the work, you should not imply endorsement by the author.