mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
nvk: Use rendering state attachment count when setting SET_CT_SELECT
In case vk_color_attachment_location_state is in its default state, we would end up with an identity mapping for color_map resulting in 8 RTs being selected instead of what is really required. This now use the rendering state attachment count to properly emit SET_CT_SELECT. Found while debugging MRT on "dEQP-VK.shader_object.rendering.color_attachment_count_1.extra_attachment_after_1.none.none.same_color_formats.after.none.r16g16_sint_d32_sfloat_s8_uint" and while comparing with the proprietary driver. Signed-off-by: Mary Guillemard <mary@mary.zone> Fixes:84de6c12b2("nvk: Emit SET_CT_SELECT based on the dynamic color location map") Reviewed-by: Mel Henning <mhenning@darkrefraction.com> Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com> (cherry picked from commit86d190e158) Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39003>
This commit is contained in:
parent
0823d1b35c
commit
9ce7afc1ac
2 changed files with 2 additions and 2 deletions
|
|
@ -114,7 +114,7 @@
|
|||
"description": "nvk: Use rendering state attachment count when setting SET_CT_SELECT",
|
||||
"nominated": true,
|
||||
"nomination_type": 2,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "84de6c12b26358fec759511fd2b6944fe85505a4",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -3362,7 +3362,7 @@ nvk_flush_cb_state(struct nvk_cmd_buffer *cmd)
|
|||
int8_t loc_att[NVK_MAX_RTS] = { -1, -1, -1, -1, -1, -1, -1, -1};
|
||||
uint8_t max_loc = 0;
|
||||
uint32_t att_used = 0;
|
||||
for (uint8_t a = 0; a < MESA_VK_MAX_COLOR_ATTACHMENTS; a++) {
|
||||
for (uint8_t a = 0; a < render->color_att_count; a++) {
|
||||
if (dyn->cal.color_map[a] == MESA_VK_ATTACHMENT_UNUSED)
|
||||
continue;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue