Mesa (main): zink: clamp dynamic fb layers better
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Thu Jun 16 00:19:06 UTC 2022
Module: Mesa
Branch: main
Commit: 7edecbf4c2728d1f8e82da63cb2027933020b821
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=7edecbf4c2728d1f8e82da63cb2027933020b821
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Wed Jun 15 13:00:16 2022 -0400
zink: clamp dynamic fb layers better
this needs to be the minimum layer, not the maximum
Fixes: c81cd989c85 ("zink: use dynamic rendering (most of the time)")
Reviewed-by: Adam Jackson <ajax at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17061>
---
src/gallium/drivers/zink/zink_context.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gallium/drivers/zink/zink_context.c b/src/gallium/drivers/zink/zink_context.c
index 82903ed77f0..be5c81ddc11 100644
--- a/src/gallium/drivers/zink/zink_context.c
+++ b/src/gallium/drivers/zink/zink_context.c
@@ -2617,7 +2617,7 @@ zink_set_framebuffer_state(struct pipe_context *pctx,
ctx->dynamic_fb.info.renderArea.extent.width = state->width;
ctx->dynamic_fb.info.renderArea.extent.height = state->height;
ctx->dynamic_fb.info.colorAttachmentCount = ctx->fb_state.nr_cbufs;
- unsigned layers = MAX2(util_framebuffer_get_num_layers(state), 1);
+ unsigned layers = MAX2(zink_framebuffer_get_num_layers(state), 1);
ctx->rp_changed |= ctx->dynamic_fb.info.layerCount != layers;
ctx->dynamic_fb.info.layerCount = layers;
ctx->gfx_pipeline_state.rendering_info.colorAttachmentCount = ctx->fb_state.nr_cbufs;
More information about the mesa-commit
mailing list