module external.directx.dxgiddi;

/*-------------------------------------------------------------------------------------
 *
 * Copyright (c) Microsoft Corporation
 *
 *-------------------------------------------------------------------------------------*/

// DXGI Basic Device Driver Interface Definitions Header translation from dxgiddi.h
// Latest update: Windows 10, version 1809

import std.bitmanip : bitfields;
import external.directx.dxgicommon;
import external.directx.dxgi;
import external.directx.d3dukmdt;

enum _FACDXGI_DDI = 0x87b;

pure nothrow @safe @nogc
{
    HRESULT MAKE_DXGI_DDI_HRESULT(uint code)
    {
        return MAKE_HRESULT(1, _FACDXGI_DDI, code);
    }

    HRESULT MAKE_DXGI_DDI_STATUS(uint code)
    {
        return MAKE_HRESULT(0, _FACDXGI_DDI, code);
    }
}

alias DXGI_DDI_HDEVICE = UINT_PTR;
alias DXGI_DDI_HRESOURCE = UINT_PTR;

alias DXGI_DDI_RESIDENCY = uint;
enum : DXGI_DDI_RESIDENCY
{
    DXGI_DDI_RESIDENCY_FULLY_RESIDENT = 1,
    DXGI_DDI_RESIDENCY_RESIDENT_IN_SHARED_MEMORY = 2,
    DXGI_DDI_RESIDENCY_EVICTED_TO_DISK = 3,
}

alias DXGI_DDI_FLIP_INTERVAL_TYPE = uint;
enum : DXGI_DDI_FLIP_INTERVAL_TYPE
{
    DXGI_DDI_FLIP_INTERVAL_IMMEDIATE = 0,
    DXGI_DDI_FLIP_INTERVAL_ONE = 1,
    DXGI_DDI_FLIP_INTERVAL_TWO = 2,
    DXGI_DDI_FLIP_INTERVAL_THREE = 3,
    DXGI_DDI_FLIP_INTERVAL_FOUR = 4,
    // For the sync interval override in the present callbacks, IMMEDIATE means the API semantic of sync interval 0, where IMMEDIATE_ALLOW_TEARING is equivalent to the addition of the ALLOW_TEARING API flags.
    DXGI_DDI_FLIP_INTERVAL_IMMEDIATE_ALLOW_TEARING = 5,
}

struct DXGI_DDI_PRESENT_FLAGS
{
    union
    {
        mixin(bitfields!(uint, "Blt", 1, uint, "Flip", 1, uint, "PreferRight", 1, uint, "TemporaryMono", 1, uint, "AllowTearing", 1, uint, "AllowFlexibleRefresh", 1, uint, "Reserved", 26));
        uint Value;
    }
}

struct DXGI_DDI_ARG_PRESENT
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_DDI_HRESOURCE hSurfaceToPresent; //in
    uint SrcSubResourceIndex; // Index of surface level
    DXGI_DDI_HRESOURCE hDstResource; // if non-zero, it's the destination of the present
    uint DstSubResourceIndex; // Index of surface level
    void* pDXGIContext; // opaque: Pass this to the Present callback
    DXGI_DDI_PRESENT_FLAGS Flags; // Presentation flags.
    DXGI_DDI_FLIP_INTERVAL_TYPE FlipInterval; // Presentation interval (flip only)
}

struct DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES
{
    DXGI_DDI_HDEVICE hDevice; //in
    const DXGI_DDI_HRESOURCE* pResources; //in: Array of Resources to rotate identities; 0 <= 1, 1 <= 2, etc.
    uint Resources;
}

struct DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_GAMMA_CONTROL_CAPABILITIES* pGammaCapabilities; //in/out
}

struct DXGI_DDI_ARG_SET_GAMMA_CONTROL
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_GAMMA_CONTROL GammaControl; //in
}

struct DXGI_DDI_ARG_SETDISPLAYMODE
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_DDI_HRESOURCE hResource; // Source surface
    uint SubResourceIndex; // Index of surface level
}

struct DXGI_DDI_ARG_SETRESOURCEPRIORITY
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_DDI_HRESOURCE hResource; //in
    uint Priority; //in
}

struct DXGI_DDI_ARG_QUERYRESOURCERESIDENCY
{
    DXGI_DDI_HDEVICE hDevice; //in
    const DXGI_DDI_HRESOURCE* pResources; //in
    DXGI_DDI_RESIDENCY* pStatus; //out
    size_t Resources; //in
}

struct DXGI_DDI_RATIONAL
{
    uint Numerator;
    uint Denominator;
}

