Getting image informations
Gerhard Häring
gerhard at bigfoot.de
Mon May 20 16:48:02 EDT 2002
* Sebastian Roth <xsebbi at gmx.de> [2002-05-20 22:35 +0200]:
> Hi all,
>
> I'm currently looking for an function that give informations about an
> image/pictire -file like test.png oder test.gif. I need especially two
> informations:
> width and heigth .
>
> Midnight Commander can tell me this things, but how could Python do
> that? Is there an special module for such things?
The Python Imaging Library (PIL) http://www.pythonware.com/products/pil/
If you use Linux or *BSD, it's usually even available as a
RPM/dpkg/package/... on your distribution's CDs or in the ports
collection. But installing from source is no problem, either.
Gerhard
--
mail: gerhard <at> bigfoot <dot> de registered Linux user #64239
web: http://www.cs.fhm.edu/~ifw00065/ OpenPGP public key id AD24C930
public key fingerprint: 3FCC 8700 3012 0A9E B0C9 3667 814B 9CAA AD24 C930
reduce(lambda x,y:x+y,map(lambda x:chr(ord(x)^42),tuple('zS^BED\nX_FOY\x0b')))
More information about the Python-list
mailing list