Page 1 of 1

PerlMagick syntax Composite

Posted: 2018-02-28T08:26:45-07:00
by zemlik
sorry put this on other board in error

I don't do this very often.
have an array of images and pixel coordinates.
would like to combine over another image at those coordinates.
not understanding the syntax
something like

Code: Select all

while ($y <=  $#frames){
#say $frames[$y][0]; # the backgound
#say $frames[$y][1]; # the x pixel coordinate
#say $frames[$y][2]; # the y pixel coordinate
$base->Composite(image =>$over, qw(compose ScrAtop geometry $xpix $ypix));

Re: PerlMagick syntax Composite

Posted: 2018-02-28T09:49:06-07:00
by zemlik
I dunno if something is messed up.

use Image::Magick;

$base->Composite(image=>$over,compose=>'over',geometry=>'+$xpix +$ypix');
there is error
"Uncaught exception from user code:
Can't locate object method "Composite" via package"

Debian testing (buster)
I had installed perlmagick with apt and if I try to install
"cpanm Image::Magick"
it fails to make.

are PerlMagick and Image::Magick different things ?

"cpanm Image::Magick"
fails because
"fatal error: magick/magick-baseconfig.h: No such file or directory"
it is not in /usr/include/ImageMagick-6/magick

apt-get install libimage-magick-perl
apt-get install perlmagick
apt-get install libmagickcore-dev
apt-get install imagemagick-6-common
apt-get install libmagickcore-6-headers
apt-get install libperl-dev

and still no luck

Is error my system or syntax ?

Re: PerlMagick syntax Composite

Posted: 2018-03-03T12:44:55-07:00
by zemlik
well I thought somebody might take pity. Is sorted now, I had my quotation marks in a twist.

Code: Select all

doesn't seem to matter that cpanm version fails to install.