UpdateDataHeader.cs 964 B

123456789101112131415161718192021222324252627282930313233
  1. using System.Runtime.CompilerServices;
  2. namespace Ryujinx.Audio.Renderer.Common
  3. {
  4. /// <summary>
  5. /// Update data header used for input and output of <see cref="Server.AudioRenderSystem.Update(System.Memory{byte}, System.Memory{byte}, System.ReadOnlyMemory{byte})"/>.
  6. /// </summary>
  7. public struct UpdateDataHeader
  8. {
  9. public int Revision;
  10. public uint BehaviourSize;
  11. public uint MemoryPoolsSize;
  12. public uint VoicesSize;
  13. public uint VoiceResourcesSize;
  14. public uint EffectsSize;
  15. public uint MixesSize;
  16. public uint SinksSize;
  17. public uint PerformanceBufferSize;
  18. public uint Unknown24;
  19. public uint RenderInfoSize;
  20. private unsafe fixed int _reserved[4];
  21. public uint TotalSize;
  22. public void Initialize(int revision)
  23. {
  24. Revision = revision;
  25. TotalSize = (uint)Unsafe.SizeOf<UpdateDataHeader>();
  26. }
  27. }
  28. }