From 1e8f7d7fcb10e99ffda78de391326263f24ffca3 Mon Sep 17 00:00:00 2001 From: Billy Laws Date: Sat, 3 Sep 2022 22:08:03 +0100 Subject: [PATCH] Implement dynamic pipeline state --- .../interconnect/maxwell_3d/pipeline_state.cpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/pipeline_state.cpp b/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/pipeline_state.cpp index 071c65e9..b7d2fd2e 100644 --- a/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/pipeline_state.cpp +++ b/app/src/main/cpp/skyline/gpu/interconnect/maxwell_3d/pipeline_state.cpp @@ -847,6 +847,23 @@ namespace skyline::gpu::interconnect::maxwell3d { }; const auto &depthStencilState{depthStencil.UpdateGet().depthStencilState}; const auto &colorBlendState{colorBlend.UpdateGet(ctx, colorAttachments.size()).colorBlendState}; + + constexpr std::array dynamicStates{ + vk::DynamicState::eViewport, + vk::DynamicState::eScissor, + vk::DynamicState::eLineWidth, + vk::DynamicState::eDepthBias, + vk::DynamicState::eBlendConstants, + vk::DynamicState::eDepthBounds, + vk::DynamicState::eStencilCompareMask, + vk::DynamicState::eStencilWriteMask, + vk::DynamicState::eStencilReference + }; + + vk::PipelineDynamicStateCreateInfo dynamicState{ + .dynamicStateCount = static_cast(dynamicStates.size()), + .pDynamicStates = dynamicStates.data() + }; } std::shared_ptr PipelineState::GetColorRenderTargetForClear(InterconnectContext &ctx, size_t index) {