ReactOS 0.4.15-dev-7677-g8209aa5
vmrender.idl
Go to the documentation of this file.
1
2cpp_quote("#if 0")
3
4 import "unknwn.idl";
5
10 typedef struct {DWORD dw1; DWORD dw2;} DDCOLORKEY;
12cpp_quote ("#endif")
13
14cpp_quote("#include <ddraw.h>")
15
16cpp_quote("#define VMRBITMAP_DISABLE 0x00000001")
17cpp_quote("#define VMRBITMAP_HDC 0x00000002")
18cpp_quote("#define VMRBITMAP_ENTIREDDS 0x00000004")
19cpp_quote("#define VMRBITMAP_SRCCOLORKEY 0x00000008")
20cpp_quote("#define VMRBITMAP_SRCRECT 0x00000010")
21
22interface IVMRSurface;
23interface IVMRSurfaceAllocator;
24interface IVMRSurfaceAllocatorNotify;
25interface IVMRImagePresenter;
26interface IVMRImagePresenterConfig;
27interface IVMRWindowlessControl;
28interface IVMRMixerControl;
29interface IVMRMixerBitmap;
30interface IVMRFilterConfig;
31interface IVMRAspectRatioControl;
32interface IVMRDeinterlaceControl;
33interface IVMRMonitorConfig;
34interface IVMRImageCompositor;
35interface IVMRVideoStreamControl;
36
37#define VMRDEVICENAMELEN 32
38#define VMRDEVICEDESCRIPTIONLEN 256
39
40typedef enum
41{
42 VMRSample_SyncPoint = 0x00000001,
43 VMRSample_Preroll = 0x00000002,
44 VMRSample_Discontinuity = 0x00000004,
45 VMRSample_TimeValid = 0x00000008,
46 VMRSample_SrcDstRectsValid= 0x00000010
47} VMRPresentationFlags;
48
49typedef enum
50{
51 AMAP_PIXELFORMAT_VALID = 0x01,
52 AMAP_3D_TARGET = 0x02,
53 AMAP_ALLOW_SYSMEM = 0x04,
54 AMAP_FORCE_SYSMEM = 0x08,
55 AMAP_DIRECTED_FLIP = 0x10,
56 AMAP_DXVA_TARGET = 0x20
57} VMRSurfaceAllocationFlags;
58
59typedef enum
60{
61 VMR_ARMODE_NONE,
62 VMR_ARMODE_LETTER_BOX
63} VMR_ASPECT_RATIO_MODE;
64
65
66typedef enum
67{
68 MixerPref_NoDecimation = 0x00000001,
69 MixerPref_DecimateOutput = 0x00000002,
70 MixerPref_ARAdjustXorY = 0x00000004,
71 MixerPref_DecimationReserved = 0x00000008,
72 MixerPref_DecimateMask = 0x0000000F,
73 MixerPref_BiLinearFiltering = 0x00000010,
74 MixerPref_PointFiltering = 0x00000020,
75 MixerPref_FilteringMask = 0x000000F0,
76 MixerPref_RenderTargetRGB = 0x00000100,
77 MixerPref_RenderTargetYUV = 0x00001000,
78 MixerPref_RenderTargetYUV420 = 0x00000200,
79 MixerPref_RenderTargetYUV422 = 0x00000400,
80 MixerPref_RenderTargetYUV444 = 0x00000800,
81 MixerPref_RenderTargetReserved = 0x0000E000,
82 MixerPref_RenderTargetMask = 0x0000FF00,
83 MixerPref_DynamicSwitchToBOB = 0x00010000,
84 MixerPref_DynamicDecimateBy2 = 0x00020000,
85 MixerPref_DynamicReserved = 0x000C0000,
86 MixerPref_DynamicMask = 0x000F0000
87} VMRMixerPrefs;
88
89typedef enum
90{
91 RenderPrefs_RestrictToInitialMonitor = 0x00000000,
92 RenderPrefs_ForceOffscreen = 0x00000001,
93 RenderPrefs_ForceOverlays = 0x00000002,
94 RenderPrefs_AllowOverlays = 0x00000000,
95 RenderPrefs_AllowOffscreen = 0x00000000,
96 RenderPrefs_DoNotRenderColorKeyAndBorder = 0x00000008,
97 RenderPrefs_Reserved = 0x00000010,
98 RenderPrefs_PreferAGPMemWhenMixing = 0x00000020,
99
100 RenderPrefs_Mask = 0x0000003f,
101} VMRRenderPrefs;
102
103typedef enum
104{
105 VMRMode_Windowed = 0x00000001,
106 VMRMode_Windowless = 0x00000002,
107 VMRMode_Renderless = 0x00000004,
108 VMRMode_Mask = 0x00000007,
109} VMRMode;
110
111enum
112{
113 MAX_NUMBER_OF_STREAMS = 16
115
116typedef enum
117{
118 DeinterlacePref_NextBest = 0x01,
119 DeinterlacePref_BOB = 0x02,
120 DeinterlacePref_Weave = 0x04,
121 DeinterlacePref_Mask = 0x07
122} VMRDeinterlacePrefs;
123
124typedef enum
125{
126 DeinterlaceTech_Unknown = 0x0000,
127 DeinterlaceTech_BOBLineReplicate = 0x0001,
128 DeinterlaceTech_BOBVerticalStretch = 0x0002,
129 DeinterlaceTech_MedianFiltering = 0x0004,
130 DeinterlaceTech_EdgeFiltering = 0x0010,
131 DeinterlaceTech_FieldAdaptive = 0x0020,
132 DeinterlaceTech_PixelAdaptive = 0x0040,
133 DeinterlaceTech_MotionVectorSteered = 0x0080
134} VMRDeinterlaceTech;
135
136typedef struct tagVMRPRESENTATIONINFO
137{
138 DWORD dwFlags;
139 LPDIRECTDRAWSURFACE7 lpSurf;
140 REFERENCE_TIME rtStart;
141 REFERENCE_TIME rtEnd;
142 SIZE szAspectRatio;
143 RECT rcSrc;
144 RECT rcDst;
145 DWORD dwTypeSpecificFlags;
146 DWORD dwInterlaceFlags;
147} VMRPRESENTATIONINFO;
148
149typedef struct tagVMRALLOCATIONINFO
150{
151 DWORD dwFlags;
152 LPBITMAPINFOHEADER lpHdr;
153 LPDDPIXELFORMAT lpPixFmt;
154 SIZE szAspectRatio;
155 DWORD dwMinBuffers;
156 DWORD dwMaxBuffers;
157 DWORD dwInterlaceFlags;
158 SIZE szNativeSize;
159} VMRALLOCATIONINFO;
160
161typedef struct _NORMALIZEDRECT
162{
163 float left;
164 float top;
165 float right;
166 float bottom;
167} NORMALIZEDRECT, *PNORMALIZEDRECT;
168
169typedef struct tagVMRGUID
170{
171 struct _GUID *pGUID, GUID;
172} VMRGUID;
173
174typedef struct tagVMRMONITORINFO
175{
176 VMRGUID guid;
177 RECT rcMonitor;
178 HMONITOR hMon;
179 DWORD dwFlags;
180 wchar_t szDevice[VMRDEVICENAMELEN];
181 wchar_t szDescription[VMRDEVICEDESCRIPTIONLEN];
182 LARGE_INTEGER liDriverVersion;
183 DWORD dwVendorId;
184 DWORD dwDeviceId;
185 DWORD dwSubSysId;
186 DWORD dwRevision;
187} VMRMONITORINFO;
188
189typedef struct _VMRFrequency
190{
191 DWORD dwNumerator;
192 DWORD dwDenominator;
193} VMRFrequency;
194
195typedef struct _VMRVideoDesc
196{
197 DWORD dwSize;
198 DWORD dwSampleWidth;
199 DWORD dwSampleHeight;
200 BOOL SingleFieldPerSample;
201 DWORD dwFourCC;
202 VMRFrequency InputSampleFreq;
203 VMRFrequency OutputFrameFreq;
204} VMRVideoDesc;
205
206typedef struct _VMRDeinterlaceCaps
207{
208 DWORD dwSize;
209 DWORD dwNumPreviousOutputFrames;
210 DWORD dwNumForwardRefSamples;
211 DWORD dwNumBackwardRefSamples;
212 VMRDeinterlaceTech DeinterlaceTechnology;
213} VMRDeinterlaceCaps;
214
215typedef struct _VMRALPHABITMAP
216{
217 DWORD dwFlags;
218 HDC hdc;
219 LPDIRECTDRAWSURFACE7 pDDS;
220 RECT rSrc;
221 NORMALIZEDRECT rDest;
222 FLOAT fAlpha;
223 COLORREF clrSrcKey;
224} VMRALPHABITMAP, *PVMRALPHABITMAP;
225
226typedef struct _VMRVIDEOSTREAMINFO
227{
228 LPDIRECTDRAWSURFACE7 pddsVideoSurface;
229 DWORD dwWidth;
230 DWORD dwHeight;
231 FLOAT dwStrmID;
232 FLOAT fAlpha;
233 DDCOLORKEY ddClrKey;
234 NORMALIZEDRECT rNormal;
235} VMRVIDEOSTREAMINFO;
236
237
238
239[
240 local,
241 object,
242 uuid(CE704FE7-E71E-41fb-BAA2-C4403E1182F5),
243 pointer_default(unique)
244]
245interface IVMRImagePresenter : IUnknown
246{
247 HRESULT StartPresenting([in] DWORD_PTR dwUserID);
248 HRESULT StopPresenting([in] DWORD_PTR dwUserID);
249 HRESULT PresentImage([in] DWORD_PTR dwUserID, [in] VMRPRESENTATIONINFO* lpPresInfo);
250};
251
252[
253 local,
254 object,
255 uuid(31ce832e-4484-458b-8cca-f4d7e3db0b52),
256 pointer_default(unique)
257]
258interface IVMRSurfaceAllocator : IUnknown
259{
260 HRESULT AllocateSurface([in] DWORD_PTR dwUserID, [in] VMRALLOCATIONINFO* lpAllocInfo, [in] [out] DWORD* lpdwActualBuffers, [out] LPDIRECTDRAWSURFACE7 *lplpSurface);
261 HRESULT FreeSurface([in] DWORD_PTR dwID);
262 HRESULT PrepareSurface([in] DWORD_PTR dwUserID, [in] LPDIRECTDRAWSURFACE7 lpSurface, [in] DWORD dwSurfaceFlags);
263 HRESULT AdviseNotify([in] IVMRSurfaceAllocatorNotify* lpIVMRSurfAllocNotify);
264};
265
266[
267 local,
268 object,
269 uuid(aada05a8-5a4e-4729-af0b-cea27aed51e2),
270 pointer_default(unique)
271]
272interface IVMRSurfaceAllocatorNotify : IUnknown
273{
274 HRESULT AdviseSurfaceAllocator([in] DWORD_PTR dwUserID, [in] IVMRSurfaceAllocator* lpIVRMSurfaceAllocator);
275 HRESULT SetDDrawDevice([in] LPDIRECTDRAW7 lpDDrawDevice, [in] HMONITOR hMonitor);
276 HRESULT ChangeDDrawDevice([in] LPDIRECTDRAW7 lpDDrawDevice, [in] HMONITOR hMonitor);
277 HRESULT RestoreDDrawSurfaces();
278 HRESULT NotifyEvent([in] LONG EventCode, [in] LONG_PTR Param1, [in] LONG_PTR Param2);
279 HRESULT SetBorderColor([in] COLORREF clrBorder);
280};
281
282[
283 local,
284 object,
285 uuid(0eb1088c-4dcd-46f0-878f-39dae86a51b7),
286 pointer_default(unique)
287]
288interface IVMRWindowlessControl : IUnknown
289{
290 HRESULT GetNativeVideoSize([out] LONG* lpWidth, [out] LONG* lpHeight, [out] LONG* lpARWidth, [out] LONG* lpARHeight);
291 HRESULT GetMinIdealVideoSize([out] LONG* lpWidth, [out] LONG* lpHeight);
292 HRESULT GetMaxIdealVideoSize([out] LONG* lpWidth, [out] LONG* lpHeight);
293 HRESULT SetVideoPosition([in] const LPRECT lpSRCRect, [in] const LPRECT lpDSTRect);
294 HRESULT GetVideoPosition([out] LPRECT lpSRCRect, [out] LPRECT lpDSTRect);
295 HRESULT GetAspectRatioMode([out] DWORD* lpAspectRatioMode);
296 HRESULT SetAspectRatioMode([in] DWORD AspectRatioMode);
297 HRESULT SetVideoClippingWindow([in] HWND hwnd);
298 HRESULT RepaintVideo([in] HWND hwnd, [in] HDC hdc);
299 HRESULT DisplayModeChanged();
300 HRESULT GetCurrentImage([out] BYTE** lpDib);
301 HRESULT SetBorderColor([in] COLORREF Clr);
302 HRESULT GetBorderColor([out] COLORREF* lpClr);
303 HRESULT SetColorKey([in] COLORREF Clr);
304 HRESULT GetColorKey([out] COLORREF* lpClr);
305};
306
307[
308 local,
309 object,
310 uuid(1c1a17b0-bed0-415d-974b-dc6696131599),
311 pointer_default(unique)
312]
313interface IVMRMixerControl : IUnknown
314{
315 HRESULT SetAlpha([in] DWORD dwStreamID, [in] float Alpha);
316 HRESULT GetAlpha([in] DWORD dwStreamID, [out] float* pAlpha);
317 HRESULT SetZOrder([in] DWORD dwStreamID, [in] DWORD dwZ);
318 HRESULT GetZOrder([in] DWORD dwStreamID, [out] DWORD* pZ);
319 HRESULT SetOutputRect([in] DWORD dwStreamID, [in] const NORMALIZEDRECT *pRect);
320 HRESULT GetOutputRect([in] DWORD dwStreamID, [out] NORMALIZEDRECT *pRect);
321 HRESULT SetBackgroundClr([in] COLORREF ClrBkg);
322 HRESULT GetBackgroundClr([in] COLORREF* lpClrBkg);
323 HRESULT SetMixingPrefs([in] DWORD dwMixerPrefs);
324 HRESULT GetMixingPrefs([out] DWORD* pdwMixerPrefs);
325};
326
327[
328 object,
329 local,
330 uuid(9cf0b1b6-fbaa-4b7f-88cf-cf1f130a0dce),
331 pointer_default(unique)
332]
333interface IVMRMonitorConfig : IUnknown
334{
335 HRESULT SetMonitor([in] const VMRGUID *pGUID);
336 HRESULT GetMonitor([out] VMRGUID *pGUID);
337 HRESULT SetDefaultMonitor([in] const VMRGUID *pGUID);
338 HRESULT GetDefaultMonitor([out] VMRGUID *pGUID);
339 HRESULT GetAvailableMonitors([out, size_is(dwMaxInfoArraySize)] VMRMONITORINFO* pInfo, [in] DWORD dwMaxInfoArraySize, [out] DWORD* pdwNumDevices);
340};
341
342
343[
344 object,
345 local,
346 uuid(9e5530c5-7034-48b4-bb46-0b8a6efc8e36),
347 pointer_default(unique)
348]
349interface IVMRFilterConfig : IUnknown
350{
351 HRESULT SetImageCompositor([in] IVMRImageCompositor* lpVMRImgCompositor);
352 HRESULT SetNumberOfStreams([in] DWORD dwMaxStreams);
353 HRESULT GetNumberOfStreams([out] DWORD* pdwMaxStreams);
354 HRESULT SetRenderingPrefs([in] DWORD dwRenderFlags);
355 HRESULT GetRenderingPrefs([out] DWORD* pdwRenderFlags);
356 HRESULT SetRenderingMode([in] DWORD Mode);
357 HRESULT GetRenderingMode([out] DWORD* pMode);
358}
359
360
361[
362 object,
363 local,
364 uuid(ede80b5c-bad6-4623-b537-65586c9f8dfd),
365 pointer_default(unique)
366]
367interface IVMRAspectRatioControl : IUnknown
368{
369 HRESULT GetAspectRatioMode([out] LPDWORD lpdwARMode);
370 HRESULT SetAspectRatioMode([in] DWORD dwARMode);
371}
372
373[
374 object,
375 local,
376 uuid(bb057577-0db8-4e6a-87a7-1a8c9a505a0f),
377 pointer_default(unique)
378]
379interface IVMRDeinterlaceControl : IUnknown
380{
381
382 HRESULT GetNumberOfDeinterlaceModes([in] VMRVideoDesc* lpVideoDescription, [in] [out] LPDWORD lpdwNumDeinterlaceModes, [out] LPGUID lpDeinterlaceModes);
383 HRESULT GetDeinterlaceModeCaps([in] LPGUID lpDeinterlaceMode, [in] VMRVideoDesc* lpVideoDescription, [in] [out] VMRDeinterlaceCaps* lpDeinterlaceCaps);
384 HRESULT GetDeinterlaceMode([in] DWORD dwStreamID, [out] LPGUID lpDeinterlaceMode );
385 HRESULT SetDeinterlaceMode([in] DWORD dwStreamID, [in] LPGUID lpDeinterlaceMode);
386 HRESULT GetDeinterlacePrefs([out] LPDWORD lpdwDeinterlacePrefs);
387 HRESULT SetDeinterlacePrefs([in] DWORD dwDeinterlacePrefs);
388 HRESULT GetActualDeinterlaceMode([in] DWORD dwStreamID, [out] LPGUID lpDeinterlaceMode);
389}
390
391[
392 object,
393 local,
394 uuid(1E673275-0257-40aa-AF20-7C608D4A0428),
395 pointer_default(unique)
396]
397interface IVMRMixerBitmap : IUnknown
398{
399 HRESULT SetAlphaBitmap([in] const VMRALPHABITMAP *pBmpParms);
400 HRESULT UpdateAlphaBitmapParameters([in] PVMRALPHABITMAP pBmpParms);
401 HRESULT GetAlphaBitmapParameters([out] PVMRALPHABITMAP pBmpParms);
402};
403
404[
405 local,
406 object,
407 uuid(7a4fb5af-479f-4074-bb40-ce6722e43c82),
408 pointer_default(unique)
409]
410interface IVMRImageCompositor : IUnknown
411{
412 HRESULT InitCompositionTarget([in] IUnknown* pD3DDevice, [in] LPDIRECTDRAWSURFACE7 pddsRenderTarget);
413 HRESULT TermCompositionTarget([in] IUnknown* pD3DDevice, [in] LPDIRECTDRAWSURFACE7 pddsRenderTarget);
414 HRESULT SetStreamMediaType([in] DWORD dwStrmID, [in] AM_MEDIA_TYPE* pmt, [in] BOOL fTexture);
415 HRESULT CompositeImage([in] IUnknown* pD3DDevice, [in] LPDIRECTDRAWSURFACE7 pddsRenderTarget, [in] AM_MEDIA_TYPE* pmtRenderTarget, [in] REFERENCE_TIME rtStart, [in] REFERENCE_TIME rtEnd, [in] DWORD dwClrBkGnd, [in] VMRVIDEOSTREAMINFO* pVideoStreamInfo, [in] UINT cStreams);
416};
417
418[
419 object,
420 local,
421 uuid(058d1f11-2a54-4bef-bd54-df706626b727),
422 pointer_default(unique)
423]
424interface IVMRVideoStreamControl: IUnknown
425{
426 HRESULT SetColorKey([in] LPDDCOLORKEY lpClrKey);
427 HRESULT GetColorKey([out] LPDDCOLORKEY lpClrKey);
428 HRESULT SetStreamActiveState([in] BOOL fActive);
429 HRESULT GetStreamActiveState([out] BOOL* lpfActive);
430};
431
432[
433 local,
434 object,
435 uuid(a9849bbe-9ec8-4263-b764-62730f0d15d0),
436 pointer_default(unique)
437]
438interface IVMRSurface : IUnknown
439{
440 HRESULT IsSurfaceLocked();
441 HRESULT LockSurface([out] BYTE** lpSurface);
442 HRESULT UnlockSurface();
443 HRESULT GetSurface([out] LPDIRECTDRAWSURFACE7 *lplpSurface);
444};
445
446[
447 local,
448 object,
449 uuid(9f3a1c85-8555-49ba-935f-be5b5b29d178),
450 pointer_default(unique)
451]
452
453interface IVMRImagePresenterConfig : IUnknown
454{
455 HRESULT SetRenderingPrefs([in] DWORD dwRenderFlags);
456 HRESULT GetRenderingPrefs([out] DWORD* dwRenderFlags);
457}
458
459[
460 local,
461 object,
462 uuid(e6f7ce40-4673-44f1-8f77-5499d68cb4ea),
463 pointer_default(unique)
464]
465
466interface IVMRImagePresenterExclModeConfig : IVMRImagePresenterConfig
467{
468 HRESULT SetXlcModeDDObjAndPrimarySurface([in] LPDIRECTDRAW7 lpDDObj, [in] LPDIRECTDRAWSURFACE7 lpPrimarySurf);
469 HRESULT GetXlcModeDDObjAndPrimarySurface([out] LPDIRECTDRAW7* lpDDObj, [out] LPDIRECTDRAWSURFACE7* lpPrimarySurf);
470}
471
472[
473 local,
474 object,
475 uuid(aac18c18-e186-46d2-825d-a1f8dc8e395a),
476 pointer_default(unique)
477]
478interface IVPManager : IUnknown
479{
480 HRESULT SetVideoPortIndex([in] DWORD dwVideoPortIndex);
481 HRESULT GetVideoPortIndex([out] DWORD* pdwVideoPortIndex);
482};
483
CD3D10_BUFFER_DESC D3D10_BUFFER_DESC cpp_quote(" ~CD3D10_BUFFER_DESC() {}") operator const D3D10_BUFFER_DESC &() const
Definition: d3d10.idl:491
DDCOLORKEY * LPDDCOLORKEY
Definition: vmrender.idl:11
DWORD * LPDIRECTDRAW7
Definition: vmrender.idl:6
DWORD * LPDIRECTDRAWSURFACE7
Definition: vmrender.idl:7
unsigned long DWORD
Definition: ntddk_ex.h:95
DWORD dw1
Definition: vmrender.idl:10