diff --git a/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs b/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs index 4b9d32ee9..fff6cf05e 100644 --- a/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs +++ b/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs @@ -909,7 +909,7 @@ namespace Ryujinx.Graphics.Vulkan oldMode = _newState.DepthMode; _newState.DepthMode = mode == DepthMode.MinusOneToOne; } - + if ((Gd.ExtendedDynamicState3Features.ExtendedDynamicState3DepthClipNegativeOneToOne ? DynamicState.DepthMode : _newState.DepthMode) != oldMode) { SignalStateChange(); diff --git a/src/Ryujinx.Graphics.Vulkan/PipelineDynamicState.cs b/src/Ryujinx.Graphics.Vulkan/PipelineDynamicState.cs index 9126771a0..bc9939d6c 100644 --- a/src/Ryujinx.Graphics.Vulkan/PipelineDynamicState.cs +++ b/src/Ryujinx.Graphics.Vulkan/PipelineDynamicState.cs @@ -318,7 +318,7 @@ namespace Ryujinx.Graphics.Vulkan _dirty |= DirtyFlags.AlphaToOne; } } - + public void SetDepthMode(bool mode) { if (DepthMode != mode) @@ -381,7 +381,7 @@ namespace Ryujinx.Graphics.Vulkan { _dirty &= ~DirtyFlags.LogicOpEnable; } - + if (!gd.ExtendedDynamicState3Features.ExtendedDynamicState3DepthClipNegativeOneToOne) { _dirty &= ~DirtyFlags.DepthMode; @@ -479,7 +479,7 @@ namespace Ryujinx.Graphics.Vulkan { RecordAlphaToOneEnable(gd, commandBuffer); } - + if (_dirty.HasFlag(DirtyFlags.DepthMode)) { RecordDepthMode(gd, commandBuffer); @@ -630,7 +630,7 @@ namespace Ryujinx.Graphics.Vulkan { gd.ExtendedDynamicState2Api.CmdSetPatchControlPoints(commandBuffer, _patchControlPoints); } - + private readonly void RecordDepthMode(VulkanRenderer gd, CommandBuffer commandBuffer) { gd.ExtendedDynamicState3Api.CmdSetDepthClipNegativeOneToOne(commandBuffer, DepthMode);