diff options
author | Jason Ekstrand <[email protected]> | 2017-12-15 13:59:33 -0800 |
---|---|---|
committer | Emil Velikov <[email protected]> | 2018-01-26 19:53:00 +0000 |
commit | 144a300204762dfaf583f6496693dd4f8c9fc266 (patch) | |
tree | c2347976a99d657b3bfccb0ed6b88be05dce464d | |
parent | 2dec9ce6874525bef0c12165b072eafe5f272500 (diff) |
anv/cmd_buffer: Use anv_descriptor_for_binding for samplers
Tested-by: Józef Kucia <[email protected]>
Reviewed-by: Topi Pohjolainen <[email protected]>
Cc: "18.0" <[email protected]>
(cherry picked from commit 31b2144c836485ef6476bd455f1c02b96deafab7)
-rw-r--r-- | src/intel/vulkan/genX_cmd_buffer.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/intel/vulkan/genX_cmd_buffer.c b/src/intel/vulkan/genX_cmd_buffer.c index 389dd7871d6..479f75b3b1a 100644 --- a/src/intel/vulkan/genX_cmd_buffer.c +++ b/src/intel/vulkan/genX_cmd_buffer.c @@ -1752,10 +1752,8 @@ emit_samplers(struct anv_cmd_buffer *cmd_buffer, for (uint32_t s = 0; s < map->sampler_count; s++) { struct anv_pipeline_binding *binding = &map->sampler_to_descriptor[s]; - struct anv_descriptor_set *set = - cmd_buffer->state.descriptors[binding->set]; - uint32_t offset = set->layout->binding[binding->binding].descriptor_index; - struct anv_descriptor *desc = &set->descriptors[offset + binding->index]; + const struct anv_descriptor *desc = + anv_descriptor_for_binding(cmd_buffer, binding); if (desc->type != VK_DESCRIPTOR_TYPE_SAMPLER && desc->type != VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER) |