Fix into GLShader::load_from_text()
This commit is contained in:
parent
6440c8ccfd
commit
8604e19384
1 changed files with 2 additions and 2 deletions
|
@ -118,9 +118,9 @@ bool GLShader::load_from_text(const char *fragment_shader, const char *vertex_sh
|
|||
glsafe(::glGetProgramiv(this->shader_program_id, GL_LINK_STATUS, ¶ms));
|
||||
if (params == GL_FALSE) {
|
||||
// Linking failed. Get the log.
|
||||
glsafe(::glGetProgramiv(this->vertex_program_id, GL_INFO_LOG_LENGTH, ¶ms));
|
||||
glsafe(::glGetProgramiv(this->shader_program_id, GL_INFO_LOG_LENGTH, ¶ms));
|
||||
std::vector<char> msg(params);
|
||||
glsafe(::glGetProgramInfoLog(this->vertex_program_id, params, ¶ms, msg.data()));
|
||||
glsafe(::glGetProgramInfoLog(this->shader_program_id, params, ¶ms, msg.data()));
|
||||
this->last_error = std::string("Shader linking failed:\n") + msg.data();
|
||||
this->release();
|
||||
return false;
|
||||
|
|
Loading…
Reference in a new issue