[qfcc] Assign indices to glsl block members

spirv-val didn't particularly like all my block members getting index 0
(really, it was tangled types, but 0 was the cause).
This commit is contained in:
Bill Currie 2024-11-21 17:25:57 +09:00
parent cfc5e0b5fd
commit fbcdf227c5

View file

@ -129,6 +129,10 @@ void
glsl_finish_block (glsl_block_t *block, specifier_t spec)
{
spec.sym = block->name;
int index = 0;
for (auto s = block->members->symbols; s; s = s->next) {
s->id = index++;
}
glsl_apply_attributes (block->attributes, spec);
}