use 5.014;
use warnings;
-our $VERSION = '1.00';
+our $VERSION = '1.01';
sub new {
my ($class, $target) = @_;
}
sub convert {
- my ($imgpath, $thumbpath, $cmds) = @_;
+ my ($imgpath, $thumbpath, $cmds, $xyres) = @_;
if (not -e $$imgpath) {
return !-e $thumbpath || unlink $thumbpath;
}
#my ($w, $h) = $imgpath->dimensions;
- my $xyres = 0 ? '600x400' : '300x200'; # cover
+ $xyres //= '300x200'; # cover
my $aspect = 3/2;
my @cmds = @{ $cmds // [] };
if (my ($cmdarg) = grep { $cmds[$_] eq '-area' } 0 .. $#cmds) {