From 9f561feecc79f5ffbeccb5c8fa4ad72de6eaefd9 Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Wed, 8 Jul 2020 09:36:00 +0200 Subject: [PATCH] radv: store the primitive topology hardware value in the pipeline Will help for upcoming changes. Signed-off-by: Samuel Pitoiset Reviewed-by: Bas Nieuwenhuizen Part-of: --- src/amd/vulkan/radv_cmd_buffer.c | 2 +- src/amd/vulkan/radv_pipeline.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/amd/vulkan/radv_cmd_buffer.c b/src/amd/vulkan/radv_cmd_buffer.c index df0191f28d6..fd8400e9b7e 100644 --- a/src/amd/vulkan/radv_cmd_buffer.c +++ b/src/amd/vulkan/radv_cmd_buffer.c @@ -1332,7 +1332,7 @@ radv_emit_line_stipple(struct radv_cmd_buffer *cmd_buffer) struct radv_pipeline *pipeline = cmd_buffer->state.pipeline; uint32_t auto_reset_cntl = 1; - if (pipeline->graphics.topology == VK_PRIMITIVE_TOPOLOGY_LINE_STRIP) + if (pipeline->graphics.topology == V_008958_DI_PT_LINESTRIP) auto_reset_cntl = 2; radeon_set_context_reg(cmd_buffer->cs, R_028A0C_PA_SC_LINE_STIPPLE, diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c index 098d26bb3b8..52a882297df 100644 --- a/src/amd/vulkan/radv_pipeline.c +++ b/src/amd/vulkan/radv_pipeline.c @@ -5063,7 +5063,7 @@ radv_pipeline_init(struct radv_pipeline *pipeline, uint32_t gs_out; uint32_t prim = si_translate_prim(pCreateInfo->pInputAssemblyState->topology); - pipeline->graphics.topology = pCreateInfo->pInputAssemblyState->topology; + pipeline->graphics.topology = si_translate_prim(pCreateInfo->pInputAssemblyState->topology); pipeline->graphics.can_use_guardband = radv_prim_can_use_guardband(pCreateInfo->pInputAssemblyState->topology); if (radv_pipeline_has_gs(pipeline)) { -- 2.30.2