DrawCommand.cs
 1  namespace Ryujinx.Graphics.GAL.Multithreading.Commands
 2  {
 3      struct DrawIndexedCommand : IGALCommand, IGALCommand<DrawIndexedCommand>
 4      {
 5          public readonly CommandType CommandType => CommandType.DrawIndexed;
 6          private int _indexCount;
 7          private int _instanceCount;
 8          private int _firstIndex;
 9          private int _firstVertex;
10          private int _firstInstance;
11  
12          public void Set(int indexCount, int instanceCount, int firstIndex, int firstVertex, int firstInstance)
13          {
14              _indexCount = indexCount;
15              _instanceCount = instanceCount;
16              _firstIndex = firstIndex;
17              _firstVertex = firstVertex;
18              _firstInstance = firstInstance;
19          }
20  
21          public static void Run(ref DrawIndexedCommand command, ThreadedRenderer threaded, IRenderer renderer)
22          {
23              renderer.Pipeline.DrawIndexed(command._indexCount, command._instanceCount, command._firstIndex, command._firstVertex, command._firstInstance);
24          }
25      }
26  }