File: glDrawBuffer.xml

package info (click to toggle)
khronos-opengl-man4 1.0~svn27841-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 24,888 kB
  • ctags: 377
  • sloc: xml: 188,408; makefile: 1,153; python: 736; sh: 49; php: 7; sed: 2
file content (98 lines) | stat: -rw-r--r-- 8,684 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "xhtml1-transitional.dtd">
<?xml-stylesheet type="text/xsl" href="mathml.xsl"?><html xmlns="http://www.w3.org/1999/xhtml" xmlns:pref="http://www.w3.org/2002/Math/preference" pref:renderer="mathplayer-dl"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><link rel="stylesheet" type="text/css" href="opengl-man.css" /><title>glDrawBuffer - OpenGL 4 Reference Pages</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1" /></head><body><div class="refentry"><a id="glDrawBuffer"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>glDrawBuffer — specify which color buffers are to be drawn into</p></div><div class="refsynopsisdiv"><h2>C Specification</h2><div class="funcsynopsis"><table border="0" class="funcprototype-table" summary="Function synopsis" style="cellspacing: 0; cellpadding: 0;"><tr><td><code class="funcdef">void <strong class="fsfunc">glDrawBuffer</strong>(</code></td><td>GLenum <var class="pdparam">mode</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer"> </div></div></div><div class="refsect1"><a id="parameters"></a><h2>Parameters</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>mode</code></em></span></dt><dd><p>
                    Specifies up to four color buffers to be drawn into.
                    Symbolic constants
                    <code class="constant">GL_NONE</code>,
                    <code class="constant">GL_FRONT_LEFT</code>,
                    <code class="constant">GL_FRONT_RIGHT</code>,
                    <code class="constant">GL_BACK_LEFT</code>,
                    <code class="constant">GL_BACK_RIGHT</code>,
                    <code class="constant">GL_FRONT</code>,
                    <code class="constant">GL_BACK</code>,
                    <code class="constant">GL_LEFT</code>,
                    <code class="constant">GL_RIGHT</code>, and
                    <code class="constant">GL_FRONT_AND_BACK</code>
                    are accepted.
                    The initial value is <code class="constant">GL_FRONT</code> for single-buffered contexts,
                    and <code class="constant">GL_BACK</code> for double-buffered contexts.
                </p></dd></dl></div></div><div class="refsect1"><a id="description"></a><h2>Description</h2><p>
            When colors are written to the frame buffer,
            they are written into the color buffers specified by <code class="function">glDrawBuffer</code>.
            The specifications are as follows:
        </p><div class="variablelist"><dl class="variablelist"><dt><span class="term"><code class="constant">GL_NONE</code></span></dt><dd><p>
                        No color buffers are written.
                    </p></dd><dt><span class="term"><code class="constant">GL_FRONT_LEFT</code></span></dt><dd><p>
                        Only the front left color buffer is written.
                    </p></dd><dt><span class="term"><code class="constant">GL_FRONT_RIGHT</code></span></dt><dd><p>
                        Only the front right color buffer is written.
                    </p></dd><dt><span class="term"><code class="constant">GL_BACK_LEFT</code></span></dt><dd><p>
                        Only the back left color buffer is written.
                    </p></dd><dt><span class="term"><code class="constant">GL_BACK_RIGHT</code></span></dt><dd><p>
                        Only the back right color buffer is written.
                    </p></dd><dt><span class="term"><code class="constant">GL_FRONT</code></span></dt><dd><p>
                        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.
                    </p></dd><dt><span class="term"><code class="constant">GL_BACK</code></span></dt><dd><p>
                        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.
                    </p></dd><dt><span class="term"><code class="constant">GL_LEFT</code></span></dt><dd><p>
                        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.
                    </p></dd><dt><span class="term"><code class="constant">GL_RIGHT</code></span></dt><dd><p>
                        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.
                    </p></dd><dt><span class="term"><code class="constant">GL_FRONT_AND_BACK</code></span></dt><dd><p>
                        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.
                    </p></dd></dl></div><p>
            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.
        </p><p>
            Monoscopic contexts include only
            <span class="emphasis"><em>left</em></span>
            buffers, and stereoscopic contexts include both
            <span class="emphasis"><em>left</em></span>
            and
            <span class="emphasis"><em>right</em></span>
            buffers.
            Likewise, single-buffered contexts include only
            <span class="emphasis"><em>front</em></span>
            buffers, and double-buffered contexts include both
            <span class="emphasis"><em>front</em></span>
            and
            <span class="emphasis"><em>back</em></span>
            buffers.
            The context is selected at GL initialization.
        </p></div><div class="refsect1"><a id="errors"></a><h2>Errors</h2><p>
            <code class="constant">GL_INVALID_ENUM</code> is generated if <em class="parameter"><code>mode</code></em> is not an accepted value.
        </p><p>
            <code class="constant">GL_INVALID_OPERATION</code> is generated if none of the buffers indicated
            by <em class="parameter"><code>mode</code></em> exists.
        </p></div><div class="refsect1"><a id="associatedgets"></a><h2>Associated Gets</h2><p>
            <a class="citerefentry" href="glGet.xml"><span class="citerefentry"><span class="refentrytitle">glGet</span></span></a> with argument <code class="constant">GL_DRAW_BUFFER</code>
        </p></div><div class="refsect1"><a id="seealso"></a><h2>See Also</h2><p>
            <a class="citerefentry" href="glBlendFunc.xml"><span class="citerefentry"><span class="refentrytitle">glBlendFunc</span></span></a>,
            <a class="citerefentry" href="glColorMask.xml"><span class="citerefentry"><span class="refentrytitle">glColorMask</span></span></a>,
            <a class="citerefentry" href="glDrawBuffers.xml"><span class="citerefentry"><span class="refentrytitle">glDrawBuffers</span></span></a>,
            <a class="citerefentry" href="glLogicOp.xml"><span class="citerefentry"><span class="refentrytitle">glLogicOp</span></span></a>,
            <a class="citerefentry" href="glReadBuffer.xml"><span class="citerefentry"><span class="refentrytitle">glReadBuffer</span></span></a>
        </p></div><div class="refsect1"><a id="Copyright"></a><h2>Copyright</h2><p>
            Copyright <span class="trademark"></span>© 1991-2006 Silicon Graphics, Inc.
            Copyright <span class="trademark"></span>© 2010-2013 Khronos Group.
            This document is licensed under the SGI Free Software B License.
            For details, see
            <a class="ulink" href="http://oss.sgi.com/projects/FreeB/" target="_top">http://oss.sgi.com/projects/FreeB/</a>.
        </p></div></div></body></html>