diff --git a/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs b/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs index 9a46cb943e..a302f730f5 100644 --- a/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs +++ b/src/Ryujinx.Graphics.Vulkan/PipelineBase.cs @@ -1721,6 +1721,11 @@ namespace Ryujinx.Graphics.Vulkan [MethodImpl(MethodImplOptions.AggressiveInlining)] private bool UpdateFeedbackLoop() { + if (!Gd.Capabilities.SupportsAttachmentFeedbackLoop) + { + return false; + } + List hazards = _descriptorSetUpdater.FeedbackLoopHazards; if ((hazards?.Count ?? 0) > 0) @@ -1765,7 +1770,7 @@ namespace Ryujinx.Graphics.Vulkan } // Stencil test being enabled doesn't necessarily mean a write, but it's not critical to check. - _passWritesDepthStencil |= (_newState.DepthTestEnable && _newState.DepthWriteEnable) || _newState.StencilTestEnable; + _passWritesDepthStencil |= _supportExtDynamic ? (DynamicState.DepthTestEnable && DynamicState.DepthWriteEnable) || _newState.StencilTestEnable : (_newState.DepthTestEnable && _newState.DepthWriteEnable) || _newState.StencilTestEnable; } private bool RecreateGraphicsPipelineIfNeeded() diff --git a/src/Ryujinx.Graphics.Vulkan/PipelineConverter.cs b/src/Ryujinx.Graphics.Vulkan/PipelineConverter.cs index 822838f005..36bd1ff455 100644 --- a/src/Ryujinx.Graphics.Vulkan/PipelineConverter.cs +++ b/src/Ryujinx.Graphics.Vulkan/PipelineConverter.cs @@ -166,6 +166,8 @@ namespace Ryujinx.Graphics.Vulkan pipeline.DepthClampEnable = state.DepthClampEnable; + pipeline.FeedbackLoopAspects = FeedbackLoopAspects.None; + pipeline.DepthMode = state.DepthMode == DepthMode.MinusOneToOne; pipeline.HasDepthStencil = state.DepthStencilEnable; diff --git a/src/Ryujinx.Graphics.Vulkan/PipelineState.cs b/src/Ryujinx.Graphics.Vulkan/PipelineState.cs index facb221abe..f447d0f20e 100644 --- a/src/Ryujinx.Graphics.Vulkan/PipelineState.cs +++ b/src/Ryujinx.Graphics.Vulkan/PipelineState.cs @@ -273,6 +273,8 @@ namespace Ryujinx.Graphics.Vulkan PolygonMode = PolygonMode.Fill; DepthBoundsTestEnable = false; + FeedbackLoopAspects = FeedbackLoopAspects.None; + _supportsExtDynamicState = supportsExtDynamicState; _supportsExtDynamicState2 = extendedDynamicState2;