zink: use correct value for color buffer sample count when creating renderpass
nr_samples is valid on the texture pipe_resource, not the surface Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6263>
This commit is contained in:

committed by
Marge Bot

parent
140f53e646
commit
f6c87216d3
@@ -444,7 +444,7 @@ get_render_pass(struct zink_context *ctx)
|
||||
struct pipe_surface *surf = fb->cbufs[i];
|
||||
if (surf) {
|
||||
state.rts[i].format = zink_get_format(screen, surf->format);
|
||||
state.rts[i].samples = surf->nr_samples > 0 ? surf->nr_samples :
|
||||
state.rts[i].samples = surf->texture->nr_samples > 0 ? surf->texture->nr_samples :
|
||||
VK_SAMPLE_COUNT_1_BIT;
|
||||
} else {
|
||||
state.rts[i].format = VK_FORMAT_R8_UINT;
|
||||
|
Reference in New Issue
Block a user