| 746 | } |
| 747 | |
| 748 | bool vtkShaderProgram::SetUniformi(const char* name, int i) |
| 749 | { |
| 750 | GLint location = static_cast<GLint>(this->FindUniform(name)); |
| 751 | if (location == -1) |
| 752 | { |
| 753 | this->Error = "Could not set uniform (does not exist) "; |
| 754 | this->Error += name; |
| 755 | return false; |
| 756 | } |
| 757 | glUniform1i(location, static_cast<GLint>(i)); |
| 758 | return true; |
| 759 | } |
| 760 | |
| 761 | bool vtkShaderProgram::SetUniformf(const char* name, float f) |
| 762 | { |