// ------------------------------------------------------------------------------
//
// This code was generated by a tool.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
//
// ------------------------------------------------------------------------------
namespace Win32.Graphics.DirectComposition;
///
/// IDCompositionVirtualSurface
[Guid("ae471c51-5f53-4a24-8d3e-d0c39c30b3f0")]
[NativeTypeName("struct IDCompositionVirtualSurface : IDCompositionSurface")]
[NativeInheritance("IDCompositionSurface")]
public unsafe partial struct IDCompositionVirtualSurface : IDCompositionVirtualSurface.Interface, INativeGuid
{
public static ref readonly Guid IID_IDCompositionVirtualSurface
{
[MethodImpl(MethodImplOptions.AggressiveInlining)]
get
{
ReadOnlySpan data = new byte[] {
0x51, 0x1C, 0x47, 0xAE,
0x53, 0x5F,
0x24, 0x4A,
0x8D,
0x3E,
0xD0,
0xC3,
0x9C,
0x30,
0xB3,
0xF0
};
Debug.Assert(data.Length == Unsafe.SizeOf());
return ref Unsafe.As(ref MemoryMarshal.GetReference(data));
}
}
#if NET6_0_OR_GREATER
static Guid* INativeGuid.NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_IDCompositionVirtualSurface));
#else
public static Guid* NativeGuid => (Guid*)Unsafe.AsPointer(ref Unsafe.AsRef(in IID_IDCompositionVirtualSurface));
#endif
public void** lpVtbl;
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(0)]
public HResult QueryInterface([NativeTypeName("const IID &")] Guid* riid, void** ppvObject)
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[0]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this), riid, ppvObject);
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(1)]
[return: NativeTypeName("ULONG")]
public uint AddRef()
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[1]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this));
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(2)]
[return: NativeTypeName("ULONG")]
public uint Release()
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[2]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this));
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(3)]
public HResult BeginDraw(RawRect* updateRect, Guid* iid, void** updateObject, System.Drawing.Point* updateOffset)
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[3]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this), updateRect, iid, updateObject, updateOffset);
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(4)]
public HResult EndDraw()
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[4]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this));
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(5)]
public HResult SuspendDraw()
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[5]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this));
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(6)]
public HResult ResumeDraw()
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[6]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this));
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(7)]
public HResult Scroll(RawRect* scrollRect, RawRect* clipRect, int offsetX, int offsetY)
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[7]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this), scrollRect, clipRect, offsetX, offsetY);
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(8)]
public HResult Resize(uint width, uint height)
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[8]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this), width, height);
}
///
[MethodImpl(MethodImplOptions.AggressiveInlining)]
[VtblIndex(9)]
public HResult Trim(RawRect* rectangles, uint count)
{
return ((delegate* unmanaged[Stdcall])(lpVtbl[9]))((IDCompositionVirtualSurface*)Unsafe.AsPointer(ref this), rectangles, count);
}
public interface Interface : IDCompositionSurface.Interface
{
[VtblIndex(8)]
HResult Resize(uint width, uint height);
[VtblIndex(9)]
HResult Trim(RawRect* rectangles, uint count);
}
}