develooper Front page | perl.beginners | Postings from July 2003

Re: processing image with perl???

Thread Previous
From:
zentara
Date:
July 1, 2003 10:06
Subject:
Re: processing image with perl???
Message ID:
3of3gv4k1bnopqbj3id7v84m3151su4aao@4ax.com
On Mon, 30 Jun 2003 22:46:10 -0700 (PDT), lingfengz@yahoo.com (Ling F.
Zhang) wrote:

>This might not exactly be a perl problem...because the
>solution might involve other things...
>
>I have an album I would like to put on line, so I am
>writting cgi script in perl to do it (because I can
>conveniently use the HTML::template module) but I need
>a way of determining the resolution of the image...how
>do I do that? is there module that would work?


use Image::Size;

# get the image size, and print it out
my ($width, $height) = imgsize("image.jpg");
print "The image is $width by $height";




Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About