Mercurial > mplayer.hg
annotate stream/tvi_dshow.h @ 30174:84f7e547aaf2
Invoke pci_db2c.awk as an argument to awk instead of letting the shell run it.
The shell looks for awk in /usr/bin, the path from the shebang line. However,
there exist systems with awk in /bin, namely archlinux.
author | diego |
---|---|
date | Mon, 04 Jan 2010 21:22:33 +0000 |
parents | 774aa6f7399e |
children | ce0122361a39 |
rev | line source |
---|---|
26029 | 1 #ifndef MPLAYER_TVI_DSHOW_H |
2 #define MPLAYER_TVI_DSHOW_H | |
24744 | 3 |
4 /// \defgroup tvi_dshow TV driver (Directshow) | |
5 | |
6 #define INITGUID | |
7 #include <inttypes.h> | |
27846
87da3db93a44
vfw.h needs a windows.h include before on MinGW64.
reimar
parents:
26029
diff
changeset
|
8 #include <windows.h> |
24744 | 9 //#include <ole2.h> |
10 #include <vfw.h> | |
11 #include "loader/dshow/mediatype.h" | |
12 #include "loader/dshow/guids.h" | |
13 | |
14 #define wtoa(strW,strA,lenA) WideCharToMultiByte(0,0,strW,-1,strA,lenA,NULL,NULL) | |
15 #define atow(strA,strW,lenW) MultiByteToWideChar(0,0,strA,strlen(strA),strW,lenW) | |
16 | |
17 typedef struct DISPPARAMS *LPDISPPARAMS; | |
18 typedef struct IFileSinkFilter *LPFILESINKFILTER; | |
19 typedef struct IAMCopyCaptureFileProgress *LPAMCOPYCAPTUREFILEPROGRESS; | |
20 typedef struct IErrorLog *LPERRORLOG; | |
21 typedef struct IAMTunerNotification *LPAMTUNERNOTIFICATION; | |
22 typedef struct IFilterGraph *LPFILTERGRAPH; | |
23 typedef struct IBaseFilter *LPBASEFILTER; | |
24 typedef struct IPin *LPPIN; | |
25 typedef struct IEnumPins *LPENUMPINS; | |
26 typedef struct IEnumFilters *LPENUMFILTERS; | |
27 typedef struct IEnumMediaTypes *LPENUMMEDIATYPES; | |
28 typedef struct IReferenceClock *LPREFERENCECLOCK; | |
29 typedef struct IMediaSample *LPMEDIASAMPLE; | |
30 typedef struct IVideoWindow *LPVIDEOWINDOW; | |
31 | |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27846
diff
changeset
|
32 typedef struct |
24744 | 33 { |
34 long cBuffers; | |
35 long cbBuffer; | |
36 long cbAlign; | |
37 long cbPrefix; | |
38 }ALLOCATOR_PROPERTIES; | |
39 | |
40 typedef | |
41 enum tagTunerInputType { TunerInputCable = 0, | |
42 TunerInputAntenna = TunerInputCable + 1 | |
43 } TunerInputType; | |
44 typedef enum tagAMTunerModeType { | |
45 AMTUNER_MODE_DEFAULT = 0x0000, | |
46 AMTUNER_MODE_TV = 0x0001, | |
47 AMTUNER_MODE_FM_RADIO = 0x0002, | |
48 AMTUNER_MODE_AM_RADIO = 0x0004, | |
49 AMTUNER_MODE_DSS = 0x0008 | |
50 } AMTunerModeType; | |
51 enum tagAMTunerSubChannel { AMTUNER_SUBCHAN_NO_TUNE = -2, | |
52 AMTUNER_SUBCHAN_DEFAULT = -1 | |
53 } AMTunerSubChannel; | |
54 typedef enum tagVideoProcAmpProperty { | |
55 VideoProcAmp_Brightness, | |
56 VideoProcAmp_Contrast, | |
57 VideoProcAmp_Hue, | |
58 VideoProcAmp_Saturation, | |
59 VideoProcAmp_Sharpness, | |
60 VideoProcAmp_Gamma, | |
61 VideoProcAmp_ColorEnable, | |
62 VideoProcAmp_WhiteBalance, | |
63 VideoProcAmp_BacklightCompensation, | |
64 VideoProcAmp_Gain | |
65 } VideoProcAmpProperty; | |
66 | |
67 typedef long OAFilterState; | |
68 typedef | |
69 enum tagAnalogVideoStandard { AnalogVideo_None = 0, | |
70 AnalogVideo_NTSC_M = 0x1, | |
71 AnalogVideo_NTSC_M_J = 0x2, | |
72 AnalogVideo_NTSC_433 = 0x4, | |
73 AnalogVideo_PAL_B = 0x10, | |
74 AnalogVideo_PAL_D = 0x20, | |
75 AnalogVideo_PAL_G = 0x40, | |
76 AnalogVideo_PAL_H = 0x80, | |
77 AnalogVideo_PAL_I = 0x100, | |
78 AnalogVideo_PAL_M = 0x200, | |
79 AnalogVideo_PAL_N = 0x400, | |
80 AnalogVideo_PAL_60 = 0x800, | |
81 AnalogVideo_SECAM_B = 0x1000, | |
82 AnalogVideo_SECAM_D = 0x2000, | |
83 AnalogVideo_SECAM_G = 0x4000, | |
84 AnalogVideo_SECAM_H = 0x8000, | |
85 AnalogVideo_SECAM_K = 0x10000, | |
86 AnalogVideo_SECAM_K1 = 0x20000, | |
87 AnalogVideo_SECAM_L = 0x40000, | |
88 AnalogVideo_SECAM_L1 = 0x80000 | |
89 } AnalogVideoStandard; | |
90 | |
91 | |
92 typedef LONG_PTR OAHWND; | |
93 typedef enum tagPhysicalConnectorType { PhysConn_Video_Tuner = 1, | |
94 PhysConn_Video_Composite = PhysConn_Video_Tuner + 1, | |
95 PhysConn_Video_SVideo = PhysConn_Video_Composite + 1, | |
96 PhysConn_Video_RGB = PhysConn_Video_SVideo + 1, | |
97 PhysConn_Video_YRYBY = PhysConn_Video_RGB + 1, | |
98 PhysConn_Video_SerialDigital = PhysConn_Video_YRYBY + 1, | |
99 PhysConn_Video_ParallelDigital = PhysConn_Video_SerialDigital + 1, | |
100 PhysConn_Video_SCSI = PhysConn_Video_ParallelDigital + 1, | |
101 PhysConn_Video_AUX = PhysConn_Video_SCSI + 1, | |
102 PhysConn_Video_1394 = PhysConn_Video_AUX + 1, | |
103 PhysConn_Video_USB = PhysConn_Video_1394 + 1, | |
104 PhysConn_Video_VideoDecoder = PhysConn_Video_USB + 1, | |
105 PhysConn_Video_VideoEncoder = PhysConn_Video_VideoDecoder + 1, | |
106 PhysConn_Video_SCART = PhysConn_Video_VideoEncoder + 1, | |
107 PhysConn_Video_Black = PhysConn_Video_SCART + 1, | |
108 PhysConn_Audio_Tuner = 0x1000, | |
109 PhysConn_Audio_Line = PhysConn_Audio_Tuner + 1, | |
110 PhysConn_Audio_Mic = PhysConn_Audio_Line + 1, | |
111 PhysConn_Audio_AESDigital = PhysConn_Audio_Mic + 1, | |
112 PhysConn_Audio_SPDIFDigital = PhysConn_Audio_AESDigital + 1, | |
113 PhysConn_Audio_SCSI = PhysConn_Audio_SPDIFDigital + 1, | |
114 PhysConn_Audio_AUX = PhysConn_Audio_SCSI + 1, | |
115 PhysConn_Audio_1394 = PhysConn_Audio_AUX + 1, | |
116 PhysConn_Audio_USB = PhysConn_Audio_1394 + 1, | |
117 PhysConn_Audio_AudioDecoder = PhysConn_Audio_USB + 1 | |
118 } PhysicalConnectorType; | |
119 | |
25607
9d0b189ce1b2
Fix illegal identifiers: Names starting with __ or _ and uppercase are reserved
diego
parents:
24744
diff
changeset
|
120 typedef struct VIDEO_STREAM_CONFIG_CAPS { |
24744 | 121 GUID guid; // will be MEDIATYPE_Video |
122 ULONG VideoStandard; // logical OR of all AnalogVideoStandards | |
123 // supported | |
124 SIZE InputSize; // the inherent size of the incoming signal | |
125 // (every pixel unique) | |
126 SIZE MinCroppingSize; // smallest rcSrc cropping rect allowed | |
127 SIZE MaxCroppingSize; // largest rcSrc cropping rect allowed | |
128 int CropGranularityX; // granularity of cropping size | |
129 int CropGranularityY; | |
130 int CropAlignX; // alignment of cropping rect | |
131 int CropAlignY; | |
132 SIZE MinOutputSize; // smallest bitmap stream can produce | |
133 SIZE MaxOutputSize; // largest bitmap stream can produce | |
134 int OutputGranularityX; // granularity of output bitmap size | |
135 int OutputGranularityY; | |
136 int StretchTapsX; // 0, no stretch, 1 pix dup, 2 interp, ... | |
137 int StretchTapsY; // Describes quality of hardware scaler | |
138 int ShrinkTapsX; // | |
139 int ShrinkTapsY; // | |
140 LONGLONG MinFrameInterval; // 100 nS units | |
141 LONGLONG MaxFrameInterval; | |
142 LONG MinBitsPerSecond; | |
143 LONG MaxBitsPerSecond; | |
144 } VIDEO_STREAM_CONFIG_CAPS, *PVIDEO_STREAM_CONFIG_CAPS; | |
145 | |
25607
9d0b189ce1b2
Fix illegal identifiers: Names starting with __ or _ and uppercase are reserved
diego
parents:
24744
diff
changeset
|
146 typedef struct AUDIO_STREAM_CONFIG_CAPS { |
24744 | 147 GUID guid; |
148 ULONG MinimumChannels; | |
149 ULONG MaximumChannels; | |
150 ULONG ChannelsGranularity; | |
151 ULONG MinimumBitsPerSample; | |
152 ULONG MaximumBitsPerSample; | |
153 ULONG BitsPerSampleGranularity; | |
154 ULONG MinimumSampleFrequency; | |
155 ULONG MaximumSampleFrequency; | |
156 ULONG SampleFrequencyGranularity; | |
157 } AUDIO_STREAM_CONFIG_CAPS; | |
158 | |
159 typedef enum tagVideoProcAmpFlags { | |
160 VideoProcAmp_Flags_Auto = 0x0001, | |
161 VideoProcAmp_Flags_Manual = 0x0002 | |
162 } VideoProcAmpFlags; | |
163 typedef enum { | |
164 PINDIR_INPUT = 0, | |
165 PINDIR_OUTPUT | |
166 } PIN_DIRECTION; | |
167 | |
168 #define KSPROPERTY_SUPPORT_GET 1 | |
169 #define KSPROPERTY_SUPPORT_SET 2 | |
170 typedef struct { | |
171 GUID Set; | |
172 ULONG Id; | |
173 ULONG Flags; | |
174 } KSIDENTIFIER; | |
175 | |
176 typedef KSIDENTIFIER KSPROPERTY; | |
177 | |
178 | |
179 typedef struct { | |
180 KSPROPERTY Property; | |
181 ULONG Mode; // IN: KSPROPERTY_TUNER_MODE | |
182 ULONG StandardsSupported; // KS_AnalogVideo_* (if TV or DSS) | |
183 ULONG MinFrequency; // Hz | |
184 ULONG MaxFrequency; // Hz | |
185 ULONG TuningGranularity; // Hz | |
186 ULONG NumberOfInputs; // count of inputs | |
187 ULONG SettlingTime; // milliSeconds | |
188 ULONG Strategy; // KS_TUNER_STRATEGY | |
189 } KSPROPERTY_TUNER_MODE_CAPS_S, *PKSPROPERTY_TUNER_MODE_CAPS_S; | |
190 | |
191 typedef struct { | |
192 KSPROPERTY Property; | |
193 ULONG Mode; // IN: KSPROPERTY_TUNER_MODE | |
194 } KSPROPERTY_TUNER_MODE_S, *PKSPROPERTY_TUNER_MODE_S; | |
195 | |
196 typedef struct { | |
197 KSPROPERTY Property; | |
198 ULONG Frequency; // Hz | |
199 ULONG LastFrequency; // Hz (last known good) | |
200 ULONG TuningFlags; // KS_TUNER_TUNING_FLAGS | |
201 ULONG VideoSubChannel; // DSS | |
202 ULONG AudioSubChannel; // DSS | |
203 ULONG Channel; // VBI decoders | |
204 ULONG Country; // VBI decoders | |
205 } KSPROPERTY_TUNER_FREQUENCY_S, *PKSPROPERTY_TUNER_FREQUENCY_S; | |
206 typedef struct { | |
207 KSPROPERTY Property; | |
208 ULONG CurrentFrequency; | |
209 ULONG PLLOffset; | |
210 ULONG SignalStrength; | |
211 ULONG Busy; | |
212 } KSPROPERTY_TUNER_STATUS_S, *PKSPROPERTY_TUNER_STATUS_S; | |
213 typedef enum { | |
214 KS_TUNER_TUNING_EXACT = 1, // No fine tuning | |
215 KS_TUNER_TUNING_FINE, // Fine grained search | |
216 KS_TUNER_TUNING_COARSE, // Coarse search | |
217 } KS_TUNER_TUNING_FLAGS; | |
218 | |
219 typedef enum { | |
220 KSPROPERTY_TUNER_CAPS, // R -overall device capabilities | |
221 KSPROPERTY_TUNER_MODE_CAPS, // R -capabilities in this mode | |
222 KSPROPERTY_TUNER_MODE, // RW -set a mode (TV, FM, AM, DSS) | |
223 KSPROPERTY_TUNER_STANDARD, // R -get TV standard (only if TV mode) | |
224 KSPROPERTY_TUNER_FREQUENCY, // RW -set/get frequency | |
225 KSPROPERTY_TUNER_INPUT, // RW -select an input | |
226 KSPROPERTY_TUNER_STATUS, // R -tuning status | |
227 KSPROPERTY_TUNER_IF_MEDIUM // R O-Medium for IF or Transport Pin | |
228 } KSPROPERTY_TUNER; | |
229 typedef enum { | |
230 KS_TUNER_STRATEGY_PLL = 0X01, // Tune by PLL offset | |
231 KS_TUNER_STRATEGY_SIGNAL_STRENGTH = 0X02, // Tune by signal strength | |
232 KS_TUNER_STRATEGY_DRIVER_TUNES = 0X04, // Driver does fine tuning | |
233 } KS_TUNER_STRATEGY; | |
234 typedef enum tagTVAudioMode { | |
235 AMTVAUDIO_MODE_MONO = 0x0001, | |
236 AMTVAUDIO_MODE_STEREO = 0x0002, | |
237 AMTVAUDIO_MODE_LANG_A = 0x0010, | |
238 AMTVAUDIO_MODE_LANG_B = 0x0020, | |
239 AMTVAUDIO_MODE_LANG_C = 0x0040, | |
240 } TVAudioMode; | |
241 | |
25607
9d0b189ce1b2
Fix illegal identifiers: Names starting with __ or _ and uppercase are reserved
diego
parents:
24744
diff
changeset
|
242 typedef struct FilterInfo { |
24744 | 243 WCHAR achName[128]; |
244 LPFILTERGRAPH pGraph; | |
245 } FILTER_INFO; | |
246 | |
25607
9d0b189ce1b2
Fix illegal identifiers: Names starting with __ or _ and uppercase are reserved
diego
parents:
24744
diff
changeset
|
247 typedef struct PinInfo { |
24744 | 248 LPBASEFILTER pFilter; |
249 PIN_DIRECTION dir; | |
250 unsigned short achName[128]; | |
251 } PIN_INFO; | |
252 //----------------------------------- | |
253 | |
254 | |
255 #undef INTERFACE | |
256 #define INTERFACE IPin | |
257 DECLARE_INTERFACE(IPin) | |
258 { | |
259 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
260 STDMETHOD_(long, AddRef) (THIS); | |
261 STDMETHOD_(long, Release) (THIS); | |
262 STDMETHOD(Connect) (THIS_ IPin *, AM_MEDIA_TYPE *); | |
263 STDMETHOD(ReceiveConnection) (THIS_ IPin *, const AM_MEDIA_TYPE *); | |
264 STDMETHOD(Disconnect) (THIS); | |
265 STDMETHOD(ConnectedTo) (THIS_ IPin **); | |
266 STDMETHOD(ConnectionMediaType) (THIS_ AM_MEDIA_TYPE * pmt); | |
267 STDMETHOD(QueryPinInfo) (THIS_ PIN_INFO *); | |
268 STDMETHOD(QueryDirection) (THIS_ PIN_DIRECTION *); | |
269 STDMETHOD(QueryId) (THIS_ unsigned short **); | |
270 STDMETHOD(QueryAccept) (THIS_ const AM_MEDIA_TYPE *); | |
271 STDMETHOD(EnumMediaTypes) (THIS_ LPENUMMEDIATYPES *); | |
272 STDMETHOD(QueryInternalConnections) (THIS_ IPin **, unsigned long *); | |
273 STDMETHOD(EndOfStream) (THIS); | |
274 STDMETHOD(BeginFlush) (THIS); | |
275 STDMETHOD(EndFlush) (THIS); | |
276 STDMETHOD(NewSegment) (THIS_ REFERENCE_TIME, REFERENCE_TIME, double); | |
277 }; | |
278 | |
279 #undef INTERFACE | |
280 #define INTERFACE IBaseFilter | |
281 DECLARE_INTERFACE(IBaseFilter) | |
282 { | |
283 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
284 STDMETHOD_(long, AddRef) (THIS); | |
285 STDMETHOD_(long, Release) (THIS); | |
286 STDMETHOD(GetClassID) (THIS_ CLSID * pClassID); | |
287 STDMETHOD(Stop) (THIS); | |
288 STDMETHOD(Pause) (THIS); | |
289 STDMETHOD(Run) (THIS_ REFERENCE_TIME tStart); | |
290 STDMETHOD(GetState) (THIS_ unsigned long, void *); | |
291 STDMETHOD(SetSyncSource) (THIS_ LPREFERENCECLOCK); | |
292 STDMETHOD(GetSyncSource) (THIS_ LPREFERENCECLOCK *); | |
293 STDMETHOD(EnumPins) (THIS_ LPENUMPINS *); | |
294 STDMETHOD(FindPin) (THIS_ const unsigned short *, LPPIN *); | |
295 STDMETHOD(QueryFilterInfo) (THIS_ void *); | |
296 STDMETHOD(JoinFilterGraph) (THIS_ LPFILTERGRAPH, | |
297 const unsigned short *); | |
298 STDMETHOD(QueryVendorInfo) (THIS_ unsigned short **); | |
299 }; | |
300 | |
301 #undef INTERFACE | |
302 #define INTERFACE IAMTVTuner | |
303 DECLARE_INTERFACE(IAMTVTuner) | |
304 { | |
305 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
306 STDMETHOD_(long, AddRef) (THIS); | |
307 STDMETHOD_(long, Release) (THIS); | |
308 STDMETHOD(put_Channel) (THIS_ long, long, long); | |
309 STDMETHOD(get_Channel) (THIS_ long *, long *, long *); | |
310 STDMETHOD(ChannelMinMax) (THIS_ long *, long *); | |
311 STDMETHOD(put_CountryCode) (THIS_ long); | |
312 STDMETHOD(get_CountryCode) (THIS_ long *); | |
313 STDMETHOD(put_TuningSpace) (THIS_ long); | |
314 STDMETHOD(get_TuningSpace) (THIS_ long *); | |
315 STDMETHOD(Logon) (THIS_ HANDLE); | |
316 STDMETHOD(Logout) (IAMTVTuner *); | |
317 STDMETHOD(SignalPresen) (THIS_ long *); | |
318 STDMETHOD(put_Mode) (THIS_ AMTunerModeType); | |
319 STDMETHOD(get_Mode) (THIS_ AMTunerModeType *); | |
320 STDMETHOD(GetAvailableModes) (THIS_ long *); | |
321 STDMETHOD(RegisterNotificationCallBack) (THIS_ LPAMTUNERNOTIFICATION, | |
322 long); | |
323 STDMETHOD(UnRegisterNotificationCallBack) (THIS_ | |
324 LPAMTUNERNOTIFICATION); | |
325 STDMETHOD(get_AvailableTVFormats) (THIS_ long *); | |
326 STDMETHOD(get_TVFormat) (THIS_ long *); | |
327 STDMETHOD(AutoTune) (THIS_ long, long *); | |
328 STDMETHOD(StoreAutoTune) (IAMTVTuner *); | |
329 STDMETHOD(get_NumInputConnections) (THIS_ long *); | |
330 STDMETHOD(put_InputType) (THIS_ long, TunerInputType); | |
331 STDMETHOD(get_InputType) (THIS_ long, TunerInputType *); | |
332 STDMETHOD(put_ConnectInput) (THIS_ long); | |
333 STDMETHOD(get_ConnectInput) (THIS_ long *); | |
334 STDMETHOD(get_VideoFrequency) (THIS_ long *); | |
335 STDMETHOD(get_AudioFrequency) (THIS_ long *); | |
336 }; | |
337 | |
338 #undef INTERFACE | |
339 #define INTERFACE IMediaControl | |
340 DECLARE_INTERFACE(IMediaControl) | |
341 { | |
342 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
343 STDMETHOD_(long, AddRef) (THIS); | |
344 STDMETHOD_(long, Release) (THIS); | |
345 STDMETHOD(GetTypeInfoCount) (THIS_ UINT *); | |
346 STDMETHOD(GetTypeInfo) (THIS_ UINT, LCID, LPTYPEINFO *); | |
347 STDMETHOD(GetIDsOfNames) (THIS_ REFIID, LPOLESTR *, UINT, LCID, | |
348 DISPID *); | |
349 STDMETHOD(Invoke) (THIS_ DISPID, REFIID, LCID, WORD, LPDISPPARAMS, | |
350 VARIANT *, EXCEPINFO *, UINT *); | |
351 STDMETHOD(Run) (THIS); | |
352 STDMETHOD(Pause) (THIS); | |
353 STDMETHOD(Stop) (THIS); | |
354 STDMETHOD(GetState) (THIS_ LONG, OAFilterState *); | |
355 STDMETHOD(RenderFile) (THIS_ BSTR); | |
356 STDMETHOD(AddSourceFilter) (THIS_ BSTR, LPDISPATCH *); | |
357 STDMETHOD(get_FilterCollection) (THIS_ LPDISPATCH *); | |
358 STDMETHOD(get_RegFilterCollection) (THIS_ LPDISPATCH *); | |
359 STDMETHOD(StopWhenReady) (IMediaControl *); | |
360 }; | |
361 | |
362 #undef INTERFACE | |
363 #define INTERFACE IGraphBuilder | |
364 DECLARE_INTERFACE(IGraphBuilder) | |
365 { | |
366 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
367 STDMETHOD_(long, AddRef) (THIS); | |
368 STDMETHOD_(long, Release) (THIS); | |
369 STDMETHOD(AddFilter) (THIS_ IBaseFilter *, LPCWSTR); | |
370 STDMETHOD(RemoveFilter) (THIS_ IBaseFilter *); | |
371 STDMETHOD(EnumFilters) (THIS_ LPENUMFILTERS *); | |
372 STDMETHOD(FindFilterByName) (THIS_ LPCWSTR, IBaseFilter **); | |
373 STDMETHOD(ConnectDirect) (THIS_ IPin *, IPin *, const AM_MEDIA_TYPE *); | |
374 STDMETHOD(Reconnect) (THIS_ IPin *); | |
375 STDMETHOD(Disconnect) (THIS_ IPin *); | |
376 STDMETHOD(SetDefaultSyncSource) (IGraphBuilder *); | |
377 STDMETHOD(Connect) (THIS_ IPin *, IPin *); | |
378 STDMETHOD(Render) (THIS_ IPin *); | |
379 STDMETHOD(RenderFile) (THIS_ LPCWSTR, LPCWSTR); | |
380 STDMETHOD(AddSourceFilter) (THIS_ LPCWSTR, LPCWSTR, IBaseFilter **); | |
381 STDMETHOD(SetLogFile) (THIS_ DWORD_PTR); | |
382 STDMETHOD(Abort) (IGraphBuilder *); | |
383 STDMETHOD(ShouldOperationContinue) (IGraphBuilder *); | |
384 }; | |
385 | |
386 | |
387 #undef INTERFACE | |
388 #define INTERFACE ICaptureGraphBuilder2 | |
389 DECLARE_INTERFACE(ICaptureGraphBuilder2) | |
390 { | |
391 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
392 STDMETHOD_(long, AddRef) (THIS); | |
393 STDMETHOD_(long, Release) (THIS); | |
394 STDMETHOD(SetFiltergraph) (THIS_ IGraphBuilder *); | |
395 STDMETHOD(GetFiltergraph) (THIS_ IGraphBuilder **); | |
396 STDMETHOD(SetOutputFileName) (THIS_ const GUID *, LPCOLESTR, | |
397 IBaseFilter **, LPFILESINKFILTER *); | |
398 STDMETHOD(FindInterface) (THIS_ const GUID *, const GUID *, | |
399 IBaseFilter *, REFIID, void **); | |
400 STDMETHOD(RenderStream) (THIS_ const GUID *, const GUID *, IUnknown *, | |
401 IBaseFilter *, IBaseFilter *); | |
402 STDMETHOD(ControlStream) (THIS_ const GUID *, const GUID *, | |
403 IBaseFilter *, REFERENCE_TIME *, | |
404 REFERENCE_TIME *, WORD, WORD); | |
405 STDMETHOD(AllocCapFile) (THIS_ LPCOLESTR, DWORDLONG); | |
406 STDMETHOD(CopyCaptureFile) (THIS_ LPOLESTR, LPOLESTR, int, | |
407 LPAMCOPYCAPTUREFILEPROGRESS); | |
408 STDMETHOD(FindPin) (THIS_ IUnknown *, PIN_DIRECTION, const GUID *, | |
409 const GUID *, BOOL, int, IPin **); | |
410 }; | |
411 | |
412 #undef INTERFACE | |
413 #define INTERFACE ICreateDevEnum | |
414 DECLARE_INTERFACE(ICreateDevEnum) | |
415 { | |
416 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
417 STDMETHOD_(long, AddRef) (THIS); | |
418 STDMETHOD_(long, Release) (THIS); | |
419 STDMETHOD(CreateClassEnumerator) (THIS_ REFCLSID, IEnumMoniker **, | |
420 DWORD); | |
421 }; | |
422 | |
423 #undef INTERFACE | |
424 #define INTERFACE IAMCrossbar | |
425 DECLARE_INTERFACE(IAMCrossbar) | |
426 { | |
427 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
428 STDMETHOD_(long, AddRef) (THIS); | |
429 STDMETHOD_(long, Release) (THIS); | |
430 STDMETHOD(get_PinCounts) (THIS_ long *, long *); | |
431 STDMETHOD(CanRoute) (THIS_ long, long); | |
432 STDMETHOD(Route) (THIS_ long, long); | |
433 STDMETHOD(get_IsRoutedTo) (THIS_ long, long *); | |
434 STDMETHOD(get_CrossbarPinInfo) (THIS_ BOOL, long, long *, long *); | |
435 }; | |
436 | |
30127
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
437 #ifndef __IPropertyBag_INTERFACE_DEFINED__ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
438 #define __IPropertyBag_INTERFACE_DEFINED__ |
24744 | 439 #undef INTERFACE |
440 #define INTERFACE IPropertyBag | |
441 DECLARE_INTERFACE(IPropertyBag) | |
442 { | |
443 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
444 STDMETHOD_(long, AddRef) (THIS); | |
445 STDMETHOD_(long, Release) (THIS); | |
446 STDMETHOD(Read) (THIS_ LPCOLESTR, LPVARIANT, LPERRORLOG); | |
447 STDMETHOD(Write) (THIS_ LPCOLESTR, LPVARIANT); | |
448 }; | |
30127
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
449 #endif |
24744 | 450 |
451 #undef INTERFACE | |
452 #define INTERFACE IAMStreamConfig | |
453 DECLARE_INTERFACE(IAMStreamConfig) | |
454 { | |
455 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
456 STDMETHOD_(long, AddRef) (THIS); | |
457 STDMETHOD_(long, Release) (THIS); | |
458 HRESULT(STDMETHODCALLTYPE * SetFormat) (THIS_ AM_MEDIA_TYPE *); | |
459 HRESULT(STDMETHODCALLTYPE * GetFormat) (THIS_ AM_MEDIA_TYPE **); | |
460 HRESULT(STDMETHODCALLTYPE * GetNumberOfCapabilities) (THIS_ int *,int *); | |
461 HRESULT(STDMETHODCALLTYPE * GetStreamCaps) (THIS_ int,AM_MEDIA_TYPE **, BYTE *); | |
462 }; | |
463 | |
464 #undef INTERFACE | |
465 #define INTERFACE IAMVideoProcAmp | |
466 DECLARE_INTERFACE(IAMVideoProcAmp) | |
467 { | |
468 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
469 STDMETHOD_(long, AddRef) (THIS); | |
470 STDMETHOD_(long, Release) (THIS); | |
471 STDMETHOD(GetRange) (THIS_ long, long *, long *, long *, long *,long *); | |
472 STDMETHOD(Set) (THIS_ long, long, long); | |
473 STDMETHOD(Get) (THIS_ long, long *, long *); | |
474 }; | |
475 | |
476 #undef INTERFACE | |
477 #define INTERFACE IKsPropertySet | |
478 DECLARE_INTERFACE(IKsPropertySet) | |
479 { | |
480 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
481 STDMETHOD_(long, AddRef) (THIS); | |
482 STDMETHOD_(long, Release) (THIS); | |
483 HRESULT(STDMETHODCALLTYPE * Set) (THIS_ REFGUID, DWORD, LPVOID, DWORD,LPVOID, DWORD); | |
484 HRESULT(STDMETHODCALLTYPE * Get) (THIS_ REFGUID, DWORD, LPVOID, DWORD,LPVOID, DWORD, DWORD *); | |
485 HRESULT(STDMETHODCALLTYPE * QuerySupported) (THIS_ REFGUID, DWORD,DWORD *); | |
486 }; | |
487 | |
488 #undef INTERFACE | |
489 #define INTERFACE IAMAnalogVideoDecoder | |
490 DECLARE_INTERFACE(IAMAnalogVideoDecoder) | |
491 { | |
492 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
493 STDMETHOD_(long, AddRef) (THIS); | |
494 STDMETHOD_(long, Release) (THIS); | |
495 STDMETHOD(get_AvailableTVFormats) (THIS_ long *); | |
496 STDMETHOD(put_TVFormat) (THIS_ long); | |
497 STDMETHOD(get_TVFormat) (THIS_ long *); | |
498 STDMETHOD(get_HorizontalLocked) (THIS_ long *); | |
499 STDMETHOD(put_VCRHorizontalLocking) (THIS_ long); | |
500 STDMETHOD(get_VCRHorizontalLocking) (THIS_ long *); | |
501 STDMETHOD(get_NumberOfLines) (THIS_ long *); | |
502 STDMETHOD(put_OutputEnable) (THIS_ long); | |
503 STDMETHOD(get_OutputEnable) (THIS_ long *); | |
504 }; | |
505 | |
506 #undef INTERFACE | |
507 #define INTERFACE IAMTVAudio | |
508 DECLARE_INTERFACE(IAMTVAudio) | |
509 { | |
510 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
511 STDMETHOD_(long, AddRef) (THIS); | |
512 STDMETHOD_(long, Release) (THIS); | |
513 STDMETHOD(GetHardwareSupportedTVAudioModes) (THIS_ long *); | |
514 STDMETHOD(GetAvailableTVAudioModes) (THIS_ long *); | |
515 STDMETHOD(get_TVAudioMode) (THIS_ long *); | |
516 STDMETHOD(put_TVAudioMode) (THIS_ long); | |
517 STDMETHOD(RegisterNotificationCallBack) (THIS_ LPAMTUNERNOTIFICATION, | |
518 long); | |
519 STDMETHOD(UnRegisterNotificationCallBack) (THIS_ | |
520 LPAMTUNERNOTIFICATION); | |
521 }; | |
522 | |
523 | |
524 #undef INTERFACE | |
525 #define INTERFACE ISampleGrabberCB | |
526 DECLARE_INTERFACE(ISampleGrabberCB) | |
527 { | |
528 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
529 STDMETHOD_(long, AddRef) (THIS); | |
530 STDMETHOD_(long, Release) (THIS); | |
531 STDMETHOD(SampleCB) (THIS_ double, LPMEDIASAMPLE); | |
532 STDMETHOD(BufferCB) (THIS_ double, BYTE *, long); | |
533 }; | |
534 | |
535 #undef INTERFACE | |
536 #define INTERFACE ISampleGrabber | |
537 DECLARE_INTERFACE(ISampleGrabber) | |
538 { | |
539 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
540 STDMETHOD_(long, AddRef) (THIS); | |
541 STDMETHOD_(long, Release) (THIS); | |
542 STDMETHOD(SetOneShot) (THIS_ BOOL); | |
543 STDMETHOD(SetMediaType) (THIS_ const AM_MEDIA_TYPE *); | |
544 STDMETHOD(GetConnectedMediaType) (THIS_ AM_MEDIA_TYPE *); | |
545 STDMETHOD(SetBufferSamples) (THIS_ BOOL); | |
546 STDMETHOD(GetCurrentBuffer) (THIS_ long *, long *); | |
547 STDMETHOD(GetCurrentSample) (THIS_ LPMEDIASAMPLE *); | |
548 STDMETHOD(SetCallback) (THIS_ ISampleGrabberCB *, long); | |
549 }; | |
550 | |
551 #undef INTERFACE | |
552 #define INTERFACE IFilterGraph | |
553 DECLARE_INTERFACE(IFilterGraph) | |
554 { | |
555 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
556 STDMETHOD_(long, AddRef) (THIS); | |
557 STDMETHOD_(long, Release) (THIS); | |
558 STDMETHOD(AddFilter) (THIS_ LPBASEFILTER, LPCWSTR); | |
559 STDMETHOD(RemoveFilter) (THIS_ LPBASEFILTER); | |
560 STDMETHOD(EnumFilters) (THIS_ LPENUMFILTERS *); | |
561 STDMETHOD(FindFilterByName) (THIS_ LPCWSTR, LPBASEFILTER *); | |
562 STDMETHOD(ConnectDirect) (THIS_ IPin *, IPin *, const AM_MEDIA_TYPE *); | |
563 STDMETHOD(Reconnect) (THIS_ LPPIN); | |
564 STDMETHOD(Disconnect) (THIS_ LPPIN); | |
565 STDMETHOD(SetDefaultSyncSource) (THIS); | |
566 }; | |
567 | |
568 #undef INTERFACE | |
569 #define INTERFACE IAMAudioInputMixer | |
570 DECLARE_INTERFACE(IAMAudioInputMixer) | |
571 { | |
572 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
573 STDMETHOD_(long, AddRef) (THIS); | |
574 STDMETHOD_(long, Release) (THIS); | |
575 STDMETHOD(put_Enable) (THIS_ BOOL); | |
576 STDMETHOD(get_Enable) (THIS_ BOOL *); | |
577 STDMETHOD(put_Mono) (THIS_ BOOL); | |
578 STDMETHOD(get_Mono) (THIS_ BOOL *); | |
579 STDMETHOD(put_MixLevel) (THIS_ double); | |
580 STDMETHOD(get_MixLevel) (THIS_ double *); | |
581 STDMETHOD(put_Pan) (THIS_ double); | |
582 STDMETHOD(get_Pan) (THIS_ double *); | |
583 STDMETHOD(put_Loudness) (THIS_ BOOL); | |
584 STDMETHOD(get_Loudness) (THIS_ BOOL *); | |
585 STDMETHOD(put_Treble) (THIS_ double); | |
586 STDMETHOD(get_Treble) (THIS_ double *); | |
587 STDMETHOD(get_TrebleRange) (THIS_ double *); | |
588 STDMETHOD(put_Bass) (THIS_ double); | |
589 STDMETHOD(get_Bass) (THIS_ double *); | |
590 STDMETHOD(get_BassRange) (THIS_ double *); | |
591 }; | |
592 | |
593 | |
594 #undef INTERFACE | |
595 #define INTERFACE IMediaSample | |
596 DECLARE_INTERFACE(IMediaSample) | |
597 { | |
598 STDMETHOD(QueryInterface) (THIS_ const GUID *, void **); | |
599 STDMETHOD_(long, AddRef) (THIS); | |
600 STDMETHOD_(long, Release) (THIS); | |
601 STDMETHOD(GetPointer )(THIS_ unsigned char** ); | |
602 STDMETHOD_(LONG,GetSize )(THIS); | |
603 STDMETHOD(GetTime )(THIS_ REFERENCE_TIME* ,REFERENCE_TIME* ); | |
604 STDMETHOD(SetTime )(THIS_ REFERENCE_TIME* ,REFERENCE_TIME* ); | |
605 STDMETHOD(IsSyncPoint )(THIS); | |
606 STDMETHOD(SetSyncPoint )(THIS_ long ); | |
607 STDMETHOD(IsPreroll )(THIS); | |
608 STDMETHOD(SetPreroll )(THIS_ long ); | |
609 STDMETHOD_(LONG,GetActualDataLength)(THIS); | |
610 STDMETHOD(SetActualDataLength )(THIS_ long ); | |
611 STDMETHOD(GetMediaType )(THIS_ AM_MEDIA_TYPE** ); | |
612 STDMETHOD(SetMediaType )(THIS_ AM_MEDIA_TYPE* ); | |
613 STDMETHOD(IsDiscontinuity )(THIS); | |
614 STDMETHOD(SetDiscontinuity )(THIS_ long ); | |
615 STDMETHOD(GetMediaTime )(THIS_ long long* ,long long* ); | |
616 STDMETHOD(SetMediaTime )(THIS_ long long* ,long long* ); | |
617 }; | |
618 | |
29263
0f1b5b68af32
whitespace cosmetics: Remove all trailing whitespace.
diego
parents:
27846
diff
changeset
|
619 |
24744 | 620 #undef INTERFACE |
621 #define INTERFACE IAMBufferNegotiation | |
622 DECLARE_INTERFACE(IAMBufferNegotiation) | |
623 { | |
624 STDMETHOD(QueryInterface )(THIS_ REFIID ,void **); | |
625 STDMETHOD_(ULONG,AddRef )(THIS); | |
626 STDMETHOD_(ULONG,Release )(THIS); | |
627 STDMETHOD(SuggestAllocatorProperties )(THIS_ const ALLOCATOR_PROPERTIES *); | |
628 STDMETHOD(GetAllocatorProperties )(THIS_ ALLOCATOR_PROPERTIES *); | |
629 }; | |
630 | |
631 | |
632 #undef INTERFACE | |
633 #define INTERFACE IVideoWindow | |
634 DECLARE_INTERFACE(IVideoWindow) | |
635 { | |
636 STDMETHOD(QueryInterface )(THIS_ REFIID ,void **); | |
637 STDMETHOD_(ULONG,AddRef )(THIS); | |
638 STDMETHOD_(ULONG,Release )(THIS); | |
639 STDMETHOD(GetTypeInfoCount) (THIS_ UINT * ); | |
640 STDMETHOD(GetTypeInfo) (THIS_ UINT ,LCID , ITypeInfo ** ); | |
641 STDMETHOD(GetIDsOfNames) (THIS_ REFIID ,LPOLESTR * , UINT ,LCID , DISPID * ); | |
642 STDMETHOD(Invoke) (THIS_ DISPID ,REFIID , LCID , WORD ,void *, VARIANT * ,EXCEPINFO * , UINT * ); | |
643 STDMETHOD(put_Caption) (THIS_ BSTR ); | |
644 STDMETHOD(get_Caption) (THIS_ BSTR * ); | |
645 STDMETHOD(put_WindowStyle) (THIS_ long ); | |
646 STDMETHOD(get_WindowStyle) (THIS_ long *); | |
647 STDMETHOD(put_WindowStyleEx) (THIS_ long ); | |
648 STDMETHOD(get_WindowStyleEx) (THIS_ long *); | |
649 STDMETHOD(put_AutoShow) (THIS_ long ); | |
650 STDMETHOD(get_AutoShow) (THIS_ long *); | |
651 STDMETHOD(put_WindowState) (THIS_ long ); | |
652 STDMETHOD(get_WindowState) (THIS_ long *); | |
653 STDMETHOD(put_BackgroundPalette) (THIS_ long ); | |
654 STDMETHOD(get_BackgroundPalette) (THIS_ long *); | |
655 STDMETHOD(put_Visible) (THIS_ long ); | |
656 STDMETHOD(get_Visible) (THIS_ long *); | |
657 STDMETHOD(put_Left) (THIS_ long ); | |
658 STDMETHOD(get_Left) (THIS_ long *); | |
659 STDMETHOD(put_Width) (THIS_ long ); | |
660 STDMETHOD(get_Width) (THIS_ long *); | |
661 STDMETHOD(put_Top) (THIS_ long ); | |
662 STDMETHOD(get_Top) (THIS_ long *); | |
663 STDMETHOD(put_Height) (THIS_ long ); | |
664 STDMETHOD(get_Height) (THIS_ long *); | |
665 STDMETHOD(put_Owner) (THIS_ OAHWND ); | |
666 STDMETHOD(get_Owner) (THIS_ OAHWND * ); | |
667 STDMETHOD(put_MessageDrain) (THIS_ OAHWND ); | |
668 STDMETHOD(get_MessageDrain) (THIS_ OAHWND * ); | |
669 STDMETHOD(get_BorderColor) (THIS_ long *); | |
670 STDMETHOD(put_BorderColor) (THIS_ long ); | |
671 STDMETHOD(get_FullScreenMode) (THIS_ long *); | |
672 STDMETHOD(put_FullScreenMode) (THIS_ long ); | |
673 STDMETHOD(SetWindowForeground) (THIS_ long ); | |
674 STDMETHOD(NotifyOwnerMessage) (THIS_ OAHWND ,long , LONG_PTR ,LONG_PTR ); | |
675 STDMETHOD(SetWindowPosition) (THIS_ long ,long , long ,long ); | |
676 STDMETHOD(GetWindowPosition) (THIS_ long *,long *, long *,long *); | |
677 STDMETHOD(GetMinIdealImageSize) (THIS_ long *, long *); | |
678 STDMETHOD(GetMaxIdealImageSize) (THIS_ long *, long *); | |
679 STDMETHOD(GetRestorePosition) (THIS_ long *,long *, long *,long *); | |
680 STDMETHOD(HideCursor) (THIS_ long ); | |
681 STDMETHOD(IsCursorHidden) (THIS_ long *); | |
682 }; | |
683 | |
30127
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
684 #ifndef DECLARE_ENUMERATOR_ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
685 #define DECLARE_ENUMERATOR_(I,T) \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
686 DECLARE_INTERFACE_(I,IUnknown) \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
687 { \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
688 STDMETHOD(QueryInterface)(I*, REFIID,PVOID*); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
689 STDMETHOD_(ULONG,AddRef)(I*); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
690 STDMETHOD_(ULONG,Release)(I*); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
691 STDMETHOD(Next)(I*, ULONG,T*,ULONG*); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
692 STDMETHOD(Skip)(I*, ULONG); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
693 STDMETHOD(Reset)(I*); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
694 STDMETHOD(Clone)(I*, I**); \ |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
695 } |
774aa6f7399e
Several hacks to fix compilation of tvi_dshow on MinGW64.
reimar
parents:
29263
diff
changeset
|
696 #endif |
24744 | 697 DECLARE_ENUMERATOR_(IEnumFilters, LPBASEFILTER); |
698 DECLARE_ENUMERATOR_(IEnumPins, LPPIN); | |
699 DECLARE_ENUMERATOR_(IEnumMediaTypes, AM_MEDIA_TYPE *); | |
700 | |
701 #define OLE_CALL(p,method) (p)->lpVtbl->method(p) | |
702 #ifdef __GNUC__ | |
703 #define OLE_CALL_ARGS(p, method, a1, args...) (p)->lpVtbl->method(p, a1, ##args) | |
704 #else | |
705 #define OLE_CALL_ARGS(p, method, ...) (p)->lpVtbl->method(p, __VA_ARGS__) | |
706 #endif | |
707 #define OLE_RELEASE_SAFE(p) if(p){ OLE_CALL((IUnknown*)p,Release); p=NULL;} | |
708 #define OLE_QUERYINTERFACE(p,iface,ptr) OLE_CALL_ARGS((IUnknown*)p,QueryInterface,&iface,(void*)&ptr) | |
709 | |
26029 | 710 #endif /* MPLAYER_TVI_DSHOW_H */ |