jeffpflueger has asked for the wisdom of the Perl Monks concerning the following question:

Image::Magick/ PerlMagick on Windows 2000!

I feel close to getting this to work....and writing scripts to rip through my extensive image files and autocrop and resize them. Active State Perl and ImageMagick seem to be running fine, but PerlMagick seems to be generating errors:
#!c:/perl -w use strict; use Image::Magick; my $image = new Image::Magick; my $x = $image->Read("nettie.tif"); warn "$x" if "$x"; $x = $image->Scale(width=>"200", height=>"200"); warn "$x" if "$x"; $x = $image->Write("nettienew.tif"); warn "$x" if "$x";


Generates these errors:
Exception 420: NoDecodeDelegateForThisImageFormat (nettie.tif) at c:/image.pl line 8. Anybody have a suggestion about what might be happening and how to proceed? Thanks!

Replies are listed 'Best First'.
Re: PerlMagick,ImageMagick on Windows 2000 with Active State Perl
by zengargoyle (Deacon) on Nov 29, 2003 at 01:10 UTC

    it sounds like ImageMagick wasn't built with TIFF support. did you compile it yourself or did it come from a binary package?

    did you install the whole ImageMagick package with it's programs or just the libraries so you could use the perl module? if you have the programs check them.

    $ identify housing.tif housing.tif TIFF 900x1300+0+0 PseudoClass 256c 8-bit 2.2m 0.090u 0:01 $ convert housing.tif housing.gif $ identify housing.gif housing.gif GIF 900x1300+0+0 PseudoClass 256c 8-bit 486.9k 0.140u 0:01

    if those don't work it's likely that your ImageMagick is missing TIFF and you need to find or build ImageMagick (and likely a libtiff) to get TIFF support.

      ImageMagick seems to be running with all the required imgae libraries just fine....
      $convert nettie.tif nettie.gif
      Works fine from the command line....The error I get is when I am using Perl and the Image::Magick module....my feeling is that this has to do with PerlMagick....the way Perl is communicating with ImageMagick....Any ideas?

      BTY ActiveState claims to provide an option to install Image::Magick at the installation of Perl if ImageMagic is already installed....I haven't seen this occur....not sure why not....
Re: PerlMagick,ImageMagick on Windows 2000 with Active State Perl
by simonm (Vicar) on Nov 29, 2003 at 00:36 UTC
      Problem Solved! Image::Magick now running on windows 2000! the problem seems to be synching the different builds of ActiveState Perl, ImageMagick and the PerlMagick module. I had to find an appropriate build of ActiveState Perl, and make sure that the Image::Magic module was the one that the version of ImageMagick I was installing matched. The best way to do the later was to use the version of ImageMagick that downloads the perl module stuff it requires at installation. Here's is how I finally got something to work:

      1) Install Active State Perl 5.8.0 build 806 available HERE
      builds 804 and 807 did not work.

      2) Install the nifty ImageMagick installer-type set-up that provides the Install Perl Magick module option. (ImageMagick-i686-pc-windows.exe)
      Available HERE

      Make sure that
      a) you check the box to install the perl magick stuff
      b) you have your machine connected to the internet. The installer will then install ImageMagick and a command prompt window will then pop-up as the Perl Magick stuff is downloaded from the internet.

      You should then be ready to go.

      Thank you for all of your help!