Make cropping optional

This commit is contained in:
Peter J. Holzer 2016-04-21 17:25:57 +02:00
parent ba6b4c824e
commit 59902c1322
1 changed files with 4 additions and 3 deletions

View File

@ -450,9 +450,10 @@ sub plot {
if ($self->{gsresolution} != $self->{finalresolution}) { if ($self->{gsresolution} != $self->{finalresolution}) {
$pipe .= "pnmscale " . ($self->{finalresolution} / $self->{gsresolution}) . " |"; $pipe .= "pnmscale " . ($self->{finalresolution} / $self->{gsresolution}) . " |";
} }
$pipe .= $pipe .= "pnmflip -cw |";
"pnmflip -cw |" . if ($self->{crop}) {
"pnmcrop 2> /dev/null |"; $pipe .= "pnmcrop 2> /dev/null |";
}
} }
if ($self->{output_format} eq "png") { if ($self->{output_format} eq "png") {