MCPcopy Create free account
hub / github.com/Kitware/VTK / SetUniformi

Method SetUniformi

Rendering/OpenGL2/vtkShaderProgram.cxx:748–759  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

746}
747
748bool 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
761bool vtkShaderProgram::SetUniformf(const char* name, float f)
762{

Callers 15

CopyOpaqueDepthBufferMethod · 0.45
BlendBackBufferMethod · 0.45
BlendFinalImageMethod · 0.45
RenderMethod · 0.45
RenderMethod · 0.45
ProjectMethod · 0.45
ApplyFilterMethod · 0.45

Calls 1

FindUniformMethod · 0.95

Tested by 2

UnitTestOpenGLUniformsFunction · 0.36