Opentk/Source/Bind/Specifications/Docs/glGetTexParameter.xml

310 lines
14 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook MathML Module V1.1b1//EN"
"http://www.oasis-open.org/docbook/xml/mathml/1.1CR1/dbmathml.dtd">
<refentry id="glGetTexParameter">
<refmeta>
<refmetainfo>
<copyright>
<year>1991-2006</year>
<holder>Silicon Graphics, Inc.</holder>
</copyright>
</refmetainfo>
<refentrytitle>glGetTexParameter</refentrytitle>
<manvolnum>3G</manvolnum>
</refmeta>
<refnamediv>
<refname>glGetTexParameter</refname>
<refpurpose>return texture parameter values</refpurpose>
</refnamediv>
<refsynopsisdiv><title>C Specification</title>
<funcsynopsis>
<funcprototype>
<funcdef>void <function>glGetTexParameterfv</function></funcdef>
<paramdef>GLenum <parameter>target</parameter></paramdef>
<paramdef>GLenum <parameter>pname</parameter></paramdef>
<paramdef>GLfloat * <parameter>params</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<funcdef>void <function>glGetTexParameteriv</function></funcdef>
<paramdef>GLenum <parameter>target</parameter></paramdef>
<paramdef>GLenum <parameter>pname</parameter></paramdef>
<paramdef>GLint * <parameter>params</parameter></paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<!-- eqn: ignoring delim $$ -->
<refsect1 id="parameters"><title>Parameters</title>
<variablelist>
<varlistentry>
<term><parameter>target</parameter></term>
<listitem>
<para>
Specifies the symbolic name of the target texture.
<constant>GL_TEXTURE_1D</constant>,
<constant>GL_TEXTURE_2D</constant>,
2010-12-04 21:51:40 +00:00
<constant>GL_TEXTURE_1D_ARRAY</constant>,
<constant>GL_TEXTURE_2D_ARRAY</constant>,
<constant>GL_TEXTURE_3D</constant>,
<constant>GL_TEXTURE_RECTANGLE</constant>, and
<constant>GL_TEXTURE_CUBE_MAP</constant>
are accepted.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>pname</parameter></term>
<listitem>
<para>
Specifies the symbolic name of a texture parameter.
<constant>GL_TEXTURE_BASE_LEVEL</constant>,
<constant>GL_TEXTURE_BORDER_COLOR</constant>,
<constant>GL_TEXTURE_COMPARE_MODE</constant>,
<constant>GL_TEXTURE_COMPARE_FUNC</constant>,
2010-12-04 21:51:40 +00:00
<constant>GL_TEXTURE_LOD_BIAS</constant>,
<constant>GL_TEXTURE_MAG_FILTER</constant>,
<constant>GL_TEXTURE_MAX_LEVEL</constant>,
<constant>GL_TEXTURE_MAX_LOD</constant>,
<constant>GL_TEXTURE_MIN_FILTER</constant>,
<constant>GL_TEXTURE_MIN_LOD</constant>,
<constant>GL_TEXTURE_SWIZZLE_R</constant>,
<constant>GL_TEXTURE_SWIZZLE_G</constant>,
<constant>GL_TEXTURE_SWIZZLE_B</constant>,
<constant>GL_TEXTURE_SWIZZLE_A</constant>,
<constant>GL_TEXTURE_SWIZZLE_RGBA</constant>,
<constant>GL_TEXTURE_WRAP_S</constant>,
<constant>GL_TEXTURE_WRAP_T</constant>, and
<constant>GL_TEXTURE_WRAP_R</constant>
are accepted.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>params</parameter></term>
<listitem>
<para>
Returns the texture parameters.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1 id="description"><title>Description</title>
<para>
<function>glGetTexParameter</function> returns in <parameter>params</parameter> the value or values of the texture parameter
specified as <parameter>pname</parameter>.
2010-12-04 21:51:40 +00:00
<parameter>target</parameter> defines the target texture.
<constant>GL_TEXTURE_1D</constant>,
<constant>GL_TEXTURE_2D</constant>,
<constant>GL_TEXTURE_3D</constant>,
<constant>GL_TEXTURE_1D_ARRAY</constant>,
<constant>GL_TEXTURE_2D_ARRAY</constant>,
<constant>GL_TEXTURE_RECTANGLE</constant>, and
<constant>GL_TEXTURE_CUBE_MAP</constant>
specify one-, two-, or three-dimensional, one-dimensional array, two-dimensional array, rectangle or cube-mapped texturing, respectively.
<parameter>pname</parameter> accepts the same symbols as <citerefentry><refentrytitle>glTexParameter</refentrytitle></citerefentry>,
with the same interpretations:
</para>
<variablelist>
<varlistentry>
<term><constant>GL_TEXTURE_MAG_FILTER</constant></term>
<listitem>
<para>
Returns the single-valued texture magnification filter,
a symbolic constant. The initial value is <constant>GL_LINEAR</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_MIN_FILTER</constant></term>
<listitem>
<para>
Returns the single-valued texture minification filter,
a symbolic constant. The initial value is <constant>GL_NEAREST_MIPMAP_LINEAR</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_MIN_LOD</constant></term>
<listitem>
<para>
Returns the single-valued texture minimum level-of-detail value. The
initial value is
<inlineequation><mml:math>
2010-12-04 21:51:40 +00:00
<!-- eqn: -1000: -->
<mml:mn>-1000</mml:mn>
</mml:math></inlineequation>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_MAX_LOD</constant></term>
<listitem>
<para>
Returns the single-valued texture maximum level-of-detail value. The
initial value is 1000.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_BASE_LEVEL</constant></term>
<listitem>
<para>
Returns the single-valued base texture mipmap level. The initial value is 0.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_MAX_LEVEL</constant></term>
<listitem>
<para>
Returns the single-valued maximum texture mipmap array level. The initial
value is 1000.
</para>
</listitem>
</varlistentry>
2010-12-04 21:51:40 +00:00
<varlistentry>
<term><constant>GL_TEXTURE_SWIZZLE_R</constant></term>
<listitem>
<para>
Returns the red component swizzle. The initial value is <constant>GL_RED</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_SWIZZLE_G</constant></term>
<listitem>
<para>
Returns the green component swizzle. The initial value is <constant>GL_GREEN</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_SWIZZLE_B</constant></term>
<listitem>
<para>
Returns the blue component swizzle. The initial value is <constant>GL_BLUE</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_SWIZZLE_A</constant></term>
<listitem>
<para>
Returns the alpha component swizzle. The initial value is <constant>GL_ALPHA</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_SWIZZLE_RGBA</constant></term>
<listitem>
<para>
Returns the component swizzle for all channels in a single query.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_WRAP_S</constant></term>
<listitem>
<para>
Returns the single-valued wrapping function for texture coordinate
<inlineequation><mml:math><mml:mi mathvariant="italic">s</mml:mi></mml:math></inlineequation>,
a symbolic constant. The initial value is <constant>GL_REPEAT</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_WRAP_T</constant></term>
<listitem>
<para>
Returns the single-valued wrapping function for texture coordinate
<inlineequation><mml:math><mml:mi mathvariant="italic">t</mml:mi></mml:math></inlineequation>,
a symbolic constant. The initial value is <constant>GL_REPEAT</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_WRAP_R</constant></term>
<listitem>
<para>
Returns the single-valued wrapping function for texture coordinate
<inlineequation><mml:math><mml:mi mathvariant="italic">r</mml:mi></mml:math></inlineequation>,
a symbolic constant. The initial value is <constant>GL_REPEAT</constant>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_BORDER_COLOR</constant></term>
<listitem>
<para>
Returns four integer or floating-point numbers that comprise the RGBA color
of the texture border.
Floating-point values are returned in the range
<inlineequation><mml:math>
2010-12-04 21:51:40 +00:00
<!-- eqn: [0,1]: -->
<mml:mfenced open="[" close="]">
<mml:mn>0</mml:mn>
<mml:mn>1</mml:mn>
</mml:mfenced>
</mml:math></inlineequation>.
Integer values are returned as a linear mapping of the internal floating-point
representation such that 1.0 maps to the most positive representable
integer and
<inlineequation><mml:math>
2010-12-04 21:51:40 +00:00
<!-- eqn: -1.0: -->
<mml:mn>-1.0</mml:mn>
</mml:math></inlineequation>
maps to the most negative representable
integer. The initial value is (0, 0, 0, 0).
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_COMPARE_MODE</constant></term>
<listitem>
<para>
Returns a single-valued texture comparison mode, a symbolic constant. The
initial value is <constant>GL_NONE</constant>. See <citerefentry><refentrytitle>glTexParameter</refentrytitle></citerefentry>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term><constant>GL_TEXTURE_COMPARE_FUNC</constant></term>
<listitem>
<para>
Returns a single-valued texture comparison function, a symbolic constant. The
initial value is <constant>GL_LEQUAL</constant>. See <citerefentry><refentrytitle>glTexParameter</refentrytitle></citerefentry>.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1 id="notes"><title>Notes</title>
<para>
If an error is generated,
no change is made to the contents of <parameter>params</parameter>.
</para>
</refsect1>
<refsect1 id="errors"><title>Errors</title>
<para>
<constant>GL_INVALID_ENUM</constant> is generated if <parameter>target</parameter> or <parameter>pname</parameter> is not an
accepted value.
</para>
</refsect1>
<refsect1 id="seealso"><title>See Also</title>
<para>
<citerefentry><refentrytitle>glTexParameter</refentrytitle></citerefentry>
</para>
</refsect1>
<refsect1 id="Copyright"><title>Copyright</title>
<para>
Copyright <trademark class="copyright"></trademark> 1991-2006
2010-12-04 21:51:40 +00:00
Silicon Graphics, Inc. Copyright <trademark class="copyright"></trademark> 2010
Khronos Group. This document is licensed under the SGI
Free Software B License. For details, see
<ulink url="http://oss.sgi.com/projects/FreeB/">http://oss.sgi.com/projects/FreeB/</ulink>.
</para>
</refsect1>
</refentry>