19#define CHARS_IN_GUID 39
26typedef struct _AMMediaType
30 BOOL bFixedSizeSamples;
31 BOOL bTemporalCompression;
36 [size_is(cbFormat)] BYTE * pbFormat;
39typedef enum _PinDirection
45#define MAX_PIN_NAME 128
46#define MAX_FILTER_NAME 128
47cpp_quote("#define MAX_PIN_NAME 128")
48cpp_quote("#define MAX_FILTER_NAME 128")
50cpp_quote("#ifndef REFERENCE_TIME_DEFINED")
51cpp_quote("#define REFERENCE_TIME_DEFINED")
52typedef LONGLONG REFERENCE_TIME;
55cpp_quote("#ifndef REFTIME_DEFINED")
56cpp_quote("#define REFTIME_DEFINED")
57typedef DOUBLE REFTIME;
60typedef DWORD_PTR HSEMAPHORE;
61typedef DWORD_PTR HEVENT;
63typedef struct _AllocatorProperties
69} ALLOCATOR_PROPERTIES;
71interface IAMovieSetup;
72interface IEnumFilters;
73interface IEnumMediaTypes;
76interface IFilterGraph;
77interface IMediaFilter;
78interface IMediaSample;
79interface IMemAllocator;
80interface IMemAllocatorCallbackTemp;
81interface IMemAllocatorNotifyCallbackTemp;
82interface IMemInputPin;
84interface IReferenceClock;
88uuid(56a86891-0ad4-11ce-b03a-0020af0ba770),
89pointer_default(unique)
91interface IPin : IUnknown
93 typedef struct _PinInfo
97 WCHAR achName[MAX_PIN_NAME];
101 [in] IPin * pReceivePin,
102 [in] const AM_MEDIA_TYPE * pmt);
104 HRESULT ReceiveConnection(
105 [in] IPin * pConnector,
106 [in] const AM_MEDIA_TYPE *pmt);
108 HRESULT Disconnect(void);
113 HRESULT ConnectionMediaType(
114 [out] AM_MEDIA_TYPE *pmt);
116 HRESULT QueryPinInfo(
117 [out] PIN_INFO * pInfo);
119 HRESULT QueryDirection(
120 [out] PIN_DIRECTION *pPinDir);
126 [in] const AM_MEDIA_TYPE *pmt);
128 HRESULT EnumMediaTypes(
129 [out] IEnumMediaTypes **ppEnum);
131 HRESULT QueryInternalConnections(
133 [in, out] ULONG *nPin);
135 HRESULT EndOfStream(void);
137 HRESULT BeginFlush(void);
139 HRESULT EndFlush(void);
141 [in] REFERENCE_TIME tStart,
142 [in] REFERENCE_TIME tStop,
150uuid(56a86892-0ad4-11ce-b03a-0020af0ba770),
151pointer_default(unique)
153interface IEnumPins : IUnknown
158 [out, size_is(cPins)] IPin ** ppPins,
159 [out] ULONG * pcFetched);
167 [out] IEnumPins **ppEnum);
170typedef IEnumPins *PENUMPINS;
174uuid(89c31040-846b-11ce-97d3-00aa0055595a),
175pointer_default(unique)
177interface IEnumMediaTypes : IUnknown
180 [in] ULONG cMediaTypes,
181 [out, size_is(cMediaTypes)]
182 AM_MEDIA_TYPE ** ppMediaTypes,
183 [out] ULONG * pcFetched
187 [in] ULONG cMediaTypes);
192 [out] IEnumMediaTypes **ppEnum
196typedef IEnumMediaTypes *PENUMMEDIATYPES;
200uuid(56a8689f-0ad4-11ce-b03a-0020af0ba770),
201pointer_default(unique)
203interface IFilterGraph : IUnknown
206 [in] IBaseFilter * pFilter,
207 [in, string] LPCWSTR pName);
209 HRESULT RemoveFilter(
210 [in] IBaseFilter * pFilter);
213 [out] IEnumFilters **ppEnum);
215 HRESULT FindFilterByName(
216 [in, string] LPCWSTR pName,
217 [out] IBaseFilter ** ppFilter);
219 HRESULT ConnectDirect(
222 [in, unique] const AM_MEDIA_TYPE* pmt);
230 HRESULT SetDefaultSyncSource(void);
233typedef IFilterGraph *PFILTERGRAPH;
237uuid(56a86893-0ad4-11ce-b03a-0020af0ba770),
238pointer_default(unique)
240interface IEnumFilters : IUnknown
244 [out] IBaseFilter ** ppFilter,
245 [out] ULONG * pcFetched);
249 [in] ULONG cFilters);
256 [out] IEnumFilters **ppEnum);
259typedef IEnumFilters *PENUMFILTERS;
263uuid(56a86899-0ad4-11ce-b03a-0020af0ba770),
264pointer_default(unique)
266interface IMediaFilter : IPersist
268 typedef enum _FilterState
278 HRESULT Run(REFERENCE_TIME tStart);
281 [in] DWORD dwMilliSecsTimeout,
282 [out] FILTER_STATE *State);
284 HRESULT SetSyncSource(
285 [in] IReferenceClock * pClock);
287 HRESULT GetSyncSource(
288 [out] IReferenceClock ** pClock);
291typedef IMediaFilter *PMEDIAFILTER;
295uuid(56a86895-0ad4-11ce-b03a-0020af0ba770),
296pointer_default(unique)
298interface IBaseFilter : IMediaFilter
300 typedef struct _FilterInfo
302 WCHAR achName[MAX_FILTER_NAME];
303 IFilterGraph * pGraph;
307 [out] IEnumPins ** ppEnum);
310 [in, string] LPCWSTR Id,
311 [out] IPin ** ppPin);
313 HRESULT QueryFilterInfo(
314 [out] FILTER_INFO * pInfo);
316 HRESULT JoinFilterGraph(
317 [in] IFilterGraph * pGraph,
318 [in, string] LPCWSTR pName);
320 HRESULT QueryVendorInfo(
321 [out, string] LPWSTR* pVendorInfo);
324typedef IBaseFilter *PFILTER;
328uuid(56a86897-0ad4-11ce-b03a-0020af0ba770),
329pointer_default(unique)
331interface IReferenceClock : IUnknown
334 [out] REFERENCE_TIME *pTime);
337 [in] REFERENCE_TIME baseTime,
338 [in] REFERENCE_TIME streamTime,
340 [out] DWORD_PTR * pdwAdviseCookie);
342 HRESULT AdvisePeriodic(
343 [in] REFERENCE_TIME startTime,
344 [in] REFERENCE_TIME periodTime,
345 [in] HSEMAPHORE hSemaphore,
346 [out] DWORD_PTR * pdwAdviseCookie);
349 [in] DWORD_PTR dwAdviseCookie);
352typedef IReferenceClock *PREFERENCECLOCK;
358uuid(ebec459c-2eca-4d42-a8af-30df557614b8),
359pointer_default(unique)
361interface IReferenceClockTimerControl : IUnknown {
363 HRESULT SetDefaultTimerResolution(
364 REFERENCE_TIME timerResolution);
365 HRESULT GetDefaultTimerResolution(
366 [out] REFERENCE_TIME* pTimerResolution);
373uuid(36b73885-c2c8-11cf-8b46-00805f6cef60),
374pointer_default(unique)
376interface IReferenceClock2 : IReferenceClock
380typedef IReferenceClock2 *PREFERENCECLOCK2;
387uuid(56a8689a-0ad4-11ce-b03a-0020af0ba770),
388pointer_default(unique)
390interface IMediaSample : IUnknown
392 HRESULT GetPointer([out] BYTE ** ppBuffer);
397 [out] REFERENCE_TIME * pTimeStart,
398 [out] REFERENCE_TIME * pTimeEnd);
401 [in] REFERENCE_TIME * pTimeStart,
402 [in] REFERENCE_TIME * pTimeEnd);
404 HRESULT IsSyncPoint(void);
406 HRESULT SetSyncPoint(BOOL bIsSyncPoint);
408 HRESULT IsPreroll(void);
410 HRESULT SetPreroll(BOOL bIsPreroll);
412 LONG GetActualDataLength(void);
414 HRESULT SetActualDataLength(LONG length);
416 HRESULT GetMediaType(AM_MEDIA_TYPE **ppMediaType);
418 HRESULT SetMediaType(AM_MEDIA_TYPE *pMediaType);
420 HRESULT IsDiscontinuity(void);
422 HRESULT SetDiscontinuity(BOOL bDiscontinuity);
424 HRESULT GetMediaTime(
425 [out] LONGLONG * pTimeStart,
426 [out] LONGLONG * pTimeEnd);
428 HRESULT SetMediaTime(
429 [in] LONGLONG * pTimeStart,
430 [in] LONGLONG * pTimeEnd);
433typedef IMediaSample *PMEDIASAMPLE;
435enum tagAM_SAMPLE_PROPERTY_FLAGS
437 AM_SAMPLE_SPLICEPOINT = 0x01,
438 AM_SAMPLE_PREROLL = 0x02,
439 AM_SAMPLE_DATADISCONTINUITY = 0x04,
440 AM_SAMPLE_TYPECHANGED = 0x08,
441 AM_SAMPLE_TIMEVALID = 0x10,
442 AM_SAMPLE_TIMEDISCONTINUITY = 0x40,
443 AM_SAMPLE_FLUSH_ON_PAUSE = 0x80,
444 AM_SAMPLE_STOPVALID = 0x100,
445 AM_SAMPLE_ENDOFSTREAM = 0x200,
447 AM_STREAM_CONTROL = 1
450typedef struct tagAM_SAMPLE2_PROPERTIES
453 DWORD dwTypeSpecificFlags;
456 REFERENCE_TIME tStart;
457 REFERENCE_TIME tStop;
459 AM_MEDIA_TYPE *pMediaType;
462} AM_SAMPLE2_PROPERTIES;
467 uuid(36b73884-c2c8-11cf-8b46-00805f6cef60),
468 pointer_default(unique)
470interface IMediaSample2 : IMediaSample
472 HRESULT GetProperties(
473 [in] DWORD cbProperties,
474 [out, size_is(cbProperties)] BYTE * pbProperties
477 HRESULT SetProperties(
478 [in] DWORD cbProperties,
479 [in, size_is(cbProperties)] const BYTE * pbProperties
483typedef IMediaSample2 *PMEDIASAMPLE2;
485#define AM_GBF_PREVFRAMESKIPPED 1
486#define AM_GBF_NOTASYNCPOINT 2
487cpp_quote("#define AM_GBF_PREVFRAMESKIPPED 1")
488cpp_quote("#define AM_GBF_NOTASYNCPOINT 2")
490cpp_quote("#define AM_GBF_NOWAIT 4")
491cpp_quote("#define AM_GBF_NODDSURFACELOCK 8")
495uuid(56a8689c-0ad4-11ce-b03a-0020af0ba770),
496pointer_default(unique)
498interface IMemAllocator : IUnknown
500 HRESULT SetProperties(
501 [in] ALLOCATOR_PROPERTIES* pRequest,
502 [out] ALLOCATOR_PROPERTIES* pActual);
504 HRESULT GetProperties(
505 [out] ALLOCATOR_PROPERTIES* pProps);
507 HRESULT Commit(void);
509 HRESULT Decommit(void);
512 [out] IMediaSample **ppBuffer,
513 [in] REFERENCE_TIME * pStartTime,
514 [in] REFERENCE_TIME * pEndTime,
517 HRESULT ReleaseBuffer(
518 [in] IMediaSample *pBuffer);
521typedef IMemAllocator *PMEMALLOCATOR;
525uuid(379a0cf0-c1de-11d2-abf5-00a0c905f375),
526pointer_default(unique)
528interface IMemAllocatorCallbackTemp : IMemAllocator
531 [in] IMemAllocatorNotifyCallbackTemp *pNotify);
533 HRESULT GetFreeCount(
534 [out] LONG *plBuffersFree);
539uuid(92980b30-c1de-11d2-abf5-00a0c905f375),
540pointer_default(unique)
542interface IMemAllocatorNotifyCallbackTemp : IUnknown
544 HRESULT NotifyRelease();
549uuid(56a8689d-0ad4-11ce-b03a-0020af0ba770),
550pointer_default(unique)
552interface IMemInputPin : IUnknown
554 HRESULT GetAllocator(
555 [out] IMemAllocator ** ppAllocator);
557 HRESULT NotifyAllocator(
558 [in] IMemAllocator * pAllocator,
559 [in] BOOL bReadOnly);
561 HRESULT GetAllocatorRequirements( [out] ALLOCATOR_PROPERTIES*pProps );
564 [in] IMediaSample * pSample);
566 HRESULT ReceiveMultiple(
567 [in, size_is(nSamples)] IMediaSample **pSamples,
569 [out] long *nSamplesProcessed);
571 HRESULT ReceiveCanBlock();
574typedef IMemInputPin *PMEMINPUTPIN;
578uuid(a3d8cec0-7e5a-11cf-bbc5-00805f6cef20),
579pointer_default(unique)
581interface IAMovieSetup : IUnknown
584 HRESULT Unregister( );
587typedef IAMovieSetup *PAMOVIESETUP;
589typedef enum AM_SEEKING_SeekingFlags
591 AM_SEEKING_NoPositioning = 0x00,
592 AM_SEEKING_AbsolutePositioning = 0x01,
593 AM_SEEKING_RelativePositioning = 0x02,
594 AM_SEEKING_IncrementalPositioning = 0x03,
595 AM_SEEKING_PositioningBitsMask = 0x03,
596 AM_SEEKING_SeekToKeyFrame = 0x04,
597 AM_SEEKING_ReturnTime = 0x08,
598 AM_SEEKING_Segment = 0x10,
599 AM_SEEKING_NoFlush = 0x20
600} AM_SEEKING_SEEKING_FLAGS;
602typedef enum AM_SEEKING_SeekingCapabilities
604 AM_SEEKING_CanSeekAbsolute = 0x001,
605 AM_SEEKING_CanSeekForwards = 0x002,
606 AM_SEEKING_CanSeekBackwards = 0x004,
607 AM_SEEKING_CanGetCurrentPos = 0x008,
608 AM_SEEKING_CanGetStopPos = 0x010,
609 AM_SEEKING_CanGetDuration = 0x020,
610 AM_SEEKING_CanPlayBackwards = 0x040,
611 AM_SEEKING_CanDoSegments = 0x080,
612 AM_SEEKING_Source = 0x100
613} AM_SEEKING_SEEKING_CAPABILITIES;
617uuid(36b73880-c2c8-11cf-8b46-00805f6cef60),
618pointer_default(unique)
620interface IMediaSeeking : IUnknown
622 HRESULT GetCapabilities( [out] DWORD * pCapabilities );
624 HRESULT CheckCapabilities( [in,out] DWORD * pCapabilities );
626 HRESULT IsFormatSupported([in] const GUID * pFormat);
628 HRESULT QueryPreferredFormat([out] GUID * pFormat);
630 HRESULT GetTimeFormat([out] GUID *pFormat);
632 HRESULT IsUsingTimeFormat([in] const GUID * pFormat);
634 HRESULT SetTimeFormat([in] const GUID * pFormat);
636 HRESULT GetDuration([out] LONGLONG *pDuration);
638 HRESULT GetStopPosition([out] LONGLONG *pStop);
640 HRESULT GetCurrentPosition([out] LONGLONG *pCurrent);
642 HRESULT ConvertTimeFormat([out] LONGLONG * pTarget, [in] const GUID * pTargetFormat,
643 [in] LONGLONG Source, [in] const GUID * pSourceFormat );
645 HRESULT SetPositions(
646 [in,out] LONGLONG * pCurrent,
647 [in] DWORD dwCurrentFlags,
648 [in,out] LONGLONG * pStop,
649 [in] DWORD dwStopFlags);
651 HRESULT GetPositions(
652 [out] LONGLONG * pCurrent,
653 [out] LONGLONG * pStop);
655 HRESULT GetAvailable(
656 [out] LONGLONG * pEarliest,
657 [out] LONGLONG * pLatest);
659 HRESULT SetRate([in] double dRate);
661 HRESULT GetRate([out] double * pdRate);
663 HRESULT GetPreroll([out] LONGLONG * pllPreroll);
666typedef IMediaSeeking *PMEDIASEEKING;
668enum tagAM_MEDIAEVENT_FLAGS
670 AM_MEDIAEVENT_NONOTIFY = 0x01
673enum _AMSTREAMSELECTINFOFLAGS
675 AMSTREAMSELECTINFO_ENABLED = 0x1,
676 AMSTREAMSELECTINFO_EXCLUSIVE = 0x2
679enum _AMSTREAMSELECTENABLEFLAGS
681 AMSTREAMSELECTENABLE_ENABLE = 0x1,
682 AMSTREAMSELECTENABLE_ENABLEALL = 0x2
687uuid(c1960960-17f5-11d1-abe1-00a0c905f375),
688pointer_default(unique)
690interface IAMStreamSelect : IUnknown
693 [out] DWORD *streams);
697 [out] AM_MEDIA_TYPE **media_type,
702 [out] IUnknown **object,
703 [out] IUnknown **unknown);
710typedef IAMStreamSelect *PAMSTREAMSELECT;
CD3D10_BUFFER_DESC D3D10_BUFFER_DESC cpp_quote(" ~CD3D10_BUFFER_DESC() {}") operator const D3D10_BUFFER_DESC &() const