Переглянути джерело

Fix NRE on gather operations with depth compare on macOS (#5832)

gdkchan 2 роки тому
батько
коміт
33ba170315

+ 4 - 1
src/Ryujinx.Graphics.Shader/Instructions/InstEmitTexture.cs

@@ -766,7 +766,10 @@ namespace Ryujinx.Graphics.Shader.Instructions
                 flags |= offset == TexOffset.Ptp ? TextureFlags.Offsets : TextureFlags.Offset;
             }
 
-            sourcesList.Add(Const((int)component));
+            if (!hasDepthCompare)
+            {
+                sourcesList.Add(Const((int)component));
+            }
 
             Operand[] sources = sourcesList.ToArray();
             Operand[] dests = new Operand[BitOperations.PopCount((uint)componentMask)];