|
INTRODUCTION
Overview
Download and Install
Quick Start
Documentation
Publications
NONFRAMEWORK CODE
Driver Interfaces
Drivers
Libraries
Utilities
FRAMEWORK CODE
Interfaces
Components
Libraries
Utilities
Full Software Listings
DEVELOPER
Tutorials
Examples
Dev Guide
Dashboard
PEOPLE
Contributors
Users
Project
Download
Mailing lists
|
|
|
hydroglu::GLProgram Class Reference
Wrapper for a GLSL program This class wraps most functionality needed to use GLSL, a compact language that typically is run in a vector processing manner on a video card.
More...
#include <glprogram.h>
List of all members.
Public Member Functions |
| GLProgram (std::string name) |
| GLProgram constructor.
|
| ~GLProgram () |
| GLProgram destructor.
|
GLuint | handle () const |
| returns the program handle
|
void | addShader (GLShaderPtr) |
| add a shader to the program
|
void | removeShader (GLShaderPtr) |
| remove a shader from the program
|
void | link () |
| link the glsl program from a set of compiled shaders Much like C++ linking takes a set of object files and builds a complete program from them so too does glsl.
|
void | enable () |
| enable the glsl program enabling a glsl program means rendering will now use your glsl program instead of the fixed pipeline rendering
|
void | disable () |
| disable the glsl program disabling a glsl program completely disables the usage glsl programs and goes back to fixed pipeline renering
|
void | setUniform (std::string uniformName, int value0) |
| set a uniform using 1 integer values
|
void | setUniform (std::string uniformName, float value0) |
| set a uniform using 1 float values
|
void | setUniform (std::string uniformName, int value0, int value1) |
| set a uniform using 2 integer values
|
void | setUniform (std::string uniformName, float value0, float value1) |
| set a uniform using 2 float values
|
void | setUniform (std::string uniformName, int value0, int value1, int value2) |
| set a uniform using 3 integer values
|
void | setUniform (std::string uniformName, float value0, float value1, float value2) |
| set a uniform using 3 float values
|
void | setUniform (std::string uniformName, int value0, int value1, int value2, int value3) |
| set a uniform using 4 integer values
|
void | setUniform (std::string uniformName, float value0, float value1, float value2, float value3) |
| set a uniform using 4 float values
|
Detailed Description
Wrapper for a GLSL program This class wraps most functionality needed to use GLSL, a compact language that typically is run in a vector processing manner on a video card.
Constructor & Destructor Documentation
GLProgram::GLProgram |
( |
std::string |
name |
) |
|
GLProgram constructor.
- Parameters:
-
| a | name for the program used for debug output to help identify which GLProgram has a problem |
Member Function Documentation
void GLProgram::addShader |
( |
GLShaderPtr |
shader |
) |
|
add a shader to the program
- Parameters:
-
| a | hydroglu GLShaderPtr, which can either be a Fragment or Vertex shader. |
GLuint GLProgram::handle |
( |
|
) |
const |
returns the program handle
- Returns:
- OpenGL glsl program handle
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
float |
value0, |
|
|
float |
value1, |
|
|
float |
value2, |
|
|
float |
value3 | |
|
) |
| | |
set a uniform using 4 float values
- Parameters:
-
| uniform | name |
| value0 | |
| value1 | |
| value2 | |
| value3 | |
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
int |
value0, |
|
|
int |
value1, |
|
|
int |
value2, |
|
|
int |
value3 | |
|
) |
| | |
set a uniform using 4 integer values
- Parameters:
-
| uniform | name |
| value0 | |
| value1 | |
| value2 | |
| value3 | |
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
float |
value0, |
|
|
float |
value1, |
|
|
float |
value2 | |
|
) |
| | |
set a uniform using 3 float values
- Parameters:
-
| uniform | name |
| value0 | |
| value1 | |
| value2 | |
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
int |
value0, |
|
|
int |
value1, |
|
|
int |
value2 | |
|
) |
| | |
set a uniform using 3 integer values
- Parameters:
-
| uniform | name |
| value0 | |
| value1 | |
| value2 | |
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
float |
value0, |
|
|
float |
value1 | |
|
) |
| | |
set a uniform using 2 float values
- Parameters:
-
| uniform | name |
| value0 | |
| value1 | |
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
int |
value0, |
|
|
int |
value1 | |
|
) |
| | |
set a uniform using 2 integer values
- Parameters:
-
| uniform | name |
| value0 | |
| value1 | |
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
float |
value0 | |
|
) |
| | |
set a uniform using 1 float values
- Parameters:
-
void GLProgram::setUniform |
( |
std::string |
uniformName, |
|
|
int |
value0 | |
|
) |
| | |
set a uniform using 1 integer values
- Parameters:
-
The documentation for this class was generated from the following files:
|
|