GLSL program that Shaders and Uniform variables are connected to. More...
#include <Program.hpp>
Public Member Functions | |
Program (const Tag &tag) | |
virtual void | addCode (int handle, const Preprocessor *preprocessor) |
virtual void | addListener (NodeListener *listener, int type) |
virtual void | apply () |
virtual void | associate () |
virtual void | finalize () |
virtual GLuint | getHandle () const |
virtual void | log () const |
virtual void | remove () |
virtual string | toString () const |
Static Public Member Functions | |
static Program * | find (Node *node) |
static Program * | getCurrent () |
Private Attributes | |
GLuint | handle |
map< int, const Preprocessor * > | code |
NodeNotifier | notifier |
Program * | previous |
Static Private Attributes | |
static Program * | current = NULL |
GLSL program that Shaders and Uniform variables are connected to.
void addCode | ( | int | handle, | |
const Preprocessor * | preprocessor | |||
) | [virtual] |
Adds link to shader code so linkage errors can be parsed.
void addListener | ( | NodeListener * | listener, | |
int | type | |||
) | [virtual] |
Adds a listener to the program.
void apply | ( | ) | [virtual] |
Installs the program into the current context.
Implements Applicable.
void associate | ( | ) | [virtual] |
Creates the program and finds the previous program.
Reimplemented from Node.
void finalize | ( | ) | [virtual] |
Links the program once other nodes have associated with it.
NodeException | if the program cannot be linked. |
Reimplemented from Node.
Program * getCurrent | ( | ) | [inline, static] |
GLuint getHandle | ( | ) | const [inline, virtual] |
void log | ( | ) | const [virtual] |
Prints the log for this program.
void remove | ( | ) | [virtual] |
Stop using this program and restore the previous one.
Implements Applicable.
string toString | ( | ) | const [virtual] |
Forms a string from the object's attributes.
Reimplemented from Node.