When SpvDecorationBinding is encountered in the SPIR-V source it now
sets explicit_binding on the nir_variable. This will be used to
determine whether to initialise sampler and image uniforms with the
binding value.
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
unsigned descriptor_set;
unsigned binding;
+ bool explicit_binding;
unsigned input_attachment_index;
bool patch;
switch (dec->decoration) {
case SpvDecorationBinding:
vtn_var->binding = dec->literals[0];
+ vtn_var->explicit_binding = true;
return;
case SpvDecorationDescriptorSet:
vtn_var->descriptor_set = dec->literals[0];
* for these. We should fix that.
*/
var->var->data.binding = var->binding;
+ var->var->data.explicit_binding = var->explicit_binding;
var->var->data.descriptor_set = var->descriptor_set;
var->var->data.index = var->input_attachment_index;