]> git.proxmox.com Git - rustc.git/blame - src/vendor/winapi/src/shared/dxgi1_6.rs
New upstream version 1.29.0+dfsg1
[rustc.git] / src / vendor / winapi / src / shared / dxgi1_6.rs
CommitLineData
8faf50e0
XL
1// Copyright © 2017 winapi-rs developers
2// Licensed under the Apache License, Version 2.0
3// <LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
4// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your option.
5// All files in the project carrying such notice may not be copied, modified, or distributed
6// except according to those terms.
7//! Mappings for the contents of dxgi1_6.h
8use shared::basetsd::SIZE_T;
9use shared::dxgi1_2::{
10 DXGI_COMPUTE_PREEMPTION_GRANULARITY, DXGI_GRAPHICS_PREEMPTION_GRANULARITY,
11};
12use shared::dxgi1_4::{IDXGIAdapter3, IDXGIAdapter3Vtbl};
13use shared::dxgi1_5::{IDXGIOutput5, IDXGIOutput5Vtbl};
14use shared::dxgitype::{DXGI_COLOR_SPACE_TYPE, DXGI_MODE_ROTATION};
15use shared::minwindef::{BOOL, FLOAT, UINT};
16use shared::windef::{HMONITOR, RECT};
17use um::winnt::{HRESULT, LUID, WCHAR};
18ENUM!{enum DXGI_ADAPTER_FLAG3 {
19 DXGI_ADAPTER_FLAG3_NONE = 0,
20 DXGI_ADAPTER_FLAG3_REMOTE = 1,
21 DXGI_ADAPTER_FLAG3_SOFTWARE = 2,
22 DXGI_ADAPTER_FLAG3_ACG_COMPATIBLE = 4,
23 DXGI_ADAPTER_FLAG3_SUPPORT_MONITORED_FENCES = 8,
24 DXGI_ADAPTER_FLAG3_SUPPORT_NON_MONITORED_FENCES = 0x10,
25 DXGI_ADAPTER_FLAG3_KEYED_MUTEX_CONFORMANCE = 0x20,
26 DXGI_ADAPTER_FLAG3_FORCE_DWORD = 0xFFFFFFFF,
27}}
28STRUCT!{struct DXGI_ADAPTER_DESC3 {
29 Description: [WCHAR; 128],
30 VendorID: UINT,
31 DeviceID: UINT,
32 SubSysID: UINT,
33 Revision: UINT,
34 DedicatedVideoMemory: SIZE_T,
35 DedicatedSystemMemory: SIZE_T,
36 SharedSystemMemory: SIZE_T,
37 AdapterLuid: LUID,
38 Flags: DXGI_ADAPTER_FLAG3,
39 GraphicsPreemptionGranularity: DXGI_GRAPHICS_PREEMPTION_GRANULARITY,
40 ComputePreemptionGranularity: DXGI_COMPUTE_PREEMPTION_GRANULARITY,
41}}
42RIDL!(#[uuid(0x3c8d99d1, 0x4fbf, 0x4181, 0xa8, 0x2c, 0xaf, 0x66, 0xbf, 0x7b, 0xd2, 0x4e)]
43interface IDXGIAdapter4(IDXGIAdapter4Vtbl): IDXGIAdapter3(IDXGIAdapter3Vtbl) {
44 fn GetDesc3(
45 pDesc: *mut DXGI_ADAPTER_DESC3,
46 ) -> HRESULT,
47});
48STRUCT!{struct DXGI_OUTPUT_DESC1 {
49 DeviceName: [WCHAR; 32],
50 DesktopCoordinates: RECT,
51 AttachedToDesktop: BOOL,
52 Rotation: DXGI_MODE_ROTATION,
53 Monitor: HMONITOR,
54 BitsPerColor: UINT,
55 ColorSpace: DXGI_COLOR_SPACE_TYPE,
56 RedPrimary: [FLOAT; 2],
57 GreenPrimary: [FLOAT; 2],
58 BluePrimary: [FLOAT; 2],
59 WhitePoint: [FLOAT; 2],
60 MinLuminance: FLOAT,
61 MaxLuminance: FLOAT,
62 MaxFullFrameLuminance: FLOAT,
63}}
64ENUM!{enum DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAGS {
65 DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAG_FULLSCREEN = 1,
66 DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAG_WINDOWED = 2,
67 DXGI_HARDWARE_COMPOSITION_SUPPORT_FLAG_CURSOR_STRETCHED = 4,
68}}
69RIDL!(#[uuid(0x068346e8, 0xaaec, 0x4b84, 0xad, 0xd7, 0x13, 0x7f, 0x51, 0x3f, 0x77, 0xa1)]
70interface IDXGIOutput6(IDXGIOutput6Vtbl): IDXGIOutput5(IDXGIOutput5Vtbl) {
71 fn GetDesc1(
72 pDesc: *mut DXGI_OUTPUT_DESC1,
73 ) -> HRESULT,
74 fn CheckHardwareCompositionSupport(
75 pFlags: *mut UINT,
76 ) -> HRESULT,
77});
78DEFINE_GUID!{IID_IDXGIAdapter4,
79 0x3c8d99d1, 0x4fbf, 0x4181, 0xa8, 0x2c, 0xaf, 0x66, 0xbf, 0x7b, 0xd2, 0x4e}
80DEFINE_GUID!{IID_IDXGIOutput6,
81 0x068346e8, 0xaaec, 0x4b84, 0xad, 0xd7, 0x13, 0x7f, 0x51, 0x3f, 0x77, 0xa1}