1GLPOLYGONSTIPPLE(3G)             OpenGL Manual            GLPOLYGONSTIPPLE(3G)
2
3
4

NAME

6       glPolygonStipple - set the polygon stippling pattern
7

C SPECIFICATION

9       void glPolygonStipple(const GLubyte * pattern);
10

PARAMETERS

12       pattern
13           Specifies a pointer to a 32 × 32 stipple pattern that will be
14           unpacked from memory in the same way that glDrawPixels() unpacks
15           pixels.
16

DESCRIPTION

18       Polygon stippling, like line stippling (see glLineStipple()), masks out
19       certain fragments produced by rasterization, creating a pattern.
20       Stippling is independent of polygon antialiasing.
21
22       pattern is a pointer to a 32 × 32 stipple pattern that is stored in
23       memory just like the pixel data supplied to a glDrawPixels() call with
24
25       height and width both equal to 32, a pixel format of GL_COLOR_INDEX,
26       and data type of GL_BITMAP. That is, the stipple pattern is represented
27       as a 32 × 32 array of 1-bit color indices packed in unsigned bytes.
28       glPixelStore() parameters like GL_UNPACK_SWAP_BYTES and
29       GL_UNPACK_LSB_FIRST affect the assembling of the bits into a stipple
30       pattern. Pixel transfer operations (shift, offset, pixel map) are not
31       applied to the stipple image, however.
32
33       If a non-zero named buffer object is bound to the
34       GL_PIXEL_UNPACK_BUFFER target (see glBindBuffer()) while a stipple
35       pattern is specified, pattern is treated as a byte offset into the
36       buffer object's data store.
37
38       To enable and disable polygon stippling, call glEnable() and
39       glDisable() with argument GL_POLYGON_STIPPLE. Polygon stippling is
40       initially disabled. If it's enabled, a rasterized polygon fragment with
41       window coordinates x w and y w is sent to the next stage of the GL if
42       and only if the (x w % 32)th bit in the (y w % 32)th row of the stipple
43       pattern is 1 (one). When polygon stippling is disabled, it is as if the
44       stipple pattern consists of all 1's.
45

ERRORS

47       GL_INVALID_OPERATION is generated if a non-zero buffer object name is
48       bound to the GL_PIXEL_UNPACK_BUFFER target and the buffer object's data
49       store is currently mapped.
50
51       GL_INVALID_OPERATION is generated if a non-zero buffer object name is
52       bound to the GL_PIXEL_UNPACK_BUFFER target and the data would be
53       unpacked from the buffer object such that the memory reads required
54       would exceed the data store size.
55
56       GL_INVALID_OPERATION is generated if glPolygonStipple is executed
57       between the execution of glBegin() and the corresponding execution of
58       glEnd().
59

ASSOCIATED GETS

61       glGetPolygonStipple()
62
63       glIsEnabled() with argument GL_POLYGON_STIPPLE
64
65       glGet() with argument GL_PIXEL_UNPACK_BUFFER_BINDING
66

SEE ALSO

68       glDrawPixels(), glLineStipple(), glPixelStore(), glPixelTransfer()
69
71       Copyright © 1991-2006 Silicon Graphics, Inc. This document is licensed
72       under the SGI Free Software B License. For details, see
73       http://oss.sgi.com/projects/FreeB/.
74

AUTHORS

76       opengl.org
77
78
79
80opengl.org                        07/13/2018              GLPOLYGONSTIPPLE(3G)
Impressum