]> git.tdb.fi Git - libs/gl.git/commitdiff
Don't try to apply push constants as uniforms in OpenGL
authorMikko Rasa <tdb@tdb.fi>
Wed, 17 Nov 2021 14:56:50 +0000 (16:56 +0200)
committerMikko Rasa <tdb@tdb.fi>
Wed, 17 Nov 2021 14:56:50 +0000 (16:56 +0200)
They shouldn't exist anyway.

source/backends/opengl/pipelinestate_backend.cpp

index 7cd654008d524f38c4d75c495959e54419a9faa0..19ee0f58f0a1788a27b46b1a326c41eafc133ca0 100644 (file)
@@ -118,7 +118,7 @@ void OpenGLPipelineState::apply(unsigned mask) const
                                                glBindBufferRange(GL_UNIFORM_BUFFER, u.binding, u.block->get_buffer()->id, u.block->get_offset(), u.block->get_data_size());
                                                bound_uniform_blocks[u.binding] = 1;
                                        }
-                                       else if(self.shprog)
+                                       else if(u.binding==ReflectData::DEFAULT_BLOCK && self.shprog)
                                        {
                                                const char *data = static_cast<const char *>(u.block->get_data_pointer());
                                                for(const Program::UniformCall &call: self.shprog->uniform_calls)