Fix total_uniforms uninitialized if missing shader program
This commit is contained in:
parent
c3f2d144b2
commit
63bb6a467b
@ -208,7 +208,7 @@ void SPShader::bindTextures(const std::array<GLuint, 6>& tex,
|
|||||||
void SPShader::addAllUniforms(RenderPass rp)
|
void SPShader::addAllUniforms(RenderPass rp)
|
||||||
{
|
{
|
||||||
#ifndef SERVER_ONLY
|
#ifndef SERVER_ONLY
|
||||||
GLint total_uniforms;
|
GLint total_uniforms = 0;
|
||||||
glGetProgramiv(m_program[rp], GL_ACTIVE_UNIFORMS, &total_uniforms);
|
glGetProgramiv(m_program[rp], GL_ACTIVE_UNIFORMS, &total_uniforms);
|
||||||
static const std::map<GLenum, std::type_index> supported_types =
|
static const std::map<GLenum, std::type_index> supported_types =
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user