DispatchComputeCommand.cs
1 namespace Ryujinx.Graphics.GAL.Multithreading.Commands 2 { 3 struct DispatchComputeCommand : IGALCommand, IGALCommand<DispatchComputeCommand> 4 { 5 public readonly CommandType CommandType => CommandType.DispatchCompute; 6 private int _groupsX; 7 private int _groupsY; 8 private int _groupsZ; 9 10 public void Set(int groupsX, int groupsY, int groupsZ) 11 { 12 _groupsX = groupsX; 13 _groupsY = groupsY; 14 _groupsZ = groupsZ; 15 } 16 17 public static void Run(ref DispatchComputeCommand command, ThreadedRenderer threaded, IRenderer renderer) 18 { 19 renderer.Pipeline.DispatchCompute(command._groupsX, command._groupsY, command._groupsZ); 20 } 21 } 22 }