alias DXGI_DDI_MODE_SCANLINE_ORDER = uint;
enum : DXGI_DDI_MODE_SCANLINE_ORDER
{
    DXGI_DDI_MODE_SCANLINE_ORDER_UNSPECIFIED = 0,
    DXGI_DDI_MODE_SCANLINE_ORDER_PROGRESSIVE = 1,
    DXGI_DDI_MODE_SCANLINE_ORDER_UPPER_FIELD_FIRST = 2,
    DXGI_DDI_MODE_SCANLINE_ORDER_LOWER_FIELD_FIRST = 3,
}

alias DXGI_DDI_MODE_SCALING = uint;
enum : DXGI_DDI_MODE_SCALING
{
    DXGI_DDI_MODE_SCALING_UNSPECIFIED = 0,
    DXGI_DDI_MODE_SCALING_STRETCHED = 1,
    DXGI_DDI_MODE_SCALING_CENTERED = 2,
}

alias DXGI_DDI_MODE_ROTATION = uint;
enum : DXGI_DDI_MODE_ROTATION
{
    DXGI_DDI_MODE_ROTATION_UNSPECIFIED = 0,
    DXGI_DDI_MODE_ROTATION_IDENTITY = 1,
    DXGI_DDI_MODE_ROTATION_ROTATE90 = 2,
    DXGI_DDI_MODE_ROTATION_ROTATE180 = 3,
    DXGI_DDI_MODE_ROTATION_ROTATE270 = 4,
}

struct DXGI_DDI_MODE_DESC
{
    uint Width;
    uint Height;
    DXGI_FORMAT Format;
    DXGI_DDI_RATIONAL RefreshRate;
    DXGI_DDI_MODE_SCANLINE_ORDER ScanlineOrdering;
    DXGI_DDI_MODE_ROTATION Rotation;
    DXGI_DDI_MODE_SCALING Scaling;
}

enum DXGI_DDI_PRIMARY_OPTIONAL = 0x1;
enum DXGI_DDI_PRIMARY_NONPREROTATED = 0x2;
enum DXGI_DDI_PRIMARY_STEREO = 0x4;
enum DXGI_DDI_PRIMARY_INDIRECT = 0x8;
enum DXGI_DDI_PRIMARY_DRIVER_FLAG_NO_SCANOUT = 0x1;

struct DXGI_DDI_PRIMARY_DESC
{
    uint Flags; // [in]
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId; // [in]
    DXGI_DDI_MODE_DESC ModeDesc; // [in]
    uint DriverFlags; // [out] Filled by the driver
}

struct DXGI_DDI_ARG_BLT_FLAGS
{
    union
    {
        mixin(bitfields!(uint, "Resolve", 1, uint, "Convert", 1, uint, "Stretch", 1, uint, "Present", 1, uint, "Reserved", 28));
        uint Value;
    }
}

struct DXGI_DDI_ARG_BLT
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_DDI_HRESOURCE hDstResource; //in
    uint DstSubresource; //in
    uint DstLeft; //in
    uint DstTop; //in
    uint DstRight; //in
    uint DstBottom; //in
    DXGI_DDI_HRESOURCE hSrcResource; //in
    uint SrcSubresource; //in
    DXGI_DDI_ARG_BLT_FLAGS Flags; //in
    DXGI_DDI_MODE_ROTATION rotate; //in
}

struct DXGI_DDI_ARG_RESOLVESHAREDRESOURCE
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_DDI_HRESOURCE hResource; //in
}

struct DXGI_DDI_ARG_BLT1
{
    DXGI_DDI_HDEVICE hDevice; //in
    DXGI_DDI_HRESOURCE hDstResource; //in
    uint DstSubresource; //in
    uint DstLeft; //in
    uint DstTop; //in
    uint DstRight; //in
    uint DstBottom; //in
    DXGI_DDI_HRESOURCE hSrcResource; //in
    uint SrcSubresource; //in
    uint SrcLeft; //in
    uint SrcTop; //in
    uint SrcRight; //in
    uint SrcBottom; //in
    DXGI_DDI_ARG_BLT_FLAGS Flags; //in
    DXGI_DDI_MODE_ROTATION rotate; //in
}

struct DXGI_DDI_ARG_OFFERRESOURCES
{
    DXGI_DDI_HDEVICE hDevice; //in:  device that created the resources
    const DXGI_DDI_HRESOURCE* pResources; //in:  array of resources to reset
    uint Resources; //in:  number of elements in pResources
    D3DDDI_OFFER_PRIORITY Priority; //in:  priority with which to reset the resources
}

struct DXGI_DDI_ARG_RECLAIMRESOURCES
{
    DXGI_DDI_HDEVICE hDevice; //in:  device that created the resources
    const DXGI_DDI_HRESOURCE* pResources; //in:  array of resources to reset
    bool* pDiscarded; //out: optional array of booleans specifying whether each resource was discarded
    uint Resources; //in:  number of elements in pResources and pDiscarded
}

