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=
"glActiveShaderProgram">
9 <holder>Khronos Group
</holder>
12 <refentrytitle>glActiveShaderProgram
</refentrytitle>
13 <manvolnum>3G
</manvolnum>
16 <refname>glActiveShaderProgram
</refname>
17 <refpurpose>set the active program object for a program pipeline object
</refpurpose>
19 <refsynopsisdiv><title>C Specification
</title>
22 <funcdef>void
<function>glActiveShaderProgram
</function></funcdef>
23 <paramdef>GLuint
<parameter>pipeline
</parameter></paramdef>
24 <paramdef>GLuint
<parameter>program
</parameter></paramdef>
28 <refsect1 id=
"parameters"><title>Parameters
</title>
31 <term><parameter>pipeline
</parameter></term>
34 Specifies the program pipeline object to set the active program object for.
39 <term><parameter>program
</parameter></term>
42 Specifies the program object to set as the active program pipeline object
<parameter>pipeline
</parameter>.
48 <refsect1 id=
"description"><title>Description
</title>
50 <function>glActiveShaderProgram
</function> sets the linked program named by
<parameter>program
</parameter>
51 to be the active program for the program pipeline object
<parameter>pipeline
</parameter>. The active
52 program in the active program pipeline object is the target of calls to
<citerefentry><refentrytitle>glUniform
</refentrytitle></citerefentry>
53 when no program has been made current through a call to
<citerefentry><refentrytitle>glUseProgram
</refentrytitle></citerefentry>.
56 <refsect1 id=
"errors"><title>Errors
</title>
58 <constant>GL_INVALID_OPERATION
</constant> is generated if
<parameter>pipeline
</parameter> is not
59 a name previously returned from a call to
<citerefentry><refentrytitle>glGenProgramPipelines
</refentrytitle></citerefentry>
60 or if such a name has been deleted by a call to
61 <citerefentry><refentrytitle>glDeleteProgramPipelines
</refentrytitle></citerefentry>.
64 <constant>GL_INVALID_OPERATION
</constant> is generated if
<parameter>program
</parameter> refers
65 to a program object that has not been successfully linked.
68 <refsect1 id=
"seealso"><title>See Also
</title>
70 <citerefentry><refentrytitle>glGenProgramPipelines
</refentrytitle></citerefentry>,
71 <citerefentry><refentrytitle>glDeleteProgramPipelines
</refentrytitle></citerefentry>,
72 <citerefentry><refentrytitle>glIsProgramPipeline
</refentrytitle></citerefentry>,
73 <citerefentry><refentrytitle>glUseProgram
</refentrytitle></citerefentry>,
74 <citerefentry><refentrytitle>glUniform
</refentrytitle></citerefentry>
77 <refsect1 id=
"Copyright"><title>Copyright
</title>
79 Copyright
<trademark class=
"copyright"></trademark> 2010 Khronos Group.
80 This material may be distributed subject to the terms and conditions set forth in
81 the Open Publication License, v
1.0,
8 June
1999.
82 <ulink url=
"http://opencontent.org/openpub/">http://opencontent.org/openpub/
</ulink>.