Dirty Arg Buffers on Program Change

This commit is contained in:
Isaac Marovitz 2024-07-02 12:00:37 +01:00 committed by Isaac Marovitz
parent de5bf3a141
commit ab79959975
2 changed files with 6 additions and 4 deletions

View file

@ -27,8 +27,10 @@ namespace Ryujinx.Graphics.Metal
Textures = 1 << 12, Textures = 1 << 12,
Images = 1 << 13, Images = 1 << 13,
RenderAll = RenderPipeline | DepthStencil | DepthClamp | DepthBias | CullMode | FrontFace | StencilRef | Viewports | Scissors | Uniforms | Storages | Textures | Images, ArgBuffers = Uniforms | Storages | Textures | Images,
ComputeAll = ComputePipeline | Uniforms | Storages | Textures | Images,
RenderAll = RenderPipeline | DepthStencil | DepthClamp | DepthBias | CullMode | FrontFace | StencilRef | Viewports | Scissors | ArgBuffers,
ComputeAll = ComputePipeline | ArgBuffers,
All = RenderAll | ComputeAll, All = RenderAll | ComputeAll,
} }

View file

@ -346,13 +346,13 @@ namespace Ryujinx.Graphics.Metal
{ {
_currentState.RenderProgram = prg; _currentState.RenderProgram = prg;
_currentState.Dirty |= DirtyFlags.RenderPipeline; _currentState.Dirty |= DirtyFlags.RenderPipeline | DirtyFlags.ArgBuffers;
} }
else if (prg.ComputeFunction != IntPtr.Zero) else if (prg.ComputeFunction != IntPtr.Zero)
{ {
_currentState.ComputeProgram = prg; _currentState.ComputeProgram = prg;
_currentState.Dirty |= DirtyFlags.ComputePipeline; _currentState.Dirty |= DirtyFlags.ComputePipeline | DirtyFlags.ArgBuffers;
} }
} }