2 * Copyright 2017 Ihsan Akmal
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 typedef enum DXGI_ADAPTER_FLAG3
23 DXGI_ADAPTER_FLAG3_NONE
= 0x0,
24 DXGI_ADAPTER_FLAG3_REMOTE
= 0x1,
25 DXGI_ADAPTER_FLAG3_SOFTWARE
= 0x2,
26 DXGI_ADAPTER_FLAG3_ACG_COMPATIBLE
= 0x4,
27 DXGI_ADAPTER_FLAG3_SUPPORT_MONITORED_FENCES
= 0x8,
28 DXGI_ADAPTER_FLAG3_SUPPORT_NON_MONITORED_FENCES
= 0x10,
29 DXGI_ADAPTER_FLAG3_KEYED_MUTEX_CONFORMANCE
= 0x20,
30 DXGI_ADAPTER_FLAG3_FORCE_DWORD
= 0xffffffff,
33 typedef enum DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAGS
35 DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAG_FULLSCREEN
= 0x1,
36 DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAG_WINDOWED
= 0x2,
37 DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAG_CURSOR_STRETCHED
= 0x4,
38 } DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAGS
;
40 typedef enum DXGI_GPU_PREFERENCE
42 DXGI_GPU_PREFERENCE_UNSPECIFIED
= 0x0,
43 DXGI_GPU_PREFERENCE_MINIMUM_POWER
= 0x1,
44 DXGI_GPU_PREFERENCE_HIGH_PERFORMANCE
= 0x2,
45 } DXGI_GPU_PREFERENCE
;
47 typedef struct DXGI_ADAPTER_DESC3
49 WCHAR Description
[128];
54 SIZE_T DedicatedVideoMemory
;
55 SIZE_T DedicatedSystemMemory
;
56 SIZE_T SharedSystemMemory
;
58 DXGI_ADAPTER_FLAG3 Flags
;
59 DXGI_GRAPHICS_PREEMPTION_GRANULARITY GraphicsPreemptionGranularity
;
60 DXGI_COMPUTE_PREEMPTION_GRANULARITY ComputePreemptionGranularity
;
63 typedef struct DXGI_OUTPUT_DESC1
66 RECT DesktopCoordinates
;
67 BOOL AttachedToDesktop
;
68 DXGI_MODE_ROTATION Rotation
;
71 DXGI_COLOR_SPACE_TYPE ColorSpace
;
73 FLOAT GreenPrimary
[2];
78 FLOAT MaxFullFrameLuminance
;
83 uuid(3c8d99d1
-4fbf
-4181-a82c
-af66bf7bd24e
),
85 pointer_default(unique)
87 interface IDXGIAdapter4
: IDXGIAdapter3
90 [out] DXGI_ADAPTER_DESC3
*desc
96 uuid(068346e8
-aaec
-4b84
-add7
-137f513f77a1
),
98 pointer_default(unique)
100 interface IDXGIOutput6
: IDXGIOutput5
103 [out] DXGI_OUTPUT_DESC1
*desc
105 HRESULT CheckHardwareCompositionSupport
(
112 uuid(c1b6694f
-ff09
-44a9
-b03c
-77900a0a1d17
),
114 pointer_default(unique)
116 interface IDXGIFactory6
: IDXGIFactory5
118 HRESULT EnumAdapterByGpuPreference
(
119 [in] UINT adapter_idx
,
120 [in] DXGI_GPU_PREFERENCE gpu_preference
,
128 uuid(a4966eed
-76db
-44da
-84c1
-ee9a7afb20a8
),
130 pointer_default(unique)
132 interface IDXGIFactory7
: IDXGIFactory6
134 HRESULT RegisterAdaptersChangedEvent
(
138 HRESULT UnregisterAdaptersChangedEvent
(