From 0ca33a6c0d409aa5d49794b6f4d8018c634fb0fb Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Thu, 11 Aug 2022 14:13:02 +0200 Subject: [PATCH] radv: copy line stipple factor/pattern only if the state isn't dynamic If line stipple is enabled and the state is dynamic we don't have to copy factor/pattern to the dynamic state struct. Signed-off-by: Samuel Pitoiset Reviewed-By: Mike Blumenkrantz Part-of: --- src/amd/vulkan/radv_pipeline.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c index ebeaafed2dc..afd8fa0c2e8 100644 --- a/src/amd/vulkan/radv_pipeline.c +++ b/src/amd/vulkan/radv_pipeline.c @@ -2151,7 +2151,7 @@ radv_pipeline_init_dynamic_state(struct radv_graphics_pipeline *pipeline, } } - if (needed_states & RADV_DYNAMIC_LINE_STIPPLE) { + if (states & RADV_DYNAMIC_LINE_STIPPLE) { dynamic->line_stipple.factor = info->rs.line_stipple_factor; dynamic->line_stipple.pattern = info->rs.line_stipple_pattern; }