enum DXGI_DDI_MAX_MULTIPLANE_OVERLAY_ALLOCATIONS = 16;

struct DXGI_DDI_MULTIPLANE_OVERLAY_CAPS
{
    uint MaxPlanes; // Total number of planes supported (including the DWM's primary)
    uint NumCapabilityGroups; // Number of plane types supported.
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS
{
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_ROTATION_WITHOUT_INDEPENDENT_FLIP = 0x1,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_VERTICAL_FLIP = 0x2,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_HORIZONTAL_FLIP = 0x4,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_DEINTERLACE = 0x8,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_STEREO = 0x10, // D3D10 or above only.
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_RGB = 0x20,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_YUV = 0x40,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_BILINEAR_FILTER = 0x80, // Can do bilinear stretching
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_HIGH_FILTER = 0x100, // Can do better than bilinear stretching
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_ROTATION = 0x200,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_FULLSCREEN_POST_COMPOSITION = 0x400,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_RESERVED1 = 0x800,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_SHARED = 0x1000,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_IMMEDIATE = 0x2000,
    DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS_PLANE0_FOR_VIRTUAL_MODE_ONLY = 0x4000,
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS
{
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS_SEPARATE = 0x1,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS_ROW_INTERLEAVED = 0x4,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS_COLUMN_INTERLEAVED = 0x8,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS_CHECKERBOARD = 0x10,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS_FLIP_MODE = 0x20,
}

struct DXGI_DDI_MULTIPLANE_OVERLAY_GROUP_CAPS
{
    uint NumPlanes;
    float MaxStretchFactor;
    float MaxShrinkFactor;
    uint OverlayCaps; // DXGI_DDI_MULTIPLANE_OVERLAY_FEATURE_CAPS
    uint StereoCaps; // DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_CAPS
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_FLAGS = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_FLAGS
{
    DXGI_DDI_MULTIPLANE_OVERLAY_FLAG_VERTICAL_FLIP = 0x1,
    DXGI_DDI_MULTIPLANE_OVERLAY_FLAG_HORIZONTAL_FLIP = 0x2,
    DXGI_DDI_MULTIPLANE_OVERLAY_FLAG_FULLSCREEN_POST_COMPOSITION = 0x4
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_BLEND = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_BLEND
{
    DXGI_DDI_MULTIPLANE_OVERLAY_BLEND_OPAQUE = 0x0,
    DXGI_DDI_MULTIPLANE_OVERLAY_BLEND_ALPHABLEND = 0x1,
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_VIDEO_FRAME_FORMAT = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_VIDEO_FRAME_FORMAT
{
    DXGI_DDI_MULIIPLANE_OVERLAY_VIDEO_FRAME_FORMAT_PROGRESSIVE = 0,
    DXGI_DDI_MULTIPLANE_OVERLAY_VIDEO_FRAME_FORMAT_INTERLACED_TOP_FIELD_FIRST = 1,
    DXGI_DDI_MULTIPLANE_OVERLAY_VIDEO_FRAME_FORMAT_INTERLACED_BOTTOM_FIELD_FIRST = 2
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_YCbCr_FLAGS = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_YCbCr_FLAGS
{
    DXGI_DDI_MULTIPLANE_OVERLAY_YCbCr_FLAG_NOMINAL_RANGE = 0x1, // 16 - 235 vs. 0 - 255
    DXGI_DDI_MULTIPLANE_OVERLAY_YCbCr_FLAG_BT709 = 0x2, // BT.709 vs. BT.601
    DXGI_DDI_MULTIPLANE_OVERLAY_YCbCr_FLAG_xvYCC = 0x4, // xvYCC vs. conventional YCbCr
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT
{
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_MONO = 0,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_HORIZONTAL = 1,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_VERTICAL = 2,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_SEPARATE = 3,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_MONO_OFFSET = 4,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_ROW_INTERLEAVED = 5,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_COLUMN_INTERLEAVED = 6,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT_CHECKERBOARD = 7
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_MODE = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_MODE
{
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_NONE = 0,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_FRAME0 = 1,
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_FRAME1 = 2,
}

alias DXGI_DDI_MULTIPLANE_OVERLAY_STRETCH_QUALITY = uint;
enum : DXGI_DDI_MULTIPLANE_OVERLAY_STRETCH_QUALITY
{
    DXGI_DDI_MULTIPLANE_OVERLAY_STRETCH_QUALITY_BILINEAR = 0x1, // Bilinear
    DXGI_DDI_MULTIPLANE_OVERLAY_STRETCH_QUALITY_HIGH = 0x2, // Maximum
}

struct DXGI_DDI_MULTIPLANE_OVERLAY_ATTRIBUTES
{
    uint Flags; // DXGI_DDI_MULTIPLANE_OVERLAY_FLAGS
    RECT SrcRect;
    RECT DstRect;

    RECT ClipRect;

    DXGI_DDI_MODE_ROTATION Rotation;
    DXGI_DDI_MULTIPLANE_OVERLAY_BLEND Blend;

    uint DirtyRectCount;
    RECT* pDirtyRects;

    uint NumFilters;
    void* pFilters;

    DXGI_DDI_MULTIPLANE_OVERLAY_VIDEO_FRAME_FORMAT VideoFrameFormat;
    uint YCbCrFlags; // DXGI_DDI_MULTIPLANE_OVERLAY_YCbCr_FLAGS
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT StereoFormat;
    bool StereoLeftViewFrame0;
    bool StereoBaseViewFrame0;
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_MODE StereoFlipMode;

    DXGI_DDI_MULTIPLANE_OVERLAY_STRETCH_QUALITY StretchQuality;

}

struct DXGI_DDI_ARG_GETMULTIPLANEOVERLAYCAPS
{
    DXGI_DDI_HDEVICE hDevice;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    DXGI_DDI_MULTIPLANE_OVERLAY_CAPS MultiplaneOverlayCaps;
}

struct DXGI_DDI_ARG_GETMULTIPLANEOVERLAYGROUPCAPS
{
    DXGI_DDI_HDEVICE hDevice;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    uint GroupIndex;
    DXGI_DDI_MULTIPLANE_OVERLAY_GROUP_CAPS MultiplaneOverlayGroupCaps;
}

struct DXGI_DDI_CHECK_MULTIPLANE_OVERLAY_SUPPORT_PLANE_INFO
{
    DXGI_DDI_HRESOURCE hResource;
    uint SubResourceIndex;
    DXGI_DDI_MULTIPLANE_OVERLAY_ATTRIBUTES PlaneAttributes;
}

struct DXGI_DDI_ARG_CHECKMULTIPLANEOVERLAYSUPPORT
{
    DXGI_DDI_HDEVICE hDevice;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    uint NumPlaneInfo;
    DXGI_DDI_CHECK_MULTIPLANE_OVERLAY_SUPPORT_PLANE_INFO* pPlaneInfo;
    bool Supported; // out: driver to fill TRUE/FALSE
}

struct DXGI_DDI_PRESENT_MULTIPLANE_OVERLAY
{
    uint LayerIndex;
    bool Enabled;
    DXGI_DDI_HRESOURCE hResource;
    uint SubResourceIndex;
    DXGI_DDI_MULTIPLANE_OVERLAY_ATTRIBUTES PlaneAttributes;
}

struct DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY
{
    DXGI_DDI_HDEVICE hDevice;
    void* pDXGIContext;

    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    DXGI_DDI_PRESENT_FLAGS Flags;
    DXGI_DDI_FLIP_INTERVAL_TYPE FlipInterval;

    uint PresentPlaneCount;
    DXGI_DDI_PRESENT_MULTIPLANE_OVERLAY* pPresentPlanes;
    uint Reserved;
}

struct DXGI_DDI_ARG_CHECKPRESENTDURATIONSUPPORT
{
    DXGI_DDI_HDEVICE hDevice;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    uint DesiredPresentDuration;
    uint ClosestSmallerDuration; // out
    uint ClosestLargerDuration; //out
}

struct DXGI_DDI_ARG_PRESENTSURFACE
{
    DXGI_DDI_HRESOURCE hSurface; // In
    uint SubResourceIndex; // Index of surface level
}

struct DXGI_DDI_ARG_PRESENT1
{
    DXGI_DDI_HDEVICE hDevice; //in
    const DXGI_DDI_ARG_PRESENTSURFACE* phSurfacesToPresent; //in
    uint SurfacesToPresent; //in
    DXGI_DDI_HRESOURCE hDstResource; // if non-zero, it's the destination of the present
    uint DstSubResourceIndex; // Index of surface level
    void* pDXGIContext; // opaque: Pass this to the Present callback
    DXGI_DDI_PRESENT_FLAGS Flags; // Presentation flags.
    DXGI_DDI_FLIP_INTERVAL_TYPE FlipInterval; // Presentation interval (flip only)
    uint Reserved;
    const RECT* pDirtyRects; // in: Array of dirty rects
    uint DirtyRects; // in: Number of dirty rects
    // out: for LDA only. Only WDDM2.0 drivers should write this value. The number of physical back buffer per logical back buffer.
    uint BackBufferMultiplicity;
}

struct DXGI_DDI_ARG_TRIMRESIDENCYSET
{
    DXGI_DDI_HDEVICE hDevice;
    D3DDDI_TRIMRESIDENCYSET_FLAGS TrimFlags;
    ulong NumBytesToTrim;
}

struct DXGI_DDI_ARG_CHECKMULTIPLANEOVERLAYCOLORSPACESUPPORT
{
    DXGI_DDI_HDEVICE hDevice;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    DXGI_FORMAT Format;
    D3DDDI_COLOR_SPACE_TYPE ColorSpace;
    bool Supported; // out 
}

struct DXGI_DDI_MULTIPLANE_OVERLAY_ATTRIBUTES1
{
    uint Flags; // DXGI_DDI_MULTIPLANE_OVERLAY_FLAGS 
    RECT SrcRect;
    RECT DstRect;
    RECT ClipRect;
    DXGI_DDI_MODE_ROTATION Rotation;
    DXGI_DDI_MULTIPLANE_OVERLAY_BLEND Blend;
    uint DirtyRectCount;
    RECT* pDirtyRects;
    DXGI_DDI_MULTIPLANE_OVERLAY_VIDEO_FRAME_FORMAT VideoFrameFormat;
    D3DDDI_COLOR_SPACE_TYPE ColorSpace;
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FORMAT StereoFormat;
    bool StereoLeftViewFrame0;
    bool StereoBaseViewFrame0;
    DXGI_DDI_MULTIPLANE_OVERLAY_STEREO_FLIP_MODE StereoFlipMode;
    DXGI_DDI_MULTIPLANE_OVERLAY_STRETCH_QUALITY StretchQuality;
    uint ColorKey;
}

struct DXGI_DDI_PRESENT_MULTIPLANE_OVERLAY1
{
    uint LayerIndex;
    bool Enabled;
    DXGI_DDI_HRESOURCE hResource;
    uint SubResourceIndex;
    DXGI_DDI_MULTIPLANE_OVERLAY_ATTRIBUTES1 PlaneAttributes;
}

struct DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY1
{
    DXGI_DDI_HDEVICE hDevice;
    void* pDXGIContext;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    DXGI_DDI_PRESENT_FLAGS Flags;
    DXGI_DDI_FLIP_INTERVAL_TYPE FlipInterval;
    uint PresentPlaneCount;
    DXGI_DDI_PRESENT_MULTIPLANE_OVERLAY1* pPresentPlanes;
}

struct DXGI_DDI_ARG_OFFERRESOURCES1
{
    DXGI_DDI_HDEVICE hDevice; //in:  device that created the resources
    const DXGI_DDI_HRESOURCE* pResources; //in:  array of resources to reset
    uint Resources; //in:  number of elements in pResources
    D3DDDI_OFFER_PRIORITY Priority; //in:  priority with which to reset the resources
    D3DDDI_OFFER_FLAGS Flags; //in:  flags specifying additional behaviors on offer
}

struct DXGI_DDI_ARG_RECLAIMRESOURCES1
{
    DXGI_DDI_HDEVICE hDevice; //in:  device that created the resources
    const DXGI_DDI_HRESOURCE* pResources; //in:  array of resources to reset
    D3DDDI_RECLAIM_RESULT* pResults; //out: array of results specifying whether each resource was successfully reclaimed, discarded, or has no commitment
    uint Resources; //in:  number of elements in pResources and pDiscarded
}

struct DXGI1_6_1_DDI_ARG_PRESENT
{
    DXGI_DDI_HDEVICE hDevice; //in
    const DXGI_DDI_ARG_PRESENTSURFACE* phSurfacesToPresent; //in
    uint SurfacesToPresent; //in
    DXGI_DDI_HRESOURCE hDstResource; // if non-zero, it's the destination of the present
    uint DstSubResourceIndex; // Index of surface level
    void* pDXGIContext; // opaque: Pass this to the Present callback
    DXGI_DDI_PRESENT_FLAGS Flags; // Presentation flags.
    DXGI_DDI_FLIP_INTERVAL_TYPE FlipInterval; // Presentation interval (flip only)
    DXGI_DDI_MODE_ROTATION RotationHint; // in: Hint that the contents of the frame are rotated with respect to scanout.
    const RECT* pDirtyRects; // in: Array of dirty rects
    uint DirtyRects; // in: Number of dirty rects
    // out: for LDA only. The number of physical back buffer per logical back buffer.
    uint BackBufferMultiplicity;
}

struct DXGI1_6_1_DDI_ARG_PRESENTMULTIPLANEOVERLAY
{
    DXGI_DDI_HDEVICE hDevice;
    void* pDXGIContext;
    D3DDDI_VIDEO_PRESENT_SOURCE_ID VidPnSourceId;
    DXGI_DDI_PRESENT_FLAGS Flags;
    DXGI_DDI_FLIP_INTERVAL_TYPE FlipInterval;
    uint PresentPlaneCount;
    DXGI_DDI_PRESENT_MULTIPLANE_OVERLAY1* pPresentPlanes;
    DXGI_DDI_MODE_ROTATION* pRotationHints;
}

struct DXGI_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
}

struct DXGI1_1_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
    HRESULT function(DXGI_DDI_ARG_RESOLVESHAREDRESOURCE*) pfnResolveSharedResource;
}

struct DXGI1_2_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
    HRESULT function(DXGI_DDI_ARG_RESOLVESHAREDRESOURCE*) pfnResolveSharedResource;
    HRESULT function(DXGI_DDI_ARG_BLT1*) pfnBlt1;
    HRESULT function(DXGI_DDI_ARG_OFFERRESOURCES*) pfnOfferResources;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES*) pfnReclaimResources;
    // Use IS_DXGI_MULTIPLANE_OVERLAY_FUNCTIONS macro to determine these functions fields are available
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYCAPS*) pfnGetMultiplaneOverlayCaps;
    HRESULT function(void*) pfnGetMultiplaneOverlayFilterRange;
    HRESULT function(DXGI_DDI_ARG_CHECKMULTIPLANEOVERLAYSUPPORT*) pfnCheckMultiplaneOverlaySupport;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY*) pfnPresentMultiplaneOverlay;
}

struct DXGI1_3_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
    HRESULT function(DXGI_DDI_ARG_RESOLVESHAREDRESOURCE*) pfnResolveSharedResource;
    HRESULT function(DXGI_DDI_ARG_BLT1*) pfnBlt1;
    HRESULT function(DXGI_DDI_ARG_OFFERRESOURCES*) pfnOfferResources;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES*) pfnReclaimResources;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYCAPS*) pfnGetMultiplaneOverlayCaps;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYGROUPCAPS*) pfnGetMultiplaneOverlayGroupCaps;
    HRESULT function(void*) pfnReserved1;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY*) pfnPresentMultiplaneOverlay;
    HRESULT function(void*) pfnReserved2;
    HRESULT function(DXGI_DDI_ARG_PRESENT1*) pfnPresent1;
    HRESULT function(DXGI_DDI_ARG_CHECKPRESENTDURATIONSUPPORT*) pfnCheckPresentDurationSupport;
}

