1 <?xml version=
"1.0" encoding=
"UTF-8"?>
2 <!DOCTYPE book PUBLIC
"-//OASIS//DTD DocBook MathML Module V1.1b1//EN"
3 "http://www.oasis-open.org/docbook/xml/mathml/1.1CR1/dbmathml.dtd">
4 <refentry id=
"glGetFramebufferParameter">
9 <holder>Khronos Group
</holder>
12 <refentrytitle>glGetFramebufferParameter
</refentrytitle>
13 <manvolnum>3G
</manvolnum>
16 <refname>glGetFramebufferParameter
</refname>
17 <refpurpose>retrieve a named parameter from a framebuffer
</refpurpose>
19 <refsynopsisdiv><title>C Specification
</title>
22 <funcdef>void
<function>glGetFramebufferParameteriv
</function></funcdef>
23 <paramdef>GLenum
<parameter>target
</parameter></paramdef>
24 <paramdef>GLenum
<parameter>pname
</parameter></paramdef>
25 <paramdef>GLint *
<parameter>params
</parameter></paramdef>
29 <refsect1 id=
"parameters"><title>Parameters
</title>
32 <term><parameter>target
</parameter></term>
35 The target of the operation, which must be
<constant>GL_READ_FRAMEBUFFER
</constant>,
36 <constant>GL_DRAW_FRAMEBUFFER
</constant> or
<constant>GL_FRAMEBUFFER
</constant>.
41 <term><parameter>pname
</parameter></term>
44 A token indicating the parameter to be retrieved.
49 <term><parameter>params
</parameter></term>
52 The address of a variable to receive the value of the parameter named
<parameter>pname
</parameter>.
58 <refsect1 id=
"description"><title>Description
</title>
60 <function>glGetFramebufferParameter
</function> retrieves the current value of the parameter
61 named
<parameter>pname
</parameter> from the framebuffer bound to
<parameter>target
</parameter>.
62 <parameter>target
</parameter> must be
<constant>GL_READ_FRAMEBFUFFER
</constant>,
63 <constant>GL_DRAW_FRAMEBUFFER
</constant> or
<constant>GL_FRAMEBUFFER
</constant>. The
64 token
<constant>GL_FRAMEBUFFER
</constant> is treated as
<constant>GL_DRAW_FRAMEBUFFER
</constant>.
65 A non-default framebuffer must be bound to
<parameter>target
</parameter>.
68 <parameter>pname
</parameter> specifies the parameter to be retrieved. The values retrieved from
69 the framebuffer are written into the variable whose address is given by
<parameter>params
</parameter>.
70 The following symbols are accepted in
<parameter>pname
</parameter>:
74 <term><constant>GL_FRAMEBUFFER_DEFAULT_WIDTH
</constant></term>
77 The value of
<constant>GL_FRAMEBUFFER_DEFAULT_WIDTH
</constant> for the framebuffer is written to the
78 single integer variable whose address is given by
<parameter>params
</parameter>.
83 <term><constant>GL_FRAMEBUFFER_DEFAULT_HEIGHT
</constant></term>
86 The value of
<constant>GL_FRAMEBUFFER_DEFAULT_HEIGHT
</constant> for the framebuffer is written to the
87 single integer variable whose address is given by
<parameter>params
</parameter>.
92 <term><constant>GL_FRAMEBUFFER_DEFAULT_LAYERS
</constant></term>
95 The value of
<constant>GL_FRAMEBUFFER_DEFAULT_LAYERS
</constant> for the framebuffer is written to the
96 single integer variable whose address is given by
<parameter>params
</parameter>.
101 <term><constant>GL_FRAMEBUFFER_DEFAULT_SAMPLES
</constant></term>
104 The value of
<constant>GL_FRAMEBUFFER_DEFAULT_SAMPLES
</constant> for the framebuffer is written to the
105 single integer variable whose address is given by
<parameter>params
</parameter>.
110 <term><constant>GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS
</constant></term>
113 If the value of
<constant>GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS
</constant> for the framebuffer is
<constant>GL_TRUE
</constant>
114 then the single integer variable whose address is in
<parameter>params
</parameter> is set to one,
115 otherwise it is set to zero.
121 <refsect1 id=
"errors"><title>Errors
</title>
123 <constant>GL_INVALID_ENUM
</constant> is generated if
<parameter>target
</parameter> is not one of the accepted
127 <constant>GL_INVALID_ENUM
</constant> is generated if
<parameter>pname
</parameter> is not one of the accepted
131 <constant>GL_INVALID_OPERATION
</constant> is generated if the default framebuffer is bound to
<parameter>target
</parameter>.
134 <parameter>params
</parameter> should be the address of a variable to which the client has write access otherwise
135 undefined behavior, including process termination may occur.
138 <refsect1 id=
"associatedgets"><title>Associated Gets
</title>
140 <citerefentry><refentrytitle>glGetFramebufferParameteriv
</refentrytitle></citerefentry>.
143 <refsect1 id=
"seealso"><title>See Also
</title>
145 <citerefentry><refentrytitle>glFramebufferParameteri
</refentrytitle></citerefentry>.
148 <refsect1 id=
"Copyright"><title>Copyright
</title>
150 Copyright
<trademark class=
"copyright"></trademark> 2012 Khronos Group.
151 This material may be distributed subject to the terms and conditions set forth in
152 the Open Publication License, v
1.0,
8 June
1999.
153 <ulink url=
"http://opencontent.org/openpub/">http://opencontent.org/openpub/
</ulink>.