File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed
Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -1100,8 +1100,8 @@ class GLUniformMatrix34fv : protected GLUniform
11001100class GLUniformBlock
11011101{
11021102protected:
1103- GLShader *_shader;
1104- std::string _name;
1103+ GLShader *_shader;
1104+ const std::string _name;
11051105 size_t _locationIndex; // Only valid if GL_ARB_shading_language_420pack is not available
11061106 const GLuint _bindingPoint; // Only valid if GL_ARB_shading_language_420pack is available
11071107
@@ -1119,14 +1119,9 @@ class GLUniformBlock
11191119 _locationIndex = index;
11201120 }
11211121
1122- const char *GetName ()
1123- {
1124- return _name.c_str ();
1125- }
1126-
11271122 void UpdateShaderProgramUniformBlockIndex ( ShaderProgramDescriptor* shaderProgram )
11281123 {
1129- shaderProgram->uniformBlockIndexes [_locationIndex] = glGetUniformBlockIndex ( shaderProgram->id , GetName () );
1124+ shaderProgram->uniformBlockIndexes [_locationIndex] = glGetUniformBlockIndex ( shaderProgram->id , _name. c_str () );
11301125 }
11311126
11321127 void SetBuffer ( GLuint buffer ) {
You can’t perform that action at this time.
0 commit comments