1 
2 
3 /* this ALWAYS GENERATED file contains the definitions for the interfaces */
4 
5 
6  /* File created by MIDL compiler version 8.01.0622 */
7 /* @@MIDL_FILE_HEADING(  ) */
8 
9 
10 
11 /* verify that the <rpcndr.h> version is high enough to compile this file*/
12 #ifndef __REQUIRED_RPCNDR_H_VERSION__
13 #define __REQUIRED_RPCNDR_H_VERSION__ 500
14 #endif
15 
16 /* verify that the <rpcsal.h> version is high enough to compile this file*/
17 #ifndef __REQUIRED_RPCSAL_H_VERSION__
18 #define __REQUIRED_RPCSAL_H_VERSION__ 100
19 #endif
20 
21 #include "rpc.h"
22 #include "rpcndr.h"
23 
24 #ifndef __RPCNDR_H_VERSION__
25 #error this stub requires an updated version of <rpcndr.h>
26 #endif /* __RPCNDR_H_VERSION__ */
27 
28 #ifndef COM_NO_WINDOWS_H
29 #include "windows.h"
30 #include "ole2.h"
31 #endif /*COM_NO_WINDOWS_H*/
32 
33 #ifndef __dxva2api_h__
34 #define __dxva2api_h__
35 
36 #if defined(_MSC_VER) && (_MSC_VER >= 1020)
37 #pragma once
38 #endif
39 
40 /* Forward Declarations */
41 
42 #ifndef __IDirect3DDeviceManager9_FWD_DEFINED__
43 #define __IDirect3DDeviceManager9_FWD_DEFINED__
44 typedef interface IDirect3DDeviceManager9 IDirect3DDeviceManager9;
45 
46 #endif 	/* __IDirect3DDeviceManager9_FWD_DEFINED__ */
47 
48 
49 #ifndef __IDirectXVideoAccelerationService_FWD_DEFINED__
50 #define __IDirectXVideoAccelerationService_FWD_DEFINED__
51 typedef interface IDirectXVideoAccelerationService IDirectXVideoAccelerationService;
52 
53 #endif 	/* __IDirectXVideoAccelerationService_FWD_DEFINED__ */
54 
55 
56 #ifndef __IDirectXVideoDecoderService_FWD_DEFINED__
57 #define __IDirectXVideoDecoderService_FWD_DEFINED__
58 typedef interface IDirectXVideoDecoderService IDirectXVideoDecoderService;
59 
60 #endif 	/* __IDirectXVideoDecoderService_FWD_DEFINED__ */
61 
62 
63 #ifndef __IDirectXVideoProcessorService_FWD_DEFINED__
64 #define __IDirectXVideoProcessorService_FWD_DEFINED__
65 typedef interface IDirectXVideoProcessorService IDirectXVideoProcessorService;
66 
67 #endif 	/* __IDirectXVideoProcessorService_FWD_DEFINED__ */
68 
69 
70 #ifndef __IDirectXVideoDecoder_FWD_DEFINED__
71 #define __IDirectXVideoDecoder_FWD_DEFINED__
72 typedef interface IDirectXVideoDecoder IDirectXVideoDecoder;
73 
74 #endif 	/* __IDirectXVideoDecoder_FWD_DEFINED__ */
75 
76 
77 #ifndef __IDirectXVideoProcessor_FWD_DEFINED__
78 #define __IDirectXVideoProcessor_FWD_DEFINED__
79 typedef interface IDirectXVideoProcessor IDirectXVideoProcessor;
80 
81 #endif 	/* __IDirectXVideoProcessor_FWD_DEFINED__ */
82 
83 
84 #ifndef __IDirectXVideoMemoryConfiguration_FWD_DEFINED__
85 #define __IDirectXVideoMemoryConfiguration_FWD_DEFINED__
86 typedef interface IDirectXVideoMemoryConfiguration IDirectXVideoMemoryConfiguration;
87 
88 #endif 	/* __IDirectXVideoMemoryConfiguration_FWD_DEFINED__ */
89 
90 
91 /* header files for imported files */
92 #include "unknwn.h"
93 
94 #ifdef __cplusplus
95 extern "C"{
96 #endif
97 
98 
99 /* interface __MIDL_itf_dxva2api_0000_0000 */
100 /* [local] */
101 
102 //
103 //   The following declarations within the 'if 0' block are dummy typedefs used to make
104 //   the evr.idl file build. The actual definitions are contained in d3d9.h
105 //
106 #if 0
107 typedef DWORD IDirect3DDevice9;
108 
109 typedef DWORD IDirect3DSurface9;
110 
111 typedef DWORD D3DFORMAT;
112 
113 typedef DWORD D3DPOOL;
114 
115 #endif
116 #ifndef DXVA2_API_DEFINED
117 #define DXVA2_API_DEFINED
118 DEFINE_GUID(DXVA2_ModeMPEG2_MoComp, 0xe6a9f44b, 0x61b0, 0x4563,0x9e,0xa4,0x63,0xd2,0xa3,0xc6,0xfe,0x66);
119 DEFINE_GUID(DXVA2_ModeMPEG2_IDCT,   0xbf22ad00, 0x03ea, 0x4690,0x80,0x77,0x47,0x33,0x46,0x20,0x9b,0x7e);
120 DEFINE_GUID(DXVA2_ModeMPEG2_VLD,    0xee27417f, 0x5e28, 0x4e65,0xbe,0xea,0x1d,0x26,0xb5,0x08,0xad,0xc9);
121 DEFINE_GUID(DXVA2_ModeMPEG1_VLD,    0x6f3ec719, 0x3735, 0x42cc,0x80,0x63,0x65,0xcc,0x3c,0xb3,0x66,0x16);
122 DEFINE_GUID(DXVA2_ModeMPEG2and1_VLD,0x86695f12, 0x340e, 0x4f04,0x9f,0xd3,0x92,0x53,0xdd,0x32,0x74,0x60);
123 DEFINE_GUID(DXVA2_ModeH264_A,  0x1b81be64, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
124 DEFINE_GUID(DXVA2_ModeH264_B,  0x1b81be65, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
125 DEFINE_GUID(DXVA2_ModeH264_C,  0x1b81be66, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
126 DEFINE_GUID(DXVA2_ModeH264_D,  0x1b81be67, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
127 DEFINE_GUID(DXVA2_ModeH264_E,  0x1b81be68, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
128 DEFINE_GUID(DXVA2_ModeH264_F,  0x1b81be69, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
129 DEFINE_GUID(DXVA2_ModeH264_VLD_WithFMOASO_NoFGT,  0xd5f04ff9, 0x3418,0x45d8,0x95,0x61,0x32,0xa7,0x6a,0xae,0x2d,0xdd);
130 DEFINE_GUID(DXVA2_ModeH264_VLD_Stereo_Progressive_NoFGT, 0xd79be8da, 0x0cf1,0x4c81,0xb8,0x2a,0x69,0xa4,0xe2,0x36,0xf4,0x3d);
131 DEFINE_GUID(DXVA2_ModeH264_VLD_Stereo_NoFGT,             0xf9aaccbb, 0xc2b6,0x4cfc,0x87,0x79,0x57,0x07,0xb1,0x76,0x05,0x52);
132 DEFINE_GUID(DXVA2_ModeH264_VLD_Multiview_NoFGT,          0x705b9d82, 0x76cf,0x49d6,0xb7,0xe6,0xac,0x88,0x72,0xdb,0x01,0x3c);
133 DEFINE_GUID(DXVA2_ModeWMV8_A,  0x1b81be80, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
134 DEFINE_GUID(DXVA2_ModeWMV8_B,  0x1b81be81, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
135 DEFINE_GUID(DXVA2_ModeWMV9_A,  0x1b81be90, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
136 DEFINE_GUID(DXVA2_ModeWMV9_B,  0x1b81be91, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
137 DEFINE_GUID(DXVA2_ModeWMV9_C,  0x1b81be94, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
138 DEFINE_GUID(DXVA2_ModeVC1_A,   0x1b81beA0, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
139 DEFINE_GUID(DXVA2_ModeVC1_B,   0x1b81beA1, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
140 DEFINE_GUID(DXVA2_ModeVC1_C,   0x1b81beA2, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
141 DEFINE_GUID(DXVA2_ModeVC1_D,   0x1b81beA3, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
142 DEFINE_GUID(DXVA2_ModeVC1_D2010,0x1b81beA4, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
143 DEFINE_GUID(DXVA2_NoEncrypt,   0x1b81beD0, 0xa0c7,0x11d3,0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
144 DEFINE_GUID(DXVA2_VideoProcProgressiveDevice, 0x5a54a0c9,0xc7ec,0x4bd9,0x8e,0xde,0xf3,0xc7,0x5d,0xc4,0x39,0x3b);
145 DEFINE_GUID(DXVA2_VideoProcBobDevice,         0x335aa36e,0x7884,0x43a4,0x9c,0x91,0x7f,0x87,0xfa,0xf3,0xe3,0x7e);
146 DEFINE_GUID(DXVA2_VideoProcSoftwareDevice,    0x4553d47f,0xee7e,0x4e3f,0x94,0x75,0xdb,0xf1,0x37,0x6c,0x48,0x10);
147 DEFINE_GUID(DXVA2_ModeMPEG4pt2_VLD_Simple,           0xefd64d74, 0xc9e8,0x41d7,0xa5,0xe9,0xe9,0xb0,0xe3,0x9f,0xa3,0x19);
148 DEFINE_GUID(DXVA2_ModeMPEG4pt2_VLD_AdvSimple_NoGMC,  0xed418a9f, 0x010d,0x4eda,0x9a,0xe3,0x9a,0x65,0x35,0x8d,0x8d,0x2e);
149 DEFINE_GUID(DXVA2_ModeMPEG4pt2_VLD_AdvSimple_GMC,    0xab998b5b, 0x4258,0x44a9,0x9f,0xeb,0x94,0xe5,0x97,0xa6,0xba,0xae);
150 DEFINE_GUID(DXVA2_ModeHEVC_VLD_Main,    0x5b11d51b, 0x2f4c,0x4452,0xbc,0xc3,0x09,0xf2,0xa1,0x16,0x0c,0xc0);
151 DEFINE_GUID(DXVA2_ModeHEVC_VLD_Main10,  0x107af0e0, 0xef1a,0x4d19,0xab,0xa8,0x67,0xa1,0x63,0x07,0x3d,0x13);
152 DEFINE_GUID(DXVA2_ModeVP9_VLD_Profile0,       0x463707f8, 0xa1d0, 0x4585, 0x87, 0x6d, 0x83, 0xaa, 0x6d, 0x60, 0xb8, 0x9e);
153 DEFINE_GUID(DXVA2_ModeVP9_VLD_10bit_Profile2, 0xa4c749ef, 0x6ecf, 0x48aa, 0x84, 0x48, 0x50, 0xa7, 0xa1, 0x16, 0x5f, 0xf7);
154 DEFINE_GUID(DXVA2_ModeVP8_VLD,                0x90b899ea, 0x3a62, 0x4705, 0x88, 0xb3, 0x8d, 0xf0, 0x4b, 0x27, 0x44, 0xe7);
155 #define DXVA2_ModeMPEG2_MOCOMP      DXVA2_ModeMPEG2_MoComp
156 #define DXVA2_ModeWMV8_PostProc     DXVA2_ModeWMV8_A
157 #define DXVA2_ModeWMV8_MoComp       DXVA2_ModeWMV8_B
158 #define DXVA2_ModeWMV9_PostProc     DXVA2_ModeWMV9_A
159 #define DXVA2_ModeWMV9_MoComp       DXVA2_ModeWMV9_B
160 #define DXVA2_ModeWMV9_IDCT         DXVA2_ModeWMV9_C
161 #define DXVA2_ModeVC1_PostProc      DXVA2_ModeVC1_A
162 #define DXVA2_ModeVC1_MoComp        DXVA2_ModeVC1_B
163 #define DXVA2_ModeVC1_IDCT          DXVA2_ModeVC1_C
164 #define DXVA2_ModeVC1_VLD           DXVA2_ModeVC1_D
165 #define DXVA2_ModeH264_MoComp_NoFGT DXVA2_ModeH264_A
166 #define DXVA2_ModeH264_MoComp_FGT   DXVA2_ModeH264_B
167 #define DXVA2_ModeH264_IDCT_NoFGT   DXVA2_ModeH264_C
168 #define DXVA2_ModeH264_IDCT_FGT     DXVA2_ModeH264_D
169 #define DXVA2_ModeH264_VLD_NoFGT    DXVA2_ModeH264_E
170 #define DXVA2_ModeH264_VLD_FGT      DXVA2_ModeH264_F
171 #define DXVA2_E_NOT_INITIALIZED     ((HRESULT)0x80041000L)
172 #define DXVA2_E_NEW_VIDEO_DEVICE    ((HRESULT)0x80041001L)
173 #define DXVA2_E_VIDEO_DEVICE_LOCKED ((HRESULT)0x80041002L)
174 #define DXVA2_E_NOT_AVAILABLE       ((HRESULT)0x80041003L)
175 #if defined(_WIN32) && !defined(_NO_COM)
176 DEFINE_GUID(IID_IDirect3DDeviceManager9,          0xa0cade0f,0x06d5,0x4cf4,0xa1,0xc7,0xf3,0xcd,0xd7,0x25,0xaa,0x75);
177 DEFINE_GUID(IID_IDirectXVideoAccelerationService, 0xfc51a550,0xd5e7,0x11d9,0xaf,0x55,0x00,0x05,0x4e,0x43,0xff,0x02);
178 DEFINE_GUID(IID_IDirectXVideoDecoderService,      0xfc51a551,0xd5e7,0x11d9,0xaf,0x55,0x00,0x05,0x4e,0x43,0xff,0x02);
179 DEFINE_GUID(IID_IDirectXVideoProcessorService,    0xfc51a552,0xd5e7,0x11d9,0xaf,0x55,0x00,0x05,0x4e,0x43,0xff,0x02);
180 DEFINE_GUID(IID_IDirectXVideoDecoder,             0xf2b0810a,0xfd00,0x43c9,0x91,0x8c,0xdf,0x94,0xe2,0xd8,0xef,0x7d);
181 DEFINE_GUID(IID_IDirectXVideoProcessor,           0x8c3a39f0,0x916e,0x4690,0x80,0x4f,0x4c,0x80,0x01,0x35,0x5d,0x25);
182 DEFINE_GUID(IID_IDirectXVideoMemoryConfiguration, 0xb7f916dd,0xdb3b,0x49c1,0x84,0xd7,0xe4,0x5e,0xf9,0x9e,0xc7,0x26);
183 #endif
184 #ifndef MAX_DEINTERLACE_SURFACES
185 #define MAX_DEINTERLACE_SURFACES 32
186 #endif
187 #ifndef MAX_SUBSTREAMS
188 #define MAX_SUBSTREAMS 15
189 #endif
190 #pragma warning( push )
191 #pragma warning( disable : 4201 ) // nonstandard extension used : nameless struct/union
192 typedef struct _DXVA2_ExtendedFormat
193     {
194     union
195         {
196         struct
197             {
198             UINT SampleFormat	: 8;
199             UINT VideoChromaSubsampling	: 4;
200             UINT NominalRange	: 3;
201             UINT VideoTransferMatrix	: 3;
202             UINT VideoLighting	: 4;
203             UINT VideoPrimaries	: 5;
204             UINT VideoTransferFunction	: 5;
205             } 	;
206         UINT value;
207         } 	;
208     } 	DXVA2_ExtendedFormat;
209 
210 #pragma warning( pop )
211 typedef
212 enum _DXVA2_SampleFormat
213     {
214         DXVA2_SampleFormatMask	= 0xff,
215         DXVA2_SampleUnknown	= 0,
216         DXVA2_SampleProgressiveFrame	= 2,
217         DXVA2_SampleFieldInterleavedEvenFirst	= 3,
218         DXVA2_SampleFieldInterleavedOddFirst	= 4,
219         DXVA2_SampleFieldSingleEven	= 5,
220         DXVA2_SampleFieldSingleOdd	= 6,
221         DXVA2_SampleSubStream	= 7
222     } 	DXVA2_SampleFormat;
223 
224 typedef
225 enum _DXVA2_VideoChromaSubSampling
226     {
227         DXVA2_VideoChromaSubsamplingMask	= 0xf,
228         DXVA2_VideoChromaSubsampling_Unknown	= 0,
229         DXVA2_VideoChromaSubsampling_ProgressiveChroma	= 0x8,
230         DXVA2_VideoChromaSubsampling_Horizontally_Cosited	= 0x4,
231         DXVA2_VideoChromaSubsampling_Vertically_Cosited	= 0x2,
232         DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes	= 0x1,
233         DXVA2_VideoChromaSubsampling_MPEG2	= ( DXVA2_VideoChromaSubsampling_Horizontally_Cosited | DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes ) ,
234         DXVA2_VideoChromaSubsampling_MPEG1	= DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes,
235         DXVA2_VideoChromaSubsampling_DV_PAL	= ( DXVA2_VideoChromaSubsampling_Horizontally_Cosited | DXVA2_VideoChromaSubsampling_Vertically_Cosited ) ,
236         DXVA2_VideoChromaSubsampling_Cosited	= ( ( DXVA2_VideoChromaSubsampling_Horizontally_Cosited | DXVA2_VideoChromaSubsampling_Vertically_Cosited )  | DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes )
237     } 	DXVA2_VideoChromaSubSampling;
238 
239 typedef
240 enum _DXVA2_NominalRange
241     {
242         DXVA2_NominalRangeMask	= 0x7,
243         DXVA2_NominalRange_Unknown	= 0,
244         DXVA2_NominalRange_Normal	= 1,
245         DXVA2_NominalRange_Wide	= 2,
246         DXVA2_NominalRange_0_255	= 1,
247         DXVA2_NominalRange_16_235	= 2,
248         DXVA2_NominalRange_48_208	= 3
249     } 	DXVA2_NominalRange;
250 
251 typedef
252 enum _DXVA2_VideoTransferMatrix
253     {
254         DXVA2_VideoTransferMatrixMask	= 0x7,
255         DXVA2_VideoTransferMatrix_Unknown	= 0,
256         DXVA2_VideoTransferMatrix_BT709	= 1,
257         DXVA2_VideoTransferMatrix_BT601	= 2,
258         DXVA2_VideoTransferMatrix_SMPTE240M	= 3
259     } 	DXVA2_VideoTransferMatrix;
260 
261 typedef
262 enum _DXVA2_VideoLighting
263     {
264         DXVA2_VideoLightingMask	= 0xf,
265         DXVA2_VideoLighting_Unknown	= 0,
266         DXVA2_VideoLighting_bright	= 1,
267         DXVA2_VideoLighting_office	= 2,
268         DXVA2_VideoLighting_dim	= 3,
269         DXVA2_VideoLighting_dark	= 4
270     } 	DXVA2_VideoLighting;
271 
272 typedef
273 enum _DXVA2_VideoPrimaries
274     {
275         DXVA2_VideoPrimariesMask	= 0x1f,
276         DXVA2_VideoPrimaries_Unknown	= 0,
277         DXVA2_VideoPrimaries_reserved	= 1,
278         DXVA2_VideoPrimaries_BT709	= 2,
279         DXVA2_VideoPrimaries_BT470_2_SysM	= 3,
280         DXVA2_VideoPrimaries_BT470_2_SysBG	= 4,
281         DXVA2_VideoPrimaries_SMPTE170M	= 5,
282         DXVA2_VideoPrimaries_SMPTE240M	= 6,
283         DXVA2_VideoPrimaries_EBU3213	= 7,
284         DXVA2_VideoPrimaries_SMPTE_C	= 8
285     } 	DXVA2_VideoPrimaries;
286 
287 typedef
288 enum _DXVA2_VideoTransferFunction
289     {
290         DXVA2_VideoTransFuncMask	= 0x1f,
291         DXVA2_VideoTransFunc_Unknown	= 0,
292         DXVA2_VideoTransFunc_10	= 1,
293         DXVA2_VideoTransFunc_18	= 2,
294         DXVA2_VideoTransFunc_20	= 3,
295         DXVA2_VideoTransFunc_22	= 4,
296         DXVA2_VideoTransFunc_709	= 5,
297         DXVA2_VideoTransFunc_240M	= 6,
298         DXVA2_VideoTransFunc_sRGB	= 7,
299         DXVA2_VideoTransFunc_28	= 8
300     } 	DXVA2_VideoTransferFunction;
301 
302 //
303 // Deprecated labels - please use the ones in the DXVA2_VideoTransferFunction enum.
304 //
305 #define DXVA2_VideoTransFunc_22_709         DXVA2_VideoTransFunc_709
306 #define DXVA2_VideoTransFunc_22_240M        DXVA2_VideoTransFunc_240M
307 #define DXVA2_VideoTransFunc_22_8bit_sRGB   DXVA2_VideoTransFunc_sRGB
308 typedef struct _DXVA2_Frequency
309     {
310     UINT Numerator;
311     UINT Denominator;
312     } 	DXVA2_Frequency;
313 
314 typedef struct _DXVA2_VideoDesc
315     {
316     UINT SampleWidth;
317     UINT SampleHeight;
318     DXVA2_ExtendedFormat SampleFormat;
319     D3DFORMAT Format;
320     DXVA2_Frequency InputSampleFreq;
321     DXVA2_Frequency OutputFrameFreq;
322     UINT UABProtectionLevel;
323     UINT Reserved;
324     } 	DXVA2_VideoDesc;
325 
326 
327 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0003
328     {
329         DXVA2_DeinterlaceTech_Unknown	= 0,
330         DXVA2_DeinterlaceTech_BOBLineReplicate	= 0x1,
331         DXVA2_DeinterlaceTech_BOBVerticalStretch	= 0x2,
332         DXVA2_DeinterlaceTech_BOBVerticalStretch4Tap	= 0x4,
333         DXVA2_DeinterlaceTech_MedianFiltering	= 0x8,
334         DXVA2_DeinterlaceTech_EdgeFiltering	= 0x10,
335         DXVA2_DeinterlaceTech_FieldAdaptive	= 0x20,
336         DXVA2_DeinterlaceTech_PixelAdaptive	= 0x40,
337         DXVA2_DeinterlaceTech_MotionVectorSteered	= 0x80,
338         DXVA2_DeinterlaceTech_InverseTelecine	= 0x100,
339         DXVA2_DeinterlaceTech_Mask	= 0x1ff
340     } ;
341 
342 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0004
343     {
344         DXVA2_NoiseFilterLumaLevel	= 1,
345         DXVA2_NoiseFilterLumaThreshold	= 2,
346         DXVA2_NoiseFilterLumaRadius	= 3,
347         DXVA2_NoiseFilterChromaLevel	= 4,
348         DXVA2_NoiseFilterChromaThreshold	= 5,
349         DXVA2_NoiseFilterChromaRadius	= 6,
350         DXVA2_DetailFilterLumaLevel	= 7,
351         DXVA2_DetailFilterLumaThreshold	= 8,
352         DXVA2_DetailFilterLumaRadius	= 9,
353         DXVA2_DetailFilterChromaLevel	= 10,
354         DXVA2_DetailFilterChromaThreshold	= 11,
355         DXVA2_DetailFilterChromaRadius	= 12
356     } ;
357 
358 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0005
359     {
360         DXVA2_NoiseFilterTech_Unsupported	= 0,
361         DXVA2_NoiseFilterTech_Unknown	= 0x1,
362         DXVA2_NoiseFilterTech_Median	= 0x2,
363         DXVA2_NoiseFilterTech_Temporal	= 0x4,
364         DXVA2_NoiseFilterTech_BlockNoise	= 0x8,
365         DXVA2_NoiseFilterTech_MosquitoNoise	= 0x10,
366         DXVA2_NoiseFilterTech_Mask	= 0x1f
367     } ;
368 
369 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0006
370     {
371         DXVA2_DetailFilterTech_Unsupported	= 0,
372         DXVA2_DetailFilterTech_Unknown	= 0x1,
373         DXVA2_DetailFilterTech_Edge	= 0x2,
374         DXVA2_DetailFilterTech_Sharpening	= 0x4,
375         DXVA2_DetailFilterTech_Mask	= 0x7
376     } ;
377 
378 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0007
379     {
380         DXVA2_ProcAmp_None	= 0,
381         DXVA2_ProcAmp_Brightness	= 0x1,
382         DXVA2_ProcAmp_Contrast	= 0x2,
383         DXVA2_ProcAmp_Hue	= 0x4,
384         DXVA2_ProcAmp_Saturation	= 0x8,
385         DXVA2_ProcAmp_Mask	= 0xf
386     } ;
387 
388 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0008
389     {
390         DXVA2_VideoProcess_None	= 0,
391         DXVA2_VideoProcess_YUV2RGB	= 0x1,
392         DXVA2_VideoProcess_StretchX	= 0x2,
393         DXVA2_VideoProcess_StretchY	= 0x4,
394         DXVA2_VideoProcess_AlphaBlend	= 0x8,
395         DXVA2_VideoProcess_SubRects	= 0x10,
396         DXVA2_VideoProcess_SubStreams	= 0x20,
397         DXVA2_VideoProcess_SubStreamsExtended	= 0x40,
398         DXVA2_VideoProcess_YUV2RGBExtended	= 0x80,
399         DXVA2_VideoProcess_AlphaBlendExtended	= 0x100,
400         DXVA2_VideoProcess_Constriction	= 0x200,
401         DXVA2_VideoProcess_NoiseFilter	= 0x400,
402         DXVA2_VideoProcess_DetailFilter	= 0x800,
403         DXVA2_VideoProcess_PlanarAlpha	= 0x1000,
404         DXVA2_VideoProcess_LinearScaling	= 0x2000,
405         DXVA2_VideoProcess_GammaCompensated	= 0x4000,
406         DXVA2_VideoProcess_MaintainsOriginalFieldData	= 0x8000,
407         DXVA2_VideoProcess_Mask	= 0xffff
408     } ;
409 
410 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0009
411     {
412         DXVA2_VPDev_HardwareDevice	= 0x1,
413         DXVA2_VPDev_EmulatedDXVA1	= 0x2,
414         DXVA2_VPDev_SoftwareDevice	= 0x4,
415         DXVA2_VPDev_Mask	= 0x7
416     } ;
417 
418 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0010
419     {
420         DXVA2_SampleData_RFF	= 0x1,
421         DXVA2_SampleData_TFF	= 0x2,
422         DXVA2_SampleData_RFF_TFF_Present	= 0x4,
423         DXVA2_SampleData_Mask	= 0xffff
424     } ;
425 
426 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0011
427     {
428         DXVA2_DestData_RFF	= 0x1,
429         DXVA2_DestData_TFF	= 0x2,
430         DXVA2_DestData_RFF_TFF_Present	= 0x4,
431         DXVA2_DestData_Mask	= 0xffff
432     } ;
433 typedef struct _DXVA2_VideoProcessorCaps
434     {
435     UINT DeviceCaps;
436     D3DPOOL InputPool;
437     UINT NumForwardRefSamples;
438     UINT NumBackwardRefSamples;
439     UINT Reserved;
440     UINT DeinterlaceTechnology;
441     UINT ProcAmpControlCaps;
442     UINT VideoProcessorOperations;
443     UINT NoiseFilterTechnology;
444     UINT DetailFilterTechnology;
445     } 	DXVA2_VideoProcessorCaps;
446 
447 #ifdef __midl
448 typedef LONG DXVA2_Fixed32;
449 
450 #else
451 #pragma warning( push )
452 #pragma warning( disable : 4201 ) // nonstandard extension used : nameless struct/union
453 typedef struct _DXVA2_Fixed32
454 {
455     union {
456         struct {
457             USHORT  Fraction;
458             SHORT   Value;
459         };
460         LONG ll;
461     };
462 } DXVA2_Fixed32;
463 #pragma warning( pop )
464 #endif
465 typedef struct _DXVA2_AYUVSample8
466     {
467     UCHAR Cr;
468     UCHAR Cb;
469     UCHAR Y;
470     UCHAR Alpha;
471     } 	DXVA2_AYUVSample8;
472 
473 typedef struct _DXVA2_AYUVSample16
474     {
475     USHORT Cr;
476     USHORT Cb;
477     USHORT Y;
478     USHORT Alpha;
479     } 	DXVA2_AYUVSample16;
480 
481 typedef LONGLONG REFERENCE_TIME;
482 
483 #if defined(_D3D9_H_) || defined(_d3d9P_H_)
484 typedef struct _DXVA2_VideoSample
485     {
486     REFERENCE_TIME Start;
487     REFERENCE_TIME End;
488     DXVA2_ExtendedFormat SampleFormat;
489     IDirect3DSurface9 *SrcSurface;
490     RECT SrcRect;
491     RECT DstRect;
492     DXVA2_AYUVSample8 Pal[ 16 ];
493     DXVA2_Fixed32 PlanarAlpha;
494     DWORD SampleData;
495     } 	DXVA2_VideoSample;
496 
497 #endif  // _D3D9_H_
498 typedef struct _DXVA2_ValueRange
499     {
500     DXVA2_Fixed32 MinValue;
501     DXVA2_Fixed32 MaxValue;
502     DXVA2_Fixed32 DefaultValue;
503     DXVA2_Fixed32 StepSize;
504     } 	DXVA2_ValueRange;
505 
506 typedef struct _DXVA2_ProcAmpValues
507     {
508     DXVA2_Fixed32 Brightness;
509     DXVA2_Fixed32 Contrast;
510     DXVA2_Fixed32 Hue;
511     DXVA2_Fixed32 Saturation;
512     } 	DXVA2_ProcAmpValues;
513 
514 typedef struct _DXVA2_FilterValues
515     {
516     DXVA2_Fixed32 Level;
517     DXVA2_Fixed32 Threshold;
518     DXVA2_Fixed32 Radius;
519     } 	DXVA2_FilterValues;
520 
521 typedef struct _DXVA2_VideoProcessBltParams
522     {
523     REFERENCE_TIME TargetFrame;
524     RECT TargetRect;
525     SIZE ConstrictionSize;
526     UINT StreamingFlags;
527     DXVA2_AYUVSample16 BackgroundColor;
528     DXVA2_ExtendedFormat DestFormat;
529     DXVA2_ProcAmpValues ProcAmpValues;
530     DXVA2_Fixed32 Alpha;
531     DXVA2_FilterValues NoiseFilterLuma;
532     DXVA2_FilterValues NoiseFilterChroma;
533     DXVA2_FilterValues DetailFilterLuma;
534     DXVA2_FilterValues DetailFilterChroma;
535     DWORD DestData;
536     } 	DXVA2_VideoProcessBltParams;
537 
538 
539 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0012
540     {
541         DXVA2_PictureParametersBufferType	= 0,
542         DXVA2_MacroBlockControlBufferType	= 1,
543         DXVA2_ResidualDifferenceBufferType	= 2,
544         DXVA2_DeblockingControlBufferType	= 3,
545         DXVA2_InverseQuantizationMatrixBufferType	= 4,
546         DXVA2_SliceControlBufferType	= 5,
547         DXVA2_BitStreamDateBufferType	= 6,
548         DXVA2_MotionVectorBuffer	= 7,
549         DXVA2_FilmGrainBuffer	= 8
550     } ;
551 
552 enum __MIDL___MIDL_itf_dxva2api_0000_0000_0013
553     {
554         DXVA2_VideoDecoderRenderTarget	= 0,
555         DXVA2_VideoProcessorRenderTarget	= 1,
556         DXVA2_VideoSoftwareRenderTarget	= 2
557     } ;
558 typedef struct _DXVA2_ConfigPictureDecode
559     {
560     GUID guidConfigBitstreamEncryption;
561     GUID guidConfigMBcontrolEncryption;
562     GUID guidConfigResidDiffEncryption;
563     UINT ConfigBitstreamRaw;
564     UINT ConfigMBcontrolRasterOrder;
565     UINT ConfigResidDiffHost;
566     UINT ConfigSpatialResid8;
567     UINT ConfigResid8Subtraction;
568     UINT ConfigSpatialHost8or9Clipping;
569     UINT ConfigSpatialResidInterleaved;
570     UINT ConfigIntraResidUnsigned;
571     UINT ConfigResidDiffAccelerator;
572     UINT ConfigHostInverseScan;
573     UINT ConfigSpecificIDCT;
574     UINT Config4GroupedCoefs;
575     USHORT ConfigMinRenderTargetBuffCount;
576     USHORT ConfigDecoderSpecific;
577     } 	DXVA2_ConfigPictureDecode;
578 
579 typedef struct _DXVA2_DecodeBufferDesc
580     {
581     DWORD CompressedBufferType;
582     UINT BufferIndex;
583     UINT DataOffset;
584     UINT DataSize;
585     UINT FirstMBaddress;
586     UINT NumMBsInBuffer;
587     UINT Width;
588     UINT Height;
589     UINT Stride;
590     UINT ReservedBits;
591     PVOID pvPVPState;
592     } 	DXVA2_DecodeBufferDesc;
593 
594 // The value in pvPVPState depends on the type of crypo used.  For
595 // D3DCRYPTOTYPE_AES128_CTR, pvPState points to the following structure:
596 
597 typedef struct _DXVA2_AES_CTR_IV
598     {
599     UINT64 IV;
600     UINT64 Count;
601     } 	DXVA2_AES_CTR_IV;
602 
603 typedef struct _DXVA2_DecodeExtensionData
604     {
605     UINT Function;
606     PVOID pPrivateInputData;
607     UINT PrivateInputDataSize;
608     PVOID pPrivateOutputData;
609     UINT PrivateOutputDataSize;
610     } 	DXVA2_DecodeExtensionData;
611 
612 // DXVA2_DECODE_GET_DRIVER_HANDLE is an extension function that allows the
613 // driver to return a handle for the DXVA2 decode device that can be used to
614 // associate it with a IDirect3DCryptoSession9 interface.  When this function
615 // is used:
616 //     pPrivateInputData = NULL
617 //     pPrivateInputDataSize = 0
618 //     pPrivateOutputData = HANDLE*
619 //     pPrivateOutputDataSize = sizeof(HANDLE)
620 #define DXVA2_DECODE_GET_DRIVER_HANDLE               0x725
621 
622 // DXVA2_DECODE_SPECIFY_ENCRYPTED_BLOCKS is an extension function that that allows
623 // the decoder to specify which portions of the compressed buffers are encrypted.
624 // If this fucntion is not used to specify this information, it is assumed that
625 // the entire buffer is encrypted.
626 //     pPrivateInputData = D3DENCRYPTED_BLOCK_INFO*;
627 //     PrivateInputDataSize = sizeof(D3DENCRYPTED_BLOCK_INFO);
628 //     pPrivateOutputData = NULL;
629 //     PrivateOutputDataSize = 0;
630 #define DXVA2_DECODE_SPECIFY_ENCRYPTED_BLOCKS	0x724
631 
632 typedef struct _DXVA2_DecodeExecuteParams
633     {
634     UINT NumCompBuffers;
635     DXVA2_DecodeBufferDesc *pCompressedBuffers;
636     DXVA2_DecodeExtensionData *pExtensionData;
637     } 	DXVA2_DecodeExecuteParams;
638 
639 #if defined(_D3D9_H_) || defined(_d3d9P_H_)
640 
641 
642 
643 
644 
645 
646 
647 
648 extern RPC_IF_HANDLE __MIDL_itf_dxva2api_0000_0000_v0_0_c_ifspec;
649 extern RPC_IF_HANDLE __MIDL_itf_dxva2api_0000_0000_v0_0_s_ifspec;
650 
651 #ifndef __IDirect3DDeviceManager9_INTERFACE_DEFINED__
652 #define __IDirect3DDeviceManager9_INTERFACE_DEFINED__
653 
654 /* interface IDirect3DDeviceManager9 */
655 /* [local][helpstring][uuid][object] */
656 
657 
658 EXTERN_C const IID IID_IDirect3DDeviceManager9;
659 
660 #if defined(__cplusplus) && !defined(CINTERFACE)
661 
662     MIDL_INTERFACE("a0cade0f-06d5-4cf4-a1c7-f3cdd725aa75")
663     IDirect3DDeviceManager9 : public IUnknown
664     {
665     public:
666         virtual HRESULT STDMETHODCALLTYPE ResetDevice(
667             /* [annotation][in] */
668             _In_  IDirect3DDevice9 *pDevice,
669             /* [annotation][in] */
670             _In_  UINT resetToken) = 0;
671 
672         virtual HRESULT STDMETHODCALLTYPE OpenDeviceHandle(
673             /* [annotation][out] */
674             _Out_  HANDLE *phDevice) = 0;
675 
676         virtual HRESULT STDMETHODCALLTYPE CloseDeviceHandle(
677             /* [annotation][in] */
678             _In_  HANDLE hDevice) = 0;
679 
680         virtual HRESULT STDMETHODCALLTYPE TestDevice(
681             /* [annotation][in] */
682             _In_  HANDLE hDevice) = 0;
683 
684         virtual HRESULT STDMETHODCALLTYPE LockDevice(
685             /* [annotation][in] */
686             _In_  HANDLE hDevice,
687             /* [annotation][out] */
688             _Outptr_  IDirect3DDevice9 **ppDevice,
689             /* [annotation][in] */
690             _In_  BOOL fBlock) = 0;
691 
692         virtual HRESULT STDMETHODCALLTYPE UnlockDevice(
693             /* [annotation][in] */
694             _In_  HANDLE hDevice,
695             /* [annotation][in] */
696             _In_  BOOL fSaveState) = 0;
697 
698         virtual HRESULT STDMETHODCALLTYPE GetVideoService(
699             /* [annotation][in] */
700             _In_  HANDLE hDevice,
701             /* [annotation][in] */
702             _In_  REFIID riid,
703             /* [annotation][out] */
704             _Outptr_  void **ppService) = 0;
705 
706     };
707 
708 
709 #else 	/* C style interface */
710 
711     typedef struct IDirect3DDeviceManager9Vtbl
712     {
713         BEGIN_INTERFACE
714 
715         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
716             IDirect3DDeviceManager9 * This,
717             /* [in] */ REFIID riid,
718             /* [annotation][iid_is][out] */
719             _COM_Outptr_  void **ppvObject);
720 
721         ULONG ( STDMETHODCALLTYPE *AddRef )(
722             IDirect3DDeviceManager9 * This);
723 
724         ULONG ( STDMETHODCALLTYPE *Release )(
725             IDirect3DDeviceManager9 * This);
726 
727         HRESULT ( STDMETHODCALLTYPE *ResetDevice )(
728             IDirect3DDeviceManager9 * This,
729             /* [annotation][in] */
730             _In_  IDirect3DDevice9 *pDevice,
731             /* [annotation][in] */
732             _In_  UINT resetToken);
733 
734         HRESULT ( STDMETHODCALLTYPE *OpenDeviceHandle )(
735             IDirect3DDeviceManager9 * This,
736             /* [annotation][out] */
737             _Out_  HANDLE *phDevice);
738 
739         HRESULT ( STDMETHODCALLTYPE *CloseDeviceHandle )(
740             IDirect3DDeviceManager9 * This,
741             /* [annotation][in] */
742             _In_  HANDLE hDevice);
743 
744         HRESULT ( STDMETHODCALLTYPE *TestDevice )(
745             IDirect3DDeviceManager9 * This,
746             /* [annotation][in] */
747             _In_  HANDLE hDevice);
748 
749         HRESULT ( STDMETHODCALLTYPE *LockDevice )(
750             IDirect3DDeviceManager9 * This,
751             /* [annotation][in] */
752             _In_  HANDLE hDevice,
753             /* [annotation][out] */
754             _Outptr_  IDirect3DDevice9 **ppDevice,
755             /* [annotation][in] */
756             _In_  BOOL fBlock);
757 
758         HRESULT ( STDMETHODCALLTYPE *UnlockDevice )(
759             IDirect3DDeviceManager9 * This,
760             /* [annotation][in] */
761             _In_  HANDLE hDevice,
762             /* [annotation][in] */
763             _In_  BOOL fSaveState);
764 
765         HRESULT ( STDMETHODCALLTYPE *GetVideoService )(
766             IDirect3DDeviceManager9 * This,
767             /* [annotation][in] */
768             _In_  HANDLE hDevice,
769             /* [annotation][in] */
770             _In_  REFIID riid,
771             /* [annotation][out] */
772             _Outptr_  void **ppService);
773 
774         END_INTERFACE
775     } IDirect3DDeviceManager9Vtbl;
776 
777     interface IDirect3DDeviceManager9
778     {
779         CONST_VTBL struct IDirect3DDeviceManager9Vtbl *lpVtbl;
780     };
781 
782 
783 
784 #ifdef COBJMACROS
785 
786 
787 #define IDirect3DDeviceManager9_QueryInterface(This,riid,ppvObject)	\
788     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
789 
790 #define IDirect3DDeviceManager9_AddRef(This)	\
791     ( (This)->lpVtbl -> AddRef(This) )
792 
793 #define IDirect3DDeviceManager9_Release(This)	\
794     ( (This)->lpVtbl -> Release(This) )
795 
796 
797 #define IDirect3DDeviceManager9_ResetDevice(This,pDevice,resetToken)	\
798     ( (This)->lpVtbl -> ResetDevice(This,pDevice,resetToken) )
799 
800 #define IDirect3DDeviceManager9_OpenDeviceHandle(This,phDevice)	\
801     ( (This)->lpVtbl -> OpenDeviceHandle(This,phDevice) )
802 
803 #define IDirect3DDeviceManager9_CloseDeviceHandle(This,hDevice)	\
804     ( (This)->lpVtbl -> CloseDeviceHandle(This,hDevice) )
805 
806 #define IDirect3DDeviceManager9_TestDevice(This,hDevice)	\
807     ( (This)->lpVtbl -> TestDevice(This,hDevice) )
808 
809 #define IDirect3DDeviceManager9_LockDevice(This,hDevice,ppDevice,fBlock)	\
810     ( (This)->lpVtbl -> LockDevice(This,hDevice,ppDevice,fBlock) )
811 
812 #define IDirect3DDeviceManager9_UnlockDevice(This,hDevice,fSaveState)	\
813     ( (This)->lpVtbl -> UnlockDevice(This,hDevice,fSaveState) )
814 
815 #define IDirect3DDeviceManager9_GetVideoService(This,hDevice,riid,ppService)	\
816     ( (This)->lpVtbl -> GetVideoService(This,hDevice,riid,ppService) )
817 
818 #endif /* COBJMACROS */
819 
820 
821 #endif 	/* C style interface */
822 
823 
824 
825 
826 #endif 	/* __IDirect3DDeviceManager9_INTERFACE_DEFINED__ */
827 
828 
829 #ifndef __IDirectXVideoAccelerationService_INTERFACE_DEFINED__
830 #define __IDirectXVideoAccelerationService_INTERFACE_DEFINED__
831 
832 /* interface IDirectXVideoAccelerationService */
833 /* [local][helpstring][uuid][object] */
834 
835 
836 EXTERN_C const IID IID_IDirectXVideoAccelerationService;
837 
838 #if defined(__cplusplus) && !defined(CINTERFACE)
839 
840     MIDL_INTERFACE("fc51a550-d5e7-11d9-af55-00054e43ff02")
841     IDirectXVideoAccelerationService : public IUnknown
842     {
843     public:
844         virtual HRESULT STDMETHODCALLTYPE CreateSurface(
845             /* [annotation][in] */
846             _In_  UINT Width,
847             /* [annotation][in] */
848             _In_  UINT Height,
849             /* [annotation][in] */
850             _In_  UINT BackBuffers,
851             /* [annotation][in] */
852             _In_  D3DFORMAT Format,
853             /* [annotation][in] */
854             _In_  D3DPOOL Pool,
855             /* [annotation][in] */
856             _In_  DWORD Usage,
857             /* [annotation][in] */
858             _In_  DWORD DxvaType,
859             /* [annotation][size_is][out] */
860             _Out_writes_(BackBuffers+1)  IDirect3DSurface9 **ppSurface,
861             /* [annotation][out][in] */
862             _Inout_opt_  HANDLE *pSharedHandle) = 0;
863 
864     };
865 
866 
867 #else 	/* C style interface */
868 
869     typedef struct IDirectXVideoAccelerationServiceVtbl
870     {
871         BEGIN_INTERFACE
872 
873         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
874             IDirectXVideoAccelerationService * This,
875             /* [in] */ REFIID riid,
876             /* [annotation][iid_is][out] */
877             _COM_Outptr_  void **ppvObject);
878 
879         ULONG ( STDMETHODCALLTYPE *AddRef )(
880             IDirectXVideoAccelerationService * This);
881 
882         ULONG ( STDMETHODCALLTYPE *Release )(
883             IDirectXVideoAccelerationService * This);
884 
885         HRESULT ( STDMETHODCALLTYPE *CreateSurface )(
886             IDirectXVideoAccelerationService * This,
887             /* [annotation][in] */
888             _In_  UINT Width,
889             /* [annotation][in] */
890             _In_  UINT Height,
891             /* [annotation][in] */
892             _In_  UINT BackBuffers,
893             /* [annotation][in] */
894             _In_  D3DFORMAT Format,
895             /* [annotation][in] */
896             _In_  D3DPOOL Pool,
897             /* [annotation][in] */
898             _In_  DWORD Usage,
899             /* [annotation][in] */
900             _In_  DWORD DxvaType,
901             /* [annotation][size_is][out] */
902             _Out_writes_(BackBuffers+1)  IDirect3DSurface9 **ppSurface,
903             /* [annotation][out][in] */
904             _Inout_opt_  HANDLE *pSharedHandle);
905 
906         END_INTERFACE
907     } IDirectXVideoAccelerationServiceVtbl;
908 
909     interface IDirectXVideoAccelerationService
910     {
911         CONST_VTBL struct IDirectXVideoAccelerationServiceVtbl *lpVtbl;
912     };
913 
914 
915 
916 #ifdef COBJMACROS
917 
918 
919 #define IDirectXVideoAccelerationService_QueryInterface(This,riid,ppvObject)	\
920     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
921 
922 #define IDirectXVideoAccelerationService_AddRef(This)	\
923     ( (This)->lpVtbl -> AddRef(This) )
924 
925 #define IDirectXVideoAccelerationService_Release(This)	\
926     ( (This)->lpVtbl -> Release(This) )
927 
928 
929 #define IDirectXVideoAccelerationService_CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle)	\
930     ( (This)->lpVtbl -> CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle) )
931 
932 #endif /* COBJMACROS */
933 
934 
935 #endif 	/* C style interface */
936 
937 
938 
939 
940 #endif 	/* __IDirectXVideoAccelerationService_INTERFACE_DEFINED__ */
941 
942 
943 #ifndef __IDirectXVideoDecoderService_INTERFACE_DEFINED__
944 #define __IDirectXVideoDecoderService_INTERFACE_DEFINED__
945 
946 /* interface IDirectXVideoDecoderService */
947 /* [local][helpstring][uuid][object] */
948 
949 
950 EXTERN_C const IID IID_IDirectXVideoDecoderService;
951 
952 #if defined(__cplusplus) && !defined(CINTERFACE)
953 
954     MIDL_INTERFACE("fc51a551-d5e7-11d9-af55-00054e43ff02")
955     IDirectXVideoDecoderService : public IDirectXVideoAccelerationService
956     {
957     public:
958         virtual HRESULT STDMETHODCALLTYPE GetDecoderDeviceGuids(
959             /* [annotation][out] */
960             _Out_  UINT *pCount,
961             /* [annotation][size_is][unique][out] */
962             _Outptr_result_buffer_maybenull_(*pCount)  GUID **pGuids) = 0;
963 
964         virtual HRESULT STDMETHODCALLTYPE GetDecoderRenderTargets(
965             /* [annotation][in] */
966             _In_  REFGUID Guid,
967             /* [annotation][out] */
968             _Out_  UINT *pCount,
969             /* [annotation][size_is][unique][out] */
970             _Outptr_result_buffer_maybenull_(*pCount)  D3DFORMAT **pFormats) = 0;
971 
972         virtual HRESULT STDMETHODCALLTYPE GetDecoderConfigurations(
973             /* [annotation][in] */
974             _In_  REFGUID Guid,
975             /* [annotation][in] */
976             _In_  const DXVA2_VideoDesc *pVideoDesc,
977             /* [annotation][in] */
978             _Reserved_  void *pReserved,
979             /* [annotation][out] */
980             _Out_  UINT *pCount,
981             /* [annotation][size_is][unique][out] */
982             _Outptr_result_buffer_maybenull_(*pCount)  DXVA2_ConfigPictureDecode **ppConfigs) = 0;
983 
984         virtual HRESULT STDMETHODCALLTYPE CreateVideoDecoder(
985             /* [annotation][in] */
986             _In_  REFGUID Guid,
987             /* [annotation][in] */
988             _In_  const DXVA2_VideoDesc *pVideoDesc,
989             /* [annotation][in] */
990             _In_  const DXVA2_ConfigPictureDecode *pConfig,
991             /* [annotation][size_is][in] */
992             _In_reads_(NumRenderTargets)  IDirect3DSurface9 **ppDecoderRenderTargets,
993             /* [annotation][in] */
994             _In_  UINT NumRenderTargets,
995             /* [annotation][out] */
996             _Outptr_  IDirectXVideoDecoder **ppDecode) = 0;
997 
998     };
999 
1000 
1001 #else 	/* C style interface */
1002 
1003     typedef struct IDirectXVideoDecoderServiceVtbl
1004     {
1005         BEGIN_INTERFACE
1006 
1007         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
1008             IDirectXVideoDecoderService * This,
1009             /* [in] */ REFIID riid,
1010             /* [annotation][iid_is][out] */
1011             _COM_Outptr_  void **ppvObject);
1012 
1013         ULONG ( STDMETHODCALLTYPE *AddRef )(
1014             IDirectXVideoDecoderService * This);
1015 
1016         ULONG ( STDMETHODCALLTYPE *Release )(
1017             IDirectXVideoDecoderService * This);
1018 
1019         HRESULT ( STDMETHODCALLTYPE *CreateSurface )(
1020             IDirectXVideoDecoderService * This,
1021             /* [annotation][in] */
1022             _In_  UINT Width,
1023             /* [annotation][in] */
1024             _In_  UINT Height,
1025             /* [annotation][in] */
1026             _In_  UINT BackBuffers,
1027             /* [annotation][in] */
1028             _In_  D3DFORMAT Format,
1029             /* [annotation][in] */
1030             _In_  D3DPOOL Pool,
1031             /* [annotation][in] */
1032             _In_  DWORD Usage,
1033             /* [annotation][in] */
1034             _In_  DWORD DxvaType,
1035             /* [annotation][size_is][out] */
1036             _Out_writes_(BackBuffers+1)  IDirect3DSurface9 **ppSurface,
1037             /* [annotation][out][in] */
1038             _Inout_opt_  HANDLE *pSharedHandle);
1039 
1040         HRESULT ( STDMETHODCALLTYPE *GetDecoderDeviceGuids )(
1041             IDirectXVideoDecoderService * This,
1042             /* [annotation][out] */
1043             _Out_  UINT *pCount,
1044             /* [annotation][size_is][unique][out] */
1045             _Outptr_result_buffer_maybenull_(*pCount)  GUID **pGuids);
1046 
1047         HRESULT ( STDMETHODCALLTYPE *GetDecoderRenderTargets )(
1048             IDirectXVideoDecoderService * This,
1049             /* [annotation][in] */
1050             _In_  REFGUID Guid,
1051             /* [annotation][out] */
1052             _Out_  UINT *pCount,
1053             /* [annotation][size_is][unique][out] */
1054             _Outptr_result_buffer_maybenull_(*pCount)  D3DFORMAT **pFormats);
1055 
1056         HRESULT ( STDMETHODCALLTYPE *GetDecoderConfigurations )(
1057             IDirectXVideoDecoderService * This,
1058             /* [annotation][in] */
1059             _In_  REFGUID Guid,
1060             /* [annotation][in] */
1061             _In_  const DXVA2_VideoDesc *pVideoDesc,
1062             /* [annotation][in] */
1063             _Reserved_  void *pReserved,
1064             /* [annotation][out] */
1065             _Out_  UINT *pCount,
1066             /* [annotation][size_is][unique][out] */
1067             _Outptr_result_buffer_maybenull_(*pCount)  DXVA2_ConfigPictureDecode **ppConfigs);
1068 
1069         HRESULT ( STDMETHODCALLTYPE *CreateVideoDecoder )(
1070             IDirectXVideoDecoderService * This,
1071             /* [annotation][in] */
1072             _In_  REFGUID Guid,
1073             /* [annotation][in] */
1074             _In_  const DXVA2_VideoDesc *pVideoDesc,
1075             /* [annotation][in] */
1076             _In_  const DXVA2_ConfigPictureDecode *pConfig,
1077             /* [annotation][size_is][in] */
1078             _In_reads_(NumRenderTargets)  IDirect3DSurface9 **ppDecoderRenderTargets,
1079             /* [annotation][in] */
1080             _In_  UINT NumRenderTargets,
1081             /* [annotation][out] */
1082             _Outptr_  IDirectXVideoDecoder **ppDecode);
1083 
1084         END_INTERFACE
1085     } IDirectXVideoDecoderServiceVtbl;
1086 
1087     interface IDirectXVideoDecoderService
1088     {
1089         CONST_VTBL struct IDirectXVideoDecoderServiceVtbl *lpVtbl;
1090     };
1091 
1092 
1093 
1094 #ifdef COBJMACROS
1095 
1096 
1097 #define IDirectXVideoDecoderService_QueryInterface(This,riid,ppvObject)	\
1098     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
1099 
1100 #define IDirectXVideoDecoderService_AddRef(This)	\
1101     ( (This)->lpVtbl -> AddRef(This) )
1102 
1103 #define IDirectXVideoDecoderService_Release(This)	\
1104     ( (This)->lpVtbl -> Release(This) )
1105 
1106 
1107 #define IDirectXVideoDecoderService_CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle)	\
1108     ( (This)->lpVtbl -> CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle) )
1109 
1110 
1111 #define IDirectXVideoDecoderService_GetDecoderDeviceGuids(This,pCount,pGuids)	\
1112     ( (This)->lpVtbl -> GetDecoderDeviceGuids(This,pCount,pGuids) )
1113 
1114 #define IDirectXVideoDecoderService_GetDecoderRenderTargets(This,Guid,pCount,pFormats)	\
1115     ( (This)->lpVtbl -> GetDecoderRenderTargets(This,Guid,pCount,pFormats) )
1116 
1117 #define IDirectXVideoDecoderService_GetDecoderConfigurations(This,Guid,pVideoDesc,pReserved,pCount,ppConfigs)	\
1118     ( (This)->lpVtbl -> GetDecoderConfigurations(This,Guid,pVideoDesc,pReserved,pCount,ppConfigs) )
1119 
1120 #define IDirectXVideoDecoderService_CreateVideoDecoder(This,Guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumRenderTargets,ppDecode)	\
1121     ( (This)->lpVtbl -> CreateVideoDecoder(This,Guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumRenderTargets,ppDecode) )
1122 
1123 #endif /* COBJMACROS */
1124 
1125 
1126 #endif 	/* C style interface */
1127 
1128 
1129 
1130 
1131 #endif 	/* __IDirectXVideoDecoderService_INTERFACE_DEFINED__ */
1132 
1133 
1134 #ifndef __IDirectXVideoProcessorService_INTERFACE_DEFINED__
1135 #define __IDirectXVideoProcessorService_INTERFACE_DEFINED__
1136 
1137 /* interface IDirectXVideoProcessorService */
1138 /* [local][helpstring][uuid][object] */
1139 
1140 
1141 EXTERN_C const IID IID_IDirectXVideoProcessorService;
1142 
1143 #if defined(__cplusplus) && !defined(CINTERFACE)
1144 
1145     MIDL_INTERFACE("fc51a552-d5e7-11d9-af55-00054e43ff02")
1146     IDirectXVideoProcessorService : public IDirectXVideoAccelerationService
1147     {
1148     public:
1149         virtual HRESULT STDMETHODCALLTYPE RegisterVideoProcessorSoftwareDevice(
1150             /* [annotation][in] */
1151             _In_  void *pCallbacks) = 0;
1152 
1153         virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorDeviceGuids(
1154             /* [annotation][in] */
1155             _In_  const DXVA2_VideoDesc *pVideoDesc,
1156             /* [annotation][out] */
1157             _Out_  UINT *pCount,
1158             /* [annotation][size_is][unique][out] */
1159             _Outptr_result_buffer_maybenull_(*pCount)  GUID **pGuids) = 0;
1160 
1161         virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorRenderTargets(
1162             /* [annotation][in] */
1163             _In_  REFGUID VideoProcDeviceGuid,
1164             /* [annotation][in] */
1165             _In_  const DXVA2_VideoDesc *pVideoDesc,
1166             /* [annotation][out] */
1167             _Out_  UINT *pCount,
1168             /* [annotation][size_is][unique][out] */
1169             _Outptr_result_buffer_maybenull_(*pCount)  D3DFORMAT **pFormats) = 0;
1170 
1171         virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorSubStreamFormats(
1172             /* [annotation][in] */
1173             _In_  REFGUID VideoProcDeviceGuid,
1174             /* [annotation][in] */
1175             _In_  const DXVA2_VideoDesc *pVideoDesc,
1176             /* [annotation][in] */
1177             _In_  D3DFORMAT RenderTargetFormat,
1178             /* [annotation][out] */
1179             _Out_  UINT *pCount,
1180             /* [annotation][size_is][unique][out] */
1181             _Outptr_result_buffer_maybenull_(*pCount)  D3DFORMAT **pFormats) = 0;
1182 
1183         virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorCaps(
1184             /* [annotation][in] */
1185             _In_  REFGUID VideoProcDeviceGuid,
1186             /* [annotation][in] */
1187             _In_  const DXVA2_VideoDesc *pVideoDesc,
1188             /* [annotation][in] */
1189             _In_  D3DFORMAT RenderTargetFormat,
1190             /* [annotation][out] */
1191             _Out_  DXVA2_VideoProcessorCaps *pCaps) = 0;
1192 
1193         virtual HRESULT STDMETHODCALLTYPE GetProcAmpRange(
1194             /* [annotation][in] */
1195             _In_  REFGUID VideoProcDeviceGuid,
1196             /* [annotation][in] */
1197             _In_  const DXVA2_VideoDesc *pVideoDesc,
1198             /* [annotation][in] */
1199             _In_  D3DFORMAT RenderTargetFormat,
1200             /* [annotation][in] */
1201             _In_  UINT ProcAmpCap,
1202             /* [annotation][out] */
1203             _Out_  DXVA2_ValueRange *pRange) = 0;
1204 
1205         virtual HRESULT STDMETHODCALLTYPE GetFilterPropertyRange(
1206             /* [annotation][in] */
1207             _In_  REFGUID VideoProcDeviceGuid,
1208             /* [annotation][in] */
1209             _In_  const DXVA2_VideoDesc *pVideoDesc,
1210             /* [annotation][in] */
1211             _In_  D3DFORMAT RenderTargetFormat,
1212             /* [annotation][in] */
1213             _In_  UINT FilterSetting,
1214             /* [annotation][out] */
1215             _Out_  DXVA2_ValueRange *pRange) = 0;
1216 
1217         virtual HRESULT STDMETHODCALLTYPE CreateVideoProcessor(
1218             /* [annotation][in] */
1219             _In_  REFGUID VideoProcDeviceGuid,
1220             /* [annotation][in] */
1221             _In_  const DXVA2_VideoDesc *pVideoDesc,
1222             /* [annotation][in] */
1223             _In_  D3DFORMAT RenderTargetFormat,
1224             /* [annotation][in] */
1225             _In_  UINT MaxNumSubStreams,
1226             /* [annotation][out] */
1227             _Outptr_  IDirectXVideoProcessor **ppVidProcess) = 0;
1228 
1229     };
1230 
1231 
1232 #else 	/* C style interface */
1233 
1234     typedef struct IDirectXVideoProcessorServiceVtbl
1235     {
1236         BEGIN_INTERFACE
1237 
1238         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
1239             IDirectXVideoProcessorService * This,
1240             /* [in] */ REFIID riid,
1241             /* [annotation][iid_is][out] */
1242             _COM_Outptr_  void **ppvObject);
1243 
1244         ULONG ( STDMETHODCALLTYPE *AddRef )(
1245             IDirectXVideoProcessorService * This);
1246 
1247         ULONG ( STDMETHODCALLTYPE *Release )(
1248             IDirectXVideoProcessorService * This);
1249 
1250         HRESULT ( STDMETHODCALLTYPE *CreateSurface )(
1251             IDirectXVideoProcessorService * This,
1252             /* [annotation][in] */
1253             _In_  UINT Width,
1254             /* [annotation][in] */
1255             _In_  UINT Height,
1256             /* [annotation][in] */
1257             _In_  UINT BackBuffers,
1258             /* [annotation][in] */
1259             _In_  D3DFORMAT Format,
1260             /* [annotation][in] */
1261             _In_  D3DPOOL Pool,
1262             /* [annotation][in] */
1263             _In_  DWORD Usage,
1264             /* [annotation][in] */
1265             _In_  DWORD DxvaType,
1266             /* [annotation][size_is][out] */
1267             _Out_writes_(BackBuffers+1)  IDirect3DSurface9 **ppSurface,
1268             /* [annotation][out][in] */
1269             _Inout_opt_  HANDLE *pSharedHandle);
1270 
1271         HRESULT ( STDMETHODCALLTYPE *RegisterVideoProcessorSoftwareDevice )(
1272             IDirectXVideoProcessorService * This,
1273             /* [annotation][in] */
1274             _In_  void *pCallbacks);
1275 
1276         HRESULT ( STDMETHODCALLTYPE *GetVideoProcessorDeviceGuids )(
1277             IDirectXVideoProcessorService * This,
1278             /* [annotation][in] */
1279             _In_  const DXVA2_VideoDesc *pVideoDesc,
1280             /* [annotation][out] */
1281             _Out_  UINT *pCount,
1282             /* [annotation][size_is][unique][out] */
1283             _Outptr_result_buffer_maybenull_(*pCount)  GUID **pGuids);
1284 
1285         HRESULT ( STDMETHODCALLTYPE *GetVideoProcessorRenderTargets )(
1286             IDirectXVideoProcessorService * This,
1287             /* [annotation][in] */
1288             _In_  REFGUID VideoProcDeviceGuid,
1289             /* [annotation][in] */
1290             _In_  const DXVA2_VideoDesc *pVideoDesc,
1291             /* [annotation][out] */
1292             _Out_  UINT *pCount,
1293             /* [annotation][size_is][unique][out] */
1294             _Outptr_result_buffer_maybenull_(*pCount)  D3DFORMAT **pFormats);
1295 
1296         HRESULT ( STDMETHODCALLTYPE *GetVideoProcessorSubStreamFormats )(
1297             IDirectXVideoProcessorService * This,
1298             /* [annotation][in] */
1299             _In_  REFGUID VideoProcDeviceGuid,
1300             /* [annotation][in] */
1301             _In_  const DXVA2_VideoDesc *pVideoDesc,
1302             /* [annotation][in] */
1303             _In_  D3DFORMAT RenderTargetFormat,
1304             /* [annotation][out] */
1305             _Out_  UINT *pCount,
1306             /* [annotation][size_is][unique][out] */
1307             _Outptr_result_buffer_maybenull_(*pCount)  D3DFORMAT **pFormats);
1308 
1309         HRESULT ( STDMETHODCALLTYPE *GetVideoProcessorCaps )(
1310             IDirectXVideoProcessorService * This,
1311             /* [annotation][in] */
1312             _In_  REFGUID VideoProcDeviceGuid,
1313             /* [annotation][in] */
1314             _In_  const DXVA2_VideoDesc *pVideoDesc,
1315             /* [annotation][in] */
1316             _In_  D3DFORMAT RenderTargetFormat,
1317             /* [annotation][out] */
1318             _Out_  DXVA2_VideoProcessorCaps *pCaps);
1319 
1320         HRESULT ( STDMETHODCALLTYPE *GetProcAmpRange )(
1321             IDirectXVideoProcessorService * This,
1322             /* [annotation][in] */
1323             _In_  REFGUID VideoProcDeviceGuid,
1324             /* [annotation][in] */
1325             _In_  const DXVA2_VideoDesc *pVideoDesc,
1326             /* [annotation][in] */
1327             _In_  D3DFORMAT RenderTargetFormat,
1328             /* [annotation][in] */
1329             _In_  UINT ProcAmpCap,
1330             /* [annotation][out] */
1331             _Out_  DXVA2_ValueRange *pRange);
1332 
1333         HRESULT ( STDMETHODCALLTYPE *GetFilterPropertyRange )(
1334             IDirectXVideoProcessorService * This,
1335             /* [annotation][in] */
1336             _In_  REFGUID VideoProcDeviceGuid,
1337             /* [annotation][in] */
1338             _In_  const DXVA2_VideoDesc *pVideoDesc,
1339             /* [annotation][in] */
1340             _In_  D3DFORMAT RenderTargetFormat,
1341             /* [annotation][in] */
1342             _In_  UINT FilterSetting,
1343             /* [annotation][out] */
1344             _Out_  DXVA2_ValueRange *pRange);
1345 
1346         HRESULT ( STDMETHODCALLTYPE *CreateVideoProcessor )(
1347             IDirectXVideoProcessorService * This,
1348             /* [annotation][in] */
1349             _In_  REFGUID VideoProcDeviceGuid,
1350             /* [annotation][in] */
1351             _In_  const DXVA2_VideoDesc *pVideoDesc,
1352             /* [annotation][in] */
1353             _In_  D3DFORMAT RenderTargetFormat,
1354             /* [annotation][in] */
1355             _In_  UINT MaxNumSubStreams,
1356             /* [annotation][out] */
1357             _Outptr_  IDirectXVideoProcessor **ppVidProcess);
1358 
1359         END_INTERFACE
1360     } IDirectXVideoProcessorServiceVtbl;
1361 
1362     interface IDirectXVideoProcessorService
1363     {
1364         CONST_VTBL struct IDirectXVideoProcessorServiceVtbl *lpVtbl;
1365     };
1366 
1367 
1368 
1369 #ifdef COBJMACROS
1370 
1371 
1372 #define IDirectXVideoProcessorService_QueryInterface(This,riid,ppvObject)	\
1373     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
1374 
1375 #define IDirectXVideoProcessorService_AddRef(This)	\
1376     ( (This)->lpVtbl -> AddRef(This) )
1377 
1378 #define IDirectXVideoProcessorService_Release(This)	\
1379     ( (This)->lpVtbl -> Release(This) )
1380 
1381 
1382 #define IDirectXVideoProcessorService_CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle)	\
1383     ( (This)->lpVtbl -> CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle) )
1384 
1385 
1386 #define IDirectXVideoProcessorService_RegisterVideoProcessorSoftwareDevice(This,pCallbacks)	\
1387     ( (This)->lpVtbl -> RegisterVideoProcessorSoftwareDevice(This,pCallbacks) )
1388 
1389 #define IDirectXVideoProcessorService_GetVideoProcessorDeviceGuids(This,pVideoDesc,pCount,pGuids)	\
1390     ( (This)->lpVtbl -> GetVideoProcessorDeviceGuids(This,pVideoDesc,pCount,pGuids) )
1391 
1392 #define IDirectXVideoProcessorService_GetVideoProcessorRenderTargets(This,VideoProcDeviceGuid,pVideoDesc,pCount,pFormats)	\
1393     ( (This)->lpVtbl -> GetVideoProcessorRenderTargets(This,VideoProcDeviceGuid,pVideoDesc,pCount,pFormats) )
1394 
1395 #define IDirectXVideoProcessorService_GetVideoProcessorSubStreamFormats(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCount,pFormats)	\
1396     ( (This)->lpVtbl -> GetVideoProcessorSubStreamFormats(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCount,pFormats) )
1397 
1398 #define IDirectXVideoProcessorService_GetVideoProcessorCaps(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCaps)	\
1399     ( (This)->lpVtbl -> GetVideoProcessorCaps(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,pCaps) )
1400 
1401 #define IDirectXVideoProcessorService_GetProcAmpRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,ProcAmpCap,pRange)	\
1402     ( (This)->lpVtbl -> GetProcAmpRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,ProcAmpCap,pRange) )
1403 
1404 #define IDirectXVideoProcessorService_GetFilterPropertyRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,FilterSetting,pRange)	\
1405     ( (This)->lpVtbl -> GetFilterPropertyRange(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,FilterSetting,pRange) )
1406 
1407 #define IDirectXVideoProcessorService_CreateVideoProcessor(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,MaxNumSubStreams,ppVidProcess)	\
1408     ( (This)->lpVtbl -> CreateVideoProcessor(This,VideoProcDeviceGuid,pVideoDesc,RenderTargetFormat,MaxNumSubStreams,ppVidProcess) )
1409 
1410 #endif /* COBJMACROS */
1411 
1412 
1413 #endif 	/* C style interface */
1414 
1415 
1416 
1417 
1418 #endif 	/* __IDirectXVideoProcessorService_INTERFACE_DEFINED__ */
1419 
1420 
1421 #ifndef __IDirectXVideoDecoder_INTERFACE_DEFINED__
1422 #define __IDirectXVideoDecoder_INTERFACE_DEFINED__
1423 
1424 /* interface IDirectXVideoDecoder */
1425 /* [local][helpstring][uuid][object] */
1426 
1427 
1428 EXTERN_C const IID IID_IDirectXVideoDecoder;
1429 
1430 #if defined(__cplusplus) && !defined(CINTERFACE)
1431 
1432     MIDL_INTERFACE("f2b0810a-fd00-43c9-918c-df94e2d8ef7d")
1433     IDirectXVideoDecoder : public IUnknown
1434     {
1435     public:
1436         virtual HRESULT STDMETHODCALLTYPE GetVideoDecoderService(
1437             /* [annotation][out] */
1438             _Outptr_  IDirectXVideoDecoderService **ppService) = 0;
1439 
1440         virtual HRESULT STDMETHODCALLTYPE GetCreationParameters(
1441             /* [annotation][out] */
1442             _Out_opt_  GUID *pDeviceGuid,
1443             /* [annotation][out] */
1444             _Out_opt_  DXVA2_VideoDesc *pVideoDesc,
1445             /* [annotation][out] */
1446             _Out_opt_  DXVA2_ConfigPictureDecode *pConfig,
1447             /* [annotation][size_is][unique][out] */
1448             _Out_writes_(*pNumSurfaces)  IDirect3DSurface9 ***pDecoderRenderTargets,
1449             /* [annotation][out] */
1450             _Out_opt_  UINT *pNumSurfaces) = 0;
1451 
1452         virtual HRESULT STDMETHODCALLTYPE GetBuffer(
1453             /* [annotation][in] */
1454             _In_  UINT BufferType,
1455             /* [annotation][out] */
1456             _Out_  void **ppBuffer,
1457             /* [annotation][out] */
1458             _Out_  UINT *pBufferSize) = 0;
1459 
1460         virtual HRESULT STDMETHODCALLTYPE ReleaseBuffer(
1461             /* [annotation][in] */
1462             _In_  UINT BufferType) = 0;
1463 
1464         virtual HRESULT STDMETHODCALLTYPE BeginFrame(
1465             /* [annotation][in] */
1466             _In_  IDirect3DSurface9 *pRenderTarget,
1467             /* [annotation][in] */
1468             _In_opt_  void *pvPVPData) = 0;
1469 
1470         virtual HRESULT STDMETHODCALLTYPE EndFrame(
1471             /* [annotation][out] */
1472             _Inout_opt_  HANDLE *pHandleComplete) = 0;
1473 
1474         virtual HRESULT STDMETHODCALLTYPE Execute(
1475             /* [annotation][in] */
1476             _In_  const DXVA2_DecodeExecuteParams *pExecuteParams) = 0;
1477 
1478     };
1479 
1480 
1481 #else 	/* C style interface */
1482 
1483     typedef struct IDirectXVideoDecoderVtbl
1484     {
1485         BEGIN_INTERFACE
1486 
1487         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
1488             IDirectXVideoDecoder * This,
1489             /* [in] */ REFIID riid,
1490             /* [annotation][iid_is][out] */
1491             _COM_Outptr_  void **ppvObject);
1492 
1493         ULONG ( STDMETHODCALLTYPE *AddRef )(
1494             IDirectXVideoDecoder * This);
1495 
1496         ULONG ( STDMETHODCALLTYPE *Release )(
1497             IDirectXVideoDecoder * This);
1498 
1499         HRESULT ( STDMETHODCALLTYPE *GetVideoDecoderService )(
1500             IDirectXVideoDecoder * This,
1501             /* [annotation][out] */
1502             _Outptr_  IDirectXVideoDecoderService **ppService);
1503 
1504         HRESULT ( STDMETHODCALLTYPE *GetCreationParameters )(
1505             IDirectXVideoDecoder * This,
1506             /* [annotation][out] */
1507             _Out_opt_  GUID *pDeviceGuid,
1508             /* [annotation][out] */
1509             _Out_opt_  DXVA2_VideoDesc *pVideoDesc,
1510             /* [annotation][out] */
1511             _Out_opt_  DXVA2_ConfigPictureDecode *pConfig,
1512             /* [annotation][size_is][unique][out] */
1513             _Out_writes_(*pNumSurfaces)  IDirect3DSurface9 ***pDecoderRenderTargets,
1514             /* [annotation][out] */
1515             _Out_opt_  UINT *pNumSurfaces);
1516 
1517         HRESULT ( STDMETHODCALLTYPE *GetBuffer )(
1518             IDirectXVideoDecoder * This,
1519             /* [annotation][in] */
1520             _In_  UINT BufferType,
1521             /* [annotation][out] */
1522             _Out_  void **ppBuffer,
1523             /* [annotation][out] */
1524             _Out_  UINT *pBufferSize);
1525 
1526         HRESULT ( STDMETHODCALLTYPE *ReleaseBuffer )(
1527             IDirectXVideoDecoder * This,
1528             /* [annotation][in] */
1529             _In_  UINT BufferType);
1530 
1531         HRESULT ( STDMETHODCALLTYPE *BeginFrame )(
1532             IDirectXVideoDecoder * This,
1533             /* [annotation][in] */
1534             _In_  IDirect3DSurface9 *pRenderTarget,
1535             /* [annotation][in] */
1536             _In_opt_  void *pvPVPData);
1537 
1538         HRESULT ( STDMETHODCALLTYPE *EndFrame )(
1539             IDirectXVideoDecoder * This,
1540             /* [annotation][out] */
1541             _Inout_opt_  HANDLE *pHandleComplete);
1542 
1543         HRESULT ( STDMETHODCALLTYPE *Execute )(
1544             IDirectXVideoDecoder * This,
1545             /* [annotation][in] */
1546             _In_  const DXVA2_DecodeExecuteParams *pExecuteParams);
1547 
1548         END_INTERFACE
1549     } IDirectXVideoDecoderVtbl;
1550 
1551     interface IDirectXVideoDecoder
1552     {
1553         CONST_VTBL struct IDirectXVideoDecoderVtbl *lpVtbl;
1554     };
1555 
1556 
1557 
1558 #ifdef COBJMACROS
1559 
1560 
1561 #define IDirectXVideoDecoder_QueryInterface(This,riid,ppvObject)	\
1562     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
1563 
1564 #define IDirectXVideoDecoder_AddRef(This)	\
1565     ( (This)->lpVtbl -> AddRef(This) )
1566 
1567 #define IDirectXVideoDecoder_Release(This)	\
1568     ( (This)->lpVtbl -> Release(This) )
1569 
1570 
1571 #define IDirectXVideoDecoder_GetVideoDecoderService(This,ppService)	\
1572     ( (This)->lpVtbl -> GetVideoDecoderService(This,ppService) )
1573 
1574 #define IDirectXVideoDecoder_GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces)	\
1575     ( (This)->lpVtbl -> GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces) )
1576 
1577 #define IDirectXVideoDecoder_GetBuffer(This,BufferType,ppBuffer,pBufferSize)	\
1578     ( (This)->lpVtbl -> GetBuffer(This,BufferType,ppBuffer,pBufferSize) )
1579 
1580 #define IDirectXVideoDecoder_ReleaseBuffer(This,BufferType)	\
1581     ( (This)->lpVtbl -> ReleaseBuffer(This,BufferType) )
1582 
1583 #define IDirectXVideoDecoder_BeginFrame(This,pRenderTarget,pvPVPData)	\
1584     ( (This)->lpVtbl -> BeginFrame(This,pRenderTarget,pvPVPData) )
1585 
1586 #define IDirectXVideoDecoder_EndFrame(This,pHandleComplete)	\
1587     ( (This)->lpVtbl -> EndFrame(This,pHandleComplete) )
1588 
1589 #define IDirectXVideoDecoder_Execute(This,pExecuteParams)	\
1590     ( (This)->lpVtbl -> Execute(This,pExecuteParams) )
1591 
1592 #endif /* COBJMACROS */
1593 
1594 
1595 #endif 	/* C style interface */
1596 
1597 
1598 
1599 
1600 #endif 	/* __IDirectXVideoDecoder_INTERFACE_DEFINED__ */
1601 
1602 
1603 #ifndef __IDirectXVideoProcessor_INTERFACE_DEFINED__
1604 #define __IDirectXVideoProcessor_INTERFACE_DEFINED__
1605 
1606 /* interface IDirectXVideoProcessor */
1607 /* [local][helpstring][uuid][object] */
1608 
1609 
1610 EXTERN_C const IID IID_IDirectXVideoProcessor;
1611 
1612 #if defined(__cplusplus) && !defined(CINTERFACE)
1613 
1614     MIDL_INTERFACE("8c3a39f0-916e-4690-804f-4c8001355d25")
1615     IDirectXVideoProcessor : public IUnknown
1616     {
1617     public:
1618         virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorService(
1619             /* [annotation][out] */
1620             _Outptr_  IDirectXVideoProcessorService **ppService) = 0;
1621 
1622         virtual HRESULT STDMETHODCALLTYPE GetCreationParameters(
1623             /* [annotation][out] */
1624             _Out_opt_  GUID *pDeviceGuid,
1625             /* [annotation][out] */
1626             _Out_opt_  DXVA2_VideoDesc *pVideoDesc,
1627             /* [annotation][out] */
1628             _Out_opt_  D3DFORMAT *pRenderTargetFormat,
1629             /* [annotation][out] */
1630             _Out_opt_  UINT *pMaxNumSubStreams) = 0;
1631 
1632         virtual HRESULT STDMETHODCALLTYPE GetVideoProcessorCaps(
1633             /* [annotation][out] */
1634             _Out_  DXVA2_VideoProcessorCaps *pCaps) = 0;
1635 
1636         virtual HRESULT STDMETHODCALLTYPE GetProcAmpRange(
1637             /* [annotation][in] */
1638             _In_  UINT ProcAmpCap,
1639             /* [annotation][out] */
1640             _Out_  DXVA2_ValueRange *pRange) = 0;
1641 
1642         virtual HRESULT STDMETHODCALLTYPE GetFilterPropertyRange(
1643             /* [annotation][in] */
1644             _In_  UINT FilterSetting,
1645             /* [annotation][out] */
1646             _Out_  DXVA2_ValueRange *pRange) = 0;
1647 
1648         virtual HRESULT STDMETHODCALLTYPE VideoProcessBlt(
1649             /* [annotation][in] */
1650             _In_  IDirect3DSurface9 *pRenderTarget,
1651             /* [annotation][in] */
1652             _In_  const DXVA2_VideoProcessBltParams *pBltParams,
1653             /* [annotation][size_is][in] */
1654             _In_reads_(NumSamples)  const DXVA2_VideoSample *pSamples,
1655             /* [annotation][in] */
1656             _In_  UINT NumSamples,
1657             /* [annotation][out] */
1658             _Inout_opt_  HANDLE *pHandleComplete) = 0;
1659 
1660     };
1661 
1662 
1663 #else 	/* C style interface */
1664 
1665     typedef struct IDirectXVideoProcessorVtbl
1666     {
1667         BEGIN_INTERFACE
1668 
1669         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
1670             IDirectXVideoProcessor * This,
1671             /* [in] */ REFIID riid,
1672             /* [annotation][iid_is][out] */
1673             _COM_Outptr_  void **ppvObject);
1674 
1675         ULONG ( STDMETHODCALLTYPE *AddRef )(
1676             IDirectXVideoProcessor * This);
1677 
1678         ULONG ( STDMETHODCALLTYPE *Release )(
1679             IDirectXVideoProcessor * This);
1680 
1681         HRESULT ( STDMETHODCALLTYPE *GetVideoProcessorService )(
1682             IDirectXVideoProcessor * This,
1683             /* [annotation][out] */
1684             _Outptr_  IDirectXVideoProcessorService **ppService);
1685 
1686         HRESULT ( STDMETHODCALLTYPE *GetCreationParameters )(
1687             IDirectXVideoProcessor * This,
1688             /* [annotation][out] */
1689             _Out_opt_  GUID *pDeviceGuid,
1690             /* [annotation][out] */
1691             _Out_opt_  DXVA2_VideoDesc *pVideoDesc,
1692             /* [annotation][out] */
1693             _Out_opt_  D3DFORMAT *pRenderTargetFormat,
1694             /* [annotation][out] */
1695             _Out_opt_  UINT *pMaxNumSubStreams);
1696 
1697         HRESULT ( STDMETHODCALLTYPE *GetVideoProcessorCaps )(
1698             IDirectXVideoProcessor * This,
1699             /* [annotation][out] */
1700             _Out_  DXVA2_VideoProcessorCaps *pCaps);
1701 
1702         HRESULT ( STDMETHODCALLTYPE *GetProcAmpRange )(
1703             IDirectXVideoProcessor * This,
1704             /* [annotation][in] */
1705             _In_  UINT ProcAmpCap,
1706             /* [annotation][out] */
1707             _Out_  DXVA2_ValueRange *pRange);
1708 
1709         HRESULT ( STDMETHODCALLTYPE *GetFilterPropertyRange )(
1710             IDirectXVideoProcessor * This,
1711             /* [annotation][in] */
1712             _In_  UINT FilterSetting,
1713             /* [annotation][out] */
1714             _Out_  DXVA2_ValueRange *pRange);
1715 
1716         HRESULT ( STDMETHODCALLTYPE *VideoProcessBlt )(
1717             IDirectXVideoProcessor * This,
1718             /* [annotation][in] */
1719             _In_  IDirect3DSurface9 *pRenderTarget,
1720             /* [annotation][in] */
1721             _In_  const DXVA2_VideoProcessBltParams *pBltParams,
1722             /* [annotation][size_is][in] */
1723             _In_reads_(NumSamples)  const DXVA2_VideoSample *pSamples,
1724             /* [annotation][in] */
1725             _In_  UINT NumSamples,
1726             /* [annotation][out] */
1727             _Inout_opt_  HANDLE *pHandleComplete);
1728 
1729         END_INTERFACE
1730     } IDirectXVideoProcessorVtbl;
1731 
1732     interface IDirectXVideoProcessor
1733     {
1734         CONST_VTBL struct IDirectXVideoProcessorVtbl *lpVtbl;
1735     };
1736 
1737 
1738 
1739 #ifdef COBJMACROS
1740 
1741 
1742 #define IDirectXVideoProcessor_QueryInterface(This,riid,ppvObject)	\
1743     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
1744 
1745 #define IDirectXVideoProcessor_AddRef(This)	\
1746     ( (This)->lpVtbl -> AddRef(This) )
1747 
1748 #define IDirectXVideoProcessor_Release(This)	\
1749     ( (This)->lpVtbl -> Release(This) )
1750 
1751 
1752 #define IDirectXVideoProcessor_GetVideoProcessorService(This,ppService)	\
1753     ( (This)->lpVtbl -> GetVideoProcessorService(This,ppService) )
1754 
1755 #define IDirectXVideoProcessor_GetCreationParameters(This,pDeviceGuid,pVideoDesc,pRenderTargetFormat,pMaxNumSubStreams)	\
1756     ( (This)->lpVtbl -> GetCreationParameters(This,pDeviceGuid,pVideoDesc,pRenderTargetFormat,pMaxNumSubStreams) )
1757 
1758 #define IDirectXVideoProcessor_GetVideoProcessorCaps(This,pCaps)	\
1759     ( (This)->lpVtbl -> GetVideoProcessorCaps(This,pCaps) )
1760 
1761 #define IDirectXVideoProcessor_GetProcAmpRange(This,ProcAmpCap,pRange)	\
1762     ( (This)->lpVtbl -> GetProcAmpRange(This,ProcAmpCap,pRange) )
1763 
1764 #define IDirectXVideoProcessor_GetFilterPropertyRange(This,FilterSetting,pRange)	\
1765     ( (This)->lpVtbl -> GetFilterPropertyRange(This,FilterSetting,pRange) )
1766 
1767 #define IDirectXVideoProcessor_VideoProcessBlt(This,pRenderTarget,pBltParams,pSamples,NumSamples,pHandleComplete)	\
1768     ( (This)->lpVtbl -> VideoProcessBlt(This,pRenderTarget,pBltParams,pSamples,NumSamples,pHandleComplete) )
1769 
1770 #endif /* COBJMACROS */
1771 
1772 
1773 #endif 	/* C style interface */
1774 
1775 
1776 
1777 
1778 #endif 	/* __IDirectXVideoProcessor_INTERFACE_DEFINED__ */
1779 
1780 
1781 /* interface __MIDL_itf_dxva2api_0000_0006 */
1782 /* [local] */
1783 
1784 typedef /* [public][public][public] */
1785 enum __MIDL___MIDL_itf_dxva2api_0000_0006_0001
1786     {
1787         DXVA2_SurfaceType_DecoderRenderTarget	= 0,
1788         DXVA2_SurfaceType_ProcessorRenderTarget	= 1,
1789         DXVA2_SurfaceType_D3DRenderTargetTexture	= 2
1790     } 	DXVA2_SurfaceType;
1791 
1792 
1793 
1794 extern RPC_IF_HANDLE __MIDL_itf_dxva2api_0000_0006_v0_0_c_ifspec;
1795 extern RPC_IF_HANDLE __MIDL_itf_dxva2api_0000_0006_v0_0_s_ifspec;
1796 
1797 #ifndef __IDirectXVideoMemoryConfiguration_INTERFACE_DEFINED__
1798 #define __IDirectXVideoMemoryConfiguration_INTERFACE_DEFINED__
1799 
1800 /* interface IDirectXVideoMemoryConfiguration */
1801 /* [local][helpstring][uuid][object] */
1802 
1803 
1804 EXTERN_C const IID IID_IDirectXVideoMemoryConfiguration;
1805 
1806 #if defined(__cplusplus) && !defined(CINTERFACE)
1807 
1808     MIDL_INTERFACE("b7f916dd-db3b-49c1-84d7-e45ef99ec726")
1809     IDirectXVideoMemoryConfiguration : public IUnknown
1810     {
1811     public:
1812         virtual HRESULT STDMETHODCALLTYPE GetAvailableSurfaceTypeByIndex(
1813             /* [annotation][in] */
1814             _In_  DWORD dwTypeIndex,
1815             /* [annotation][out] */
1816             _Out_  DXVA2_SurfaceType *pdwType) = 0;
1817 
1818         virtual HRESULT STDMETHODCALLTYPE SetSurfaceType(
1819             /* [annotation][in] */
1820             _In_  DXVA2_SurfaceType dwType) = 0;
1821 
1822     };
1823 
1824 
1825 #else 	/* C style interface */
1826 
1827     typedef struct IDirectXVideoMemoryConfigurationVtbl
1828     {
1829         BEGIN_INTERFACE
1830 
1831         HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
1832             IDirectXVideoMemoryConfiguration * This,
1833             /* [in] */ REFIID riid,
1834             /* [annotation][iid_is][out] */
1835             _COM_Outptr_  void **ppvObject);
1836 
1837         ULONG ( STDMETHODCALLTYPE *AddRef )(
1838             IDirectXVideoMemoryConfiguration * This);
1839 
1840         ULONG ( STDMETHODCALLTYPE *Release )(
1841             IDirectXVideoMemoryConfiguration * This);
1842 
1843         HRESULT ( STDMETHODCALLTYPE *GetAvailableSurfaceTypeByIndex )(
1844             IDirectXVideoMemoryConfiguration * This,
1845             /* [annotation][in] */
1846             _In_  DWORD dwTypeIndex,
1847             /* [annotation][out] */
1848             _Out_  DXVA2_SurfaceType *pdwType);
1849 
1850         HRESULT ( STDMETHODCALLTYPE *SetSurfaceType )(
1851             IDirectXVideoMemoryConfiguration * This,
1852             /* [annotation][in] */
1853             _In_  DXVA2_SurfaceType dwType);
1854 
1855         END_INTERFACE
1856     } IDirectXVideoMemoryConfigurationVtbl;
1857 
1858     interface IDirectXVideoMemoryConfiguration
1859     {
1860         CONST_VTBL struct IDirectXVideoMemoryConfigurationVtbl *lpVtbl;
1861     };
1862 
1863 
1864 
1865 #ifdef COBJMACROS
1866 
1867 
1868 #define IDirectXVideoMemoryConfiguration_QueryInterface(This,riid,ppvObject)	\
1869     ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
1870 
1871 #define IDirectXVideoMemoryConfiguration_AddRef(This)	\
1872     ( (This)->lpVtbl -> AddRef(This) )
1873 
1874 #define IDirectXVideoMemoryConfiguration_Release(This)	\
1875     ( (This)->lpVtbl -> Release(This) )
1876 
1877 
1878 #define IDirectXVideoMemoryConfiguration_GetAvailableSurfaceTypeByIndex(This,dwTypeIndex,pdwType)	\
1879     ( (This)->lpVtbl -> GetAvailableSurfaceTypeByIndex(This,dwTypeIndex,pdwType) )
1880 
1881 #define IDirectXVideoMemoryConfiguration_SetSurfaceType(This,dwType)	\
1882     ( (This)->lpVtbl -> SetSurfaceType(This,dwType) )
1883 
1884 #endif /* COBJMACROS */
1885 
1886 
1887 #endif 	/* C style interface */
1888 
1889 
1890 
1891 
1892 #endif 	/* __IDirectXVideoMemoryConfiguration_INTERFACE_DEFINED__ */
1893 
1894 
1895 /* interface __MIDL_itf_dxva2api_0000_0007 */
1896 /* [local] */
1897 
1898 STDAPI DXVA2CreateDirect3DDeviceManager9(
1899     _Out_ UINT* pResetToken,
1900     _Outptr_ IDirect3DDeviceManager9** ppDeviceManager
1901     );
1902 STDAPI DXVA2CreateVideoService(
1903     _In_ IDirect3DDevice9* pDD,
1904     _In_ REFIID riid,
1905     _Outptr_ void** ppService
1906     );
1907 #endif  // _D3D9_H_
DXVA2FloatToFixed(_In_ const float _float_)1908 __inline DXVA2_Fixed32 DXVA2FloatToFixed(_In_ const float _float_)
1909 {
1910     DXVA2_Fixed32 _fixed_;
1911     _fixed_.Fraction = LOWORD(_float_ * 0x10000);
1912     _fixed_.Value = HIWORD(_float_ * 0x10000);
1913     return _fixed_;
1914 }
DXVA2FixedToFloat(_In_ const DXVA2_Fixed32 _fixed_)1915 __inline float DXVA2FixedToFloat(_In_ const DXVA2_Fixed32 _fixed_)
1916 {
1917     return (FLOAT)_fixed_.Value + (FLOAT)_fixed_.Fraction / 0x10000;
1918 }
DXVA2_Fixed32TransparentAlpha()1919 __inline const DXVA2_Fixed32 DXVA2_Fixed32TransparentAlpha()
1920 {
1921     DXVA2_Fixed32 _fixed_ = {0, 0};
1922     return _fixed_;
1923 }
DXVA2_Fixed32OpaqueAlpha()1924 __inline const DXVA2_Fixed32 DXVA2_Fixed32OpaqueAlpha()
1925 {
1926     DXVA2_Fixed32 _fixed_ = {0, 1};
1927     return _fixed_;
1928 }
1929 #endif
1930 
1931 
1932 extern RPC_IF_HANDLE __MIDL_itf_dxva2api_0000_0007_v0_0_c_ifspec;
1933 extern RPC_IF_HANDLE __MIDL_itf_dxva2api_0000_0007_v0_0_s_ifspec;
1934 
1935 /* Additional Prototypes for ALL interfaces */
1936 
1937 /* end of Additional Prototypes */
1938 
1939 #ifdef __cplusplus
1940 }
1941 #endif
1942 
1943 #endif
1944 
1945 
1946