1/*** Autogenerated by WIDL 1.6 from include/dxva2api.idl - Do not edit ***/
2
3#ifndef __REQUIRED_RPCNDR_H_VERSION__
4#define __REQUIRED_RPCNDR_H_VERSION__ 475
5#endif
6
7#include <rpc.h>
8#include <rpcndr.h>
9
10#ifndef COM_NO_WINDOWS_H
11#include <windows.h>
12#include <ole2.h>
13#endif
14
15#ifndef __dxva2api_h__
16#define __dxva2api_h__
17
18/* Forward declarations */
19
20#ifndef __IDirect3DDeviceManager9_FWD_DEFINED__
21#define __IDirect3DDeviceManager9_FWD_DEFINED__
22typedef interface IDirect3DDeviceManager9 IDirect3DDeviceManager9;
23#endif
24
25#ifndef __IDirectXVideoDecoder_FWD_DEFINED__
26#define __IDirectXVideoDecoder_FWD_DEFINED__
27typedef interface IDirectXVideoDecoder IDirectXVideoDecoder;
28#endif
29
30#ifndef __IDirectXVideoAccelerationService_FWD_DEFINED__
31#define __IDirectXVideoAccelerationService_FWD_DEFINED__
32typedef interface IDirectXVideoAccelerationService IDirectXVideoAccelerationService;
33#endif
34
35#ifndef __IDirectXVideoDecoderService_FWD_DEFINED__
36#define __IDirectXVideoDecoderService_FWD_DEFINED__
37typedef interface IDirectXVideoDecoderService IDirectXVideoDecoderService;
38#endif
39
40/* Headers for imported files */
41
42#include <unknwn.h>
43
44#ifdef __cplusplus
45extern "C" {
46#endif
47
48#if 0
49typedef DWORD IDirect3DDevice9;
50typedef DWORD IDirect3DSurface9;
51typedef DWORD D3DFORMAT;
52typedef DWORD D3DPOOL;
53#endif
54#ifndef __IDirectXVideoDecoderService_FWD_DEFINED__
55#define __IDirectXVideoDecoderService_FWD_DEFINED__
56typedef interface IDirectXVideoDecoderService IDirectXVideoDecoderService;
57#endif
58
59#ifndef __REFERENCE_TIME_DEFINED
60#define __REFERENCE_TIME_DEFINED
61typedef LONGLONG REFERENCE_TIME;
62#endif /*__REFERENCE_TIME_DEFINED*/
63#define DXVA2_ProcAmp_None 0x0000
64#define DXVA2_ProcAmp_Brightness 0x0001
65#define DXVA2_ProcAmp_Contrast 0x0002
66#define DXVA2_ProcAmp_Hue 0x0004
67#define DXVA2_ProcAmp_Saturation 0x0008
68
69#define DXVA2_E_NOT_INITIALIZED     MAKE_HRESULT(1, 4, 4096)
70#define DXVA2_E_NEW_VIDEO_DEVICE    MAKE_HRESULT(1, 4, 4097)
71#define DXVA2_E_VIDEO_DEVICE_LOCKED MAKE_HRESULT(1, 4, 4098)
72#define DXVA2_E_NOT_AVAILABLE       MAKE_HRESULT(1, 4, 4099)
73
74DEFINE_GUID(DXVA2_ModeMPEG2_MoComp, 0xe6a9f44b, 0x61b0,0x4563, 0x9e,0xa4,0x63,0xd2,0xa3,0xc6,0xfe,0x66);
75DEFINE_GUID(DXVA2_ModeMPEG2_IDCT, 0xbf22ad00, 0x03ea,0x4690, 0x80,0x77,0x47,0x33,0x46,0x20,0x9b,0x7e);
76DEFINE_GUID(DXVA2_ModeMPEG2_VLD, 0xee27417f, 0x5e28,0x4e65, 0xbe,0xea,0x1d,0x26,0xb5,0x08,0xad,0xc9);
77DEFINE_GUID(DXVA2_ModeH264_A, 0x1b81be64, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
78DEFINE_GUID(DXVA2_ModeH264_B, 0x1b81be65, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
79DEFINE_GUID(DXVA2_ModeH264_C, 0x1b81be66, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
80DEFINE_GUID(DXVA2_ModeH264_D, 0x1b81be67, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
81DEFINE_GUID(DXVA2_ModeH264_E, 0x1b81be68, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
82DEFINE_GUID(DXVA2_ModeH264_F, 0x1b81be69, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
83DEFINE_GUID(DXVA2_ModeWMV8_A, 0x1b81be80, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
84DEFINE_GUID(DXVA2_ModeWMV8_B, 0x1b81be81, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
85DEFINE_GUID(DXVA2_ModeWMV9_A, 0x1b81be90, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
86DEFINE_GUID(DXVA2_ModeWMV9_B, 0x1b81be91, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
87DEFINE_GUID(DXVA2_ModeWMV9_C, 0x1b81be94, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
88DEFINE_GUID(DXVA2_ModeVC1_A, 0x1b81beA0, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
89DEFINE_GUID(DXVA2_ModeVC1_B, 0x1b81beA1, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
90DEFINE_GUID(DXVA2_ModeVC1_C, 0x1b81beA2, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
91DEFINE_GUID(DXVA2_ModeVC1_D, 0x1b81beA3, 0xa0c7,0x11d3, 0xb9,0x84,0x00,0xc0,0x4f,0x2e,0x73,0xc5);
92
93typedef enum _DXVA2_SampleFormat {
94  DXVA2_SampleFormatMask                  = 0x00FF,
95  DXVA2_SampleUnknown                     = 0,
96  DXVA2_SampleProgressiveFrame            = 2,
97  DXVA2_SampleFieldInterleavedEvenFirst   = 3,
98  DXVA2_SampleFieldInterleavedOddFirst    = 4,
99  DXVA2_SampleFieldSingleEven             = 5,
100  DXVA2_SampleFieldSingleOdd              = 6,
101  DXVA2_SampleSubStream                   = 7
102} DXVA2_SampleFormat;
103
104typedef enum _DXVA2_VideoChromaSubSampling {
105  DXVA2_VideoChromaSubsamplingMask                              = 0x0F,
106  DXVA2_VideoChromaSubsampling_Unknown                          = 0,
107  DXVA2_VideoChromaSubsampling_ProgressiveChroma                = 0x8,
108  DXVA2_VideoChromaSubsampling_Horizontally_Cosited             = 0x4,
109  DXVA2_VideoChromaSubsampling_Vertically_Cosited               = 0x2,
110  DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes   = 0x1,
111  DXVA2_VideoChromaSubsampling_MPEG2                            =
112              DXVA2_VideoChromaSubsampling_Horizontally_Cosited |
113              DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes,
114  DXVA2_VideoChromaSubsampling_MPEG1                            =
115              DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes,
116  DXVA2_VideoChromaSubsampling_DV_PAL                           =
117              DXVA2_VideoChromaSubsampling_Horizontally_Cosited |
118              DXVA2_VideoChromaSubsampling_Vertically_Cosited,
119  DXVA2_VideoChromaSubsampling_Cosited                          =
120              DXVA2_VideoChromaSubsampling_Horizontally_Cosited |
121              DXVA2_VideoChromaSubsampling_Vertically_Cosited |
122              DXVA2_VideoChromaSubsampling_Vertically_AlignedChromaPlanes
123} DXVA2_VideoChromaSubSampling;
124
125typedef enum _DXVA2_NominalRange {
126  DXVA2_NominalRangeMask       = 0x07,
127  DXVA2_NominalRange_Unknown   = 0,
128  DXVA2_NominalRange_Normal    = 1,
129  DXVA2_NominalRange_Wide      = 2,
130  DXVA2_NominalRange_0_255     = 1,
131  DXVA2_NominalRange_16_235    = 2,
132  DXVA2_NominalRange_48_208    = 3
133} DXVA2_NominalRange;
134
135typedef enum _DXVA2_VideoLighting {
136  DXVA2_VideoLightingMask       = 0x0F,
137  DXVA2_VideoLighting_Unknown   = 0,
138  DXVA2_VideoLighting_bright    = 1,
139  DXVA2_VideoLighting_office    = 2,
140  DXVA2_VideoLighting_dim       = 3,
141  DXVA2_VideoLighting_dark      = 4
142} DXVA2_VideoLighting;
143
144typedef enum _DXVA2_VideoPrimaries {
145  DXVA2_VideoPrimariesMask             = 0x001f,
146  DXVA2_VideoPrimaries_Unknown         = 0,
147  DXVA2_VideoPrimaries_reserved        = 1,
148  DXVA2_VideoPrimaries_BT709           = 2,
149  DXVA2_VideoPrimaries_BT470_2_SysM    = 3,
150  DXVA2_VideoPrimaries_BT470_2_SysBG   = 4,
151  DXVA2_VideoPrimaries_SMPTE170M       = 5,
152  DXVA2_VideoPrimaries_SMPTE240M       = 6,
153  DXVA2_VideoPrimaries_EBU3213         = 7,
154  DXVA2_VideoPrimaries_SMPTE_C         = 8
155} DXVA2_VideoPrimaries;
156
157typedef enum _DXVA2_VideoTransferFunction {
158  DXVA2_VideoTransFuncMask       = 0x001f,
159  DXVA2_VideoTransFunc_Unknown   = 0,
160  DXVA2_VideoTransFunc_10        = 1,
161  DXVA2_VideoTransFunc_18        = 2,
162  DXVA2_VideoTransFunc_20        = 3,
163  DXVA2_VideoTransFunc_22        = 4,
164  DXVA2_VideoTransFunc_709       = 5,
165  DXVA2_VideoTransFunc_240M      = 6,
166  DXVA2_VideoTransFunc_sRGB      = 7,
167  DXVA2_VideoTransFunc_28        = 8
168} DXVA2_VideoTransferFunction;
169
170typedef enum  {
171  DXVA2_SurfaceType_DecoderRenderTarget      = 0,
172  DXVA2_SurfaceType_ProcessorRenderTarget    = 1,
173  DXVA2_SurfaceType_D3DRenderTargetTexture   = 2
174} DXVA2_SurfaceType;
175
176typedef enum _DXVA2_VideoTransferMatrix {
177  DXVA2_VideoTransferMatrixMask         = 0x07,
178  DXVA2_VideoTransferMatrix_Unknown     = 0,
179  DXVA2_VideoTransferMatrix_BT709       = 1,
180  DXVA2_VideoTransferMatrix_BT601       = 2,
181  DXVA2_VideoTransferMatrix_SMPTE240M   = 3
182} DXVA2_VideoTransferMatrix;
183
184typedef struct _DXVA2_AYUVSample16 {
185  USHORT Cr;
186  USHORT Cb;
187  USHORT Y;
188  USHORT Alpha;
189} DXVA2_AYUVSample16;
190
191typedef struct _DXVA2_AYUVSample8 {
192  UCHAR Cr;
193  UCHAR Cb;
194  UCHAR Y;
195  UCHAR Alpha;
196} DXVA2_AYUVSample8;
197typedef struct _DXVA2_ConfigPictureDecode {
198    GUID guidConfigBitstreamEncryption;
199    GUID guidConfigMBcontrolEncryption;
200    GUID guidConfigResidDiffEncryption;
201    UINT ConfigBitstreamRaw;
202    UINT ConfigMBcontrolRasterOrder;
203    UINT ConfigResidDiffHost;
204    UINT ConfigSpatialResid8;
205    UINT ConfigResid8Subtraction;
206    UINT ConfigSpatialHost8or9Clipping;
207    UINT ConfigSpatialResidInterleaved;
208    UINT ConfigIntraResidUnsigned;
209    UINT ConfigResidDiffAccelerator;
210    UINT ConfigHostInverseScan;
211    UINT ConfigSpecificIDCT;
212    UINT Config4GroupedCoefs;
213    USHORT ConfigMinRenderTargetBuffCount;
214    USHORT ConfigDecoderSpecific;
215} DXVA2_ConfigPictureDecode;
216typedef struct _DXVA2_DecodeBufferDesc {
217    DWORD CompressedBufferType;
218    UINT BufferIndex;
219    UINT DataOffset;
220    UINT DataSize;
221    UINT FirstMBaddress;
222    UINT NumMBsInBuffer;
223    UINT Width;
224    UINT Height;
225    UINT Stride;
226    UINT ReservedBits;
227    PVOID pvPVPState;
228} DXVA2_DecodeBufferDesc;
229typedef struct _DXVA2_DecodeExtensionData {
230    UINT Function;
231    PVOID pPrivateInputData;
232    UINT PrivateInputDataSize;
233    PVOID pPrivateOutputData;
234    UINT PrivateOutputDataSize;
235} DXVA2_DecodeExtensionData;
236typedef struct _DXVA2_DecodeExecuteParams {
237    UINT NumCompBuffers;
238    DXVA2_DecodeBufferDesc *pCompressedBuffers;
239    DXVA2_DecodeExtensionData *pExtensionData;
240} DXVA2_DecodeExecuteParams;
241typedef struct _DXVA2_ExtendedFormat {
242    __C89_NAMELESS union {
243        __C89_NAMELESS struct {
244            UINT SampleFormat : 8;
245            UINT VideoChromaSubsampling : 4;
246            UINT NominalRange : 3;
247            UINT VideoTransferMatrix : 3;
248            UINT VideoLighting : 4;
249            UINT VideoPrimaries : 5;
250            UINT VideoTransferFunction : 5;
251        } __C89_NAMELESSSTRUCTNAME;
252        UINT value;
253    } __C89_NAMELESSUNIONNAME;
254} DXVA2_ExtendedFormat;
255typedef struct _DXVA2_Fixed32 {
256  __C89_NAMELESS union {
257    __C89_NAMELESS struct {
258      USHORT Fraction;
259      SHORT  Value;
260    } DUMMYSTRUCTNAME;
261    LONG   ll;
262  } DUMMYUNIONNAME;
263} DXVA2_Fixed32;
264
265typedef struct _DXVA2_FilterValues {
266  DXVA2_Fixed32 Level;
267  DXVA2_Fixed32 Threshold;
268  DXVA2_Fixed32 Radius;
269} DXVA2_FilterValues;
270typedef struct _DXVA2_Frequency {
271    UINT Numerator;
272    UINT Denominator;
273} DXVA2_Frequency;
274typedef struct _DXVA2_ProcAmpValues {
275  DXVA2_Fixed32 Brightness;
276  DXVA2_Fixed32 Contrast;
277  DXVA2_Fixed32 Hue;
278  DXVA2_Fixed32 Saturation;
279} DXVA2_ProcAmpValues;
280
281typedef struct _DXVA2_ValueRange {
282  DXVA2_Fixed32 MinValue;
283  DXVA2_Fixed32 MaxValue;
284  DXVA2_Fixed32 DefaultValue;
285  DXVA2_Fixed32 StepSize;
286} DXVA2_ValueRange;
287typedef struct _DXVA2_VideoDesc {
288    UINT SampleWidth;
289    UINT SampleHeight;
290    DXVA2_ExtendedFormat SampleFormat;
291    D3DFORMAT Format;
292    DXVA2_Frequency InputSampleFreq;
293    DXVA2_Frequency OutputFrameFreq;
294    UINT UABProtectionLevel;
295    UINT Reserved;
296} DXVA2_VideoDesc;
297/* DeviceCaps
298DXVA2_VPDev_EmulatedDXVA1
299DXVA2_VPDev_HardwareDevice
300DXVA2_VPDev_SoftwareDevice
301*/
302/* DeinterlaceTechnology
303DXVA2_DeinterlaceTech_Unknown
304DXVA2_DeinterlaceTech_BOBLineReplicate
305DXVA2_DeinterlaceTech_BOBVerticalStretch
306DXVA2_DeinterlaceTech_BOBVerticalStretch4Tap
307DXVA2_DeinterlaceTech_MedianFiltering
308DXVA2_DeinterlaceTech_EdgeFiltering
309DXVA2_DeinterlaceTech_FieldAdaptive
310DXVA2_DeinterlaceTech_PixelAdaptive
311DXVA2_DeinterlaceTech_MotionVectorSteered
312DXVA2_DeinterlaceTech_InverseTelecine
313*/
314
315/* VideoProcessorOperations
316DXVA2_VideoProcess_YUV2RGB
317DXVA2_VideoProcess_StretchX
318DXVA2_VideoProcess_StretchY
319DXVA2_VideoProcess_AlphaBlend
320DXVA2_VideoProcess_SubRects
321DXVA2_VideoProcess_SubStreams
322DXVA2_VideoProcess_SubStreamsExtended
323DXVA2_VideoProcess_YUV2RGBExtended
324DXVA2_VideoProcess_AlphaBlendExtended
325DXVA2_VideoProcess_Constriction
326DXVA2_VideoProcess_NoiseFilter
327DXVA2_VideoProcess_DetailFilter
328DXVA2_VideoProcess_PlanarAlpha
329DXVA2_VideoProcess_LinearScaling
330DXVA2_VideoProcess_GammaCompensated
331DXVA2_VideoProcess_MaintainsOriginalFieldData
332*/
333
334/*NoiseFilterTechnology
335DXVA2_NoiseFilterTech_Unsupported
336DXVA2_NoiseFilterTech_Unknown
337DXVA2_NoiseFilterTech_Median
338DXVA2_NoiseFilterTech_Temporal
339DXVA2_NoiseFilterTech_BlockNoise
340DXVA2_NoiseFilterTech_MosquitoNoise
341*/
342
343/* DetailFilterTechnology
344DXVA2_DetailFilterTech_Unsupported
345DXVA2_DetailFilterTech_Unknown
346DXVA2_DetailFilterTech_Edge
347DXVA2_DetailFilterTech_Sharpening
348*/
349typedef struct _DXVA2_VideoProcessBltParams {
350  REFERENCE_TIME       TargetFrame;
351  RECT                 TargetRect;
352  SIZE                 ConstrictionSize;
353  UINT                 StreamingFlags;
354  DXVA2_AYUVSample16   BackgroundColor;
355  DXVA2_ExtendedFormat DestFormat;
356  DXVA2_ProcAmpValues  ProcAmpValues;
357  DXVA2_Fixed32        Alpha;
358  DXVA2_FilterValues   NoiseFilterLuma;
359  DXVA2_FilterValues   NoiseFilterChroma;
360  DXVA2_FilterValues   DetailFilterLuma;
361  DXVA2_FilterValues   DetailFilterChroma;
362  DWORD                DestData;
363} DXVA2_VideoProcessBltParams;
364
365#ifdef _D3D9_H_
366typedef struct _DXVA2_VideoProcessorCaps {
367  UINT    DeviceCaps;
368  D3DPOOL InputPool;
369  UINT    NumForwardRefSamples;
370  UINT    NumBackwardRefSamples;
371  UINT    Reserved;
372  UINT    DeinterlaceTechnology;
373  UINT    ProcAmpControlCaps;
374  UINT    VideoProcessorOperations;
375  UINT    NoiseFilterTechnology;
376  UINT    DetailFilterTechnology;
377} DXVA2_VideoProcessorCaps;
378#endif
379
380/* SampleData
381DXVA2_SampleData_RFF
382DXVA2_SampleData_TFF
383DXVA2_SampleData_RFF_TFF_Present
384*/
385
386#ifdef _D3D9_H_
387typedef struct _DXVA2_VideoSample {
388  REFERENCE_TIME       Start;
389  REFERENCE_TIME       End;
390  DXVA2_ExtendedFormat SampleFormat;
391  IDirect3DSurface9*   SrcSurface;
392  RECT                 SrcRect;
393  RECT                 DstRect;
394  DXVA2_AYUVSample8    Pal[16];
395  DXVA2_Fixed32        PlanarAlpha;
396  DWORD                SampleData;
397} DXVA2_VideoSample;
398#endif
399
400/* Constants */
401
402#define DXVA2_VideoDecoderRenderTarget 0
403#define DXVA2_VideoProcessorRenderTarget 1
404#define DXVA2_VideoSoftwareRenderTarget 2
405
406/* CompressedBufferType */
407#define DXVA2_PictureParametersBufferType 0
408#define DXVA2_MacroBlockControlBufferType 1
409#define DXVA2_ResidualDifferenceBufferType 2
410#define DXVA2_DeblockingControlBufferType 3
411#define DXVA2_InverseQuantizationMatrixBufferType 4
412#define DXVA2_SliceControlBufferType 5
413#define DXVA2_BitStreamDateBufferType 6
414#define DXVA2_MotionVectorBuffer 7
415#define DXVA2_FilmGrainBuffer 8
416
417__forceinline const DXVA2_Fixed32 DXVA2_Fixed32OpaqueAlpha (void) {
418  DXVA2_Fixed32 f32;
419  f32.ll = 0 + (1 << 16);
420  return f32;
421}
422
423__forceinline const DXVA2_Fixed32 DXVA2_Fixed32TransparentAlpha (void) {
424  DXVA2_Fixed32 f32;
425  f32.ll = 0;
426  return f32;
427}
428
429__forceinline float DXVA2FixedToFloat (const DXVA2_Fixed32 f32) {
430  return (float)f32.Value + (float)f32.Fraction / (1 << 16);
431}
432
433__forceinline DXVA2_Fixed32 DXVA2FloatToFixed (const float f) {
434  DXVA2_Fixed32 f32;
435  f32.Value    = ((ULONG) (f * (1 << 16))) >> 16;
436  f32.Fraction = ((ULONG) (f * (1 << 16))) & 0xFFFF;
437  return f32;
438}
439#ifdef _D3D9_H_
440HRESULT WINAPI DXVA2CreateDirect3DDeviceManager9(UINT *pResetToken,IDirect3DDeviceManager9 **ppDXVAManager);
441HRESULT WINAPI DXVA2CreateVideoService(IDirect3DDevice9 *pDD,REFIID riid,void **ppService);
442/*****************************************************************************
443 * IDirect3DDeviceManager9 interface
444 */
445#ifndef __IDirect3DDeviceManager9_INTERFACE_DEFINED__
446#define __IDirect3DDeviceManager9_INTERFACE_DEFINED__
447
448DEFINE_GUID(IID_IDirect3DDeviceManager9, 0xa0cade0f, 0x06d5, 0x4cf4, 0xa1,0xc7, 0xf3,0xcd,0xd7,0x25,0xaa,0x75);
449#if defined(__cplusplus) && !defined(CINTERFACE)
450MIDL_INTERFACE("a0cade0f-06d5-4cf4-a1c7-f3cdd725aa75")
451IDirect3DDeviceManager9 : public IUnknown
452{
453    virtual HRESULT STDMETHODCALLTYPE ResetDevice(
454        IDirect3DDevice9 *pDevice,
455        UINT resetToken) = 0;
456
457    virtual HRESULT STDMETHODCALLTYPE OpenDeviceHandle(
458        HANDLE *phDevice) = 0;
459
460    virtual HRESULT STDMETHODCALLTYPE CloseDeviceHandle(
461        HANDLE hDevice) = 0;
462
463    virtual HRESULT STDMETHODCALLTYPE TestDevice(
464        HANDLE hDevice) = 0;
465
466    virtual HRESULT STDMETHODCALLTYPE LockDevice(
467        HANDLE hDevice,
468        IDirect3DDevice9 **ppDevice,
469        WINBOOL fBlock) = 0;
470
471    virtual HRESULT STDMETHODCALLTYPE UnlockDevice(
472        HANDLE hDevice,
473        WINBOOL fSaveState) = 0;
474
475    virtual HRESULT STDMETHODCALLTYPE GetVideoService(
476        HANDLE hDevice,
477        REFIID riid,
478        void **ppService) = 0;
479
480};
481#ifdef __CRT_UUID_DECL
482__CRT_UUID_DECL(IDirect3DDeviceManager9, 0xa0cade0f, 0x06d5, 0x4cf4, 0xa1,0xc7, 0xf3,0xcd,0xd7,0x25,0xaa,0x75)
483#endif
484#else
485typedef struct IDirect3DDeviceManager9Vtbl {
486    BEGIN_INTERFACE
487
488    /*** IUnknown methods ***/
489    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
490        IDirect3DDeviceManager9* This,
491        REFIID riid,
492        void **ppvObject);
493
494    ULONG (STDMETHODCALLTYPE *AddRef)(
495        IDirect3DDeviceManager9* This);
496
497    ULONG (STDMETHODCALLTYPE *Release)(
498        IDirect3DDeviceManager9* This);
499
500    /*** IDirect3DDeviceManager9 methods ***/
501    HRESULT (STDMETHODCALLTYPE *ResetDevice)(
502        IDirect3DDeviceManager9* This,
503        IDirect3DDevice9 *pDevice,
504        UINT resetToken);
505
506    HRESULT (STDMETHODCALLTYPE *OpenDeviceHandle)(
507        IDirect3DDeviceManager9* This,
508        HANDLE *phDevice);
509
510    HRESULT (STDMETHODCALLTYPE *CloseDeviceHandle)(
511        IDirect3DDeviceManager9* This,
512        HANDLE hDevice);
513
514    HRESULT (STDMETHODCALLTYPE *TestDevice)(
515        IDirect3DDeviceManager9* This,
516        HANDLE hDevice);
517
518    HRESULT (STDMETHODCALLTYPE *LockDevice)(
519        IDirect3DDeviceManager9* This,
520        HANDLE hDevice,
521        IDirect3DDevice9 **ppDevice,
522        WINBOOL fBlock);
523
524    HRESULT (STDMETHODCALLTYPE *UnlockDevice)(
525        IDirect3DDeviceManager9* This,
526        HANDLE hDevice,
527        WINBOOL fSaveState);
528
529    HRESULT (STDMETHODCALLTYPE *GetVideoService)(
530        IDirect3DDeviceManager9* This,
531        HANDLE hDevice,
532        REFIID riid,
533        void **ppService);
534
535    END_INTERFACE
536} IDirect3DDeviceManager9Vtbl;
537interface IDirect3DDeviceManager9 {
538    CONST_VTBL IDirect3DDeviceManager9Vtbl* lpVtbl;
539};
540
541#ifdef COBJMACROS
542#ifndef WIDL_C_INLINE_WRAPPERS
543/*** IUnknown methods ***/
544#define IDirect3DDeviceManager9_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
545#define IDirect3DDeviceManager9_AddRef(This) (This)->lpVtbl->AddRef(This)
546#define IDirect3DDeviceManager9_Release(This) (This)->lpVtbl->Release(This)
547/*** IDirect3DDeviceManager9 methods ***/
548#define IDirect3DDeviceManager9_ResetDevice(This,pDevice,resetToken) (This)->lpVtbl->ResetDevice(This,pDevice,resetToken)
549#define IDirect3DDeviceManager9_OpenDeviceHandle(This,phDevice) (This)->lpVtbl->OpenDeviceHandle(This,phDevice)
550#define IDirect3DDeviceManager9_CloseDeviceHandle(This,hDevice) (This)->lpVtbl->CloseDeviceHandle(This,hDevice)
551#define IDirect3DDeviceManager9_TestDevice(This,hDevice) (This)->lpVtbl->TestDevice(This,hDevice)
552#define IDirect3DDeviceManager9_LockDevice(This,hDevice,ppDevice,fBlock) (This)->lpVtbl->LockDevice(This,hDevice,ppDevice,fBlock)
553#define IDirect3DDeviceManager9_UnlockDevice(This,hDevice,fSaveState) (This)->lpVtbl->UnlockDevice(This,hDevice,fSaveState)
554#define IDirect3DDeviceManager9_GetVideoService(This,hDevice,riid,ppService) (This)->lpVtbl->GetVideoService(This,hDevice,riid,ppService)
555#else
556/*** IUnknown methods ***/
557static FORCEINLINE HRESULT IDirect3DDeviceManager9_QueryInterface(IDirect3DDeviceManager9* This,REFIID riid,void **ppvObject) {
558    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
559}
560static FORCEINLINE ULONG IDirect3DDeviceManager9_AddRef(IDirect3DDeviceManager9* This) {
561    return This->lpVtbl->AddRef(This);
562}
563static FORCEINLINE ULONG IDirect3DDeviceManager9_Release(IDirect3DDeviceManager9* This) {
564    return This->lpVtbl->Release(This);
565}
566/*** IDirect3DDeviceManager9 methods ***/
567static FORCEINLINE HRESULT IDirect3DDeviceManager9_ResetDevice(IDirect3DDeviceManager9* This,IDirect3DDevice9 *pDevice,UINT resetToken) {
568    return This->lpVtbl->ResetDevice(This,pDevice,resetToken);
569}
570static FORCEINLINE HRESULT IDirect3DDeviceManager9_OpenDeviceHandle(IDirect3DDeviceManager9* This,HANDLE *phDevice) {
571    return This->lpVtbl->OpenDeviceHandle(This,phDevice);
572}
573static FORCEINLINE HRESULT IDirect3DDeviceManager9_CloseDeviceHandle(IDirect3DDeviceManager9* This,HANDLE hDevice) {
574    return This->lpVtbl->CloseDeviceHandle(This,hDevice);
575}
576static FORCEINLINE HRESULT IDirect3DDeviceManager9_TestDevice(IDirect3DDeviceManager9* This,HANDLE hDevice) {
577    return This->lpVtbl->TestDevice(This,hDevice);
578}
579static FORCEINLINE HRESULT IDirect3DDeviceManager9_LockDevice(IDirect3DDeviceManager9* This,HANDLE hDevice,IDirect3DDevice9 **ppDevice,WINBOOL fBlock) {
580    return This->lpVtbl->LockDevice(This,hDevice,ppDevice,fBlock);
581}
582static FORCEINLINE HRESULT IDirect3DDeviceManager9_UnlockDevice(IDirect3DDeviceManager9* This,HANDLE hDevice,WINBOOL fSaveState) {
583    return This->lpVtbl->UnlockDevice(This,hDevice,fSaveState);
584}
585static FORCEINLINE HRESULT IDirect3DDeviceManager9_GetVideoService(IDirect3DDeviceManager9* This,HANDLE hDevice,REFIID riid,void **ppService) {
586    return This->lpVtbl->GetVideoService(This,hDevice,riid,ppService);
587}
588#endif
589#endif
590
591#endif
592
593HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_ResetDevice_Proxy(
594    IDirect3DDeviceManager9* This,
595    IDirect3DDevice9 *pDevice,
596    UINT resetToken);
597void __RPC_STUB IDirect3DDeviceManager9_ResetDevice_Stub(
598    IRpcStubBuffer* This,
599    IRpcChannelBuffer* pRpcChannelBuffer,
600    PRPC_MESSAGE pRpcMessage,
601    DWORD* pdwStubPhase);
602HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_OpenDeviceHandle_Proxy(
603    IDirect3DDeviceManager9* This,
604    HANDLE *phDevice);
605void __RPC_STUB IDirect3DDeviceManager9_OpenDeviceHandle_Stub(
606    IRpcStubBuffer* This,
607    IRpcChannelBuffer* pRpcChannelBuffer,
608    PRPC_MESSAGE pRpcMessage,
609    DWORD* pdwStubPhase);
610HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_CloseDeviceHandle_Proxy(
611    IDirect3DDeviceManager9* This,
612    HANDLE hDevice);
613void __RPC_STUB IDirect3DDeviceManager9_CloseDeviceHandle_Stub(
614    IRpcStubBuffer* This,
615    IRpcChannelBuffer* pRpcChannelBuffer,
616    PRPC_MESSAGE pRpcMessage,
617    DWORD* pdwStubPhase);
618HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_TestDevice_Proxy(
619    IDirect3DDeviceManager9* This,
620    HANDLE hDevice);
621void __RPC_STUB IDirect3DDeviceManager9_TestDevice_Stub(
622    IRpcStubBuffer* This,
623    IRpcChannelBuffer* pRpcChannelBuffer,
624    PRPC_MESSAGE pRpcMessage,
625    DWORD* pdwStubPhase);
626HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_LockDevice_Proxy(
627    IDirect3DDeviceManager9* This,
628    HANDLE hDevice,
629    IDirect3DDevice9 **ppDevice,
630    WINBOOL fBlock);
631void __RPC_STUB IDirect3DDeviceManager9_LockDevice_Stub(
632    IRpcStubBuffer* This,
633    IRpcChannelBuffer* pRpcChannelBuffer,
634    PRPC_MESSAGE pRpcMessage,
635    DWORD* pdwStubPhase);
636HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_UnlockDevice_Proxy(
637    IDirect3DDeviceManager9* This,
638    HANDLE hDevice,
639    WINBOOL fSaveState);
640void __RPC_STUB IDirect3DDeviceManager9_UnlockDevice_Stub(
641    IRpcStubBuffer* This,
642    IRpcChannelBuffer* pRpcChannelBuffer,
643    PRPC_MESSAGE pRpcMessage,
644    DWORD* pdwStubPhase);
645HRESULT STDMETHODCALLTYPE IDirect3DDeviceManager9_GetVideoService_Proxy(
646    IDirect3DDeviceManager9* This,
647    HANDLE hDevice,
648    REFIID riid,
649    void **ppService);
650void __RPC_STUB IDirect3DDeviceManager9_GetVideoService_Stub(
651    IRpcStubBuffer* This,
652    IRpcChannelBuffer* pRpcChannelBuffer,
653    PRPC_MESSAGE pRpcMessage,
654    DWORD* pdwStubPhase);
655
656#endif  /* __IDirect3DDeviceManager9_INTERFACE_DEFINED__ */
657
658/*****************************************************************************
659 * IDirectXVideoDecoder interface
660 */
661#ifndef __IDirectXVideoDecoder_INTERFACE_DEFINED__
662#define __IDirectXVideoDecoder_INTERFACE_DEFINED__
663
664DEFINE_GUID(IID_IDirectXVideoDecoder, 0xf2b0810a, 0xfd00, 0x43c9, 0x91,0x8c, 0xdf,0x94,0xe2,0xd8,0xef,0x7d);
665#if defined(__cplusplus) && !defined(CINTERFACE)
666MIDL_INTERFACE("f2b0810a-fd00-43c9-918c-df94e2d8ef7d")
667IDirectXVideoDecoder : public IUnknown
668{
669    virtual HRESULT STDMETHODCALLTYPE GetVideoDecoderService(
670        IDirectXVideoDecoderService **ppService) = 0;
671
672    virtual HRESULT STDMETHODCALLTYPE GetCreationParameters(
673        GUID *pDeviceGuid,
674        DXVA2_VideoDesc *pVideoDesc,
675        DXVA2_ConfigPictureDecode *pConfig,
676        IDirect3DSurface9 ***pDecoderRenderTargets,
677        UINT *pNumSurfaces) = 0;
678
679    virtual HRESULT STDMETHODCALLTYPE GetBuffer(
680        UINT BufferType,
681        void **ppBuffer,
682        UINT *pBufferSize) = 0;
683
684    virtual HRESULT STDMETHODCALLTYPE ReleaseBuffer(
685        UINT BufferType) = 0;
686
687    virtual HRESULT STDMETHODCALLTYPE BeginFrame(
688        IDirect3DSurface9 *pRenderTarget,
689        void *pvPVPData) = 0;
690
691    virtual HRESULT STDMETHODCALLTYPE EndFrame(
692        HANDLE *pHandleComplete) = 0;
693
694    virtual HRESULT STDMETHODCALLTYPE Execute(
695        const DXVA2_DecodeExecuteParams *pExecuteParams) = 0;
696
697};
698#ifdef __CRT_UUID_DECL
699__CRT_UUID_DECL(IDirectXVideoDecoder, 0xf2b0810a, 0xfd00, 0x43c9, 0x91,0x8c, 0xdf,0x94,0xe2,0xd8,0xef,0x7d)
700#endif
701#else
702typedef struct IDirectXVideoDecoderVtbl {
703    BEGIN_INTERFACE
704
705    /*** IUnknown methods ***/
706    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
707        IDirectXVideoDecoder* This,
708        REFIID riid,
709        void **ppvObject);
710
711    ULONG (STDMETHODCALLTYPE *AddRef)(
712        IDirectXVideoDecoder* This);
713
714    ULONG (STDMETHODCALLTYPE *Release)(
715        IDirectXVideoDecoder* This);
716
717    /*** IDirectXVideoDecoder methods ***/
718    HRESULT (STDMETHODCALLTYPE *GetVideoDecoderService)(
719        IDirectXVideoDecoder* This,
720        IDirectXVideoDecoderService **ppService);
721
722    HRESULT (STDMETHODCALLTYPE *GetCreationParameters)(
723        IDirectXVideoDecoder* This,
724        GUID *pDeviceGuid,
725        DXVA2_VideoDesc *pVideoDesc,
726        DXVA2_ConfigPictureDecode *pConfig,
727        IDirect3DSurface9 ***pDecoderRenderTargets,
728        UINT *pNumSurfaces);
729
730    HRESULT (STDMETHODCALLTYPE *GetBuffer)(
731        IDirectXVideoDecoder* This,
732        UINT BufferType,
733        void **ppBuffer,
734        UINT *pBufferSize);
735
736    HRESULT (STDMETHODCALLTYPE *ReleaseBuffer)(
737        IDirectXVideoDecoder* This,
738        UINT BufferType);
739
740    HRESULT (STDMETHODCALLTYPE *BeginFrame)(
741        IDirectXVideoDecoder* This,
742        IDirect3DSurface9 *pRenderTarget,
743        void *pvPVPData);
744
745    HRESULT (STDMETHODCALLTYPE *EndFrame)(
746        IDirectXVideoDecoder* This,
747        HANDLE *pHandleComplete);
748
749    HRESULT (STDMETHODCALLTYPE *Execute)(
750        IDirectXVideoDecoder* This,
751        const DXVA2_DecodeExecuteParams *pExecuteParams);
752
753    END_INTERFACE
754} IDirectXVideoDecoderVtbl;
755interface IDirectXVideoDecoder {
756    CONST_VTBL IDirectXVideoDecoderVtbl* lpVtbl;
757};
758
759#ifdef COBJMACROS
760#ifndef WIDL_C_INLINE_WRAPPERS
761/*** IUnknown methods ***/
762#define IDirectXVideoDecoder_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
763#define IDirectXVideoDecoder_AddRef(This) (This)->lpVtbl->AddRef(This)
764#define IDirectXVideoDecoder_Release(This) (This)->lpVtbl->Release(This)
765/*** IDirectXVideoDecoder methods ***/
766#define IDirectXVideoDecoder_GetVideoDecoderService(This,ppService) (This)->lpVtbl->GetVideoDecoderService(This,ppService)
767#define IDirectXVideoDecoder_GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces) (This)->lpVtbl->GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces)
768#define IDirectXVideoDecoder_GetBuffer(This,BufferType,ppBuffer,pBufferSize) (This)->lpVtbl->GetBuffer(This,BufferType,ppBuffer,pBufferSize)
769#define IDirectXVideoDecoder_ReleaseBuffer(This,BufferType) (This)->lpVtbl->ReleaseBuffer(This,BufferType)
770#define IDirectXVideoDecoder_BeginFrame(This,pRenderTarget,pvPVPData) (This)->lpVtbl->BeginFrame(This,pRenderTarget,pvPVPData)
771#define IDirectXVideoDecoder_EndFrame(This,pHandleComplete) (This)->lpVtbl->EndFrame(This,pHandleComplete)
772#define IDirectXVideoDecoder_Execute(This,pExecuteParams) (This)->lpVtbl->Execute(This,pExecuteParams)
773#else
774/*** IUnknown methods ***/
775static FORCEINLINE HRESULT IDirectXVideoDecoder_QueryInterface(IDirectXVideoDecoder* This,REFIID riid,void **ppvObject) {
776    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
777}
778static FORCEINLINE ULONG IDirectXVideoDecoder_AddRef(IDirectXVideoDecoder* This) {
779    return This->lpVtbl->AddRef(This);
780}
781static FORCEINLINE ULONG IDirectXVideoDecoder_Release(IDirectXVideoDecoder* This) {
782    return This->lpVtbl->Release(This);
783}
784/*** IDirectXVideoDecoder methods ***/
785static FORCEINLINE HRESULT IDirectXVideoDecoder_GetVideoDecoderService(IDirectXVideoDecoder* This,IDirectXVideoDecoderService **ppService) {
786    return This->lpVtbl->GetVideoDecoderService(This,ppService);
787}
788static FORCEINLINE HRESULT IDirectXVideoDecoder_GetCreationParameters(IDirectXVideoDecoder* This,GUID *pDeviceGuid,DXVA2_VideoDesc *pVideoDesc,DXVA2_ConfigPictureDecode *pConfig,IDirect3DSurface9 ***pDecoderRenderTargets,UINT *pNumSurfaces) {
789    return This->lpVtbl->GetCreationParameters(This,pDeviceGuid,pVideoDesc,pConfig,pDecoderRenderTargets,pNumSurfaces);
790}
791static FORCEINLINE HRESULT IDirectXVideoDecoder_GetBuffer(IDirectXVideoDecoder* This,UINT BufferType,void **ppBuffer,UINT *pBufferSize) {
792    return This->lpVtbl->GetBuffer(This,BufferType,ppBuffer,pBufferSize);
793}
794static FORCEINLINE HRESULT IDirectXVideoDecoder_ReleaseBuffer(IDirectXVideoDecoder* This,UINT BufferType) {
795    return This->lpVtbl->ReleaseBuffer(This,BufferType);
796}
797static FORCEINLINE HRESULT IDirectXVideoDecoder_BeginFrame(IDirectXVideoDecoder* This,IDirect3DSurface9 *pRenderTarget,void *pvPVPData) {
798    return This->lpVtbl->BeginFrame(This,pRenderTarget,pvPVPData);
799}
800static FORCEINLINE HRESULT IDirectXVideoDecoder_EndFrame(IDirectXVideoDecoder* This,HANDLE *pHandleComplete) {
801    return This->lpVtbl->EndFrame(This,pHandleComplete);
802}
803static FORCEINLINE HRESULT IDirectXVideoDecoder_Execute(IDirectXVideoDecoder* This,const DXVA2_DecodeExecuteParams *pExecuteParams) {
804    return This->lpVtbl->Execute(This,pExecuteParams);
805}
806#endif
807#endif
808
809#endif
810
811HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_GetVideoDecoderService_Proxy(
812    IDirectXVideoDecoder* This,
813    IDirectXVideoDecoderService **ppService);
814void __RPC_STUB IDirectXVideoDecoder_GetVideoDecoderService_Stub(
815    IRpcStubBuffer* This,
816    IRpcChannelBuffer* pRpcChannelBuffer,
817    PRPC_MESSAGE pRpcMessage,
818    DWORD* pdwStubPhase);
819HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_GetCreationParameters_Proxy(
820    IDirectXVideoDecoder* This,
821    GUID *pDeviceGuid,
822    DXVA2_VideoDesc *pVideoDesc,
823    DXVA2_ConfigPictureDecode *pConfig,
824    IDirect3DSurface9 ***pDecoderRenderTargets,
825    UINT *pNumSurfaces);
826void __RPC_STUB IDirectXVideoDecoder_GetCreationParameters_Stub(
827    IRpcStubBuffer* This,
828    IRpcChannelBuffer* pRpcChannelBuffer,
829    PRPC_MESSAGE pRpcMessage,
830    DWORD* pdwStubPhase);
831HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_GetBuffer_Proxy(
832    IDirectXVideoDecoder* This,
833    UINT BufferType,
834    void **ppBuffer,
835    UINT *pBufferSize);
836void __RPC_STUB IDirectXVideoDecoder_GetBuffer_Stub(
837    IRpcStubBuffer* This,
838    IRpcChannelBuffer* pRpcChannelBuffer,
839    PRPC_MESSAGE pRpcMessage,
840    DWORD* pdwStubPhase);
841HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_ReleaseBuffer_Proxy(
842    IDirectXVideoDecoder* This,
843    UINT BufferType);
844void __RPC_STUB IDirectXVideoDecoder_ReleaseBuffer_Stub(
845    IRpcStubBuffer* This,
846    IRpcChannelBuffer* pRpcChannelBuffer,
847    PRPC_MESSAGE pRpcMessage,
848    DWORD* pdwStubPhase);
849HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_BeginFrame_Proxy(
850    IDirectXVideoDecoder* This,
851    IDirect3DSurface9 *pRenderTarget,
852    void *pvPVPData);
853void __RPC_STUB IDirectXVideoDecoder_BeginFrame_Stub(
854    IRpcStubBuffer* This,
855    IRpcChannelBuffer* pRpcChannelBuffer,
856    PRPC_MESSAGE pRpcMessage,
857    DWORD* pdwStubPhase);
858HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_EndFrame_Proxy(
859    IDirectXVideoDecoder* This,
860    HANDLE *pHandleComplete);
861void __RPC_STUB IDirectXVideoDecoder_EndFrame_Stub(
862    IRpcStubBuffer* This,
863    IRpcChannelBuffer* pRpcChannelBuffer,
864    PRPC_MESSAGE pRpcMessage,
865    DWORD* pdwStubPhase);
866HRESULT STDMETHODCALLTYPE IDirectXVideoDecoder_Execute_Proxy(
867    IDirectXVideoDecoder* This,
868    const DXVA2_DecodeExecuteParams *pExecuteParams);
869void __RPC_STUB IDirectXVideoDecoder_Execute_Stub(
870    IRpcStubBuffer* This,
871    IRpcChannelBuffer* pRpcChannelBuffer,
872    PRPC_MESSAGE pRpcMessage,
873    DWORD* pdwStubPhase);
874
875#endif  /* __IDirectXVideoDecoder_INTERFACE_DEFINED__ */
876
877/*****************************************************************************
878 * IDirectXVideoAccelerationService interface
879 */
880#ifndef __IDirectXVideoAccelerationService_INTERFACE_DEFINED__
881#define __IDirectXVideoAccelerationService_INTERFACE_DEFINED__
882
883DEFINE_GUID(IID_IDirectXVideoAccelerationService, 0xfc51a550, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02);
884#if defined(__cplusplus) && !defined(CINTERFACE)
885MIDL_INTERFACE("fc51a550-d5e7-11d9-af55-00054e43ff02")
886IDirectXVideoAccelerationService : public IUnknown
887{
888    virtual HRESULT STDMETHODCALLTYPE CreateSurface(
889        UINT Width,
890        UINT Height,
891        UINT BackBuffers,
892        D3DFORMAT Format,
893        D3DPOOL Pool,
894        DWORD Usage,
895        DWORD DxvaType,
896        IDirect3DSurface9 **ppSurface,
897        HANDLE *pSharedHandle) = 0;
898
899};
900#ifdef __CRT_UUID_DECL
901__CRT_UUID_DECL(IDirectXVideoAccelerationService, 0xfc51a550, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02)
902#endif
903#else
904typedef struct IDirectXVideoAccelerationServiceVtbl {
905    BEGIN_INTERFACE
906
907    /*** IUnknown methods ***/
908    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
909        IDirectXVideoAccelerationService* This,
910        REFIID riid,
911        void **ppvObject);
912
913    ULONG (STDMETHODCALLTYPE *AddRef)(
914        IDirectXVideoAccelerationService* This);
915
916    ULONG (STDMETHODCALLTYPE *Release)(
917        IDirectXVideoAccelerationService* This);
918
919    /*** IDirectXVideoAccelerationService methods ***/
920    HRESULT (STDMETHODCALLTYPE *CreateSurface)(
921        IDirectXVideoAccelerationService* This,
922        UINT Width,
923        UINT Height,
924        UINT BackBuffers,
925        D3DFORMAT Format,
926        D3DPOOL Pool,
927        DWORD Usage,
928        DWORD DxvaType,
929        IDirect3DSurface9 **ppSurface,
930        HANDLE *pSharedHandle);
931
932    END_INTERFACE
933} IDirectXVideoAccelerationServiceVtbl;
934interface IDirectXVideoAccelerationService {
935    CONST_VTBL IDirectXVideoAccelerationServiceVtbl* lpVtbl;
936};
937
938#ifdef COBJMACROS
939#ifndef WIDL_C_INLINE_WRAPPERS
940/*** IUnknown methods ***/
941#define IDirectXVideoAccelerationService_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
942#define IDirectXVideoAccelerationService_AddRef(This) (This)->lpVtbl->AddRef(This)
943#define IDirectXVideoAccelerationService_Release(This) (This)->lpVtbl->Release(This)
944/*** IDirectXVideoAccelerationService methods ***/
945#define IDirectXVideoAccelerationService_CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle) (This)->lpVtbl->CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle)
946#else
947/*** IUnknown methods ***/
948static FORCEINLINE HRESULT IDirectXVideoAccelerationService_QueryInterface(IDirectXVideoAccelerationService* This,REFIID riid,void **ppvObject) {
949    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
950}
951static FORCEINLINE ULONG IDirectXVideoAccelerationService_AddRef(IDirectXVideoAccelerationService* This) {
952    return This->lpVtbl->AddRef(This);
953}
954static FORCEINLINE ULONG IDirectXVideoAccelerationService_Release(IDirectXVideoAccelerationService* This) {
955    return This->lpVtbl->Release(This);
956}
957/*** IDirectXVideoAccelerationService methods ***/
958static FORCEINLINE HRESULT IDirectXVideoAccelerationService_CreateSurface(IDirectXVideoAccelerationService* This,UINT Width,UINT Height,UINT BackBuffers,D3DFORMAT Format,D3DPOOL Pool,DWORD Usage,DWORD DxvaType,IDirect3DSurface9 **ppSurface,HANDLE *pSharedHandle) {
959    return This->lpVtbl->CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle);
960}
961#endif
962#endif
963
964#endif
965
966HRESULT STDMETHODCALLTYPE IDirectXVideoAccelerationService_CreateSurface_Proxy(
967    IDirectXVideoAccelerationService* This,
968    UINT Width,
969    UINT Height,
970    UINT BackBuffers,
971    D3DFORMAT Format,
972    D3DPOOL Pool,
973    DWORD Usage,
974    DWORD DxvaType,
975    IDirect3DSurface9 **ppSurface,
976    HANDLE *pSharedHandle);
977void __RPC_STUB IDirectXVideoAccelerationService_CreateSurface_Stub(
978    IRpcStubBuffer* This,
979    IRpcChannelBuffer* pRpcChannelBuffer,
980    PRPC_MESSAGE pRpcMessage,
981    DWORD* pdwStubPhase);
982
983#endif  /* __IDirectXVideoAccelerationService_INTERFACE_DEFINED__ */
984
985/*****************************************************************************
986 * IDirectXVideoDecoderService interface
987 */
988#ifndef __IDirectXVideoDecoderService_INTERFACE_DEFINED__
989#define __IDirectXVideoDecoderService_INTERFACE_DEFINED__
990
991DEFINE_GUID(IID_IDirectXVideoDecoderService, 0xfc51a551, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02);
992#if defined(__cplusplus) && !defined(CINTERFACE)
993MIDL_INTERFACE("fc51a551-d5e7-11d9-af55-00054e43ff02")
994IDirectXVideoDecoderService : public IDirectXVideoAccelerationService
995{
996    virtual HRESULT STDMETHODCALLTYPE GetDecoderDeviceGuids(
997        UINT *pCount,
998        GUID **pGuids) = 0;
999
1000    virtual HRESULT STDMETHODCALLTYPE GetDecoderRenderTargets(
1001        REFGUID Guid,
1002        UINT *pCount,
1003        D3DFORMAT **pFormats) = 0;
1004
1005    virtual HRESULT STDMETHODCALLTYPE GetDecoderConfigurations(
1006        REFGUID Guid,
1007        const DXVA2_VideoDesc *pVideoDesc,
1008        void *pReserved,
1009        UINT *pCount,
1010        DXVA2_ConfigPictureDecode **ppConfigs) = 0;
1011
1012    virtual HRESULT STDMETHODCALLTYPE CreateVideoDecoder(
1013        REFGUID Guid,
1014        const DXVA2_VideoDesc *pVideoDesc,
1015        const DXVA2_ConfigPictureDecode *pConfig,
1016        IDirect3DSurface9 **ppDecoderRenderTargets,
1017        UINT NumRenderTargets,
1018        IDirectXVideoDecoder **ppDecode) = 0;
1019
1020};
1021#ifdef __CRT_UUID_DECL
1022__CRT_UUID_DECL(IDirectXVideoDecoderService, 0xfc51a551, 0xd5e7, 0x11d9, 0xaf,0x55, 0x00,0x05,0x4e,0x43,0xff,0x02)
1023#endif
1024#else
1025typedef struct IDirectXVideoDecoderServiceVtbl {
1026    BEGIN_INTERFACE
1027
1028    /*** IUnknown methods ***/
1029    HRESULT (STDMETHODCALLTYPE *QueryInterface)(
1030        IDirectXVideoDecoderService* This,
1031        REFIID riid,
1032        void **ppvObject);
1033
1034    ULONG (STDMETHODCALLTYPE *AddRef)(
1035        IDirectXVideoDecoderService* This);
1036
1037    ULONG (STDMETHODCALLTYPE *Release)(
1038        IDirectXVideoDecoderService* This);
1039
1040    /*** IDirectXVideoAccelerationService methods ***/
1041    HRESULT (STDMETHODCALLTYPE *CreateSurface)(
1042        IDirectXVideoDecoderService* This,
1043        UINT Width,
1044        UINT Height,
1045        UINT BackBuffers,
1046        D3DFORMAT Format,
1047        D3DPOOL Pool,
1048        DWORD Usage,
1049        DWORD DxvaType,
1050        IDirect3DSurface9 **ppSurface,
1051        HANDLE *pSharedHandle);
1052
1053    /*** IDirectXVideoDecoderService methods ***/
1054    HRESULT (STDMETHODCALLTYPE *GetDecoderDeviceGuids)(
1055        IDirectXVideoDecoderService* This,
1056        UINT *pCount,
1057        GUID **pGuids);
1058
1059    HRESULT (STDMETHODCALLTYPE *GetDecoderRenderTargets)(
1060        IDirectXVideoDecoderService* This,
1061        REFGUID Guid,
1062        UINT *pCount,
1063        D3DFORMAT **pFormats);
1064
1065    HRESULT (STDMETHODCALLTYPE *GetDecoderConfigurations)(
1066        IDirectXVideoDecoderService* This,
1067        REFGUID Guid,
1068        const DXVA2_VideoDesc *pVideoDesc,
1069        void *pReserved,
1070        UINT *pCount,
1071        DXVA2_ConfigPictureDecode **ppConfigs);
1072
1073    HRESULT (STDMETHODCALLTYPE *CreateVideoDecoder)(
1074        IDirectXVideoDecoderService* This,
1075        REFGUID Guid,
1076        const DXVA2_VideoDesc *pVideoDesc,
1077        const DXVA2_ConfigPictureDecode *pConfig,
1078        IDirect3DSurface9 **ppDecoderRenderTargets,
1079        UINT NumRenderTargets,
1080        IDirectXVideoDecoder **ppDecode);
1081
1082    END_INTERFACE
1083} IDirectXVideoDecoderServiceVtbl;
1084interface IDirectXVideoDecoderService {
1085    CONST_VTBL IDirectXVideoDecoderServiceVtbl* lpVtbl;
1086};
1087
1088#ifdef COBJMACROS
1089#ifndef WIDL_C_INLINE_WRAPPERS
1090/*** IUnknown methods ***/
1091#define IDirectXVideoDecoderService_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
1092#define IDirectXVideoDecoderService_AddRef(This) (This)->lpVtbl->AddRef(This)
1093#define IDirectXVideoDecoderService_Release(This) (This)->lpVtbl->Release(This)
1094/*** IDirectXVideoAccelerationService methods ***/
1095#define IDirectXVideoDecoderService_CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle) (This)->lpVtbl->CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle)
1096/*** IDirectXVideoDecoderService methods ***/
1097#define IDirectXVideoDecoderService_GetDecoderDeviceGuids(This,pCount,pGuids) (This)->lpVtbl->GetDecoderDeviceGuids(This,pCount,pGuids)
1098#define IDirectXVideoDecoderService_GetDecoderRenderTargets(This,Guid,pCount,pFormats) (This)->lpVtbl->GetDecoderRenderTargets(This,Guid,pCount,pFormats)
1099#define IDirectXVideoDecoderService_GetDecoderConfigurations(This,Guid,pVideoDesc,pReserved,pCount,ppConfigs) (This)->lpVtbl->GetDecoderConfigurations(This,Guid,pVideoDesc,pReserved,pCount,ppConfigs)
1100#define IDirectXVideoDecoderService_CreateVideoDecoder(This,Guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumRenderTargets,ppDecode) (This)->lpVtbl->CreateVideoDecoder(This,Guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumRenderTargets,ppDecode)
1101#else
1102/*** IUnknown methods ***/
1103static FORCEINLINE HRESULT IDirectXVideoDecoderService_QueryInterface(IDirectXVideoDecoderService* This,REFIID riid,void **ppvObject) {
1104    return This->lpVtbl->QueryInterface(This,riid,ppvObject);
1105}
1106static FORCEINLINE ULONG IDirectXVideoDecoderService_AddRef(IDirectXVideoDecoderService* This) {
1107    return This->lpVtbl->AddRef(This);
1108}
1109static FORCEINLINE ULONG IDirectXVideoDecoderService_Release(IDirectXVideoDecoderService* This) {
1110    return This->lpVtbl->Release(This);
1111}
1112/*** IDirectXVideoAccelerationService methods ***/
1113static FORCEINLINE HRESULT IDirectXVideoDecoderService_CreateSurface(IDirectXVideoDecoderService* This,UINT Width,UINT Height,UINT BackBuffers,D3DFORMAT Format,D3DPOOL Pool,DWORD Usage,DWORD DxvaType,IDirect3DSurface9 **ppSurface,HANDLE *pSharedHandle) {
1114    return This->lpVtbl->CreateSurface(This,Width,Height,BackBuffers,Format,Pool,Usage,DxvaType,ppSurface,pSharedHandle);
1115}
1116/*** IDirectXVideoDecoderService methods ***/
1117static FORCEINLINE HRESULT IDirectXVideoDecoderService_GetDecoderDeviceGuids(IDirectXVideoDecoderService* This,UINT *pCount,GUID **pGuids) {
1118    return This->lpVtbl->GetDecoderDeviceGuids(This,pCount,pGuids);
1119}
1120static FORCEINLINE HRESULT IDirectXVideoDecoderService_GetDecoderRenderTargets(IDirectXVideoDecoderService* This,REFGUID Guid,UINT *pCount,D3DFORMAT **pFormats) {
1121    return This->lpVtbl->GetDecoderRenderTargets(This,Guid,pCount,pFormats);
1122}
1123static FORCEINLINE HRESULT IDirectXVideoDecoderService_GetDecoderConfigurations(IDirectXVideoDecoderService* This,REFGUID Guid,const DXVA2_VideoDesc *pVideoDesc,void *pReserved,UINT *pCount,DXVA2_ConfigPictureDecode **ppConfigs) {
1124    return This->lpVtbl->GetDecoderConfigurations(This,Guid,pVideoDesc,pReserved,pCount,ppConfigs);
1125}
1126static FORCEINLINE HRESULT IDirectXVideoDecoderService_CreateVideoDecoder(IDirectXVideoDecoderService* This,REFGUID Guid,const DXVA2_VideoDesc *pVideoDesc,const DXVA2_ConfigPictureDecode *pConfig,IDirect3DSurface9 **ppDecoderRenderTargets,UINT NumRenderTargets,IDirectXVideoDecoder **ppDecode) {
1127    return This->lpVtbl->CreateVideoDecoder(This,Guid,pVideoDesc,pConfig,ppDecoderRenderTargets,NumRenderTargets,ppDecode);
1128}
1129#endif
1130#endif
1131
1132#endif
1133
1134HRESULT STDMETHODCALLTYPE IDirectXVideoDecoderService_GetDecoderDeviceGuids_Proxy(
1135    IDirectXVideoDecoderService* This,
1136    UINT *pCount,
1137    GUID **pGuids);
1138void __RPC_STUB IDirectXVideoDecoderService_GetDecoderDeviceGuids_Stub(
1139    IRpcStubBuffer* This,
1140    IRpcChannelBuffer* pRpcChannelBuffer,
1141    PRPC_MESSAGE pRpcMessage,
1142    DWORD* pdwStubPhase);
1143HRESULT STDMETHODCALLTYPE IDirectXVideoDecoderService_GetDecoderRenderTargets_Proxy(
1144    IDirectXVideoDecoderService* This,
1145    REFGUID Guid,
1146    UINT *pCount,
1147    D3DFORMAT **pFormats);
1148void __RPC_STUB IDirectXVideoDecoderService_GetDecoderRenderTargets_Stub(
1149    IRpcStubBuffer* This,
1150    IRpcChannelBuffer* pRpcChannelBuffer,
1151    PRPC_MESSAGE pRpcMessage,
1152    DWORD* pdwStubPhase);
1153HRESULT STDMETHODCALLTYPE IDirectXVideoDecoderService_GetDecoderConfigurations_Proxy(
1154    IDirectXVideoDecoderService* This,
1155    REFGUID Guid,
1156    const DXVA2_VideoDesc *pVideoDesc,
1157    void *pReserved,
1158    UINT *pCount,
1159    DXVA2_ConfigPictureDecode **ppConfigs);
1160void __RPC_STUB IDirectXVideoDecoderService_GetDecoderConfigurations_Stub(
1161    IRpcStubBuffer* This,
1162    IRpcChannelBuffer* pRpcChannelBuffer,
1163    PRPC_MESSAGE pRpcMessage,
1164    DWORD* pdwStubPhase);
1165HRESULT STDMETHODCALLTYPE IDirectXVideoDecoderService_CreateVideoDecoder_Proxy(
1166    IDirectXVideoDecoderService* This,
1167    REFGUID Guid,
1168    const DXVA2_VideoDesc *pVideoDesc,
1169    const DXVA2_ConfigPictureDecode *pConfig,
1170    IDirect3DSurface9 **ppDecoderRenderTargets,
1171    UINT NumRenderTargets,
1172    IDirectXVideoDecoder **ppDecode);
1173void __RPC_STUB IDirectXVideoDecoderService_CreateVideoDecoder_Stub(
1174    IRpcStubBuffer* This,
1175    IRpcChannelBuffer* pRpcChannelBuffer,
1176    PRPC_MESSAGE pRpcMessage,
1177    DWORD* pdwStubPhase);
1178
1179#endif  /* __IDirectXVideoDecoderService_INTERFACE_DEFINED__ */
1180
1181#endif /* _D3D9_H_ */
1182/* Begin additional prototypes for all interfaces */
1183
1184
1185/* End additional prototypes */
1186
1187#ifdef __cplusplus
1188}
1189#endif
1190
1191#endif /* __dxva2api_h__ */
1192