aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMarco Carvalho <marcolucio27@gmail.com>2023-08-16 18:24:44 -0300
committerGitHub <noreply@github.com>2023-08-16 23:24:44 +0200
commit64079c034c1c3a18133542d6ac745490149d8043 (patch)
treefd7aef08b6992d143ed287a67812758c895cdfe0 /src
parent17354d59d14680258186168c1c462654665ee8c7 (diff)
Prefer jagged arrays over multidimensional (#5562)1.1.994
* fix CA1814 * Update .editorconfig removing .editorconfig rule
Diffstat (limited to 'src')
-rw-r--r--src/Ryujinx.Graphics.Shader/Instructions/InstEmitTexture.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Ryujinx.Graphics.Shader/Instructions/InstEmitTexture.cs b/src/Ryujinx.Graphics.Shader/Instructions/InstEmitTexture.cs
index 1b2673ab..bbac8038 100644
--- a/src/Ryujinx.Graphics.Shader/Instructions/InstEmitTexture.cs
+++ b/src/Ryujinx.Graphics.Shader/Instructions/InstEmitTexture.cs
@@ -10,10 +10,10 @@ namespace Ryujinx.Graphics.Shader.Instructions
{
static partial class InstEmit
{
- private static readonly int[,] _maskLut = new int[,]
+ private static readonly int[][] _maskLut = new int[][]
{
- { 0b0001, 0b0010, 0b0100, 0b1000, 0b0011, 0b1001, 0b1010, 0b1100 },
- { 0b0111, 0b1011, 0b1101, 0b1110, 0b1111, 0b0000, 0b0000, 0b0000 },
+ new int[] { 0b0001, 0b0010, 0b0100, 0b1000, 0b0011, 0b1001, 0b1010, 0b1100 },
+ new int[] { 0b0111, 0b1011, 0b1101, 0b1110, 0b1111, 0b0000, 0b0000, 0b0000 },
};
public const bool Sample1DAs2D = true;
@@ -605,7 +605,7 @@ namespace Ryujinx.Graphics.Shader.Instructions
Operand[] rd1 = new Operand[2] { ConstF(0), ConstF(0) };
int handle = imm;
- int componentMask = _maskLut[dest2 == RegisterConsts.RegisterZeroIndex ? 0 : 1, writeMask];
+ int componentMask = _maskLut[dest2 == RegisterConsts.RegisterZeroIndex ? 0 : 1][writeMask];
int componentsCount = BitOperations.PopCount((uint)componentMask);