To mvMat binded range of buffer with type GL_SHADER_STORAGE_BUFFER. Buffer size is 65556 (1024 matrices)
First set of ObjectIndex to any value is OK
Second set of ObjectIndex to any value get GL_INVALID_OPERATION error generated. Wrong component type or count.
This message I get from DebugCallback, when execution point return from callback to place after glUniformi1
Also glGetProgramResourceiv for GL_TOP_LEVEL_ARRAY_SIZE return zero.
Well, it’s all kind of hard to tell without seeing the actual code where you’re getting these errors. Also, I don’t see what this has to do with a storage buffer; how uniforms works is an entirely orthogonal issue.
I agree, but it is hard to cut code from framework and make it clear to all. My hope is that someone faced a similar problem.
I think most likely problem in driver - it can’t properly setup index for array through uniform or can’t properly calculate array length from buffer size.
I will try to make a simple demo with raw GL for better understanding.
gDebugger help me.
Error was trivial - second setting of uniform was happens for other shader program where not that uniform.
So there is no driver bug, only curved hands :whistle: