2 * Copyright 2014 Jacek Caban for CodeWeavers
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_OFFER_RESOURCE_PRIORITY
{
22 DXGI_OFFER_RESOURCE_PRIORITY_LOW
= 1,
23 DXGI_OFFER_RESOURCE_PRIORITY_NORMAL
,
24 DXGI_OFFER_RESOURCE_PRIORITY_HIGH
25 } DXGI_OFFER_RESOURCE_PRIORITY
;
27 typedef enum DXGI_ALPHA_MODE
{
28 DXGI_ALPHA_MODE_UNSPECIFIED
= 0,
29 DXGI_ALPHA_MODE_PREMULTIPLIED
= 1,
30 DXGI_ALPHA_MODE_STRAIGHT
= 2,
31 DXGI_ALPHA_MODE_IGNORE
= 3,
32 DXGI_ALPHA_MODE_FORCE_DWORD
= 0xffffffff
37 uuid(05008617-fbfd
-4051-a790
-144884b4f6a9
),
39 pointer_default(unique)
41 interface IDXGIDevice2
: IDXGIDevice1
43 HRESULT OfferResources
(
44 [in] UINT NumResources
,
45 [in, size_is(NumResources
)] IDXGIResource
*const *ppResources
,
46 [in] DXGI_OFFER_RESOURCE_PRIORITY Priority
);
48 HRESULT ReclaimResources
(
49 [in] UINT NumResources
,
50 [in, size_is(NumResources
)] IDXGIResource
*const *ppResources
,
51 [out, size_is(NumResources
)] BOOL
*pDiscarded
);
53 HRESULT EnqueueSetEvent
(
57 typedef enum DXGI_SCALING
{
58 DXGI_SCALING_STRETCH
= 0,
62 typedef struct DXGI_SWAP_CHAIN_DESC1
{
67 DXGI_SAMPLE_DESC SampleDesc
;
68 DXGI_USAGE BufferUsage
;
71 DXGI_SWAP_EFFECT SwapEffect
;
72 DXGI_ALPHA_MODE AlphaMode
;
74 } DXGI_SWAP_CHAIN_DESC1
;
76 typedef struct DXGI_SWAP_CHAIN_FULLSCREEN_DESC
{
77 DXGI_RATIONAL RefreshRate
;
78 DXGI_MODE_SCANLINE_ORDER ScanlineOrdering
;
79 DXGI_MODE_SCALING Scaling
;
81 } DXGI_SWAP_CHAIN_FULLSCREEN_DESC
;
83 typedef struct DXGI_PRESENT_PARAMETERS
{
88 } DXGI_PRESENT_PARAMETERS
;
92 uuid(790a45f7
-0d42
-4876-983a
-0a55cfe6f4aa
),
94 pointer_default(unique)
96 interface IDXGISwapChain1
: IDXGISwapChain
99 [out] DXGI_SWAP_CHAIN_DESC1
*pDesc
);
101 HRESULT GetFullscreenDesc
(
102 [out] DXGI_SWAP_CHAIN_FULLSCREEN_DESC
*pDesc
);
107 HRESULT GetCoreWindow
(
112 [in] UINT SyncInterval
,
113 [in] UINT PresentFlags
,
114 [in] const DXGI_PRESENT_PARAMETERS
*pPresentParameters
);
116 BOOL IsTemporaryMonoSupported
();
118 HRESULT GetRestrictToOutput
(
119 [out] IDXGIOutput
**ppRestrictToOutput
);
121 HRESULT SetBackgroundColor
(
122 [in] const DXGI_RGBA
*pColor
);
124 HRESULT GetBackgroundColor
(
125 [out] DXGI_RGBA
*pColor
);
128 [in] DXGI_MODE_ROTATION Rotation
);
131 [out] DXGI_MODE_ROTATION
*pRotation
);