glPolygonStipple

Aus DGL Wiki
Version vom 11. September 2004, 22:28 Uhr von Phobeus (Diskussion | Beiträge) (Beginn mit Eintragung, Struktur fertig, Beschreibung fehlt)

(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Wechseln zu: Navigation, Suche

Vorlage:unvollständig

glPolygonStipple


Name

glPolygonStipple - Setzt das Muster mit dem die Polygone getüpfelt werden


Delphi-Spezifikation

procedure glPolygonStipple(const mask : PGLubyte;)


Parameter

mask Spezifiziert einen Zeiger auf einem 32x32 Tüpfel-Muster, dass im Speicher genauso abgelegt wird wie bei glDrawPixels.


Beschreibung

Das tüpfeln von Polygonen, sowie bei Linien (siehe glLineStipple), deckte bestimmte Fragmente bei der Rasterung ab und erzeugt somit ein Muster. Das Tüpfeln ist hierbei abhängig vom Antialiasing des Polygons.

mask is a pointer to a 32x32 stipple pattern that is stored in memory just like the pixel data supplied to a glDrawPixels call with height and width both equal to 32, a pixel format of GL_COLOR_INDEX, and data type of GL_BITMAP. That is, the stipple pattern is represented as a 32x32 array of 1-bit color indices packed in unsigned bytes. glPixelStore parameters like GL_UNPACK_SWAP_BYTES and GL_UNPACK_LSB_FIRST affect the assembling of the bits into a stipple pattern. Pixel transfer operations (shift, offset, pixel map) are not applied to the stipple image, however.

Um das Tüpfeln von Polygonen zu aktivieren oder zu deaktivieren, rufe glEnable und glDisable mit dem Argument GL_POLYGON_STIPPLE auf. Das Tüpfeln von Polygonen ist beim Start deaktiviert. If it is enabled, a rasterized polygon fragment with window coordinates xw and yw is sent to the next stage of the GL if and only if the (xw mod 32)th bit in the (yw mod 32)th row of the stipple pattern is 1 (one). When polygon stippling is disabled, it is as if the stipple pattern consists of all 1's.


Fehlermeldungen

GL_INVALID_OPERATION wird generiert wenn glRect innerhalb eines glBegin-glEnd Blocks aufgerufen wird.


Zugehörige Wertrückgaben

glGetPolygonStipple
glIsEnabled mit dem Token with argument GL_POLYGON_STIPPLE

Siehe auch

glDrawPixels, glLineStipple, glPixelStore, glPixelTransfer