ShaderState.cs 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. namespace Ryujinx.Graphics.Gpu.State
  2. {
  3. /// <summary>
  4. /// Graphics shader stage state.
  5. /// </summary>
  6. struct ShaderState
  7. {
  8. #pragma warning disable CS0649
  9. public uint Control;
  10. public uint Offset;
  11. public uint Unknown0x8;
  12. public int MaxRegisters;
  13. public ShaderType Type;
  14. public uint Unknown0x14;
  15. public uint Unknown0x18;
  16. public uint Unknown0x1c;
  17. public uint Unknown0x20;
  18. public uint Unknown0x24;
  19. public uint Unknown0x28;
  20. public uint Unknown0x2c;
  21. public uint Unknown0x30;
  22. public uint Unknown0x34;
  23. public uint Unknown0x38;
  24. public uint Unknown0x3c;
  25. #pragma warning restore CS0649
  26. /// <summary>
  27. /// Unpacks shader enable information.
  28. /// Must be ignored for vertex shaders, those are always enabled.
  29. /// </summary>
  30. /// <returns>True if the stage is enabled, false otherwise</returns>
  31. public bool UnpackEnable()
  32. {
  33. return (Control & 1) != 0;
  34. }
  35. }
  36. }