struct DXGI1_4_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
    HRESULT function(DXGI_DDI_ARG_RESOLVESHAREDRESOURCE*) pfnResolveSharedResource;
    HRESULT function(DXGI_DDI_ARG_BLT1*) pfnBlt1;
    HRESULT function(DXGI_DDI_ARG_OFFERRESOURCES*) pfnOfferResources;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES*) pfnReclaimResources;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYCAPS*) pfnGetMultiplaneOverlayCaps;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYGROUPCAPS*) pfnGetMultiplaneOverlayGroupCaps;
    HRESULT function(void*) pfnReserved1;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY*) pfnPresentMultiplaneOverlay;
    HRESULT function(void*) pfnReserved2;
    HRESULT function(DXGI_DDI_ARG_PRESENT1*) pfnPresent1;
    HRESULT function(DXGI_DDI_ARG_CHECKPRESENTDURATIONSUPPORT*) pfnCheckPresentDurationSupport;
    HRESULT function(DXGI_DDI_ARG_TRIMRESIDENCYSET*) pfnTrimResidencySet;
    HRESULT function(DXGI_DDI_ARG_CHECKMULTIPLANEOVERLAYCOLORSPACESUPPORT*) pfnCheckMultiplaneOverlayColorSpaceSupport;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY1*) pfnPresentMultiplaneOverlay1;
}

