zink: use GENERAL layout for sampler images that are also bound as shader images
we can't have the same image with 2 layouts, so just go with the more global one Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9883>
This commit is contained in:
parent
ed0fedf1c2
commit
5c1ce2edb8
|
@ -1054,7 +1054,8 @@ update_sampler_descriptors(struct zink_context *ctx, struct zink_descriptor_set
|
|||
bufferview = sampler_view->buffer_view->buffer_view;
|
||||
} else if (res) {
|
||||
imageview = sampler_view->image_view->image_view;
|
||||
layout = VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL;
|
||||
layout = (res->bind_history & BITFIELD64_BIT(ZINK_DESCRIPTOR_TYPE_IMAGE)) ?
|
||||
VK_IMAGE_LAYOUT_GENERAL : VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL;
|
||||
sampler = ctx->sampler_states[stage][index + k];
|
||||
}
|
||||
assert(num_resources < num_bindings);
|
||||
|
|
Loading…
Reference in New Issue