This works for me at the command line...

use strict;
use CGI;
use CGI::Carp qw/fatalsToBrowser/;
use Image::Magick;
my $q = Image::Magick->new;
$q->Set(size=>'30x105');
$q->Read('gradient:#00f685-#0083f8');
$q->Rotate(-90);
$q->Raise('6x6');
$q->Annotate(text=>'Push
Me',font=>'@/Fonts/LucidaBrightItalic.ttf',fill=>'black',
gravity=>'Center',pointsize=>18);
$q->Write('button.gif');
$q->Write('win:');

You really need to check the web server logs to see what error is being
thrown.  I'm assuming that there is more to your script that you gave us,
and since this seems to work fine, I would think the error is being caused
by something else.  Perhaps the user that the web server runs under doesn't
have write access to the drive?  Or maybe you aren't printing a Content-type
header?

Rob

-----Original Message-----
From: Paul Johnson [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 28, 2001 3:10 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: Question for those familiar with imagemagick for perl


On Fri, Dec 28, 2001 at 01:59:38PM -0500, [EMAIL PROTECTED] wrote:
> Hello, I asked this question to their list, but nobody had an answer, and
the 
> help isn't reliable, so I hope I can ask. It is about a perl script, which

> comes with it. button.pl
> 
> It gives a software error:
> Software error:
> Execution of /home/sites/site30/web/button.pl aborted due to compilation 
> errors. 
> 
> #!/usr/bin/perl -w
> #
> # Make simple beveled button.
> #
> use strict;
> 
> use CGI;
> use CGI::Carp qw/fatalsToBrowser/;
> use Image::Magick;
> $q=Image::Magick->new;

my $q = Image::Magick->new;

> $q->Set(size=>'30x105');
> $q->Read('gradient:#00f685-#0083f8');
> $q->Rotate(-90);
> $q->Raise('6x6');
> $q->Annotate(text=>'Push Me',font=>'@/Fonts/LucidaBrightItalic.ttf',fill=>
> 'black', gravity=>'Center',pointsize=>18);
> $q->Write('button.gif');
> $q->Write('win:');

That may not be the whole story, but it's not helping matters at all.

-- 
Paul Johnson - [EMAIL PROTECTED]
http://www.pjcj.net

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to