struct DXGI1_5_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
    HRESULT function(DXGI_DDI_ARG_RESOLVESHAREDRESOURCE*) pfnResolveSharedResource;
    HRESULT function(DXGI_DDI_ARG_BLT1*) pfnBlt1;
    HRESULT function(DXGI_DDI_ARG_OFFERRESOURCES1*) pfnOfferResources1;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES*) pfnReclaimResources;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYCAPS*) pfnGetMultiplaneOverlayCaps;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYGROUPCAPS*) pfnGetMultiplaneOverlayGroupCaps;
    HRESULT function(void*) pfnReserved1;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY*) pfnPresentMultiplaneOverlay;
    HRESULT function(void*) pfnReserved2;
    HRESULT function(DXGI_DDI_ARG_PRESENT1*) pfnPresent1;
    HRESULT function(DXGI_DDI_ARG_CHECKPRESENTDURATIONSUPPORT*) pfnCheckPresentDurationSupport;
    HRESULT function(DXGI_DDI_ARG_TRIMRESIDENCYSET*) pfnTrimResidencySet;
    HRESULT function(DXGI_DDI_ARG_CHECKMULTIPLANEOVERLAYCOLORSPACESUPPORT*) pfnCheckMultiplaneOverlayColorSpaceSupport;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY1*) pfnPresentMultiplaneOverlay1;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES1*) pfnReclaimResources1;
}

