Merge branch 'et_gcode_viewer' of https://github.com/prusa3d/PrusaSlicer into et_gcode_viewer
This commit is contained in:
commit
a9e2444d29
@ -79,7 +79,7 @@ GLShaderProgram* GLShadersManager::get_current_shader()
|
|||||||
GLint id = 0;
|
GLint id = 0;
|
||||||
glsafe(::glGetIntegerv(GL_CURRENT_PROGRAM, &id));
|
glsafe(::glGetIntegerv(GL_CURRENT_PROGRAM, &id));
|
||||||
if (id == 0)
|
if (id == 0)
|
||||||
return false;
|
return nullptr;
|
||||||
|
|
||||||
auto it = std::find_if(m_shaders.begin(), m_shaders.end(), [id](std::unique_ptr<GLShaderProgram>& p) { return p->get_id() == id; });
|
auto it = std::find_if(m_shaders.begin(), m_shaders.end(), [id](std::unique_ptr<GLShaderProgram>& p) { return p->get_id() == id; });
|
||||||
return (it != m_shaders.end()) ? it->get() : nullptr;
|
return (it != m_shaders.end()) ? it->get() : nullptr;
|
||||||
|
Loading…
Reference in New Issue
Block a user