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

NAME

6       glDrawBuffer - specify which color buffers are to be drawn into
7

C SPECIFICATION

9       void glDrawBuffer(GLenum mode);
10

PARAMETERS

12       mode
13           Specifies up to four color buffers to be drawn into. Symbolic
14           constants GL_NONE, GL_FRONT_LEFT, GL_FRONT_RIGHT, GL_BACK_LEFT,
15           GL_BACK_RIGHT, GL_FRONT, GL_BACK, GL_LEFT, GL_RIGHT, and
16           GL_FRONT_AND_BACK are accepted. The initial value is GL_FRONT for
17           single-buffered contexts, and GL_BACK for double-buffered contexts.
18

DESCRIPTION

20       When colors are written to the frame buffer, they are written into the
21       color buffers specified by glDrawBuffer. The specifications are as
22       follows:
23
24       GL_NONE
25           No color buffers are written.
26
27       GL_FRONT_LEFT
28           Only the front left color buffer is written.
29
30       GL_FRONT_RIGHT
31           Only the front right color buffer is written.
32
33       GL_BACK_LEFT
34           Only the back left color buffer is written.
35
36       GL_BACK_RIGHT
37           Only the back right color buffer is written.
38
39       GL_FRONT
40           Only the front left and front right color buffers are written. If
41           there is no front right color buffer, only the front left color
42           buffer is written.
43
44       GL_BACK
45           Only the back left and back right color buffers are written. If
46           there is no back right color buffer, only the back left color
47           buffer is written.
48
49       GL_LEFT
50           Only the front left and back left color buffers are written. If
51           there is no back left color buffer, only the front left color
52           buffer is written.
53
54       GL_RIGHT
55           Only the front right and back right color buffers are written. If
56           there is no back right color buffer, only the front right color
57           buffer is written.
58
59       GL_FRONT_AND_BACK
60           All the front and back color buffers (front left, front right, back
61           left, back right) are written. If there are no back color buffers,
62           only the front left and front right color buffers are written. If
63           there are no right color buffers, only the front left and back left
64           color buffers are written. If there are no right or back color
65           buffers, only the front left color buffer is written.
66
67       If more than one color buffer is selected for drawing, then blending or
68       logical operations are computed and applied independently for each
69       color buffer and can produce different results in each buffer.
70
71       Monoscopic contexts include only left buffers, and stereoscopic
72       contexts include both left and right buffers. Likewise, single-buffered
73       contexts include only front buffers, and double-buffered contexts
74       include both front and back buffers. The context is selected at GL
75       initialization.
76

ERRORS

78       GL_INVALID_ENUM is generated if mode is not an accepted value.
79
80       GL_INVALID_OPERATION is generated if none of the buffers indicated by
81       mode exists.
82

ASSOCIATED GETS

84       glGet() with argument GL_DRAW_BUFFER
85

SEE ALSO

87       glBlendFunc(), glColorMask(), glDrawBuffers(), glLogicOp(),
88       glReadBuffer()
89
91       Copyright © 1991-2006 Silicon Graphics, Inc. This document is licensed
92       under the SGI Free Software B License. For details, see
93       http://oss.sgi.com/projects/FreeB/.
94

AUTHORS

96       opengl.org
97
98
99
100opengl.org                        06/10/2014                  GLDRAWBUFFER(3G)
Impressum