struct DXGI1_6_1_DDI_BASE_FUNCTIONS
{
extern (Windows):
    HRESULT function(DXGI_DDI_ARG_PRESENT*) pfnPresent;
    HRESULT function(DXGI_DDI_ARG_GET_GAMMA_CONTROL_CAPS*) pfnGetGammaCaps;
    HRESULT function(DXGI_DDI_ARG_SETDISPLAYMODE*) pfnSetDisplayMode;
    HRESULT function(DXGI_DDI_ARG_SETRESOURCEPRIORITY*) pfnSetResourcePriority;
    HRESULT function(DXGI_DDI_ARG_QUERYRESOURCERESIDENCY*) pfnQueryResourceResidency;
    HRESULT function(DXGI_DDI_ARG_ROTATE_RESOURCE_IDENTITIES*) pfnRotateResourceIdentities;
    HRESULT function(DXGI_DDI_ARG_BLT*) pfnBlt;
    HRESULT function(DXGI_DDI_ARG_RESOLVESHAREDRESOURCE*) pfnResolveSharedResource;
    HRESULT function(DXGI_DDI_ARG_BLT1*) pfnBlt1;
    HRESULT function(DXGI_DDI_ARG_OFFERRESOURCES1*) pfnOfferResources1;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES*) pfnReclaimResources;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYCAPS*) pfnGetMultiplaneOverlayCaps;
    HRESULT function(DXGI_DDI_ARG_GETMULTIPLANEOVERLAYGROUPCAPS*) pfnGetMultiplaneOverlayGroupCaps;
    HRESULT function(void*) pfnReserved1;
    HRESULT function(DXGI_DDI_ARG_PRESENTMULTIPLANEOVERLAY*) pfnPresentMultiplaneOverlay;
    HRESULT function(void*) pfnReserved2;
    HRESULT function(DXGI1_6_1_DDI_ARG_PRESENT*) pfnPresent1;
    HRESULT function(DXGI_DDI_ARG_CHECKPRESENTDURATIONSUPPORT*) pfnCheckPresentDurationSupport;
    HRESULT function(DXGI_DDI_ARG_TRIMRESIDENCYSET*) pfnTrimResidencySet;
    HRESULT function(DXGI_DDI_ARG_CHECKMULTIPLANEOVERLAYCOLORSPACESUPPORT*) pfnCheckMultiplaneOverlayColorSpaceSupport;
    HRESULT function(DXGI1_6_1_DDI_ARG_PRESENTMULTIPLANEOVERLAY*) pfnPresentMultiplaneOverlay1;
    HRESULT function(DXGI_DDI_ARG_RECLAIMRESOURCES1*) pfnReclaimResources1;
}

