From fd475bdd8e561d2f4314e4fa3af926ac233ac9c6 Mon Sep 17 00:00:00 2001 From: Flyinghead Date: Mon, 14 Oct 2024 17:19:41 +0200 Subject: [PATCH] vk: some pipelines don't need the provoking vertex extension ModVol and OIT Final and Clear pipelines don't need it. --- core/rend/vulkan/oit/oit_pipeline.cpp | 44 --------------------------- core/rend/vulkan/pipeline.cpp | 11 ------- 2 files changed, 55 deletions(-) diff --git a/core/rend/vulkan/oit/oit_pipeline.cpp b/core/rend/vulkan/oit/oit_pipeline.cpp index d7543934b..312941a4f 100644 --- a/core/rend/vulkan/oit/oit_pipeline.cpp +++ b/core/rend/vulkan/oit/oit_pipeline.cpp @@ -222,17 +222,6 @@ void OITPipelineManager::CreateFinalPipeline(bool dithering) 0.0f, // depthBiasSlopeFactor 1.0f // lineWidth ); - - // Dreamcast uses the last vertex as the provoking vertex, but Vulkan uses the first. - // Utilize VK_EXT_provoking_vertex when available to set the provoking vertex to be the - // last vertex - vk::PipelineRasterizationProvokingVertexStateCreateInfoEXT provokingVertexInfo{}; - if (GetContext()->hasProvokingVertex()) - { - provokingVertexInfo.provokingVertexMode = vk::ProvokingVertexModeEXT::eLastVertex; - pipelineRasterizationStateCreateInfo.pNext = &provokingVertexInfo; - } - vk::PipelineMultisampleStateCreateInfo pipelineMultisampleStateCreateInfo; // Depth and stencil @@ -317,17 +306,6 @@ void OITPipelineManager::CreateClearPipeline() 0.0f, // depthBiasSlopeFactor 1.0f // lineWidth ); - - // Dreamcast uses the last vertex as the provoking vertex, but Vulkan uses the first. - // Utilize VK_EXT_provoking_vertex when available to set the provoking vertex to be the - // last vertex - vk::PipelineRasterizationProvokingVertexStateCreateInfoEXT provokingVertexInfo{}; - if (GetContext()->hasProvokingVertex()) - { - provokingVertexInfo.provokingVertexMode = vk::ProvokingVertexModeEXT::eLastVertex; - pipelineRasterizationStateCreateInfo.pNext = &provokingVertexInfo; - } - vk::PipelineMultisampleStateCreateInfo pipelineMultisampleStateCreateInfo; // Depth and stencil @@ -410,17 +388,6 @@ void OITPipelineManager::CreateModVolPipeline(ModVolMode mode, int cullMode, boo 0.0f, // depthBiasSlopeFactor 1.0f // lineWidth ); - - // Dreamcast uses the last vertex as the provoking vertex, but Vulkan uses the first. - // Utilize VK_EXT_provoking_vertex when available to set the provoking vertex to be the - // last vertex - vk::PipelineRasterizationProvokingVertexStateCreateInfoEXT provokingVertexInfo{}; - if (GetContext()->hasProvokingVertex()) - { - provokingVertexInfo.provokingVertexMode = vk::ProvokingVertexModeEXT::eLastVertex; - pipelineRasterizationStateCreateInfo.pNext = &provokingVertexInfo; - } - vk::PipelineMultisampleStateCreateInfo pipelineMultisampleStateCreateInfo; // Depth and stencil @@ -533,17 +500,6 @@ void OITPipelineManager::CreateTrModVolPipeline(ModVolMode mode, int cullMode, b 0.0f, // depthBiasSlopeFactor 1.0f // lineWidth ); - - // Dreamcast uses the last vertex as the provoking vertex, but Vulkan uses the first. - // Utilize VK_EXT_provoking_vertex when available to set the provoking vertex to be the - // last vertex - vk::PipelineRasterizationProvokingVertexStateCreateInfoEXT provokingVertexInfo{}; - if (GetContext()->hasProvokingVertex()) - { - provokingVertexInfo.provokingVertexMode = vk::ProvokingVertexModeEXT::eLastVertex; - pipelineRasterizationStateCreateInfo.pNext = &provokingVertexInfo; - } - vk::PipelineMultisampleStateCreateInfo pipelineMultisampleStateCreateInfo; // Depth and stencil diff --git a/core/rend/vulkan/pipeline.cpp b/core/rend/vulkan/pipeline.cpp index faba68abe..90ce604be 100644 --- a/core/rend/vulkan/pipeline.cpp +++ b/core/rend/vulkan/pipeline.cpp @@ -67,17 +67,6 @@ void PipelineManager::CreateModVolPipeline(ModVolMode mode, int cullMode, bool n 0.0f, // depthBiasSlopeFactor 1.0f // lineWidth ); - - // Dreamcast uses the last vertex as the provoking vertex, but Vulkan uses the first. - // Utilize VK_EXT_provoking_vertex when available to set the provoking vertex to be the - // last vertex - vk::PipelineRasterizationProvokingVertexStateCreateInfoEXT provokingVertexInfo{}; - if (GetContext()->hasProvokingVertex()) - { - provokingVertexInfo.provokingVertexMode = vk::ProvokingVertexModeEXT::eLastVertex; - pipelineRasterizationStateCreateInfo.pNext = &provokingVertexInfo; - } - vk::PipelineMultisampleStateCreateInfo pipelineMultisampleStateCreateInfo; // Depth and stencil