From b66f6ce6732aa245983b18e785df6395e4cf04f5 Mon Sep 17 00:00:00 2001 From: sunshineinabox Date: Tue, 23 Jul 2024 20:58:47 -0700 Subject: [PATCH] Resolve some validation errors --- src/Ryujinx.Graphics.Vulkan/PipelineBase.cs | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs b/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs index 4a98a456d..eed18c6dd 100644 --- a/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs +++ b/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs @@ -880,10 +880,7 @@ namespace Ryujinx.Graphics.Vulkan if (_supportExtDynamic) { DynamicState.SetDepthTestBool(depthTest.TestEnable, depthTest.WriteEnable); - if (depthTest.TestEnable) - { - DynamicState.SetDepthTestCompareOp(depthTest.Func.Convert()); - } + DynamicState.SetDepthTestCompareOp(depthTest.TestEnable ? depthTest.Func.Convert() : default); } else { @@ -975,13 +972,13 @@ namespace Ryujinx.Graphics.Vulkan _newState.LogicOpEnable = logicOpEnable; - if (Gd.ExtendedDynamicState2Features.ExtendedDynamicState2LogicOp && logicOpEnable) + if (Gd.ExtendedDynamicState2Features.ExtendedDynamicState2LogicOp) { - DynamicState.SetLogicOp(op.Convert()); + DynamicState.SetLogicOp(logicOpEnable ? op.Convert() : default); } - else if (logicOpEnable) + else { - _newState.LogicOp = op.Convert(); + _newState.LogicOp = logicOpEnable ? op.Convert() : default; } SignalStateChange();