Or, it might be a result of the PerlMagick implementation, but after I finally, recognized the error-checking I'd seen in examples:
Code: Select all
$x=$image->Crop(someparameters);
warn "$x" if "$x";
$image->[$x]->Frame("100x200");
and added the same to my code, I started seeing the warning messages that in some cases, the single-quote/apostrophe/' character had been causing method calls to fail silently when used for the "geometry=>" string.
For example, in my case,
Code: Select all
#$err=$croppingrow->Crop(geometry=>'${xwidsrc}x1+0+0'); # FAILS and no crop is performed
$err=$croppingrow->Crop(geometry=>"${xwidsrc}x1+0+0"); # SUCCEEDS
warn "$err" if "$err";
However, taking a look at the Manipulate An Image section in the same place, it would take a sharp eye to notice that single and double quotes are used in different contexts (and in any event my latest experience is that the single-quoted geometry string is actually wrong on my system.
![Sad :(](./images/smilies/icon_sad.gif)
Code: Select all
$image->Crop(geometry=>'100x100+10+20');
$image->[$x]->Frame("100x200");