2.3. Bilder mit Transparenz exportieren

There are two different approaches used by graphic file formats for supporting transparent image areas: simple binary transparency and alpha transparency. Simple binary transparency is supported in the GIF format; one color from the indexed color palette is marked as the transparent color. Alpha transparency is supported in the PNG format; the transparency information is stored in a separate channel, the Alpha channel.

[Anmerkung] Anmerkung

Das GIF-Format wird nur selten verwendet, da PNG alle Features von GIF unterstützt und dazu zusätzliche Features wie z.B. Alpha-Transparenz. Allerdings wird GIF noch für Animationen genutzt.

Prozedur 6.1. Ein Bild mit transparenten Bereichen erstellen (Alpha-Transparenz)

  1. Wir benutzen das gleiche Bild wie in den vergangenen Tutorials: Wilber, das GIMP-Maskottchen.

    Abbildung 6.4. Das Bild mit Wilber im RGBA-Modus geöffnet

    Das Bild mit Wilber im RGBA-Modus geöffnet

  2. To export an image with alpha transparency, you must have an alpha channel. To check if the image has an alpha channel, go to the Channels Dialog and verify that an entry for Alpha exists, besides Red, Green and Blue. If this is not the case, add a new alpha channel from the layers menu; Layer+TransparencyAdd Alpha Channel.

  3. Die ursprüngliche XCF-Datei enthält Hintergrundebenen, die Sie entfernen können. GIMP enthält einige Standardfilter, die das Erstellen von Farbverläufen unterstützen (sehen Sie unter Filter+Licht und Schatten nach). Ihrer Phantasie sind dabei keine Grenzen gesetzt. Die Möglichkeiten von Alpha-Transparenz demonstriert hier ein leichtes Hintergrundglühen um Wilber herum.

  4. After you're done with your image, you can export it in PNG format.

Abbildung 6.5. Darstellung der Transparenz

Darstellung der Transparenz

Die kleinen grauen Kästchen in der Hintergrundebene stellen die transparente Region des exportierten Bildes dar, während Sie das Bild mit GIMP bearbeiten.