struct DXGIDDICB_PRESENT
{
    D3DKMT_HANDLE hSrcAllocation; // in: The allocation of which content will be presented
    D3DKMT_HANDLE hDstAllocation; // in: if non-zero, it's the destination allocation of the present
    void* pDXGIContext; // opaque: Fill this with the value in DXGI_DDI_ARG_PRESENT.pDXGIContext
    HANDLE hContext; // in: Context being submitted to.
    uint BroadcastContextCount; // in: Specifies the number of context to broadcast this present operation to. Only supported for flip operation.
    HANDLE[D3DDDI_MAX_BROADCAST_CONTEXT] BroadcastContext; // in: Specifies the handle of the context to broadcast to.
    D3DKMT_HANDLE* BroadcastSrcAllocation; // in: LDA
    D3DKMT_HANDLE* BroadcastDstAllocation; // in: LDA
    uint PrivateDriverDataSize; // in:
    PVOID pPrivateDriverData; // in: Private driver data to pass to DdiPresent and DdiSetVidPnSourceAddress
    BOOLEAN bOptimizeForComposition; // out: DWM is involved in composition
    bool SyncIntervalOverrideValid;
    DXGI_DDI_FLIP_INTERVAL_TYPE SyncIntervalOverride;
}

struct DXGIDDI_MULTIPLANE_OVERLAY_ALLOCATION_INFO
{
    D3DKMT_HANDLE PresentAllocation;
    uint SubResourceIndex;
}

struct DXGIDDICB_PRESENT_MULTIPLANE_OVERLAY
{
    void* pDXGIContext; // opaque: Fill this with the value in DXGI_DDI_ARG_PRESENT.pDXGIContext
    HANDLE hContext;
    uint BroadcastContextCount;
    HANDLE[D3DDDI_MAX_BROADCAST_CONTEXT] BroadcastContext;
    DWORD AllocationInfoCount;
    DXGIDDI_MULTIPLANE_OVERLAY_ALLOCATION_INFO[DXGI_DDI_MAX_MULTIPLANE_OVERLAY_ALLOCATIONS] AllocationInfo;
}

