Slide 19
Slide 19 text
script
script
#!/usr/bin/perl
use strict;
use warnings;
my $out="out_lighten.bmp";
my @list= glob('*.JPG');
my $N=$#list+1;
my $i=0;
foreach my $file (sort @list) {
$i++;
if ($i == 1) {
print "\n#$i/$N cp $file $out\n";
my @args = ( "convert", $file, $out );
system(@args) == 0
or die "system @args failed: $?";
} else {
print "#$i/$N composite -compose lighten $file $out $out\n";
my @args = ( "composite", "-compose", "lighten", $file, $out, $out );
system(@args) == 0
or die "system @args failed: $?";
}
}
19 / 27