示例#1
0
void ShaderProgramGl::setUniform(const string &name, const Matrix3f &value){
	assertGl();
	glUniformMatrix3fvARB(getLocation(name), 1, GL_FALSE, value.ptr());
	assertGl();
}
示例#2
0
void GLSLProgram::setUniform(int uniformLoc, Matrix3f& mat) {
	assert(m_linked);
	glUniformMatrix3fv(uniformLoc, 1, false, mat.ptr());
}
示例#3
0
	void GLProgram::setArg( const char* name, const Matrix3f & m )
	{
		GLint loc = glGetUniformLocation( program, name);
		glUniformMatrix3fv( loc, 1, true , ( const GLfloat* ) m.ptr() );
	}