[Python-de] PIL und Tiff's
René Liebscher
R.Liebscher at gmx.de
Mon Okt 27 09:07:21 CET 2003
Hallo,
also wenn ich das in der Doku richtig lese
http://www.pythonware.com/library/pil/handbook/image-file-formats.htm
unterstützt PIL sowieso kein Alpha-Kanal bei TIFF.
Bei PNG steht zumindest RGBA da, wie wär es damit statt TIFF?
MfG
Rene
----- Original Message -----
From: "Hans Gubitz" <gubitz at netcologne.de>
To: <python-de at python.net>
Sent: Friday, October 24, 2003 3:54 PM
Subject: [Python-de] PIL und Tiff's
> Hallo,
>
> ich möchte aus einem Bitmap den Hintergrund entfernen und ihn später
> per Python-Script in definierten Farben setzen können.
>
> Dazu habe ich mit Gimp in diesem Bild einen Alpha-Kanal gesetzt.
> damit Teile des Bildes transparent gemacht und es im Format TIF ohne
> Kompression gespeichert.
>
> Leider war das aber schon das Ende der ganzen Aktion, da das Modul
> Image den Typ dieses Bildes nicht mehr erkennen kann.
>
> >>> alpha=Image.open('alpha.tif')
> Traceback (most recent call last):
> File "<stdin>", line 1, in ?
> File "/usr/lib/python2.3/site-packages/PIL/Image.py", line 1571, in open
> raise IOError("cannot identify image file")
> IOError: cannot identify image file
> >>>
>
>
> Was nun?
>
> Gruß
> Hans Gubitz
> --
> Hans Gubitz <gubitz at netcologne.de>
>
>
> _______________________________________________
> Python-de maillist - Python-de at python.net
> http://python.net/mailman/listinfo/python-de
>
>