1545
|
1 #ifndef DS_INTERFACES_H
|
|
2 #define DS_INTERFACES_H
|
|
3
|
168
|
4 /*
|
|
5
|
1545
|
6 Definition of important DirectShow interfaces.
|
|
7 Created using freely-available DirectX 8.0 SDK
|
|
8 ( http://msdn.microsoft.com )
|
168
|
9
|
|
10 */
|
|
11
|
2069
|
12 #include "com.h"
|
168
|
13 #include "guids.h"
|
1545
|
14
|
168
|
15 #ifndef STDCALL
|
1545
|
16 #define STDCALL __attribute__((__stdcall__))
|
168
|
17 #endif
|
|
18
|
|
19 typedef GUID& REFIID;
|
|
20 typedef GUID CLSID;
|
|
21 typedef GUID IID;
|
|
22
|
|
23 /* Sh*t. MSVC++ and g++ use different methods of storing vtables. */
|
|
24
|
|
25 struct IBaseFilter;
|
|
26 struct IReferenceClock;
|
|
27 struct IEnumPins;
|
|
28 struct IEnumMediaTypes;
|
|
29 struct IPin;
|
|
30 struct IFilterGraph;
|
|
31 struct IMemInputPin;
|
|
32 struct IMemAllocator;
|
|
33 struct IMediaSample;
|
1545
|
34 struct IHidden;
|
|
35 struct IHidden2;
|
168
|
36
|
|
37 enum PIN_DIRECTION;
|
|
38
|
|
39 class IClassFactory2
|
|
40 {
|
|
41 public:
|
|
42 virtual long STDCALL QueryInterface(GUID* iid, void** ppv) =0;
|
|
43 virtual long STDCALL AddRef() =0;
|
|
44 virtual long STDCALL Release() =0;
|
|
45 virtual long STDCALL CreateInstance(IUnknown* pUnkOuter, GUID* riid, void** ppvObject) =0;
|
|
46 };
|
|
47
|
|
48 struct IBaseFilter_vt: IUnknown_vt
|
|
49 {
|
1545
|
50 HRESULT STDCALL ( *GetClassID )(IBaseFilter * This,
|
|
51 /* [out] */ CLSID *pClassID);
|
|
52 HRESULT STDCALL ( *Stop )(IBaseFilter * This);
|
|
53 HRESULT STDCALL ( *Pause )(IBaseFilter * This);
|
|
54 HRESULT STDCALL ( *Run )(IBaseFilter * This,
|
|
55 REFERENCE_TIME tStart);
|
|
56 HRESULT STDCALL ( *GetState )(IBaseFilter * This,
|
|
57 /* [in] */ unsigned long dwMilliSecsTimeout,
|
|
58 ///* [out] */ FILTER_STATE *State);
|
|
59 void* State);
|
|
60 HRESULT STDCALL ( *SetSyncSource )(IBaseFilter * This,
|
|
61 /* [in] */ IReferenceClock *pClock);
|
|
62 HRESULT STDCALL ( *GetSyncSource )(IBaseFilter * This,
|
|
63 /* [out] */ IReferenceClock **pClock);
|
|
64 HRESULT STDCALL ( *EnumPins )(IBaseFilter * This,
|
|
65 /* [out] */ IEnumPins **ppEnum);
|
|
66 HRESULT STDCALL ( *FindPin )(IBaseFilter * This,
|
|
67 /* [string][in] */ const unsigned short* Id,
|
|
68 /* [out] */ IPin **ppPin);
|
|
69 HRESULT STDCALL ( *QueryFilterInfo )(IBaseFilter * This,
|
|
70 // /* [out] */ FILTER_INFO *pInfo);
|
|
71 void* pInfo);
|
|
72 HRESULT STDCALL ( *JoinFilterGraph )(IBaseFilter * This,
|
|
73 /* [in] */ IFilterGraph *pGraph,
|
|
74 /* [string][in] */ const unsigned short* pName);
|
|
75 HRESULT STDCALL ( *QueryVendorInfo )(IBaseFilter * This,
|
|
76 /* [string][out] */ unsigned short* *pVendorInfo);
|
168
|
77 };
|
|
78
|
|
79 struct IBaseFilter
|
|
80 {
|
|
81 struct IBaseFilter_vt *vt;
|
|
82 };
|
|
83
|
1545
|
84
|
168
|
85 struct IEnumPins_vt: IUnknown_vt
|
|
86 {
|
1545
|
87 HRESULT STDCALL ( *Next )(IEnumPins * This,
|
|
88 /* [in] */ unsigned long cPins,
|
|
89 /* [size_is][out] */ IPin **ppPins,
|
|
90 /* [out] */ unsigned long *pcFetched);
|
|
91 HRESULT STDCALL ( *Skip )(IEnumPins * This,
|
|
92 /* [in] */ unsigned long cPins);
|
|
93 HRESULT STDCALL ( *Reset )(IEnumPins * This);
|
|
94 HRESULT STDCALL ( *Clone )(IEnumPins * This,
|
|
95 /* [out] */ IEnumPins **ppEnum);
|
168
|
96 };
|
|
97
|
|
98 struct IEnumPins
|
|
99 {
|
1545
|
100 struct IEnumPins_vt *vt;
|
168
|
101 };
|
|
102
|
|
103
|
|
104 struct IPin_vt: IUnknown_vt
|
|
105 {
|
1545
|
106 HRESULT STDCALL ( *Connect )(IPin * This,
|
|
107 /* [in] */ IPin *pReceivePin,
|
|
108 /* [in] */ /*const*/ AM_MEDIA_TYPE *pmt);
|
|
109 HRESULT STDCALL ( *ReceiveConnection )(IPin * This,
|
|
110 /* [in] */ IPin *pConnector,
|
|
111 /* [in] */ const AM_MEDIA_TYPE *pmt);
|
|
112 HRESULT STDCALL ( *Disconnect )(IPin * This);
|
|
113 HRESULT STDCALL ( *ConnectedTo )(IPin * This, /* [out] */ IPin **pPin);
|
|
114 HRESULT STDCALL ( *ConnectionMediaType )(IPin * This,
|
|
115 /* [out] */ AM_MEDIA_TYPE *pmt);
|
|
116 HRESULT STDCALL ( *QueryPinInfo )(IPin * This, /* [out] */ PIN_INFO *pInfo);
|
|
117 HRESULT STDCALL ( *QueryDirection )(IPin * This,
|
|
118 /* [out] */ PIN_DIRECTION *pPinDir);
|
|
119 HRESULT STDCALL ( *QueryId )(IPin * This, /* [out] */ unsigned short* *Id);
|
|
120 HRESULT STDCALL ( *QueryAccept )(IPin * This,
|
|
121 /* [in] */ const AM_MEDIA_TYPE *pmt);
|
|
122 HRESULT STDCALL ( *EnumMediaTypes )(IPin * This,
|
|
123 /* [out] */ IEnumMediaTypes **ppEnum);
|
|
124 HRESULT STDCALL ( *QueryInternalConnections )(IPin * This,
|
|
125 /* [out] */ IPin **apPin,
|
|
126 /* [out][in] */ unsigned long *nPin);
|
|
127 HRESULT STDCALL ( *EndOfStream )(IPin * This);
|
|
128 HRESULT STDCALL ( *BeginFlush )(IPin * This);
|
|
129 HRESULT STDCALL ( *EndFlush )(IPin * This);
|
|
130 HRESULT STDCALL ( *NewSegment )(IPin * This,
|
|
131 /* [in] */ REFERENCE_TIME tStart,
|
|
132 /* [in] */ REFERENCE_TIME tStop,
|
|
133 /* [in] */ double dRate);
|
168
|
134 };
|
|
135
|
|
136 struct IPin
|
|
137 {
|
|
138 IPin_vt *vt;
|
|
139 };
|
|
140
|
1545
|
141
|
168
|
142 struct IEnumMediaTypes_vt: IUnknown_vt
|
|
143 {
|
1545
|
144 HRESULT STDCALL ( *Next )(IEnumMediaTypes * This,
|
|
145 /* [in] */ unsigned long cMediaTypes,
|
|
146 /* [size_is][out] */ AM_MEDIA_TYPE **ppMediaTypes,
|
|
147 /* [out] */ unsigned long *pcFetched);
|
|
148 HRESULT STDCALL ( *Skip )(IEnumMediaTypes * This,
|
|
149 /* [in] */ unsigned long cMediaTypes);
|
|
150 HRESULT STDCALL ( *Reset )(IEnumMediaTypes * This);
|
|
151 HRESULT STDCALL ( *Clone )(IEnumMediaTypes * This,
|
|
152 /* [out] */ IEnumMediaTypes **ppEnum);
|
168
|
153 };
|
|
154
|
|
155 struct IEnumMediaTypes
|
|
156 {
|
|
157 IEnumMediaTypes_vt *vt;
|
|
158 };
|
|
159
|
1545
|
160
|
168
|
161 struct IMemInputPin_vt: IUnknown_vt
|
|
162 {
|
1545
|
163 HRESULT STDCALL ( *GetAllocator )(IMemInputPin * This,
|
|
164 /* [out] */ IMemAllocator **ppAllocator);
|
|
165 HRESULT STDCALL ( *NotifyAllocator )(IMemInputPin * This,
|
|
166 /* [in] */ IMemAllocator *pAllocator,
|
|
167 /* [in] */ int bReadOnly);
|
|
168 HRESULT STDCALL ( *GetAllocatorRequirements )(IMemInputPin * This,
|
|
169 /* [out] */ ALLOCATOR_PROPERTIES *pProps);
|
|
170 HRESULT STDCALL ( *Receive )(IMemInputPin * This,
|
|
171 /* [in] */ IMediaSample *pSample);
|
|
172 HRESULT STDCALL ( *ReceiveMultiple )(IMemInputPin * This,
|
|
173 /* [size_is][in] */ IMediaSample **pSamples,
|
|
174 /* [in] */ long nSamples,
|
|
175 /* [out] */ long *nSamplesProcessed);
|
|
176 HRESULT STDCALL ( *ReceiveCanBlock )(IMemInputPin * This);
|
168
|
177 };
|
|
178
|
|
179 struct IMemInputPin
|
|
180 {
|
|
181 IMemInputPin_vt *vt;
|
|
182 };
|
|
183
|
|
184
|
|
185 struct IMemAllocator_vt: IUnknown_vt
|
|
186 {
|
1545
|
187 HRESULT STDCALL ( *SetProperties )(IMemAllocator * This,
|
|
188 /* [in] */ ALLOCATOR_PROPERTIES *pRequest,
|
|
189 /* [out] */ ALLOCATOR_PROPERTIES *pActual);
|
|
190 HRESULT STDCALL ( *GetProperties )(IMemAllocator * This,
|
|
191 /* [out] */ ALLOCATOR_PROPERTIES *pProps);
|
|
192 HRESULT STDCALL ( *Commit )(IMemAllocator * This);
|
|
193 HRESULT STDCALL ( *Decommit )(IMemAllocator * This);
|
|
194 HRESULT STDCALL ( *GetBuffer )(IMemAllocator * This,
|
|
195 /* [out] */ IMediaSample **ppBuffer,
|
|
196 /* [in] */ REFERENCE_TIME *pStartTime,
|
|
197 /* [in] */ REFERENCE_TIME *pEndTime,
|
|
198 /* [in] */ unsigned long dwFlags);
|
|
199 HRESULT STDCALL ( *ReleaseBuffer )(IMemAllocator * This,
|
|
200 /* [in] */ IMediaSample *pBuffer);
|
168
|
201 };
|
|
202
|
|
203 struct IMemAllocator
|
|
204 {
|
|
205 IMemAllocator_vt *vt;
|
|
206 };
|
|
207
|
1545
|
208
|
168
|
209 struct IMediaSample_vt: IUnknown_vt
|
|
210 {
|
1545
|
211 HRESULT STDCALL ( *GetPointer )(IMediaSample * This,
|
|
212 /* [out] */ unsigned char **ppBuffer);
|
|
213 long STDCALL ( *GetSize )(IMediaSample * This);
|
|
214 HRESULT STDCALL ( *GetTime )(IMediaSample * This,
|
|
215 /* [out] */ REFERENCE_TIME *pTimeStart,
|
|
216 /* [out] */ REFERENCE_TIME *pTimeEnd);
|
|
217 HRESULT STDCALL ( *SetTime )(IMediaSample * This,
|
|
218 /* [in] */ REFERENCE_TIME *pTimeStart,
|
|
219 /* [in] */ REFERENCE_TIME *pTimeEnd);
|
|
220 HRESULT STDCALL ( *IsSyncPoint )(IMediaSample * This);
|
|
221 HRESULT STDCALL ( *SetSyncPoint )(IMediaSample * This,
|
|
222 long bIsSyncPoint);
|
|
223 HRESULT STDCALL ( *IsPreroll )(IMediaSample * This);
|
|
224 HRESULT STDCALL ( *SetPreroll )(IMediaSample * This,
|
|
225 long bIsPreroll);
|
|
226 long STDCALL ( *GetActualDataLength )(IMediaSample * This);
|
|
227 HRESULT STDCALL ( *SetActualDataLength )(IMediaSample * This,
|
|
228 long __MIDL_0010);
|
|
229 HRESULT STDCALL ( *GetMediaType )(IMediaSample * This,
|
|
230 AM_MEDIA_TYPE **ppMediaType);
|
|
231 HRESULT STDCALL ( *SetMediaType )(IMediaSample * This,
|
|
232 AM_MEDIA_TYPE *pMediaType);
|
|
233 HRESULT STDCALL ( *IsDiscontinuity )(IMediaSample * This);
|
|
234 HRESULT STDCALL ( *SetDiscontinuity )(IMediaSample * This,
|
|
235 long bDiscontinuity);
|
|
236 HRESULT STDCALL ( *GetMediaTime )(IMediaSample * This,
|
|
237 /* [out] */ long long *pTimeStart,
|
|
238 /* [out] */ long long *pTimeEnd);
|
|
239 HRESULT STDCALL ( *SetMediaTime )(IMediaSample * This,
|
|
240 /* [in] */ long long *pTimeStart,
|
|
241 /* [in] */ long long *pTimeEnd);
|
168
|
242 };
|
|
243
|
|
244 struct IMediaSample
|
|
245 {
|
|
246 struct IMediaSample_vt *vt;
|
|
247 };
|
|
248
|
1545
|
249
|
168
|
250 struct IHidden_vt: IUnknown_vt
|
|
251 {
|
1545
|
252 HRESULT STDCALL ( *GetSmth )(IHidden * This, int* pv);
|
|
253 HRESULT STDCALL ( *SetSmth )(IHidden * This, int v1, int v2);
|
|
254 HRESULT STDCALL ( *GetSmth2 )(IHidden * This, int* pv);
|
|
255 HRESULT STDCALL ( *SetSmth2 )(IHidden * This, int v1, int v2);
|
|
256 HRESULT STDCALL ( *GetSmth3 )(IHidden * This, int* pv);
|
|
257 HRESULT STDCALL ( *SetSmth3 )(IHidden * This, int v1, int v2);
|
|
258 HRESULT STDCALL ( *GetSmth4 )(IHidden * This, int* pv);
|
|
259 HRESULT STDCALL ( *SetSmth4 )(IHidden * This, int v1, int v2);
|
|
260 HRESULT STDCALL ( *GetSmth5 )(IHidden * This, int* pv);
|
|
261 HRESULT STDCALL ( *SetSmth5 )(IHidden * This, int v1, int v2);
|
|
262 HRESULT STDCALL ( *GetSmth6 )(IHidden * This, int* pv);
|
168
|
263 };
|
1545
|
264
|
168
|
265 struct IHidden
|
|
266 {
|
|
267 struct IHidden_vt *vt;
|
|
268 };
|
|
269
|
|
270 struct IHidden2_vt: IUnknown_vt
|
|
271 {
|
|
272 HRESULT STDCALL (*unk1) ();
|
|
273 HRESULT STDCALL (*unk2) ();
|
|
274 HRESULT STDCALL (*unk3) ();
|
|
275 HRESULT STDCALL (*DecodeGet) (IHidden2* This, int* region);
|
|
276 HRESULT STDCALL (*unk5) ();
|
|
277 HRESULT STDCALL (*DecodeSet) (IHidden2* This, int* region);
|
|
278 HRESULT STDCALL (*unk7) ();
|
|
279 HRESULT STDCALL (*unk8) ();
|
|
280 };
|
1545
|
281
|
168
|
282 struct IHidden2
|
|
283 {
|
|
284 struct IHidden2_vt *vt;
|
|
285 };
|
1545
|
286
|
|
287 #endif /* DS_INTERFACES_H */
|