On 3 Nov 2005 at 15:29, Mike Blezien wrote:
> Hello,
>
> I'm using ImageMagick to create thumbnails and other image manipulation with
> a
> upload script. And was wondering if the actual pixel size can be checked with
> ImageMagick ?? I've used Image::Size to do this, but was wondering it can be
> done using ImageMagick without having to install a separate module for this.
>
> A simple example would be appreciated if you know how this is done.
>From perlmagick docs:
($width, $height, $size, $format) = $image->Ping('logo.png');
This is the quickest method as it reads the information from the file
header rather than opening/reading the entire file. This doesn't tell
you how many pixel per inch there are. You need to use the depth
method for that.
You should check out
http://www.cit.gu.edu.au/~anthony/graphics/imagick6/.
It is an excellent source of information on IM including a section on
creating thumbnails.
HTH.
Dp
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>