Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

file 18 lines (13 sloc) 0.427 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
#!/usr/bin/perl
use strict;
use warnings;

use Image::Magick;

my ( $image, $x );

$image = Image::Magick->new;

$image->Read('o1.png','o2.png',"o3.png","o4.png","o5.png","o6.png",'o7.png','o8.png','o9.png');
$image->Quantize(colorspace => 'gray');
$image->Threshold(threshold => '70%', channel => 'All');

for (my $i = 0; $image->[$i]; $i++) {
        my $x = $image->[$i]->Write("g".($i+1).".png");
        warn $x if $x;
}
Something went wrong with that request. Please try again.