From 17334b21313ce6f86cedf49f60761e5c555b46f0 Mon Sep 17 00:00:00 2001 From: Samuliak Date: Fri, 24 May 2024 17:59:49 +0200 Subject: [PATCH] remove useless parameters --- src/Ryujinx.Graphics.Metal/HelperShader.cs | 3 --- src/Ryujinx.Graphics.Metal/Pipeline.cs | 8 ++------ 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/src/Ryujinx.Graphics.Metal/HelperShader.cs b/src/Ryujinx.Graphics.Metal/HelperShader.cs index 2405e8066..d26aa345e 100644 --- a/src/Ryujinx.Graphics.Metal/HelperShader.cs +++ b/src/Ryujinx.Graphics.Metal/HelperShader.cs @@ -83,7 +83,6 @@ namespace Ryujinx.Graphics.Metal } public unsafe void ClearColor( - Texture dst, int index, ReadOnlySpan clearColor) { @@ -108,7 +107,6 @@ namespace Ryujinx.Graphics.Metal _pipeline.SetUniformBuffers([new BufferAssignment(0, range)]); _pipeline.SetProgram(_programsColorClear[index]); - _pipeline.SetRenderTargets([dst], null); // _pipeline.SetRenderTargetColorMasks([componentMask]); _pipeline.SetPrimitiveTopology(PrimitiveTopology.TriangleStrip); _pipeline.Draw(4, 1, 0, 0); @@ -118,7 +116,6 @@ namespace Ryujinx.Graphics.Metal } public unsafe void ClearDepthStencil( - Texture dst, ReadOnlySpan depthValue, bool depthMask, int stencilValue, diff --git a/src/Ryujinx.Graphics.Metal/Pipeline.cs b/src/Ryujinx.Graphics.Metal/Pipeline.cs index 2f11de985..a53d7cc1e 100644 --- a/src/Ryujinx.Graphics.Metal/Pipeline.cs +++ b/src/Ryujinx.Graphics.Metal/Pipeline.cs @@ -214,16 +214,12 @@ namespace Ryujinx.Graphics.Metal { float[] colors = [color.Red, color.Green, color.Blue, color.Alpha]; - Texture target = _encoderStateManager.RenderTargets[index]; - - _helperShader.ClearColor(target, index, colors); + _helperShader.ClearColor(index, colors); } public void ClearRenderTargetDepthStencil(int layer, int layerCount, float depthValue, bool depthMask, int stencilValue, int stencilMask) { - Texture target = _encoderStateManager.DepthStencil; - - _helperShader.ClearDepthStencil(target, [depthValue], depthMask, stencilValue, stencilMask); + _helperShader.ClearDepthStencil([depthValue], depthMask, stencilValue, stencilMask); } public void CommandBufferBarrier()