// ------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
// ------------------------------------------------------------------------------

namespace Win32.Media.Audio.XAudio2;

/// <include file='../XAudio2.xml' path='doc/member[@name="IXAPOParameters"]/*' />
/// <unmanaged>IXAPOParameters</unmanaged>
[Guid("26d95c66-80f2-499a-ad54-5ae7f01c6d98")]
[NativeTypeName("struct IXAPOParameters : IUnknown")]
[NativeInheritance("IUnknown")]
public unsafe partial struct IXAPOParameters : IXAPOParameters.Interface, INativeGuid
{
	public static ref readonly Guid IID_IXAPOParameters
	{
		[MethodImpl(MethodImplOptions.AggressiveInlining)]
		get
		{
			ReadOnlySpan<byte> data = new byte[] {
				0x66, 0x5C, 0xD9, 0x26,
				0xF2, 0x80,
				0x9A, 0x49,
				0xAD,
				0x54,
				0x5A,
				0xE7,
				0xF0,
				0x1C,
				0x6D,
				0x98
			};

			Debug.Assert(data.Length == Unsafe.SizeOf<Guid>());
			return ref Unsafe.As<byte, Guid>(ref MemoryMarshal.GetReference(data));
		}
	}

	static Guid* INativeGuid.NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_IXAPOParameters));

	public void** lpVtbl;

	/// <inheritdoc cref="IUnknown.QueryInterface" />
	[MethodImpl(MethodImplOptions.AggressiveInlining)]
	[VtblIndex(0)]
	public HResult QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject)
	{
		return ((delegate* unmanaged[MemberFunction]<IXAPOParameters*, Guid*, void**, int>)(lpVtbl[0]))((IXAPOParameters*)Unsafe.AsPointer(ref this), riid, ppvObject);
	}

	/// <inheritdoc cref="IUnknown.AddRef" />
	[MethodImpl(MethodImplOptions.AggressiveInlining)]
	[VtblIndex(1)]
	[return: NativeTypeName("ULONG")]
	public uint AddRef()
	{
		return ((delegate* unmanaged[MemberFunction]<IXAPOParameters*, uint>)(lpVtbl[1]))((IXAPOParameters*)Unsafe.AsPointer(ref this));
	}

	/// <inheritdoc cref="IUnknown.Release" />
	[MethodImpl(MethodImplOptions.AggressiveInlining)]
	[VtblIndex(2)]
	[return: NativeTypeName("ULONG")]
	public uint Release()
	{
		return ((delegate* unmanaged[MemberFunction]<IXAPOParameters*, uint>)(lpVtbl[2]))((IXAPOParameters*)Unsafe.AsPointer(ref this));
	}

	/// <include file='../XAudio2.xml' path='doc/member[@name="IXAPOParameters::SetParameters"]/*' />
	[MethodImpl(MethodImplOptions.AggressiveInlining)]
	[VtblIndex(3)]
	public void SetParameters(void* pParameters, uint ParameterByteSize)
	{
		((delegate* unmanaged[MemberFunction]<IXAPOParameters*, void*, uint, void>)(lpVtbl[3]))((IXAPOParameters*)Unsafe.AsPointer(ref this), pParameters, ParameterByteSize);
	}

	/// <include file='../XAudio2.xml' path='doc/member[@name="IXAPOParameters::GetParameters"]/*' />
	[MethodImpl(MethodImplOptions.AggressiveInlining)]
	[VtblIndex(4)]
	public void GetParameters(void* pParameters, uint ParameterByteSize)
	{
		((delegate* unmanaged[MemberFunction]<IXAPOParameters*, void*, uint, void>)(lpVtbl[4]))((IXAPOParameters*)Unsafe.AsPointer(ref this), pParameters, ParameterByteSize);
	}

	public interface Interface : IUnknown.Interface
	{
		[VtblIndex(3)]
		void SetParameters(void* pParameters, uint ParameterByteSize);

		[VtblIndex(4)]
		void GetParameters(void* pParameters, uint ParameterByteSize);
	}
}

