DrawState.cs 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. using Ryujinx.Graphics.GAL;
  2. namespace Ryujinx.Graphics.Gpu.Engine.Threed
  3. {
  4. /// <summary>
  5. /// Draw state.
  6. /// </summary>
  7. class DrawState
  8. {
  9. /// <summary>
  10. /// First index to be used for the draw on the index buffer.
  11. /// </summary>
  12. public int FirstIndex;
  13. /// <summary>
  14. /// Number of indices to be used for the draw on the index buffer.
  15. /// </summary>
  16. public int IndexCount;
  17. /// <summary>
  18. /// Indicates if the next draw will be a indexed draw.
  19. /// </summary>
  20. public bool DrawIndexed;
  21. /// <summary>
  22. /// Indicates if the next draw will be a indirect draw.
  23. /// </summary>
  24. public bool DrawIndirect;
  25. /// <summary>
  26. /// Indicates if any of the currently used vertex shaders reads the instance ID.
  27. /// </summary>
  28. public bool VsUsesInstanceId;
  29. /// <summary>
  30. /// Indicates if any of the currently used vertex buffers is instanced.
  31. /// </summary>
  32. public bool IsAnyVbInstanced;
  33. /// <summary>
  34. /// Indicates that the draw is writing the base vertex, base instance and draw index to Constant Buffer 0.
  35. /// </summary>
  36. public bool HasConstantBufferDrawParameters;
  37. /// <summary>
  38. /// Primitive topology for the next draw.
  39. /// </summary>
  40. public PrimitiveTopology Topology;
  41. /// <summary>
  42. /// Index buffer data streamer for inline index buffer updates, such as those used in legacy OpenGL.
  43. /// </summary>
  44. public IbStreamer IbStreamer = new IbStreamer();
  45. }
  46. }