NAME
glDrawBuffer
- specify which color buffers are to be drawn into
C SPECIFICATION
void ggllDDrraawwBBuuffffeerr(
GLenum _m_o_d_e )
delim $$
PARAMETERS
-
_m_o_d_e
-
Specifies up to four color buffers to be drawn into.
Symbolic constants
GGLL__NNOONNEE,
GGLL__FFRROONNTT__LLEEFFTT,
GGLL__FFRROONNTT__RRIIGGHHTT,
GGLL__BBAACCKK__LLEEFFTT,
GGLL__BBAACCKK__RRIIGGHHTT,
GGLL__FFRROONNTT,
GGLL__BBAACCKK,
GGLL__LLEEFFTT,
GGLL__RRIIGGHHTT,
GGLL__FFRROONNTT__AANNDD__BBAACCKK, and
GGLL__AAUUXX_i,
where _i is between 0 and
``GGLL__AAUUXX__BBUUFFFFEERRSS'' -1,
are accepted (GGLL__AAUUXX__BBUUFFFFEERRSS is not the upper limit; use ggllGGeett
to query the number of available aux buffers.)
The initial value is GGLL__FFRROONNTT for single-buffered contexts,
and GGLL__BBAACCKK for double-buffered contexts.
DESCRIPTION
When colors are written to the frame buffer,
they are written into the color buffers specified by ggllDDrraawwBBuuffffeerr.
The specifications are as follows:
-
GGLL__NNOONNEE
-
No color buffers are written.
-
GGLL__FFRROONNTT__LLEEFFTT
-
Only the front left color buffer is written.
-
GGLL__FFRROONNTT__RRIIGGHHTT
-
Only the front right color buffer is written.
-
GGLL__BBAACCKK__LLEEFFTT
-
Only the back left color buffer is written.
-
GGLL__BBAACCKK__RRIIGGHHTT
-
Only the back right color buffer is written.
-
GGLL__FFRROONNTT
-
Only the front left and front right color buffers are written.
If there is no front right color buffer,
only the front left color buffer is written.
-
GGLL__BBAACCKK
-
Only the back left and back right color buffers are written.
If there is no back right color buffer,
only the back left color buffer is written.
-
GGLL__LLEEFFTT
-
Only the front left and back left color buffers are written.
If there is no back left color buffer,
only the front left color buffer is written.
-
GGLL__RRIIGGHHTT
-
Only the front right and back right color buffers are written.
If there is no back right color buffer,
only the front right color buffer is written.
-
GGLL__FFRROONNTT__AANNDD__BBAACCKK
-
All the front and back color buffers
(front left, front right, back left, back right)
are written.
If there are no back color buffers,
only the front left and front right color buffers are written.
If there are no right color buffers,
only the front left and back left color buffers are written.
If there are no right or back color buffers,
only the front left color buffer is written.
-
GGLL__AAUUXX_i
-
Only auxiliary color buffer _i is written.
If more than one color buffer is selected for drawing,
then blending or logical operations are computed and applied independently
for each color buffer and can produce different results in each buffer.
Monoscopic contexts include only
left
buffers, and stereoscopic contexts include both
left
and
right
buffers.
Likewise, single-buffered contexts include only
front
buffers, and double-buffered contexts include both
front
and
back
buffers.
The context is selected at GL initialization.
NOTES
It is always the case that GGLL__AAUUXX$i$ = GGLL__AAUUXX00 + $i$.
ERRORS
GGLL__IINNVVAALLIIDD__EENNUUMM is generated if _m_o_d_e is not an accepted value.
GGLL__IINNVVAALLIIDD__OOPPEERRAATTIIOONN is generated if none of the buffers indicated
by _m_o_d_e exists.
GGLL__IINNVVAALLIIDD__OOPPEERRAATTIIOONN is generated if ggllDDrraawwBBuuffffeerr
is executed between the execution of ggllBBeeggiinn
and the corresponding execution of ggllEEnndd.
ASSOCIATED GETS
ggllGGeett with argument GGLL__DDRRAAWW__BBUUFFFFEERR
ggllGGeett with argument GGLL__AAUUXX__BBUUFFFFEERRSS
SEE ALSO
ggllBBlleennddFFuunncc((33GG)),
ggllCCoolloorrMMaasskk((33GG)),
ggllIInnddeexxMMaasskk((33GG)),
ggllLLooggiiccOOpp((33GG)),
ggllRReeaaddBBuuffffeerr((33GG))