in reply to Image::Magick resize question
If you die or warn when failing to open the image, you'll get much better diagnostics. The error message you have suggests that fh IMAGE is not being set to anything useful:
will holler as soon as it sees that your file doesn't open. The message will tell you, more or less, what is lacking. I suspect that either file permissions are wrong, or paths are relative to the wrong directory.open IMAGE, "< $picture" or die $!;
To live by: Always Check Status of System Interfaces After Use.
Update: On the error checking and operator precedence issue, you could replace '||' in your $image->Read() statement with &&, but that form is confusing to most people. merlyn's two statement form is more readable to programmers without a strong background. in C.
After Compline,
Zaxo
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Image::Magick resize question
by emilford (Friar) on Jun 08, 2002 at 13:15 UTC | |
by merlyn (Sage) on Jun 08, 2002 at 14:17 UTC | |
by mt2k (Hermit) on Jun 08, 2002 at 22:32 UTC | |
by Aristotle (Chancellor) on Jun 08, 2002 at 22:51 UTC | |
by emilford (Friar) on Jun 09, 2002 at 15:31 UTC | |
by Aristotle (Chancellor) on Jun 09, 2002 at 20:03 UTC |