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

NAME

6       glLineStipple - specify the line stipple pattern
7

C SPECIFICATION

9       void glLineStipple(GLint factor, GLushort pattern);
10

PARAMETERS

12       factor
13           Specifies a multiplier for each bit in the line stipple pattern. If
14           factor is 3, for example, each bit in the pattern is used three
15           times before the next bit in the pattern is used.  factor is
16           clamped to the range [1, 256] and defaults to 1.
17
18       pattern
19           Specifies a 16-bit integer whose bit pattern determines which
20           fragments of a line will be drawn when the line is rasterized. Bit
21           zero is used first; the default pattern is all 1's.
22

DESCRIPTION

24       Line stippling masks out certain fragments produced by rasterization;
25       those fragments will not be drawn. The masking is achieved by using
26       three parameters: the 16-bit line stipple pattern pattern, the repeat
27       count factor, and an integer stipple counter s.
28
29       Counter s is reset to 0 whenever glBegin() is called and before each
30       line segment of a glBegin()(GL_LINES)/glEnd() sequence is generated. It
31       is incremented after each fragment of a unit width aliased line segment
32       is generated or after each i fragments of an i width line segment are
33       generated. The i fragments associated with count s are masked out if
34
35       pattern bit s factor % 16
36
37       is 0, otherwise these fragments are sent to the frame buffer. Bit zero
38       of pattern is the least significant bit.
39
40       Antialiased lines are treated as a sequence of 1 × width rectangles for
41       purposes of stippling. Whether rectangle s is rasterized or not depends
42       on the fragment rule described for aliased lines, counting rectangles
43       rather than groups of fragments.
44
45       To enable and disable line stippling, call glEnable() and glDisable()
46       with argument GL_LINE_STIPPLE. When enabled, the line stipple pattern
47       is applied as described above. When disabled, it is as if the pattern
48       were all 1's. Initially, line stippling is disabled.
49

ERRORS

51       GL_INVALID_OPERATION is generated if glLineStipple is executed between
52       the execution of glBegin() and the corresponding execution of glEnd().
53

ASSOCIATED GETS

55       glGet() with argument GL_LINE_STIPPLE_PATTERN
56
57       glGet() with argument GL_LINE_STIPPLE_REPEAT
58
59       glIsEnabled() with argument GL_LINE_STIPPLE
60

SEE ALSO

62       glLineWidth(), glPolygonStipple()
63
65       Copyright © 1991-2006 Silicon Graphics, Inc. This document is licensed
66       under the SGI Free Software B License. For details, see
67       http://oss.sgi.com/projects/FreeB/.
68

AUTHORS

70       opengl.org
71
72
73
74opengl.org                        07/13/2018                 GLLINESTIPPLE(3G)
Impressum