source: Daodan/MSYS2/mingw32/i686-w64-mingw32/include/mfplay.h@ 1194

Last change on this file since 1194 was 1166, checked in by rossy, 3 years ago

Daodan: Replace MinGW build env with an up-to-date MSYS2 env

File size: 42.6 KB
Line 
1/*** Autogenerated by WIDL 6.4 from include/mfplay.idl - Do not edit ***/
2
3#ifdef _WIN32
4#ifndef __REQUIRED_RPCNDR_H_VERSION__
5#define __REQUIRED_RPCNDR_H_VERSION__ 475
6#endif
7#include <rpc.h>
8#include <rpcndr.h>
9#endif
10
11#ifndef COM_NO_WINDOWS_H
12#include <windows.h>
13#include <ole2.h>
14#endif
15
16#ifndef __mfplay_h__
17#define __mfplay_h__
18
19/* Forward declarations */
20
21#ifndef __IMFPMediaPlayer_FWD_DEFINED__
22#define __IMFPMediaPlayer_FWD_DEFINED__
23typedef interface IMFPMediaPlayer IMFPMediaPlayer;
24#ifdef __cplusplus
25interface IMFPMediaPlayer;
26#endif /* __cplusplus */
27#endif
28
29#ifndef __IMFPMediaItem_FWD_DEFINED__
30#define __IMFPMediaItem_FWD_DEFINED__
31typedef interface IMFPMediaItem IMFPMediaItem;
32#ifdef __cplusplus
33interface IMFPMediaItem;
34#endif /* __cplusplus */
35#endif
36
37#ifndef __IMFPMediaPlayerCallback_FWD_DEFINED__
38#define __IMFPMediaPlayerCallback_FWD_DEFINED__
39typedef interface IMFPMediaPlayerCallback IMFPMediaPlayerCallback;
40#ifdef __cplusplus
41interface IMFPMediaPlayerCallback;
42#endif /* __cplusplus */
43#endif
44
45/* Headers for imported files */
46
47#include <unknwn.h>
48#include <propsys.h>
49#include <mfidl.h>
50#include <evr.h>
51
52#ifdef __cplusplus
53extern "C" {
54#endif
55
56/**
57 * This file is part of the mingw-w64 runtime package.
58 * No warranty is given; refer to the file DISCLAIMER within this package.
59 */
60
61#if (WINVER >= _WIN32_WINNT_WIN7)
62#ifndef __IMFPMediaPlayer_FWD_DEFINED__
63#define __IMFPMediaPlayer_FWD_DEFINED__
64typedef interface IMFPMediaPlayer IMFPMediaPlayer;
65#ifdef __cplusplus
66interface IMFPMediaPlayer;
67#endif /* __cplusplus */
68#endif
69
70#ifndef __IMFPMediaItem_FWD_DEFINED__
71#define __IMFPMediaItem_FWD_DEFINED__
72typedef interface IMFPMediaItem IMFPMediaItem;
73#ifdef __cplusplus
74interface IMFPMediaItem;
75#endif /* __cplusplus */
76#endif
77
78#ifndef __IMFPMediaPlayerCallback_FWD_DEFINED__
79#define __IMFPMediaPlayerCallback_FWD_DEFINED__
80typedef interface IMFPMediaPlayerCallback IMFPMediaPlayerCallback;
81#ifdef __cplusplus
82interface IMFPMediaPlayerCallback;
83#endif /* __cplusplus */
84#endif
85
86#ifndef __IMFMediaEvent_FWD_DEFINED__
87#define __IMFMediaEvent_FWD_DEFINED__
88typedef interface IMFMediaEvent IMFMediaEvent;
89#ifdef __cplusplus
90interface IMFMediaEvent;
91#endif /* __cplusplus */
92#endif
93
94#ifndef __IMFNetCredential_FWD_DEFINED__
95#define __IMFNetCredential_FWD_DEFINED__
96typedef interface IMFNetCredential IMFNetCredential;
97#ifdef __cplusplus
98interface IMFNetCredential;
99#endif /* __cplusplus */
100#endif
101
102
103interface IMFMediaEvent;
104interface IMFNetCredential;
105
106typedef UINT32 MFP_CREATION_OPTIONS;
107
108typedef enum _MFP_CREATION_OPTIONS {
109 MFP_OPTION_NONE = 0x0,
110 MFP_OPTION_FREE_THREADED_CALLBACK = 0x1,
111 MFP_OPTION_NO_MMCSS = 0x2,
112 MFP_OPTION_NO_REMOTE_DESKTOP_OPTIMIZATION = 0x4
113} _MFP_CREATION_OPTIONS;
114
115typedef enum MFP_MEDIAPLAYER_STATE {
116 MFP_MEDIAPLAYER_STATE_EMPTY = 0x0,
117 MFP_MEDIAPLAYER_STATE_STOPPED = 0x1,
118 MFP_MEDIAPLAYER_STATE_PLAYING = 0x2,
119 MFP_MEDIAPLAYER_STATE_PAUSED = 0x3,
120 MFP_MEDIAPLAYER_STATE_SHUTDOWN = 0x4
121} MFP_MEDIAPLAYER_STATE;
122
123typedef UINT32 MFP_MEDIAITEM_CHARACTERISTICS;
124
125typedef enum _MFP_MEDIAITEM_CHARACTERISTICS {
126 MFP_MEDIAITEM_IS_LIVE = 0x1,
127 MFP_MEDIAITEM_CAN_SEEK = 0x2,
128 MFP_MEDIAITEM_CAN_PAUSE = 0x4,
129 MFP_MEDIAITEM_HAS_SLOW_SEEK = 0x8
130} _MFP_MEDIAITEM_CHARACTERISTICS;
131
132typedef UINT32 MFP_CREDENTIAL_FLAGS;
133
134typedef enum _MFP_CREDENTIAL_FLAGS {
135 MFP_CREDENTIAL_PROMPT = 0x1,
136 MFP_CREDENTIAL_SAVE = 0x2,
137 MFP_CREDENTIAL_DO_NOT_CACHE = 0x4,
138 MFP_CREDENTIAL_CLEAR_TEXT = 0x8,
139 MFP_CREDENTIAL_PROXY = 0x10,
140 MFP_CREDENTIAL_LOGGED_ON_USER = 0x20
141} _MFP_CREDENTIAL_FLAGS;
142STDAPI MFPCreateMediaPlayer(LPCWSTR pwszURL, BOOL fStartPlayback, MFP_CREATION_OPTIONS creationOptions, IMFPMediaPlayerCallback * pCallback, HWND hWnd, IMFPMediaPlayer ** ppMediaPlayer);
143
144/*****************************************************************************
145 * IMFPMediaPlayer interface
146 */
147#ifndef __IMFPMediaPlayer_INTERFACE_DEFINED__
148#define __IMFPMediaPlayer_INTERFACE_DEFINED__
149
150DEFINE_GUID(IID_IMFPMediaPlayer, 0xa714590a, 0x58af, 0x430a, 0x85,0xbf, 0x44,0xf5,0xec,0x83,0x8d,0x85);
151#if defined(__cplusplus) && !defined(CINTERFACE)
152MIDL_INTERFACE("a714590a-58af-430a-85bf-44f5ec838d85")
153IMFPMediaPlayer : public IUnknown
154{
155 virtual HRESULT STDMETHODCALLTYPE Play(
156 ) = 0;
157
158 virtual HRESULT STDMETHODCALLTYPE Pause(
159 ) = 0;
160
161 virtual HRESULT STDMETHODCALLTYPE Stop(
162 ) = 0;
163
164 virtual HRESULT STDMETHODCALLTYPE FrameStep(
165 ) = 0;
166
167 virtual HRESULT STDMETHODCALLTYPE SetPosition(
168 REFGUID guidPositionType,
169 const PROPVARIANT *pvPositionValue) = 0;
170
171 virtual HRESULT STDMETHODCALLTYPE GetPosition(
172 REFGUID guidPositionType,
173 PROPVARIANT *pvPositionValue) = 0;
174
175 virtual HRESULT STDMETHODCALLTYPE GetDuration(
176 REFGUID guidPositionType,
177 PROPVARIANT *pvDurationValue) = 0;
178
179 virtual HRESULT STDMETHODCALLTYPE SetRate(
180 float flRate) = 0;
181
182 virtual HRESULT STDMETHODCALLTYPE GetRate(
183 float *pflRate) = 0;
184
185 virtual HRESULT STDMETHODCALLTYPE GetSupportedRates(
186 WINBOOL fForwardDirection,
187 float *pflSlowestRate,
188 float *pflFastestRate) = 0;
189
190 virtual HRESULT STDMETHODCALLTYPE GetState(
191 MFP_MEDIAPLAYER_STATE *peState) = 0;
192
193 virtual HRESULT STDMETHODCALLTYPE CreateMediaItemFromURL(
194 LPCWSTR pwszURL,
195 WINBOOL fSync,
196 DWORD_PTR dwUserData,
197 IMFPMediaItem **ppMediaItem) = 0;
198
199 virtual HRESULT STDMETHODCALLTYPE CreateMediaItemFromObject(
200 IUnknown *pIUnknownObj,
201 WINBOOL fSync,
202 DWORD_PTR dwUserData,
203 IMFPMediaItem **ppMediaItem) = 0;
204
205 virtual HRESULT STDMETHODCALLTYPE SetMediaItem(
206 IMFPMediaItem *pIMFPMediaItem) = 0;
207
208 virtual HRESULT STDMETHODCALLTYPE ClearMediaItem(
209 ) = 0;
210
211 virtual HRESULT STDMETHODCALLTYPE GetMediaItem(
212 IMFPMediaItem **ppIMFPMediaItem) = 0;
213
214 virtual HRESULT STDMETHODCALLTYPE GetVolume(
215 float *pflVolume) = 0;
216
217 virtual HRESULT STDMETHODCALLTYPE SetVolume(
218 float flVolume) = 0;
219
220 virtual HRESULT STDMETHODCALLTYPE GetBalance(
221 float *pflBalance) = 0;
222
223 virtual HRESULT STDMETHODCALLTYPE SetBalance(
224 float flBalance) = 0;
225
226 virtual HRESULT STDMETHODCALLTYPE GetMute(
227 WINBOOL *pfMute) = 0;
228
229 virtual HRESULT STDMETHODCALLTYPE SetMute(
230 WINBOOL fMute) = 0;
231
232 virtual HRESULT STDMETHODCALLTYPE GetNativeVideoSize(
233 SIZE *pszVideo,
234 SIZE *pszARVideo) = 0;
235
236 virtual HRESULT STDMETHODCALLTYPE GetIdealVideoSize(
237 SIZE *pszMin,
238 SIZE *pszMax) = 0;
239
240 virtual HRESULT STDMETHODCALLTYPE SetVideoSourceRect(
241 const MFVideoNormalizedRect *pnrcSource) = 0;
242
243 virtual HRESULT STDMETHODCALLTYPE GetVideoSourceRect(
244 MFVideoNormalizedRect *pnrcSource) = 0;
245
246 virtual HRESULT STDMETHODCALLTYPE SetAspectRatioMode(
247 DWORD dwAspectRatioMode) = 0;
248
249 virtual HRESULT STDMETHODCALLTYPE GetAspectRatioMode(
250 DWORD *pdwAspectRatioMode) = 0;
251
252 virtual HRESULT STDMETHODCALLTYPE GetVideoWindow(
253 HWND *phwndVideo) = 0;
254
255 virtual HRESULT STDMETHODCALLTYPE UpdateVideo(
256 ) = 0;
257
258 virtual HRESULT STDMETHODCALLTYPE SetBorderColor(
259 COLORREF Clr) = 0;
260
261 virtual HRESULT STDMETHODCALLTYPE GetBorderColor(
262 COLORREF *pClr) = 0;
263
264 virtual HRESULT STDMETHODCALLTYPE InsertEffect(
265 IUnknown *pEffect,
266 WINBOOL fOptional) = 0;
267
268 virtual HRESULT STDMETHODCALLTYPE RemoveEffect(
269 IUnknown *pEffect) = 0;
270
271 virtual HRESULT STDMETHODCALLTYPE RemoveAllEffects(
272 ) = 0;
273
274 virtual HRESULT STDMETHODCALLTYPE Shutdown(
275 ) = 0;
276
277};
278#ifdef __CRT_UUID_DECL
279__CRT_UUID_DECL(IMFPMediaPlayer, 0xa714590a, 0x58af, 0x430a, 0x85,0xbf, 0x44,0xf5,0xec,0x83,0x8d,0x85)
280#endif
281#else
282typedef struct IMFPMediaPlayerVtbl {
283 BEGIN_INTERFACE
284
285 /*** IUnknown methods ***/
286 HRESULT (STDMETHODCALLTYPE *QueryInterface)(
287 IMFPMediaPlayer *This,
288 REFIID riid,
289 void **ppvObject);
290
291 ULONG (STDMETHODCALLTYPE *AddRef)(
292 IMFPMediaPlayer *This);
293
294 ULONG (STDMETHODCALLTYPE *Release)(
295 IMFPMediaPlayer *This);
296
297 /*** IMFPMediaPlayer methods ***/
298 HRESULT (STDMETHODCALLTYPE *Play)(
299 IMFPMediaPlayer *This);
300
301 HRESULT (STDMETHODCALLTYPE *Pause)(
302 IMFPMediaPlayer *This);
303
304 HRESULT (STDMETHODCALLTYPE *Stop)(
305 IMFPMediaPlayer *This);
306
307 HRESULT (STDMETHODCALLTYPE *FrameStep)(
308 IMFPMediaPlayer *This);
309
310 HRESULT (STDMETHODCALLTYPE *SetPosition)(
311 IMFPMediaPlayer *This,
312 REFGUID guidPositionType,
313 const PROPVARIANT *pvPositionValue);
314
315 HRESULT (STDMETHODCALLTYPE *GetPosition)(
316 IMFPMediaPlayer *This,
317 REFGUID guidPositionType,
318 PROPVARIANT *pvPositionValue);
319
320 HRESULT (STDMETHODCALLTYPE *GetDuration)(
321 IMFPMediaPlayer *This,
322 REFGUID guidPositionType,
323 PROPVARIANT *pvDurationValue);
324
325 HRESULT (STDMETHODCALLTYPE *SetRate)(
326 IMFPMediaPlayer *This,
327 float flRate);
328
329 HRESULT (STDMETHODCALLTYPE *GetRate)(
330 IMFPMediaPlayer *This,
331 float *pflRate);
332
333 HRESULT (STDMETHODCALLTYPE *GetSupportedRates)(
334 IMFPMediaPlayer *This,
335 WINBOOL fForwardDirection,
336 float *pflSlowestRate,
337 float *pflFastestRate);
338
339 HRESULT (STDMETHODCALLTYPE *GetState)(
340 IMFPMediaPlayer *This,
341 MFP_MEDIAPLAYER_STATE *peState);
342
343 HRESULT (STDMETHODCALLTYPE *CreateMediaItemFromURL)(
344 IMFPMediaPlayer *This,
345 LPCWSTR pwszURL,
346 WINBOOL fSync,
347 DWORD_PTR dwUserData,
348 IMFPMediaItem **ppMediaItem);
349
350 HRESULT (STDMETHODCALLTYPE *CreateMediaItemFromObject)(
351 IMFPMediaPlayer *This,
352 IUnknown *pIUnknownObj,
353 WINBOOL fSync,
354 DWORD_PTR dwUserData,
355 IMFPMediaItem **ppMediaItem);
356
357 HRESULT (STDMETHODCALLTYPE *SetMediaItem)(
358 IMFPMediaPlayer *This,
359 IMFPMediaItem *pIMFPMediaItem);
360
361 HRESULT (STDMETHODCALLTYPE *ClearMediaItem)(
362 IMFPMediaPlayer *This);
363
364 HRESULT (STDMETHODCALLTYPE *GetMediaItem)(
365 IMFPMediaPlayer *This,
366 IMFPMediaItem **ppIMFPMediaItem);
367
368 HRESULT (STDMETHODCALLTYPE *GetVolume)(
369 IMFPMediaPlayer *This,
370 float *pflVolume);
371
372 HRESULT (STDMETHODCALLTYPE *SetVolume)(
373 IMFPMediaPlayer *This,
374 float flVolume);
375
376 HRESULT (STDMETHODCALLTYPE *GetBalance)(
377 IMFPMediaPlayer *This,
378 float *pflBalance);
379
380 HRESULT (STDMETHODCALLTYPE *SetBalance)(
381 IMFPMediaPlayer *This,
382 float flBalance);
383
384 HRESULT (STDMETHODCALLTYPE *GetMute)(
385 IMFPMediaPlayer *This,
386 WINBOOL *pfMute);
387
388 HRESULT (STDMETHODCALLTYPE *SetMute)(
389 IMFPMediaPlayer *This,
390 WINBOOL fMute);
391
392 HRESULT (STDMETHODCALLTYPE *GetNativeVideoSize)(
393 IMFPMediaPlayer *This,
394 SIZE *pszVideo,
395 SIZE *pszARVideo);
396
397 HRESULT (STDMETHODCALLTYPE *GetIdealVideoSize)(
398 IMFPMediaPlayer *This,
399 SIZE *pszMin,
400 SIZE *pszMax);
401
402 HRESULT (STDMETHODCALLTYPE *SetVideoSourceRect)(
403 IMFPMediaPlayer *This,
404 const MFVideoNormalizedRect *pnrcSource);
405
406 HRESULT (STDMETHODCALLTYPE *GetVideoSourceRect)(
407 IMFPMediaPlayer *This,
408 MFVideoNormalizedRect *pnrcSource);
409
410 HRESULT (STDMETHODCALLTYPE *SetAspectRatioMode)(
411 IMFPMediaPlayer *This,
412 DWORD dwAspectRatioMode);
413
414 HRESULT (STDMETHODCALLTYPE *GetAspectRatioMode)(
415 IMFPMediaPlayer *This,
416 DWORD *pdwAspectRatioMode);
417
418 HRESULT (STDMETHODCALLTYPE *GetVideoWindow)(
419 IMFPMediaPlayer *This,
420 HWND *phwndVideo);
421
422 HRESULT (STDMETHODCALLTYPE *UpdateVideo)(
423 IMFPMediaPlayer *This);
424
425 HRESULT (STDMETHODCALLTYPE *SetBorderColor)(
426 IMFPMediaPlayer *This,
427 COLORREF Clr);
428
429 HRESULT (STDMETHODCALLTYPE *GetBorderColor)(
430 IMFPMediaPlayer *This,
431 COLORREF *pClr);
432
433 HRESULT (STDMETHODCALLTYPE *InsertEffect)(
434 IMFPMediaPlayer *This,
435 IUnknown *pEffect,
436 WINBOOL fOptional);
437
438 HRESULT (STDMETHODCALLTYPE *RemoveEffect)(
439 IMFPMediaPlayer *This,
440 IUnknown *pEffect);
441
442 HRESULT (STDMETHODCALLTYPE *RemoveAllEffects)(
443 IMFPMediaPlayer *This);
444
445 HRESULT (STDMETHODCALLTYPE *Shutdown)(
446 IMFPMediaPlayer *This);
447
448 END_INTERFACE
449} IMFPMediaPlayerVtbl;
450
451interface IMFPMediaPlayer {
452 CONST_VTBL IMFPMediaPlayerVtbl* lpVtbl;
453};
454
455#ifdef COBJMACROS
456#ifndef WIDL_C_INLINE_WRAPPERS
457/*** IUnknown methods ***/
458#define IMFPMediaPlayer_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
459#define IMFPMediaPlayer_AddRef(This) (This)->lpVtbl->AddRef(This)
460#define IMFPMediaPlayer_Release(This) (This)->lpVtbl->Release(This)
461/*** IMFPMediaPlayer methods ***/
462#define IMFPMediaPlayer_Play(This) (This)->lpVtbl->Play(This)
463#define IMFPMediaPlayer_Pause(This) (This)->lpVtbl->Pause(This)
464#define IMFPMediaPlayer_Stop(This) (This)->lpVtbl->Stop(This)
465#define IMFPMediaPlayer_FrameStep(This) (This)->lpVtbl->FrameStep(This)
466#define IMFPMediaPlayer_SetPosition(This,guidPositionType,pvPositionValue) (This)->lpVtbl->SetPosition(This,guidPositionType,pvPositionValue)
467#define IMFPMediaPlayer_GetPosition(This,guidPositionType,pvPositionValue) (This)->lpVtbl->GetPosition(This,guidPositionType,pvPositionValue)
468#define IMFPMediaPlayer_GetDuration(This,guidPositionType,pvDurationValue) (This)->lpVtbl->GetDuration(This,guidPositionType,pvDurationValue)
469#define IMFPMediaPlayer_SetRate(This,flRate) (This)->lpVtbl->SetRate(This,flRate)
470#define IMFPMediaPlayer_GetRate(This,pflRate) (This)->lpVtbl->GetRate(This,pflRate)
471#define IMFPMediaPlayer_GetSupportedRates(This,fForwardDirection,pflSlowestRate,pflFastestRate) (This)->lpVtbl->GetSupportedRates(This,fForwardDirection,pflSlowestRate,pflFastestRate)
472#define IMFPMediaPlayer_GetState(This,peState) (This)->lpVtbl->GetState(This,peState)
473#define IMFPMediaPlayer_CreateMediaItemFromURL(This,pwszURL,fSync,dwUserData,ppMediaItem) (This)->lpVtbl->CreateMediaItemFromURL(This,pwszURL,fSync,dwUserData,ppMediaItem)
474#define IMFPMediaPlayer_CreateMediaItemFromObject(This,pIUnknownObj,fSync,dwUserData,ppMediaItem) (This)->lpVtbl->CreateMediaItemFromObject(This,pIUnknownObj,fSync,dwUserData,ppMediaItem)
475#define IMFPMediaPlayer_SetMediaItem(This,pIMFPMediaItem) (This)->lpVtbl->SetMediaItem(This,pIMFPMediaItem)
476#define IMFPMediaPlayer_ClearMediaItem(This) (This)->lpVtbl->ClearMediaItem(This)
477#define IMFPMediaPlayer_GetMediaItem(This,ppIMFPMediaItem) (This)->lpVtbl->GetMediaItem(This,ppIMFPMediaItem)
478#define IMFPMediaPlayer_GetVolume(This,pflVolume) (This)->lpVtbl->GetVolume(This,pflVolume)
479#define IMFPMediaPlayer_SetVolume(This,flVolume) (This)->lpVtbl->SetVolume(This,flVolume)
480#define IMFPMediaPlayer_GetBalance(This,pflBalance) (This)->lpVtbl->GetBalance(This,pflBalance)
481#define IMFPMediaPlayer_SetBalance(This,flBalance) (This)->lpVtbl->SetBalance(This,flBalance)
482#define IMFPMediaPlayer_GetMute(This,pfMute) (This)->lpVtbl->GetMute(This,pfMute)
483#define IMFPMediaPlayer_SetMute(This,fMute) (This)->lpVtbl->SetMute(This,fMute)
484#define IMFPMediaPlayer_GetNativeVideoSize(This,pszVideo,pszARVideo) (This)->lpVtbl->GetNativeVideoSize(This,pszVideo,pszARVideo)
485#define IMFPMediaPlayer_GetIdealVideoSize(This,pszMin,pszMax) (This)->lpVtbl->GetIdealVideoSize(This,pszMin,pszMax)
486#define IMFPMediaPlayer_SetVideoSourceRect(This,pnrcSource) (This)->lpVtbl->SetVideoSourceRect(This,pnrcSource)
487#define IMFPMediaPlayer_GetVideoSourceRect(This,pnrcSource) (This)->lpVtbl->GetVideoSourceRect(This,pnrcSource)
488#define IMFPMediaPlayer_SetAspectRatioMode(This,dwAspectRatioMode) (This)->lpVtbl->SetAspectRatioMode(This,dwAspectRatioMode)
489#define IMFPMediaPlayer_GetAspectRatioMode(This,pdwAspectRatioMode) (This)->lpVtbl->GetAspectRatioMode(This,pdwAspectRatioMode)
490#define IMFPMediaPlayer_GetVideoWindow(This,phwndVideo) (This)->lpVtbl->GetVideoWindow(This,phwndVideo)
491#define IMFPMediaPlayer_UpdateVideo(This) (This)->lpVtbl->UpdateVideo(This)
492#define IMFPMediaPlayer_SetBorderColor(This,Clr) (This)->lpVtbl->SetBorderColor(This,Clr)
493#define IMFPMediaPlayer_GetBorderColor(This,pClr) (This)->lpVtbl->GetBorderColor(This,pClr)
494#define IMFPMediaPlayer_InsertEffect(This,pEffect,fOptional) (This)->lpVtbl->InsertEffect(This,pEffect,fOptional)
495#define IMFPMediaPlayer_RemoveEffect(This,pEffect) (This)->lpVtbl->RemoveEffect(This,pEffect)
496#define IMFPMediaPlayer_RemoveAllEffects(This) (This)->lpVtbl->RemoveAllEffects(This)
497#define IMFPMediaPlayer_Shutdown(This) (This)->lpVtbl->Shutdown(This)
498#else
499/*** IUnknown methods ***/
500static FORCEINLINE HRESULT IMFPMediaPlayer_QueryInterface(IMFPMediaPlayer* This,REFIID riid,void **ppvObject) {
501 return This->lpVtbl->QueryInterface(This,riid,ppvObject);
502}
503static FORCEINLINE ULONG IMFPMediaPlayer_AddRef(IMFPMediaPlayer* This) {
504 return This->lpVtbl->AddRef(This);
505}
506static FORCEINLINE ULONG IMFPMediaPlayer_Release(IMFPMediaPlayer* This) {
507 return This->lpVtbl->Release(This);
508}
509/*** IMFPMediaPlayer methods ***/
510static FORCEINLINE HRESULT IMFPMediaPlayer_Play(IMFPMediaPlayer* This) {
511 return This->lpVtbl->Play(This);
512}
513static FORCEINLINE HRESULT IMFPMediaPlayer_Pause(IMFPMediaPlayer* This) {
514 return This->lpVtbl->Pause(This);
515}
516static FORCEINLINE HRESULT IMFPMediaPlayer_Stop(IMFPMediaPlayer* This) {
517 return This->lpVtbl->Stop(This);
518}
519static FORCEINLINE HRESULT IMFPMediaPlayer_FrameStep(IMFPMediaPlayer* This) {
520 return This->lpVtbl->FrameStep(This);
521}
522static FORCEINLINE HRESULT IMFPMediaPlayer_SetPosition(IMFPMediaPlayer* This,REFGUID guidPositionType,const PROPVARIANT *pvPositionValue) {
523 return This->lpVtbl->SetPosition(This,guidPositionType,pvPositionValue);
524}
525static FORCEINLINE HRESULT IMFPMediaPlayer_GetPosition(IMFPMediaPlayer* This,REFGUID guidPositionType,PROPVARIANT *pvPositionValue) {
526 return This->lpVtbl->GetPosition(This,guidPositionType,pvPositionValue);
527}
528static FORCEINLINE HRESULT IMFPMediaPlayer_GetDuration(IMFPMediaPlayer* This,REFGUID guidPositionType,PROPVARIANT *pvDurationValue) {
529 return This->lpVtbl->GetDuration(This,guidPositionType,pvDurationValue);
530}
531static FORCEINLINE HRESULT IMFPMediaPlayer_SetRate(IMFPMediaPlayer* This,float flRate) {
532 return This->lpVtbl->SetRate(This,flRate);
533}
534static FORCEINLINE HRESULT IMFPMediaPlayer_GetRate(IMFPMediaPlayer* This,float *pflRate) {
535 return This->lpVtbl->GetRate(This,pflRate);
536}
537static FORCEINLINE HRESULT IMFPMediaPlayer_GetSupportedRates(IMFPMediaPlayer* This,WINBOOL fForwardDirection,float *pflSlowestRate,float *pflFastestRate) {
538 return This->lpVtbl->GetSupportedRates(This,fForwardDirection,pflSlowestRate,pflFastestRate);
539}
540static FORCEINLINE HRESULT IMFPMediaPlayer_GetState(IMFPMediaPlayer* This,MFP_MEDIAPLAYER_STATE *peState) {
541 return This->lpVtbl->GetState(This,peState);
542}
543static FORCEINLINE HRESULT IMFPMediaPlayer_CreateMediaItemFromURL(IMFPMediaPlayer* This,LPCWSTR pwszURL,WINBOOL fSync,DWORD_PTR dwUserData,IMFPMediaItem **ppMediaItem) {
544 return This->lpVtbl->CreateMediaItemFromURL(This,pwszURL,fSync,dwUserData,ppMediaItem);
545}
546static FORCEINLINE HRESULT IMFPMediaPlayer_CreateMediaItemFromObject(IMFPMediaPlayer* This,IUnknown *pIUnknownObj,WINBOOL fSync,DWORD_PTR dwUserData,IMFPMediaItem **ppMediaItem) {
547 return This->lpVtbl->CreateMediaItemFromObject(This,pIUnknownObj,fSync,dwUserData,ppMediaItem);
548}
549static FORCEINLINE HRESULT IMFPMediaPlayer_SetMediaItem(IMFPMediaPlayer* This,IMFPMediaItem *pIMFPMediaItem) {
550 return This->lpVtbl->SetMediaItem(This,pIMFPMediaItem);
551}
552static FORCEINLINE HRESULT IMFPMediaPlayer_ClearMediaItem(IMFPMediaPlayer* This) {
553 return This->lpVtbl->ClearMediaItem(This);
554}
555static FORCEINLINE HRESULT IMFPMediaPlayer_GetMediaItem(IMFPMediaPlayer* This,IMFPMediaItem **ppIMFPMediaItem) {
556 return This->lpVtbl->GetMediaItem(This,ppIMFPMediaItem);
557}
558static FORCEINLINE HRESULT IMFPMediaPlayer_GetVolume(IMFPMediaPlayer* This,float *pflVolume) {
559 return This->lpVtbl->GetVolume(This,pflVolume);
560}
561static FORCEINLINE HRESULT IMFPMediaPlayer_SetVolume(IMFPMediaPlayer* This,float flVolume) {
562 return This->lpVtbl->SetVolume(This,flVolume);
563}
564static FORCEINLINE HRESULT IMFPMediaPlayer_GetBalance(IMFPMediaPlayer* This,float *pflBalance) {
565 return This->lpVtbl->GetBalance(This,pflBalance);
566}
567static FORCEINLINE HRESULT IMFPMediaPlayer_SetBalance(IMFPMediaPlayer* This,float flBalance) {
568 return This->lpVtbl->SetBalance(This,flBalance);
569}
570static FORCEINLINE HRESULT IMFPMediaPlayer_GetMute(IMFPMediaPlayer* This,WINBOOL *pfMute) {
571 return This->lpVtbl->GetMute(This,pfMute);
572}
573static FORCEINLINE HRESULT IMFPMediaPlayer_SetMute(IMFPMediaPlayer* This,WINBOOL fMute) {
574 return This->lpVtbl->SetMute(This,fMute);
575}
576static FORCEINLINE HRESULT IMFPMediaPlayer_GetNativeVideoSize(IMFPMediaPlayer* This,SIZE *pszVideo,SIZE *pszARVideo) {
577 return This->lpVtbl->GetNativeVideoSize(This,pszVideo,pszARVideo);
578}
579static FORCEINLINE HRESULT IMFPMediaPlayer_GetIdealVideoSize(IMFPMediaPlayer* This,SIZE *pszMin,SIZE *pszMax) {
580 return This->lpVtbl->GetIdealVideoSize(This,pszMin,pszMax);
581}
582static FORCEINLINE HRESULT IMFPMediaPlayer_SetVideoSourceRect(IMFPMediaPlayer* This,const MFVideoNormalizedRect *pnrcSource) {
583 return This->lpVtbl->SetVideoSourceRect(This,pnrcSource);
584}
585static FORCEINLINE HRESULT IMFPMediaPlayer_GetVideoSourceRect(IMFPMediaPlayer* This,MFVideoNormalizedRect *pnrcSource) {
586 return This->lpVtbl->GetVideoSourceRect(This,pnrcSource);
587}
588static FORCEINLINE HRESULT IMFPMediaPlayer_SetAspectRatioMode(IMFPMediaPlayer* This,DWORD dwAspectRatioMode) {
589 return This->lpVtbl->SetAspectRatioMode(This,dwAspectRatioMode);
590}
591static FORCEINLINE HRESULT IMFPMediaPlayer_GetAspectRatioMode(IMFPMediaPlayer* This,DWORD *pdwAspectRatioMode) {
592 return This->lpVtbl->GetAspectRatioMode(This,pdwAspectRatioMode);
593}
594static FORCEINLINE HRESULT IMFPMediaPlayer_GetVideoWindow(IMFPMediaPlayer* This,HWND *phwndVideo) {
595 return This->lpVtbl->GetVideoWindow(This,phwndVideo);
596}
597static FORCEINLINE HRESULT IMFPMediaPlayer_UpdateVideo(IMFPMediaPlayer* This) {
598 return This->lpVtbl->UpdateVideo(This);
599}
600static FORCEINLINE HRESULT IMFPMediaPlayer_SetBorderColor(IMFPMediaPlayer* This,COLORREF Clr) {
601 return This->lpVtbl->SetBorderColor(This,Clr);
602}
603static FORCEINLINE HRESULT IMFPMediaPlayer_GetBorderColor(IMFPMediaPlayer* This,COLORREF *pClr) {
604 return This->lpVtbl->GetBorderColor(This,pClr);
605}
606static FORCEINLINE HRESULT IMFPMediaPlayer_InsertEffect(IMFPMediaPlayer* This,IUnknown *pEffect,WINBOOL fOptional) {
607 return This->lpVtbl->InsertEffect(This,pEffect,fOptional);
608}
609static FORCEINLINE HRESULT IMFPMediaPlayer_RemoveEffect(IMFPMediaPlayer* This,IUnknown *pEffect) {
610 return This->lpVtbl->RemoveEffect(This,pEffect);
611}
612static FORCEINLINE HRESULT IMFPMediaPlayer_RemoveAllEffects(IMFPMediaPlayer* This) {
613 return This->lpVtbl->RemoveAllEffects(This);
614}
615static FORCEINLINE HRESULT IMFPMediaPlayer_Shutdown(IMFPMediaPlayer* This) {
616 return This->lpVtbl->Shutdown(This);
617}
618#endif
619#endif
620
621#endif
622
623
624#endif /* __IMFPMediaPlayer_INTERFACE_DEFINED__ */
625
626EXTERN_GUID( MFP_POSITIONTYPE_100NS, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0 );
627
628/*****************************************************************************
629 * IMFPMediaItem interface
630 */
631#ifndef __IMFPMediaItem_INTERFACE_DEFINED__
632#define __IMFPMediaItem_INTERFACE_DEFINED__
633
634DEFINE_GUID(IID_IMFPMediaItem, 0x90eb3e6b, 0xecbf, 0x45cc, 0xb1,0xda, 0xc6,0xfe,0x3e,0xa7,0x0d,0x57);
635#if defined(__cplusplus) && !defined(CINTERFACE)
636MIDL_INTERFACE("90eb3e6b-ecbf-45cc-b1da-c6fe3ea70d57")
637IMFPMediaItem : public IUnknown
638{
639 virtual HRESULT STDMETHODCALLTYPE GetMediaPlayer(
640 IMFPMediaPlayer **ppMediaPlayer) = 0;
641
642 virtual HRESULT STDMETHODCALLTYPE GetURL(
643 LPWSTR *ppwszURL) = 0;
644
645 virtual HRESULT STDMETHODCALLTYPE GetObject(
646 IUnknown **ppIUnknown) = 0;
647
648 virtual HRESULT STDMETHODCALLTYPE GetUserData(
649 DWORD_PTR *pdwUserData) = 0;
650
651 virtual HRESULT STDMETHODCALLTYPE SetUserData(
652 DWORD_PTR dwUserData) = 0;
653
654 virtual HRESULT STDMETHODCALLTYPE GetStartStopPosition(
655 GUID *pguidStartPositionType,
656 PROPVARIANT *pvStartValue,
657 GUID *pguidStopPositionType,
658 PROPVARIANT *pvStopValue) = 0;
659
660 virtual HRESULT STDMETHODCALLTYPE SetStartStopPosition(
661 const GUID *pguidStartPositionType,
662 const PROPVARIANT *pvStartValue,
663 const GUID *pguidStopPositionType,
664 const PROPVARIANT *pvStopValue) = 0;
665
666 virtual HRESULT STDMETHODCALLTYPE HasVideo(
667 WINBOOL *pfHasVideo,
668 WINBOOL *pfSelected) = 0;
669
670 virtual HRESULT STDMETHODCALLTYPE HasAudio(
671 WINBOOL *pfHasAudio,
672 WINBOOL *pfSelected) = 0;
673
674 virtual HRESULT STDMETHODCALLTYPE IsProtected(
675 WINBOOL *pfProtected) = 0;
676
677 virtual HRESULT STDMETHODCALLTYPE GetDuration(
678 REFGUID guidPositionType,
679 PROPVARIANT *pvDurationValue) = 0;
680
681 virtual HRESULT STDMETHODCALLTYPE GetNumberOfStreams(
682 DWORD *pdwStreamCount) = 0;
683
684 virtual HRESULT STDMETHODCALLTYPE GetStreamSelection(
685 DWORD dwStreamIndex,
686 WINBOOL *pfEnabled) = 0;
687
688 virtual HRESULT STDMETHODCALLTYPE SetStreamSelection(
689 DWORD dwStreamIndex,
690 WINBOOL fEnabled) = 0;
691
692 virtual HRESULT STDMETHODCALLTYPE GetStreamAttribute(
693 DWORD dwStreamIndex,
694 REFGUID guidMFAttribute,
695 PROPVARIANT *pvValue) = 0;
696
697 virtual HRESULT STDMETHODCALLTYPE GetPresentationAttribute(
698 REFGUID guidMFAttribute,
699 PROPVARIANT *pvValue) = 0;
700
701 virtual HRESULT STDMETHODCALLTYPE GetCharacteristics(
702 MFP_MEDIAITEM_CHARACTERISTICS *pCharacteristics) = 0;
703
704 virtual HRESULT STDMETHODCALLTYPE SetStreamSink(
705 DWORD dwStreamIndex,
706 IUnknown *pMediaSink) = 0;
707
708 virtual HRESULT STDMETHODCALLTYPE GetMetadata(
709 IPropertyStore **ppMetadataStore) = 0;
710
711};
712#ifdef __CRT_UUID_DECL
713__CRT_UUID_DECL(IMFPMediaItem, 0x90eb3e6b, 0xecbf, 0x45cc, 0xb1,0xda, 0xc6,0xfe,0x3e,0xa7,0x0d,0x57)
714#endif
715#else
716typedef struct IMFPMediaItemVtbl {
717 BEGIN_INTERFACE
718
719 /*** IUnknown methods ***/
720 HRESULT (STDMETHODCALLTYPE *QueryInterface)(
721 IMFPMediaItem *This,
722 REFIID riid,
723 void **ppvObject);
724
725 ULONG (STDMETHODCALLTYPE *AddRef)(
726 IMFPMediaItem *This);
727
728 ULONG (STDMETHODCALLTYPE *Release)(
729 IMFPMediaItem *This);
730
731 /*** IMFPMediaItem methods ***/
732 HRESULT (STDMETHODCALLTYPE *GetMediaPlayer)(
733 IMFPMediaItem *This,
734 IMFPMediaPlayer **ppMediaPlayer);
735
736 HRESULT (STDMETHODCALLTYPE *GetURL)(
737 IMFPMediaItem *This,
738 LPWSTR *ppwszURL);
739
740 HRESULT (STDMETHODCALLTYPE *GetObject)(
741 IMFPMediaItem *This,
742 IUnknown **ppIUnknown);
743
744 HRESULT (STDMETHODCALLTYPE *GetUserData)(
745 IMFPMediaItem *This,
746 DWORD_PTR *pdwUserData);
747
748 HRESULT (STDMETHODCALLTYPE *SetUserData)(
749 IMFPMediaItem *This,
750 DWORD_PTR dwUserData);
751
752 HRESULT (STDMETHODCALLTYPE *GetStartStopPosition)(
753 IMFPMediaItem *This,
754 GUID *pguidStartPositionType,
755 PROPVARIANT *pvStartValue,
756 GUID *pguidStopPositionType,
757 PROPVARIANT *pvStopValue);
758
759 HRESULT (STDMETHODCALLTYPE *SetStartStopPosition)(
760 IMFPMediaItem *This,
761 const GUID *pguidStartPositionType,
762 const PROPVARIANT *pvStartValue,
763 const GUID *pguidStopPositionType,
764 const PROPVARIANT *pvStopValue);
765
766 HRESULT (STDMETHODCALLTYPE *HasVideo)(
767 IMFPMediaItem *This,
768 WINBOOL *pfHasVideo,
769 WINBOOL *pfSelected);
770
771 HRESULT (STDMETHODCALLTYPE *HasAudio)(
772 IMFPMediaItem *This,
773 WINBOOL *pfHasAudio,
774 WINBOOL *pfSelected);
775
776 HRESULT (STDMETHODCALLTYPE *IsProtected)(
777 IMFPMediaItem *This,
778 WINBOOL *pfProtected);
779
780 HRESULT (STDMETHODCALLTYPE *GetDuration)(
781 IMFPMediaItem *This,
782 REFGUID guidPositionType,
783 PROPVARIANT *pvDurationValue);
784
785 HRESULT (STDMETHODCALLTYPE *GetNumberOfStreams)(
786 IMFPMediaItem *This,
787 DWORD *pdwStreamCount);
788
789 HRESULT (STDMETHODCALLTYPE *GetStreamSelection)(
790 IMFPMediaItem *This,
791 DWORD dwStreamIndex,
792 WINBOOL *pfEnabled);
793
794 HRESULT (STDMETHODCALLTYPE *SetStreamSelection)(
795 IMFPMediaItem *This,
796 DWORD dwStreamIndex,
797 WINBOOL fEnabled);
798
799 HRESULT (STDMETHODCALLTYPE *GetStreamAttribute)(
800 IMFPMediaItem *This,
801 DWORD dwStreamIndex,
802 REFGUID guidMFAttribute,
803 PROPVARIANT *pvValue);
804
805 HRESULT (STDMETHODCALLTYPE *GetPresentationAttribute)(
806 IMFPMediaItem *This,
807 REFGUID guidMFAttribute,
808 PROPVARIANT *pvValue);
809
810 HRESULT (STDMETHODCALLTYPE *GetCharacteristics)(
811 IMFPMediaItem *This,
812 MFP_MEDIAITEM_CHARACTERISTICS *pCharacteristics);
813
814 HRESULT (STDMETHODCALLTYPE *SetStreamSink)(
815 IMFPMediaItem *This,
816 DWORD dwStreamIndex,
817 IUnknown *pMediaSink);
818
819 HRESULT (STDMETHODCALLTYPE *GetMetadata)(
820 IMFPMediaItem *This,
821 IPropertyStore **ppMetadataStore);
822
823 END_INTERFACE
824} IMFPMediaItemVtbl;
825
826interface IMFPMediaItem {
827 CONST_VTBL IMFPMediaItemVtbl* lpVtbl;
828};
829
830#ifdef COBJMACROS
831#ifndef WIDL_C_INLINE_WRAPPERS
832/*** IUnknown methods ***/
833#define IMFPMediaItem_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
834#define IMFPMediaItem_AddRef(This) (This)->lpVtbl->AddRef(This)
835#define IMFPMediaItem_Release(This) (This)->lpVtbl->Release(This)
836/*** IMFPMediaItem methods ***/
837#define IMFPMediaItem_GetMediaPlayer(This,ppMediaPlayer) (This)->lpVtbl->GetMediaPlayer(This,ppMediaPlayer)
838#define IMFPMediaItem_GetURL(This,ppwszURL) (This)->lpVtbl->GetURL(This,ppwszURL)
839#define IMFPMediaItem_GetObject(This,ppIUnknown) (This)->lpVtbl->GetObject(This,ppIUnknown)
840#define IMFPMediaItem_GetUserData(This,pdwUserData) (This)->lpVtbl->GetUserData(This,pdwUserData)
841#define IMFPMediaItem_SetUserData(This,dwUserData) (This)->lpVtbl->SetUserData(This,dwUserData)
842#define IMFPMediaItem_GetStartStopPosition(This,pguidStartPositionType,pvStartValue,pguidStopPositionType,pvStopValue) (This)->lpVtbl->GetStartStopPosition(This,pguidStartPositionType,pvStartValue,pguidStopPositionType,pvStopValue)
843#define IMFPMediaItem_SetStartStopPosition(This,pguidStartPositionType,pvStartValue,pguidStopPositionType,pvStopValue) (This)->lpVtbl->SetStartStopPosition(This,pguidStartPositionType,pvStartValue,pguidStopPositionType,pvStopValue)
844#define IMFPMediaItem_HasVideo(This,pfHasVideo,pfSelected) (This)->lpVtbl->HasVideo(This,pfHasVideo,pfSelected)
845#define IMFPMediaItem_HasAudio(This,pfHasAudio,pfSelected) (This)->lpVtbl->HasAudio(This,pfHasAudio,pfSelected)
846#define IMFPMediaItem_IsProtected(This,pfProtected) (This)->lpVtbl->IsProtected(This,pfProtected)
847#define IMFPMediaItem_GetDuration(This,guidPositionType,pvDurationValue) (This)->lpVtbl->GetDuration(This,guidPositionType,pvDurationValue)
848#define IMFPMediaItem_GetNumberOfStreams(This,pdwStreamCount) (This)->lpVtbl->GetNumberOfStreams(This,pdwStreamCount)
849#define IMFPMediaItem_GetStreamSelection(This,dwStreamIndex,pfEnabled) (This)->lpVtbl->GetStreamSelection(This,dwStreamIndex,pfEnabled)
850#define IMFPMediaItem_SetStreamSelection(This,dwStreamIndex,fEnabled) (This)->lpVtbl->SetStreamSelection(This,dwStreamIndex,fEnabled)
851#define IMFPMediaItem_GetStreamAttribute(This,dwStreamIndex,guidMFAttribute,pvValue) (This)->lpVtbl->GetStreamAttribute(This,dwStreamIndex,guidMFAttribute,pvValue)
852#define IMFPMediaItem_GetPresentationAttribute(This,guidMFAttribute,pvValue) (This)->lpVtbl->GetPresentationAttribute(This,guidMFAttribute,pvValue)
853#define IMFPMediaItem_GetCharacteristics(This,pCharacteristics) (This)->lpVtbl->GetCharacteristics(This,pCharacteristics)
854#define IMFPMediaItem_SetStreamSink(This,dwStreamIndex,pMediaSink) (This)->lpVtbl->SetStreamSink(This,dwStreamIndex,pMediaSink)
855#define IMFPMediaItem_GetMetadata(This,ppMetadataStore) (This)->lpVtbl->GetMetadata(This,ppMetadataStore)
856#else
857/*** IUnknown methods ***/
858static FORCEINLINE HRESULT IMFPMediaItem_QueryInterface(IMFPMediaItem* This,REFIID riid,void **ppvObject) {
859 return This->lpVtbl->QueryInterface(This,riid,ppvObject);
860}
861static FORCEINLINE ULONG IMFPMediaItem_AddRef(IMFPMediaItem* This) {
862 return This->lpVtbl->AddRef(This);
863}
864static FORCEINLINE ULONG IMFPMediaItem_Release(IMFPMediaItem* This) {
865 return This->lpVtbl->Release(This);
866}
867/*** IMFPMediaItem methods ***/
868static FORCEINLINE HRESULT IMFPMediaItem_GetMediaPlayer(IMFPMediaItem* This,IMFPMediaPlayer **ppMediaPlayer) {
869 return This->lpVtbl->GetMediaPlayer(This,ppMediaPlayer);
870}
871static FORCEINLINE HRESULT IMFPMediaItem_GetURL(IMFPMediaItem* This,LPWSTR *ppwszURL) {
872 return This->lpVtbl->GetURL(This,ppwszURL);
873}
874static FORCEINLINE HRESULT IMFPMediaItem_GetObject(IMFPMediaItem* This,IUnknown **ppIUnknown) {
875 return This->lpVtbl->GetObject(This,ppIUnknown);
876}
877static FORCEINLINE HRESULT IMFPMediaItem_GetUserData(IMFPMediaItem* This,DWORD_PTR *pdwUserData) {
878 return This->lpVtbl->GetUserData(This,pdwUserData);
879}
880static FORCEINLINE HRESULT IMFPMediaItem_SetUserData(IMFPMediaItem* This,DWORD_PTR dwUserData) {
881 return This->lpVtbl->SetUserData(This,dwUserData);
882}
883static FORCEINLINE HRESULT IMFPMediaItem_GetStartStopPosition(IMFPMediaItem* This,GUID *pguidStartPositionType,PROPVARIANT *pvStartValue,GUID *pguidStopPositionType,PROPVARIANT *pvStopValue) {
884 return This->lpVtbl->GetStartStopPosition(This,pguidStartPositionType,pvStartValue,pguidStopPositionType,pvStopValue);
885}
886static FORCEINLINE HRESULT IMFPMediaItem_SetStartStopPosition(IMFPMediaItem* This,const GUID *pguidStartPositionType,const PROPVARIANT *pvStartValue,const GUID *pguidStopPositionType,const PROPVARIANT *pvStopValue) {
887 return This->lpVtbl->SetStartStopPosition(This,pguidStartPositionType,pvStartValue,pguidStopPositionType,pvStopValue);
888}
889static FORCEINLINE HRESULT IMFPMediaItem_HasVideo(IMFPMediaItem* This,WINBOOL *pfHasVideo,WINBOOL *pfSelected) {
890 return This->lpVtbl->HasVideo(This,pfHasVideo,pfSelected);
891}
892static FORCEINLINE HRESULT IMFPMediaItem_HasAudio(IMFPMediaItem* This,WINBOOL *pfHasAudio,WINBOOL *pfSelected) {
893 return This->lpVtbl->HasAudio(This,pfHasAudio,pfSelected);
894}
895static FORCEINLINE HRESULT IMFPMediaItem_IsProtected(IMFPMediaItem* This,WINBOOL *pfProtected) {
896 return This->lpVtbl->IsProtected(This,pfProtected);
897}
898static FORCEINLINE HRESULT IMFPMediaItem_GetDuration(IMFPMediaItem* This,REFGUID guidPositionType,PROPVARIANT *pvDurationValue) {
899 return This->lpVtbl->GetDuration(This,guidPositionType,pvDurationValue);
900}
901static FORCEINLINE HRESULT IMFPMediaItem_GetNumberOfStreams(IMFPMediaItem* This,DWORD *pdwStreamCount) {
902 return This->lpVtbl->GetNumberOfStreams(This,pdwStreamCount);
903}
904static FORCEINLINE HRESULT IMFPMediaItem_GetStreamSelection(IMFPMediaItem* This,DWORD dwStreamIndex,WINBOOL *pfEnabled) {
905 return This->lpVtbl->GetStreamSelection(This,dwStreamIndex,pfEnabled);
906}
907static FORCEINLINE HRESULT IMFPMediaItem_SetStreamSelection(IMFPMediaItem* This,DWORD dwStreamIndex,WINBOOL fEnabled) {
908 return This->lpVtbl->SetStreamSelection(This,dwStreamIndex,fEnabled);
909}
910static FORCEINLINE HRESULT IMFPMediaItem_GetStreamAttribute(IMFPMediaItem* This,DWORD dwStreamIndex,REFGUID guidMFAttribute,PROPVARIANT *pvValue) {
911 return This->lpVtbl->GetStreamAttribute(This,dwStreamIndex,guidMFAttribute,pvValue);
912}
913static FORCEINLINE HRESULT IMFPMediaItem_GetPresentationAttribute(IMFPMediaItem* This,REFGUID guidMFAttribute,PROPVARIANT *pvValue) {
914 return This->lpVtbl->GetPresentationAttribute(This,guidMFAttribute,pvValue);
915}
916static FORCEINLINE HRESULT IMFPMediaItem_GetCharacteristics(IMFPMediaItem* This,MFP_MEDIAITEM_CHARACTERISTICS *pCharacteristics) {
917 return This->lpVtbl->GetCharacteristics(This,pCharacteristics);
918}
919static FORCEINLINE HRESULT IMFPMediaItem_SetStreamSink(IMFPMediaItem* This,DWORD dwStreamIndex,IUnknown *pMediaSink) {
920 return This->lpVtbl->SetStreamSink(This,dwStreamIndex,pMediaSink);
921}
922static FORCEINLINE HRESULT IMFPMediaItem_GetMetadata(IMFPMediaItem* This,IPropertyStore **ppMetadataStore) {
923 return This->lpVtbl->GetMetadata(This,ppMetadataStore);
924}
925#endif
926#endif
927
928#endif
929
930
931#endif /* __IMFPMediaItem_INTERFACE_DEFINED__ */
932
933
934typedef enum MFP_EVENT_TYPE {
935 MFP_EVENT_TYPE_PLAY = 0,
936 MFP_EVENT_TYPE_PAUSE = 1,
937 MFP_EVENT_TYPE_STOP = 2,
938 MFP_EVENT_TYPE_POSITION_SET = 3,
939 MFP_EVENT_TYPE_RATE_SET = 4,
940 MFP_EVENT_TYPE_MEDIAITEM_CREATED = 5,
941 MFP_EVENT_TYPE_MEDIAITEM_SET = 6,
942 MFP_EVENT_TYPE_FRAME_STEP = 7,
943 MFP_EVENT_TYPE_MEDIAITEM_CLEARED = 8,
944 MFP_EVENT_TYPE_MF = 9,
945 MFP_EVENT_TYPE_ERROR = 10,
946 MFP_EVENT_TYPE_PLAYBACK_ENDED = 11,
947 MFP_EVENT_TYPE_ACQUIRE_USER_CREDENTIAL = 12
948} MFP_EVENT_TYPE;
949
950typedef struct MFP_EVENT_HEADER {
951 MFP_EVENT_TYPE eEventType;
952 HRESULT hrEvent;
953 IMFPMediaPlayer *pMediaPlayer;
954 MFP_MEDIAPLAYER_STATE eState;
955 IPropertyStore *pPropertyStore;
956} MFP_EVENT_HEADER;
957
958typedef struct MFP_PLAY_EVENT {
959 MFP_EVENT_HEADER header;
960 IMFPMediaItem *pMediaItem;
961} MFP_PLAY_EVENT;
962
963typedef struct MFP_PAUSE_EVENT {
964 MFP_EVENT_HEADER header;
965 IMFPMediaItem *pMediaItem;
966} MFP_PAUSE_EVENT;
967
968typedef struct MFP_STOP_EVENT {
969 MFP_EVENT_HEADER header;
970 IMFPMediaItem *pMediaItem;
971} MFP_STOP_EVENT;
972
973typedef struct MFP_POSITION_SET_EVENT {
974 MFP_EVENT_HEADER header;
975 IMFPMediaItem *pMediaItem;
976} MFP_POSITION_SET_EVENT;
977
978typedef struct MFP_RATE_SET_EVENT {
979 MFP_EVENT_HEADER header;
980 IMFPMediaItem *pMediaItem;
981 float flRate;
982} MFP_RATE_SET_EVENT;
983
984typedef struct MFP_MEDIAITEM_CREATED_EVENT {
985 MFP_EVENT_HEADER header;
986 IMFPMediaItem *pMediaItem;
987 DWORD_PTR dwUserData;
988} MFP_MEDIAITEM_CREATED_EVENT;
989
990typedef struct MFP_MEDIAITEM_SET_EVENT {
991 MFP_EVENT_HEADER header;
992 IMFPMediaItem *pMediaItem;
993} MFP_MEDIAITEM_SET_EVENT;
994
995typedef struct MFP_FRAME_STEP_EVENT {
996 MFP_EVENT_HEADER header;
997 IMFPMediaItem *pMediaItem;
998} MFP_FRAME_STEP_EVENT;
999
1000typedef struct MFP_MEDIAITEM_CLEARED_EVENT {
1001 MFP_EVENT_HEADER header;
1002 IMFPMediaItem *pMediaItem;
1003} MFP_MEDIAITEM_CLEARED_EVENT;
1004
1005typedef struct MFP_MF_EVENT {
1006 MFP_EVENT_HEADER header;
1007 MediaEventType MFEventType;
1008 IMFMediaEvent *pMFMediaEvent;
1009 IMFPMediaItem *pMediaItem;
1010} MFP_MF_EVENT;
1011
1012typedef struct MFP_ERROR_EVENT {
1013 MFP_EVENT_HEADER header;
1014} MFP_ERROR_EVENT;
1015
1016typedef struct MFP_PLAYBACK_ENDED_EVENT {
1017 MFP_EVENT_HEADER header;
1018 IMFPMediaItem *pMediaItem;
1019} MFP_PLAYBACK_ENDED_EVENT;
1020
1021typedef struct MFP_ACQUIRE_USER_CREDENTIAL_EVENT {
1022 MFP_EVENT_HEADER header;
1023 DWORD_PTR dwUserData;
1024 WINBOOL fProceedWithAuthentication;
1025 HRESULT hrAuthenticationStatus;
1026 LPCWSTR pwszURL;
1027 LPCWSTR pwszSite;
1028 LPCWSTR pwszRealm;
1029 LPCWSTR pwszPackage;
1030 LONG nRetries;
1031 MFP_CREDENTIAL_FLAGS flags;
1032 IMFNetCredential *pCredential;
1033} MFP_ACQUIRE_USER_CREDENTIAL_EVENT;
1034EXTERN_C const DECLSPEC_SELECTANY PROPERTYKEY MFP_PKEY_StreamIndex = { { 0xa7cf9740, 0xe8d9, 0x4a87, { 0xbd, 0x8e, 0x29, 0x67, 0x0, 0x1f, 0xd3, 0xad } }, 0x00 };
1035EXTERN_C const DECLSPEC_SELECTANY PROPERTYKEY MFP_PKEY_StreamRenderingResults = { { 0xa7cf9740, 0xe8d9, 0x4a87, { 0xbd, 0x8e, 0x29, 0x67, 0x0, 0x1f, 0xd3, 0xad } }, 0x01 };
1036#define __MFP_CAST_EVENT( pHdr, Tag ) (((pHdr)->eEventType == MFP_EVENT_TYPE_##Tag ) ? (MFP_##Tag##_EVENT*)(pHdr) : NULL)
1037#define MFP_GET_PLAY_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, PLAY )
1038#define MFP_GET_PAUSE_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, PAUSE )
1039#define MFP_GET_STOP_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, STOP )
1040#define MFP_GET_POSITION_SET_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, POSITION_SET )
1041#define MFP_GET_RATE_SET_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, RATE_SET )
1042#define MFP_GET_MEDIAITEM_CREATED_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, MEDIAITEM_CREATED )
1043#define MFP_GET_MEDIAITEM_SET_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, MEDIAITEM_SET )
1044#define MFP_GET_FRAME_STEP_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, FRAME_STEP )
1045#define MFP_GET_MEDIAITEM_CLEARED_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, MEDIAITEM_CLEARED )
1046#define MFP_GET_MF_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, MF )
1047#define MFP_GET_ERROR_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, ERROR )
1048#define MFP_GET_PLAYBACK_ENDED_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, PLAYBACK_ENDED )
1049#define MFP_GET_ACQUIRE_USER_CREDENTIAL_EVENT( pHdr ) __MFP_CAST_EVENT( pHdr, ACQUIRE_USER_CREDENTIAL )
1050
1051/*****************************************************************************
1052 * IMFPMediaPlayerCallback interface
1053 */
1054#ifndef __IMFPMediaPlayerCallback_INTERFACE_DEFINED__
1055#define __IMFPMediaPlayerCallback_INTERFACE_DEFINED__
1056
1057DEFINE_GUID(IID_IMFPMediaPlayerCallback, 0x766c8ffb, 0x5fdb, 0x4fea, 0xa2,0x8d, 0xb9,0x12,0x99,0x6f,0x51,0xbd);
1058#if defined(__cplusplus) && !defined(CINTERFACE)
1059MIDL_INTERFACE("766c8ffb-5fdb-4fea-a28d-b912996f51bd")
1060IMFPMediaPlayerCallback : public IUnknown
1061{
1062 virtual void STDMETHODCALLTYPE OnMediaPlayerEvent(
1063 MFP_EVENT_HEADER *pEventHeader) = 0;
1064
1065};
1066#ifdef __CRT_UUID_DECL
1067__CRT_UUID_DECL(IMFPMediaPlayerCallback, 0x766c8ffb, 0x5fdb, 0x4fea, 0xa2,0x8d, 0xb9,0x12,0x99,0x6f,0x51,0xbd)
1068#endif
1069#else
1070typedef struct IMFPMediaPlayerCallbackVtbl {
1071 BEGIN_INTERFACE
1072
1073 /*** IUnknown methods ***/
1074 HRESULT (STDMETHODCALLTYPE *QueryInterface)(
1075 IMFPMediaPlayerCallback *This,
1076 REFIID riid,
1077 void **ppvObject);
1078
1079 ULONG (STDMETHODCALLTYPE *AddRef)(
1080 IMFPMediaPlayerCallback *This);
1081
1082 ULONG (STDMETHODCALLTYPE *Release)(
1083 IMFPMediaPlayerCallback *This);
1084
1085 /*** IMFPMediaPlayerCallback methods ***/
1086 void (STDMETHODCALLTYPE *OnMediaPlayerEvent)(
1087 IMFPMediaPlayerCallback *This,
1088 MFP_EVENT_HEADER *pEventHeader);
1089
1090 END_INTERFACE
1091} IMFPMediaPlayerCallbackVtbl;
1092
1093interface IMFPMediaPlayerCallback {
1094 CONST_VTBL IMFPMediaPlayerCallbackVtbl* lpVtbl;
1095};
1096
1097#ifdef COBJMACROS
1098#ifndef WIDL_C_INLINE_WRAPPERS
1099/*** IUnknown methods ***/
1100#define IMFPMediaPlayerCallback_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
1101#define IMFPMediaPlayerCallback_AddRef(This) (This)->lpVtbl->AddRef(This)
1102#define IMFPMediaPlayerCallback_Release(This) (This)->lpVtbl->Release(This)
1103/*** IMFPMediaPlayerCallback methods ***/
1104#define IMFPMediaPlayerCallback_OnMediaPlayerEvent(This,pEventHeader) (This)->lpVtbl->OnMediaPlayerEvent(This,pEventHeader)
1105#else
1106/*** IUnknown methods ***/
1107static FORCEINLINE HRESULT IMFPMediaPlayerCallback_QueryInterface(IMFPMediaPlayerCallback* This,REFIID riid,void **ppvObject) {
1108 return This->lpVtbl->QueryInterface(This,riid,ppvObject);
1109}
1110static FORCEINLINE ULONG IMFPMediaPlayerCallback_AddRef(IMFPMediaPlayerCallback* This) {
1111 return This->lpVtbl->AddRef(This);
1112}
1113static FORCEINLINE ULONG IMFPMediaPlayerCallback_Release(IMFPMediaPlayerCallback* This) {
1114 return This->lpVtbl->Release(This);
1115}
1116/*** IMFPMediaPlayerCallback methods ***/
1117static FORCEINLINE void IMFPMediaPlayerCallback_OnMediaPlayerEvent(IMFPMediaPlayerCallback* This,MFP_EVENT_HEADER *pEventHeader) {
1118 This->lpVtbl->OnMediaPlayerEvent(This,pEventHeader);
1119}
1120#endif
1121#endif
1122
1123#endif
1124
1125
1126#endif /* __IMFPMediaPlayerCallback_INTERFACE_DEFINED__ */
1127
1128#endif // (WINVER >= _WIN32_WINNT_WIN7)
1129/* Begin additional prototypes for all interfaces */
1130
1131
1132/* End additional prototypes */
1133
1134#ifdef __cplusplus
1135}
1136#endif
1137
1138#endif /* __mfplay_h__ */
Note: See TracBrowser for help on using the repository browser.