struct DXGIDDI_MULTIPLANE_OVERLAY_PLANE_INFO
{
    uint ContextCount;
    HANDLE* pContextList;
    D3DKMT_HANDLE* pAllocationList;
    uint DriverPrivateDataSize;
    VOID* pDriverPrivateData;
    bool SyncIntervalOverrideValid;
    DXGI_DDI_FLIP_INTERVAL_TYPE SyncIntervalOverride;
}

struct DXGIDDICB_PRESENT_MULTIPLANE_OVERLAY1
{
    void* pDXGIContext; // opaque: Fill this with the value in DXGI_DDI_ARG_PRESENT.pDXGIContext
    DWORD PresentPlaneCount;
    DXGIDDI_MULTIPLANE_OVERLAY_PLANE_INFO** ppPresentPlanes;
}

struct DXGIDDICB_SUBMITPRESENTBLTTOHWQUEUE
{
    D3DKMT_HANDLE hSrcAllocation; // in: The allocation of which content will be presented
    D3DKMT_HANDLE hDstAllocation; // in: The destination allocation of the present
    void* pDXGIContext; // opaque: Fill this with the value in DXGI_DDI_ARG_PRESENT.pDXGIContext
    HANDLE hHwQueue; // in: Hardware queue being submitted to.
    ulong HwQueueProgressFenceId; // Hardware queue progress fence ID that will be signaled when the Present Blt is done on the GPU
    uint PrivateDriverDataSize;
    PVOID pPrivateDriverData; // in: Private driver data to pass to DdiPresent
}

struct DXGIDDICB_SUBMITPRESENTTOHWQUEUE
{
    void* pDXGIContext; // opaque: Fill this with the value in DXGI_DDI_ARG_PRESENT.pDXGIContext
    D3DKMT_HANDLE* BroadcastSrcAllocations; // in: allocations which content will be presented
    D3DKMT_HANDLE* BroadcastDstAllocations; // in: if non-zero, it's the destination allocations of the present
    HANDLE* hHwQueues; // in: hardware queues being submitted to.
    uint BroadcastHwQueueCount; // in: the number of broadcast hardware queues
    uint PrivateDriverDataSize; // in: private driver data size in bytes
    PVOID pPrivateDriverData; // in: private driver data to pass to DdiPresent
}

extern (Windows)
{
    alias PFNDDXGIDDI_PRESENTCB = HRESULT function(HANDLE hDevice, DXGIDDICB_PRESENT*);
    alias PFNDDXGIDDI_PRESENT_MULTIPLANE_OVERLAYCB = HRESULT function(HANDLE hDevice, const DXGIDDICB_PRESENT_MULTIPLANE_OVERLAY*);
    alias PFNDDXGIDDI_PRESENT_MULTIPLANE_OVERLAY1CB = HRESULT function(HANDLE hDevice, const DXGIDDICB_PRESENT_MULTIPLANE_OVERLAY1*);
    alias PFNDDXGIDDI_SUBMITPRESENTBLTTOHWQUEUECB = HRESULT function(HANDLE hDevice, DXGIDDICB_SUBMITPRESENTBLTTOHWQUEUE*);
    alias PFNDDXGIDDI_SUBMITPRESENTTOHWQUEUECB = HRESULT function(HANDLE hDevice, DXGIDDICB_SUBMITPRESENTTOHWQUEUE*);
}

struct DXGI_DDI_BASE_CALLBACKS
{
    PFNDDXGIDDI_PRESENTCB pfnPresentCb;
    PFNDDXGIDDI_PRESENT_MULTIPLANE_OVERLAYCB pfnPresentMultiplaneOverlayCb;
    PFNDDXGIDDI_PRESENT_MULTIPLANE_OVERLAY1CB pfnPresentMultiplaneOverlay1Cb;
    PFNDDXGIDDI_SUBMITPRESENTBLTTOHWQUEUECB pfnSubmitPresentBltToHwQueueCb;
    PFNDDXGIDDI_SUBMITPRESENTTOHWQUEUECB pfnSubmitPresentToHwQueueCb;
}

struct DXGI_DDI_BASE_ARGS
{
    DXGI_DDI_BASE_CALLBACKS* pDXGIBaseCallbacks; // in: The driver should record this pointer for later use
    union
    {
        DXGI1_6_1_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions6_1;
        DXGI1_5_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions6;
        DXGI1_4_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions5;
        DXGI1_3_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions4;
        DXGI1_2_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions3;
        DXGI1_1_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions2; // in/out: The driver should fill the denoted struct with DXGI base driver entry points
        DXGI_DDI_BASE_FUNCTIONS* pDXGIDDIBaseFunctions; // in/out: The driver should fill the denoted struct with DXGI base driver entry points
    }
}
