Solved

Image::Magick

Posted on 2000-02-25
15
248 Views
Last Modified: 2010-03-05
Hi,

 This has reference to a locked question dt.2/22 "Resize images" by mmcw.
 An example of Image::Magick script was given by guadalupe :

  use Image::Magick;
  $p = new Image::Magick;
  $p->Read("imagefile");
  $p->Set(size=>'70x70');  
  $p->Write("filename");

I had tried using Image::Magick, but my error log showed this warning:

" Warning 320: no delegate for this image format () [No such file or directory]"

What does that mean?

0
Comment
Question by:leoleo
  • 6
  • 5
  • 2
  • +2
15 Comments
 
LVL 3

Expert Comment

by:guadalupe
Comment Utility
Did you change the line:


  $p->Read("imagefile");

To provide a real image file...
Like this for example:


  $p->Read("/home/user/image.gif");
0
 

Author Comment

by:leoleo
Comment Utility

Yes, I did.

And in the documentation for Image Magick I found something abt Delegates which I didn't follow clearly.
0
 
LVL 3

Expert Comment

by:guadalupe
Comment Utility
What image format are you trying to edit...?
0
 

Author Comment

by:leoleo
Comment Utility

GIF & JPG.
0
 
LVL 3

Expert Comment

by:guadalupe
Comment Utility
Ok I belive the problem is that you may not have Image Magic correctly installed...  I had mentioned in my other answer that we might be able to get away with not intalling but I had forgottem about Image Magic...  Do you have it installed...  You can get it here

http://www.wizards.dupont.com/cristy/ImageMagick.html
0
 

Author Comment

by:leoleo
Comment Utility

Yes, it is installed, and from the same site.

Otherwise it won't let me use
"use Image::Magick;" will it?

The problem comes at the Read () statement or the statement

$p = Image::Magick->new;
0
 
LVL 3

Expert Comment

by:guadalupe
Comment Utility
No, I think we have a confusuion of terms.  While the statement is

use Image::Magick

The actual package's name is Perl::Magick... This is to distinguish it from its C counterpart  Image Magick.  The thing is that the perl Mod is actually nothing more than an interface to this c library.  If you do have this c library installed then I am a bit confussed... Let me knopw and well try to work it out...  
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 

Author Comment

by:leoleo
Comment Utility

I think Perl Magick is installed, but I am not sure now. How do I check that?
0
 
LVL 3

Expert Comment

by:guadalupe
Comment Utility
To check if Perl Magick is installed try running from the command line a perl program which says

use Image::Magick;

It will tell you if the module exists in the include dirs after that we kinda have to assume that it has been correctly installed.

However the problem is you also have to see if Image Magick, the C library, is installed...  the easiest is to go to the url below and download the package which applies to you and thn install it...

http://www.wizards.dupont.com/cristy/ImageMagick.html

Lety me know how it goes...?
0
 

Author Comment

by:leoleo
Comment Utility

Yes, both are installed.
0
 

Accepted Solution

by:
davecee earned 50 total points
Comment Utility
Hi Leo,

 The problem "No delegate is installed for this file format" when trying to load a GIF file means that when ImageMagick was configured and compiled you did not specify the configure flag "enable-lzw" that enables GIF support.

 You need to reinstall ImageMagick with the "-enable-lzw" flag. You also need to use the "-enabled-shared" flag if you want to keep using the standard Perl executable, otherwise it builds a new "perlmagick" executable.

 So, it's:

 configure -enable-lzw -enable-shared

 and then

 make
 make install

0
 
LVL 1

Expert Comment

by:lambda
Comment Utility
Thanks! I'll sure try that.
And let you know.
0
 
LVL 1

Expert Comment

by:lambda
Comment Utility
sorry, got posted in the wrong window!!!
0
 

Author Comment

by:leoleo
Comment Utility
I was away, and didn't see ur proposed answer till now. And the other day EE site seemed to be having some problems... Anyway I had stopped working on Image Magick, so I can't tell you whether the proposed soln  works or not. (This is an ancient question, as you can see.)

Well, I will award points to davecee, and post another question for guadalupe with the same points.

I may work on Image Magick soon, then I will try as you suggested and if there are any more problems, I will get back to you. I'd appreciate it very much if both of you would keep ur email notification for this question on.

Thanks a lot.
0
 
LVL 3

Expert Comment

by:darinw
Comment Utility
Reviewing question.

darinw
Customer Service
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

I've just discovered very important differences between Windows an Unix formats in Perl,at least 5.xx.. MOST IMPORTANT: Use Unix file format while saving Your script. otherwise it will have ^M s or smth likely weird in the EOL, Then DO NOT use m…
On Microsoft Windows, if  when you click or type the name of a .pl file, you get an error "is not recognized as an internal or external command, operable program or batch file", then this means you do not have the .pl file extension associated with …
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now