34 void setUniform(
const char* name,
const glm::vec2& u);
35 void setUniform(
const char* name,
const glm::vec3& u);
36 void setUniform(
const char* name,
const glm::vec4& u);
37 void setUniform(
const char* name,
const glm::mat3& u);
38 void setUniform(
const char* name,
const glm::mat4& u);
39 void setUniform(
const char* name,
const std::vector<glm::mat4>& u);
44 std::map<std::string, GLuint> uniformCache;
Encapsules an OpenGL shader program.
Definition: GLProgram.h:14
int getNumberOfUniforms()
Returns the number of Uniforms available.
Definition: GLProgram.cpp:69
void setUniform(const char *name, float u)
Sets the value of the given uniform.
Definition: GLProgram.cpp:105
void link()
Links the program, so it's complete.
Definition: GLProgram.cpp:18
void bind()
Binds the program so it's used for rendering.
Definition: GLProgram.cpp:57
int getAttributeByName(char const *name)
Returns the id of the requested attribute.
Definition: GLProgram.cpp:76
Encapsuls an OpenGL shader.
Definition: GLShader.h:21
Definition: GLProgram.h:11
void bindFragDataLocation(int loc, const char *variableName)
Binds the fragment data with the given name to the location.
Definition: GLProgram.cpp:101
int getUniformByName(char const *name)
Returns the id of the requested uniform.
Definition: GLProgram.cpp:81
void attachShader(const GLShader &shader)
Attaches the given shader to this program.
Definition: GLProgram.cpp:13
void initialize()
Creates a new program.
Definition: GLProgram.cpp:8
Encapsules an OpenGL texture for easier use.
Definition: GLTexture.h:8
int getNumberOfAttributes()
Returns the number of attributes available.
Definition: GLProgram.cpp:62