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=
"glGetSamplerParameter">
9 <holder>Khronos Group
</holder>
12 <refentrytitle>glGetSamplerParameter
</refentrytitle>
13 <manvolnum>3G
</manvolnum>
16 <refname>glGetSamplerParameter
</refname>
17 <refpurpose>return sampler parameter values
</refpurpose>
19 <refsynopsisdiv><title>C Specification
</title>
22 <funcdef>void
<function>glGetSamplerParameterfv
</function></funcdef>
23 <paramdef>GLuint
<parameter>sampler
</parameter></paramdef>
24 <paramdef>GLenum
<parameter>pname
</parameter></paramdef>
25 <paramdef>GLfloat *
<parameter>params
</parameter></paramdef>
30 <funcdef>void
<function>glGetSamplerParameteriv
</function></funcdef>
31 <paramdef>GLuint
<parameter>sampler
</parameter></paramdef>
32 <paramdef>GLenum
<parameter>pname
</parameter></paramdef>
33 <paramdef>GLint *
<parameter>params
</parameter></paramdef>
38 <funcdef>void
<function>glGetSamplerParameterIiv
</function></funcdef>
39 <paramdef>GLuint
<parameter>sampler
</parameter></paramdef>
40 <paramdef>GLenum
<parameter>pname
</parameter></paramdef>
41 <paramdef>GLint *
<parameter>params
</parameter></paramdef>
46 <funcdef>void
<function>glGetSamplerParameterIuiv
</function></funcdef>
47 <paramdef>GLuint
<parameter>sampler
</parameter></paramdef>
48 <paramdef>GLenum
<parameter>pname
</parameter></paramdef>
49 <paramdef>GLuint *
<parameter>params
</parameter></paramdef>
53 <!-- eqn: ignoring delim $$ -->
54 <refsect1 id=
"parameters"><title>Parameters
</title>
57 <term><parameter>sampler
</parameter></term>
60 Specifies name of the sampler object from which to retrieve parameters.
65 <term><parameter>pname
</parameter></term>
68 Specifies the symbolic name of a sampler parameter.
69 <constant>GL_TEXTURE_MAG_FILTER
</constant>,
70 <constant>GL_TEXTURE_MIN_FILTER
</constant>,
71 <constant>GL_TEXTURE_MIN_LOD
</constant>,
72 <constant>GL_TEXTURE_MAX_LOD
</constant>,
73 <constant>GL_TEXTURE_LOD_BIAS
</constant>,
74 <constant>GL_TEXTURE_WRAP_S
</constant>,
75 <constant>GL_TEXTURE_WRAP_T
</constant>,
76 <constant>GL_TEXTURE_WRAP_R
</constant>,
77 <constant>GL_TEXTURE_BORDER_COLOR
</constant>,
78 <constant>GL_TEXTURE_COMPARE_MODE
</constant>, and
79 <constant>GL_TEXTURE_COMPARE_FUNC
</constant>
85 <term><parameter>params
</parameter></term>
88 Returns the sampler parameters.
94 <refsect1 id=
"description"><title>Description
</title>
96 <function>glGetSamplerParameter
</function> returns in
<parameter>params
</parameter> the value or values of the sampler parameter
97 specified as
<parameter>pname
</parameter>.
98 <parameter>sampler
</parameter> defines the target sampler, and must be the name of an existing sampler object, returned from a previous call
99 to
<citerefentry><refentrytitle>glGenSamplers
</refentrytitle></citerefentry>.
100 <parameter>pname
</parameter> accepts the same symbols as
<citerefentry><refentrytitle>glSamplerParameter
</refentrytitle></citerefentry>,
101 with the same interpretations:
105 <term><constant>GL_TEXTURE_MAG_FILTER
</constant></term>
108 Returns the single-valued texture magnification filter,
109 a symbolic constant. The initial value is
<constant>GL_LINEAR
</constant>.
114 <term><constant>GL_TEXTURE_MIN_FILTER
</constant></term>
117 Returns the single-valued texture minification filter,
118 a symbolic constant. The initial value is
<constant>GL_NEAREST_MIPMAP_LINEAR
</constant>.
123 <term><constant>GL_TEXTURE_MIN_LOD
</constant></term>
126 Returns the single-valued texture minimum level-of-detail value. The
128 <inlineequation><mml:math>
130 <mml:mn>-
1000</mml:mn>
131 </mml:math></inlineequation>.
136 <term><constant>GL_TEXTURE_MAX_LOD
</constant></term>
139 Returns the single-valued texture maximum level-of-detail value. The
140 initial value is
1000.
145 <term><constant>GL_TEXTURE_WRAP_S
</constant></term>
148 Returns the single-valued wrapping function for texture coordinate
149 <inlineequation><mml:math><mml:mi mathvariant=
"italic">s
</mml:mi></mml:math></inlineequation>,
150 a symbolic constant. The initial value is
<constant>GL_REPEAT
</constant>.
155 <term><constant>GL_TEXTURE_WRAP_T
</constant></term>
158 Returns the single-valued wrapping function for texture coordinate
159 <inlineequation><mml:math><mml:mi mathvariant=
"italic">t
</mml:mi></mml:math></inlineequation>,
160 a symbolic constant. The initial value is
<constant>GL_REPEAT
</constant>.
165 <term><constant>GL_TEXTURE_WRAP_R
</constant></term>
168 Returns the single-valued wrapping function for texture coordinate
169 <inlineequation><mml:math><mml:mi mathvariant=
"italic">r
</mml:mi></mml:math></inlineequation>,
170 a symbolic constant. The initial value is
<constant>GL_REPEAT
</constant>.
175 <term><constant>GL_TEXTURE_BORDER_COLOR
</constant></term>
178 Returns four integer or floating-point numbers that comprise the RGBA color
179 of the texture border.
180 Floating-point values are returned in the range
181 <inlineequation><mml:math>
183 <mml:mfenced open=
"[" close=
"]">
187 </mml:math></inlineequation>.
188 Integer values are returned as a linear mapping of the internal floating-point
189 representation such that
1.0 maps to the most positive representable
191 <inlineequation><mml:math>
193 <mml:mn>-
1.0</mml:mn>
194 </mml:math></inlineequation>
195 maps to the most negative representable
196 integer. The initial value is (
0,
0,
0,
0).
201 <term><constant>GL_TEXTURE_COMPARE_MODE
</constant></term>
204 Returns a single-valued texture comparison mode, a symbolic constant. The
205 initial value is
<constant>GL_NONE
</constant>. See
<citerefentry><refentrytitle>glSamplerParameter
</refentrytitle></citerefentry>.
210 <term><constant>GL_TEXTURE_COMPARE_FUNC
</constant></term>
213 Returns a single-valued texture comparison function, a symbolic constant. The
214 initial value is
<constant>GL_LEQUAL
</constant>. See
<citerefentry><refentrytitle>glSamplerParameter
</refentrytitle></citerefentry>.
220 <refsect1 id=
"notes"><title>Notes
</title>
222 If an error is generated,
223 no change is made to the contents of
<parameter>params
</parameter>.
226 <function>glGetSamplerParameter
</function> is available only if the GL version is
3.3 or higher.
229 <refsect1 id=
"errors"><title>Errors
</title>
231 <constant>GL_INVALID_VALUE
</constant> is generated if
<parameter>sampler
</parameter> is not the name of a sampler object returned from
232 a previous call to
<citerefentry><refentrytitle>glGenSamplers
</refentrytitle></citerefentry>.
235 <constant>GL_INVALID_ENUM
</constant> is generated if
<parameter>pname
</parameter> is not an accepted value.
238 <refsect1 id=
"seealso"><title>See Also
</title>
240 <citerefentry><refentrytitle>glSamplerParameter
</refentrytitle></citerefentry>,
241 <citerefentry><refentrytitle>glGenSamplers
</refentrytitle></citerefentry>,
242 <citerefentry><refentrytitle>glDeleteSamplers
</refentrytitle></citerefentry>,
243 <citerefentry><refentrytitle>glSamplerParameter
</refentrytitle></citerefentry>
246 <refsect1 id=
"Copyright"><title>Copyright
</title>
248 Copyright
<trademark class=
"copyright"></trademark> 2010 Khronos Group.
249 This material may be distributed subject to the terms and conditions set forth in
250 the Open Publication License, v
1.0,
8 June
1999.
251 <ulink url=
"http://opencontent.org/openpub/">http://opencontent.org/openpub/
</ulink>.