annotate loader/dshow/inputpin.c @ 3276:e279cc05f189

-ao NAS support by Tobias Diedrich <ranma@gmx.at>
author arpi
date Mon, 03 Dec 2001 01:13:48 +0000
parents 623cdb771e97
children e3bbf44dbab2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
1 #include "inputpin.h"
2069
ce45cce7f7a5 sync with avifile
arpi
parents: 1545
diff changeset
2 #include "wine/winerror.h"
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
3 #include <string.h>
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
4 #include <stdio.h>
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
5 #include <stdlib.h>
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
6
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
7 static int unimplemented(const char* s, void* p)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
8 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
9 Debug printf("%s(%p) called (UNIMPLEMENTED)", s, p);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
10 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
11 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
12
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
13 /***********
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
14 * EnumPins
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
15 ***********/
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
16
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
17 typedef struct
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
18 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
19 IEnumPins_vt* vt;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
20 IPin* pin1;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
21 IPin* pin2;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
22 int counter;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
23 GUID interfaces[2];
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
24 DECLARE_IUNKNOWN();
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
25 } CEnumPins;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
26
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
27 static long STDCALL CEnumPins_Next(IEnumPins* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
28 /* [in] */ unsigned long cMediaTypes,
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
29 /* [size_is][out] */ IPin** ppMediaTypes,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
30 /* [out] */ unsigned long* pcFetched)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
31 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
32 CEnumPins* pin = (CEnumPins*)This;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
33
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
34 Debug printf("CEnumPins_Next(%p) called\n", This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
35 if (!ppMediaTypes)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
36 return E_INVALIDARG;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
37 if (!pcFetched && (cMediaTypes!=1))
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
38 return E_INVALIDARG;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
39 if (cMediaTypes<=0)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
40 return 0;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
41
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
42 //lcounter = ((CEnumPins*)This)->counter;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
43 //lpin1 = ((CEnumPins*)This)->pin1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
44 //lpin2 = ((CEnumPins*)This)->pin2;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
45 if (((pin->counter == 2) && pin->pin2)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
46 || ((pin->counter == 1) && !pin->pin2))
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
47 {
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
48 if (pcFetched)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
49 *pcFetched=0;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
50 return 1;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
51 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
52
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
53 if (pcFetched)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
54 *pcFetched=1;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
55 if (pin->counter==0)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
56 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
57 *ppMediaTypes = pin->pin1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
58 pin->pin1->vt->AddRef((IUnknown*)pin->pin1);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
59 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
60 else
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
61 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
62 *ppMediaTypes = pin->pin2;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
63 pin->pin2->vt->AddRef((IUnknown*)pin->pin2);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
64 }
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
65 pin->counter++;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
66 if (cMediaTypes == 1)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
67 return 0;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
68 return 1;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
69 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
70
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
71 static long STDCALL CEnumPins_Skip(IEnumPins* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
72 /* [in] */ unsigned long cMediaTypes)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
73 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
74 Debug unimplemented("CEnumPins_Skip", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
75 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
76 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
77
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
78 static long STDCALL CEnumPins_Reset(IEnumPins* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
79 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
80 Debug printf("CEnumPins_Reset(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
81 ((CEnumPins*)This)->counter = 0;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
82 return 0;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
83 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
84
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
85 static long STDCALL CEnumPins_Clone(IEnumPins* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
86 /* [out] */ IEnumPins** ppEnum)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
87 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
88 Debug unimplemented("CEnumPins_Clone", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
89 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
90 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
91
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
92 static void CEnumPins_Destroy(CEnumPins* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
93 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
94 free(This->vt);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
95 free(This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
96 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
97
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
98 IMPLEMENT_IUNKNOWN(CEnumPins)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
99
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
100 static CEnumPins* CEnumPinsCreate(IPin* p, IPin* pp)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
101 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
102 CEnumPins* This = (CEnumPins*) malloc(sizeof(CEnumPins));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
103
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
104 This->pin1 = p;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
105 This->pin2 = pp;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
106 This->counter = 0;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
107 This->refcount = 1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
108
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
109 This->vt = (IEnumPins_vt*) malloc(sizeof(IEnumPins_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
110 This->vt->QueryInterface = CEnumPins_QueryInterface;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
111 This->vt->AddRef = CEnumPins_AddRef;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
112 This->vt->Release = CEnumPins_Release;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
113 This->vt->Next = CEnumPins_Next;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
114 This->vt->Skip = CEnumPins_Skip;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
115 This->vt->Reset = CEnumPins_Reset;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
116 This->vt->Clone = CEnumPins_Clone;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
117
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
118 This->interfaces[0] = IID_IUnknown;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
119 This->interfaces[1] = IID_IEnumPins;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
120
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
121 return This;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
122 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
123
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
124
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
125
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
126 /***********
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
127 * InputPin
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
128 ***********/
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
129
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
130 static long STDCALL CInputPin_Connect(IPin* This,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
131 /* [in] */ IPin* pReceivePin,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
132 /* [in] */ AM_MEDIA_TYPE* pmt)
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
133 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
134 Debug unimplemented("CInputPin_Connect", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
135 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
136 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
137
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
138 static long STDCALL CInputPin_ReceiveConnection(IPin* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
139 /* [in] */ IPin* pConnector,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
140 /* [in] */ const AM_MEDIA_TYPE *pmt)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
141 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
142 Debug unimplemented("CInputPin_ReceiveConnection", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
143 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
144 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
145
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
146 static long STDCALL CInputPin_Disconnect(IPin* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
147 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
148 Debug unimplemented("CInputPin_Disconnect", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
149 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
150 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
151
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
152 static long STDCALL CInputPin_ConnectedTo(IPin* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
153 /* [out] */ IPin** pPin)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
154 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
155 Debug unimplemented("CInputPin_ConnectedTo", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
156 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
157 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
158
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
159 static long STDCALL CInputPin_ConnectionMediaType(IPin* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
160 /* [out] */ AM_MEDIA_TYPE *pmt)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
161 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
162 Debug printf("CInputPin_ConnectionMediaType(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
163 if (!pmt)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
164 return E_INVALIDARG;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
165 *pmt=((CInputPin*)This)->type;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
166 if (pmt->cbFormat > 0)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
167 {
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
168 pmt->pbFormat=(char *)CoTaskMemAlloc(pmt->cbFormat);
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
169 memcpy(pmt->pbFormat, ((CInputPin*)This)->type.pbFormat, pmt->cbFormat);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
170 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
171 return 0;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
172 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
173
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
174 static long STDCALL CInputPin_QueryPinInfo(IPin* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
175 /* [out] */ PIN_INFO *pInfo)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
176 {
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
177 CBaseFilter* lparent=((CInputPin*)This)->parent;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
178 Debug printf("CInputPin_QueryPinInfo(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
179 pInfo->dir = PINDIR_OUTPUT;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
180 pInfo->pFilter = (IBaseFilter*) lparent;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
181 lparent->vt->AddRef((IUnknown*)lparent);
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
182 pInfo->achName[0] = 0;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
183 return 0;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
184 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
185
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
186 static long STDCALL CInputPin_QueryDirection(IPin* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
187 /* [out] */ PIN_DIRECTION *pPinDir)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
188 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
189 *pPinDir = PINDIR_OUTPUT;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
190 Debug printf("CInputPin_QueryDirection(%p) called\n", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
191 return 0;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
192 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
193
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
194 static long STDCALL CInputPin_QueryId(IPin* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
195 /* [out] */ unsigned short* *Id)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
196 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
197 Debug unimplemented("CInputPin_QueryId", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
198 return E_NOTIMPL;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
199 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
200
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
201 static long STDCALL CInputPin_QueryAccept(IPin* This,
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
202 /* [in] */ const AM_MEDIA_TYPE* pmt)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
203 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
204 Debug unimplemented("CInputPin_QueryAccept", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
205 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
206 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
207
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
208 static long STDCALL CInputPin_EnumMediaTypes(IPin* This,
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
209 /* [out] */ IEnumMediaTypes** ppEnum)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
210 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
211 Debug unimplemented("CInputPin_EnumMediaTypes", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
212 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
213 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
214
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
215 static long STDCALL CInputPin_QueryInternalConnections(IPin* This,
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
216 /* [out] */ IPin** apPin,
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
217 /* [out][in] */ unsigned long *nPin)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
218 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
219 Debug unimplemented("CInputPin_QueryInternalConnections", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
220 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
221 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
222
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
223 static long STDCALL CInputPin_EndOfStream(IPin * This)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
224 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
225 Debug unimplemented("CInputPin_EndOfStream", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
226 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
227 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
228
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
229
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
230 static long STDCALL CInputPin_BeginFlush(IPin * This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
231 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
232 Debug unimplemented("CInputPin_BeginFlush", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
233 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
234 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
235
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
236
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
237 static long STDCALL CInputPin_EndFlush(IPin* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
238 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
239 Debug unimplemented("CInputPin_EndFlush", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
240 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
241 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
242
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
243 static long STDCALL CInputPin_NewSegment(IPin* This,
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
244 /* [in] */ REFERENCE_TIME tStart,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
245 /* [in] */ REFERENCE_TIME tStop,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
246 /* [in] */ double dRate)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
247 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
248 Debug unimplemented("CInputPin_NewSegment", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
249 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
250 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
251
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
252 static void CInputPin_Destroy(CInputPin* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
253 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
254 free(This->vt);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
255 free(This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
256 }
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
257
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
258 IMPLEMENT_IUNKNOWN(CInputPin)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
259
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
260 CInputPin* CInputPinCreate(CBaseFilter* p, const AM_MEDIA_TYPE* amt)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
261 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
262 CInputPin* This = (CInputPin*) malloc(sizeof(CInputPin));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
263
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
264 This->parent = p;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
265 This->refcount = 1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
266 This->type = *amt;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
267
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
268 This->vt= (IPin_vt*) malloc(sizeof(IPin_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
269 This->vt->QueryInterface = CInputPin_QueryInterface;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
270 This->vt->AddRef = CInputPin_AddRef;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
271 This->vt->Release = CInputPin_Release;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
272 This->vt->Connect = CInputPin_Connect;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
273 This->vt->ReceiveConnection = CInputPin_ReceiveConnection;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
274 This->vt->Disconnect = CInputPin_Disconnect;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
275 This->vt->ConnectedTo = CInputPin_ConnectedTo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
276 This->vt->ConnectionMediaType = CInputPin_ConnectionMediaType;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
277 This->vt->QueryPinInfo = CInputPin_QueryPinInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
278 This->vt->QueryDirection = CInputPin_QueryDirection;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
279 This->vt->QueryId = CInputPin_QueryId;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
280 This->vt->QueryAccept = CInputPin_QueryAccept;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
281 This->vt->EnumMediaTypes = CInputPin_EnumMediaTypes;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
282 This->vt->QueryInternalConnections = CInputPin_QueryInternalConnections;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
283 This->vt->EndOfStream = CInputPin_EndOfStream;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
284 This->vt->BeginFlush = CInputPin_BeginFlush;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
285 This->vt->EndFlush = CInputPin_EndFlush;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
286 This->vt->NewSegment = CInputPin_NewSegment;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
287
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
288 This->interfaces[0]=IID_IUnknown;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
289
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
290 return This;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
291 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
292
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
293
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
294 /*************
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
295 * BaseFilter
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
296 *************/
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
297
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
298 static long STDCALL CBaseFilter_GetClassID(IBaseFilter * This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
299 /* [out] */ CLSID *pClassID)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
300 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
301 Debug unimplemented("CBaseFilter_GetClassID", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
302 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
303 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
304
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
305 static long STDCALL CBaseFilter_Stop(IBaseFilter* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
306 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
307 Debug unimplemented("CBaseFilter_Stop", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
308 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
309 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
310
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
311 static long STDCALL CBaseFilter_Pause(IBaseFilter* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
312 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
313 Debug unimplemented("CBaseFilter_Pause", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
314 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
315 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
316
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
317 static long STDCALL CBaseFilter_Run(IBaseFilter* This, REFERENCE_TIME tStart)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
318 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
319 Debug unimplemented("CBaseFilter_Run", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
320 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
321 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
322
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
323 static long STDCALL CBaseFilter_GetState(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
324 /* [in] */ unsigned long dwMilliSecsTimeout,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
325 // /* [out] */ FILTER_STATE *State)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
326 void* State)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
327 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
328 Debug unimplemented("CBaseFilter_GetState", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
329 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
330 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
331
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
332 static long STDCALL CBaseFilter_SetSyncSource(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
333 /* [in] */ IReferenceClock *pClock)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
334 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
335 Debug unimplemented("CBaseFilter_SetSyncSource", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
336 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
337 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
338
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
339 static long STDCALL CBaseFilter_GetSyncSource(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
340 /* [out] */ IReferenceClock **pClock)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
341 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
342 Debug unimplemented("CBaseFilter_GetSyncSource", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
343 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
344 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
345
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
346
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
347 static long STDCALL CBaseFilter_EnumPins(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
348 /* [out] */ IEnumPins **ppEnum)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
349 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
350 Debug printf("CBaseFilter_EnumPins(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
351 *ppEnum = (IEnumPins*) CEnumPinsCreate(((CBaseFilter*)This)->pin, ((CBaseFilter*)This)->unused_pin);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
352 return 0;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
353 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
354
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
355 static long STDCALL CBaseFilter_FindPin(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
356 /* [string][in] */ const unsigned short* Id,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
357 /* [out] */ IPin **ppPin)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
358 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
359 Debug unimplemented("CBaseFilter_FindPin\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
360 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
361 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
362
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
363 static long STDCALL CBaseFilter_QueryFilterInfo(IBaseFilter* This,
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
364 // /* [out] */ FILTER_INFO *pInfo)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
365 void* pInfo)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
366 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
367 Debug unimplemented("CBaseFilter_QueryFilterInfo", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
368 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
369 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
370
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
371 static long STDCALL CBaseFilter_JoinFilterGraph(IBaseFilter* This,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
372 /* [in] */ IFilterGraph* pGraph,
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
373 /* [string][in] */ const unsigned short* pName)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
374 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
375 Debug unimplemented("CBaseFilter_JoinFilterGraph", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
376 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
377 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
378
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
379 static long STDCALL CBaseFilter_QueryVendorInfo(IBaseFilter* This,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
380 /* [string][out] */ unsigned short** pVendorInfo)
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
381 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
382 Debug unimplemented("CBaseFilter_QueryVendorInfo", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
383 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
384 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
385
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
386 static IPin* CBaseFilter_GetPin(CBaseFilter* This)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
387 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
388 return This->pin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
389 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
390
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
391 static IPin* CBaseFilter_GetUnusedPin(CBaseFilter* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
392 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
393 return This->unused_pin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
394 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
395
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
396 static void CBaseFilter_Destroy(CBaseFilter* This)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
397 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
398 free(This->vt);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
399 This->pin->vt->Release((IUnknown*)This->pin);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
400 This->unused_pin->vt->Release((IUnknown*)This->unused_pin);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
401 free(This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
402 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
403
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
404 IMPLEMENT_IUNKNOWN(CBaseFilter)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
405
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
406 CBaseFilter* CBaseFilterCreate(const AM_MEDIA_TYPE* type, CBaseFilter2* parent)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
407 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
408 CBaseFilter* This = (CBaseFilter*) malloc(sizeof(CBaseFilter));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
409 This->refcount = 1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
410
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
411 This->pin = (IPin*) CInputPinCreate(This, type);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
412 This->unused_pin = (IPin*) CRemotePinCreate(This, parent->GetPin(parent));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
413
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
414 This->vt = (IBaseFilter_vt*) malloc(sizeof(IBaseFilter_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
415 This->vt->QueryInterface = CBaseFilter_QueryInterface;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
416 This->vt->AddRef = CBaseFilter_AddRef;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
417 This->vt->Release = CBaseFilter_Release;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
418 This->vt->GetClassID = CBaseFilter_GetClassID;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
419 This->vt->Stop = CBaseFilter_Stop;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
420 This->vt->Pause = CBaseFilter_Pause;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
421 This->vt->Run = CBaseFilter_Run;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
422 This->vt->GetState = CBaseFilter_GetState;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
423 This->vt->SetSyncSource = CBaseFilter_SetSyncSource;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
424 This->vt->GetSyncSource = CBaseFilter_GetSyncSource;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
425 This->vt->EnumPins = CBaseFilter_EnumPins;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
426 This->vt->FindPin = CBaseFilter_FindPin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
427 This->vt->QueryFilterInfo = CBaseFilter_QueryFilterInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
428 This->vt->JoinFilterGraph = CBaseFilter_JoinFilterGraph;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
429 This->vt->QueryVendorInfo = CBaseFilter_QueryVendorInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
430
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
431 This->interfaces[0] = IID_IUnknown;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
432 This->interfaces[1] = IID_IBaseFilter;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
433
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
434 This->GetPin = CBaseFilter_GetPin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
435 This->GetUnusedPin = CBaseFilter_GetUnusedPin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
436
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
437 return This;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
438 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
439
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
440
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
441 /**************
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
442 * BaseFilter2
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
443 **************/
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
444
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
445
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
446 static long STDCALL CBaseFilter2_GetClassID(IBaseFilter* This,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
447 /* [out] */ CLSID* pClassID)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
448 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
449 Debug unimplemented("CBaseFilter2_GetClassID", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
450 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
451 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
452
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
453 static long STDCALL CBaseFilter2_Stop(IBaseFilter* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
454 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
455 Debug unimplemented("CBaseFilter2_Stop", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
456 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
457 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
458
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
459 static long STDCALL CBaseFilter2_Pause(IBaseFilter* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
460 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
461 Debug unimplemented("CBaseFilter2_Pause", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
462 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
463 }
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
464
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
465 static long STDCALL CBaseFilter2_Run(IBaseFilter* This, REFERENCE_TIME tStart)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
466 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
467 Debug unimplemented("CBaseFilter2_Run", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
468 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
469 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
470
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
471
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
472 static long STDCALL CBaseFilter2_GetState(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
473 /* [in] */ unsigned long dwMilliSecsTimeout,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
474 // /* [out] */ FILTER_STATE *State)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
475 void* State)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
476 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
477 Debug unimplemented("CBaseFilter2_GetState", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
478 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
479 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
480
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
481 static long STDCALL CBaseFilter2_SetSyncSource(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
482 /* [in] */ IReferenceClock* pClock)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
483 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
484 Debug unimplemented("CBaseFilter2_SetSyncSource", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
485 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
486 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
487
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
488 static long STDCALL CBaseFilter2_GetSyncSource(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
489 /* [out] */ IReferenceClock** pClock)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
490 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
491 Debug unimplemented("CBaseFilter2_GetSyncSource", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
492 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
493 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
494
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
495 static long STDCALL CBaseFilter2_EnumPins(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
496 /* [out] */ IEnumPins** ppEnum)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
497 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
498 Debug printf("CBaseFilter2_EnumPins(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
499 *ppEnum = (IEnumPins*) CEnumPinsCreate(((CBaseFilter2*)This)->pin, 0);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
500 return 0;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
501 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
502
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
503 static long STDCALL CBaseFilter2_FindPin(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
504 /* [string][in] */ const unsigned short* Id,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
505 /* [out] */ IPin** ppPin)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
506 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
507 Debug unimplemented("CBaseFilter2_FindPin", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
508 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
509 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
510
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
511 static long STDCALL CBaseFilter2_QueryFilterInfo(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
512 // /* [out] */ FILTER_INFO *pInfo)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
513 void* pInfo)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
514 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
515 Debug unimplemented("CBaseFilter2_QueryFilterInfo", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
516 return E_NOTIMPL;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
517 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
518
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
519 static long STDCALL CBaseFilter2_JoinFilterGraph(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
520 /* [in] */ IFilterGraph* pGraph,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
521 /* [string][in] */
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
522 const unsigned short* pName)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
523 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
524 Debug unimplemented("CBaseFilter2_JoinFilterGraph", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
525 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
526 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
527
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
528 static long STDCALL CBaseFilter2_QueryVendorInfo(IBaseFilter* This,
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
529 /* [string][out] */
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
530 unsigned short** pVendorInfo)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
531 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
532 Debug unimplemented("CBaseFilter2_QueryVendorInfo", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
533 return E_NOTIMPL;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
534 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
535
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
536 static IPin* CBaseFilter2_GetPin(CBaseFilter2* This)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
537 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
538 return This->pin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
539 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
540
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
541 static void CBaseFilter2_Destroy(CBaseFilter2* This)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
542 {
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
543 Debug printf("CBaseFilter2_Destroy(%p) called\n", This);
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
544 This->pin->vt->Release((IUnknown*) This->pin);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
545 free(This->vt);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
546 free(This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
547 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
548
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
549 IMPLEMENT_IUNKNOWN(CBaseFilter2)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
550
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
551 static GUID CBaseFilter2_interf1 =
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
552 {0x76c61a30, 0xebe1, 0x11cf, {0x89, 0xf9, 0x00, 0xa0, 0xc9, 0x03, 0x49, 0xcb}};
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
553 static GUID CBaseFilter2_interf2 =
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
554 {0xaae7e4e2, 0x6388, 0x11d1, {0x8d, 0x93, 0x00, 0x60, 0x97, 0xc9, 0xa2, 0xb2}};
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
555 static GUID CBaseFilter2_interf3 =
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
556 {0x02ef04dd, 0x7580, 0x11d1, {0xbe, 0xce, 0x00, 0xc0, 0x4f, 0xb6, 0xe9, 0x37}};
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
557
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
558 CBaseFilter2* CBaseFilter2Create()
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
559 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
560 CBaseFilter2* This = (CBaseFilter2*) malloc(sizeof(CBaseFilter2));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
561
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
562 This->refcount = 1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
563 This->pin = (IPin*) CRemotePin2Create(This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
564
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
565 This->vt = (IBaseFilter_vt*) malloc(sizeof(IBaseFilter_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
566 memset(This->vt, 0, sizeof(IBaseFilter_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
567 This->vt->QueryInterface = CBaseFilter2_QueryInterface;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
568 This->vt->AddRef = CBaseFilter2_AddRef;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
569 This->vt->Release = CBaseFilter2_Release;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
570 This->vt->GetClassID = CBaseFilter2_GetClassID;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
571 This->vt->Stop = CBaseFilter2_Stop;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
572 This->vt->Pause = CBaseFilter2_Pause;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
573 This->vt->Run = CBaseFilter2_Run;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
574 This->vt->GetState = CBaseFilter2_GetState;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
575 This->vt->SetSyncSource = CBaseFilter2_SetSyncSource;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
576 This->vt->GetSyncSource = CBaseFilter2_GetSyncSource;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
577 This->vt->EnumPins = CBaseFilter2_EnumPins;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
578 This->vt->FindPin = CBaseFilter2_FindPin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
579 This->vt->QueryFilterInfo = CBaseFilter2_QueryFilterInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
580 This->vt->JoinFilterGraph = CBaseFilter2_JoinFilterGraph;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
581 This->vt->QueryVendorInfo = CBaseFilter2_QueryVendorInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
582
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
583 This->GetPin = CBaseFilter2_GetPin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
584
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
585 This->interfaces[0] = IID_IUnknown;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
586 This->interfaces[1] = IID_IBaseFilter;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
587 This->interfaces[2] = CBaseFilter2_interf1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
588 This->interfaces[3] = CBaseFilter2_interf2;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
589 This->interfaces[4] = CBaseFilter2_interf3;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
590
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
591 return This;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
592 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
593
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
594
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
595 /*************
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
596 * CRemotePin
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
597 *************/
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
598
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
599
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
600 static long STDCALL CRemotePin_ConnectedTo(IPin* This, /* [out] */ IPin** pPin)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
601 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
602 Debug printf("CRemotePin_ConnectedTo(%p) called\n", This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
603 if (!pPin)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
604 return E_INVALIDARG;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
605 *pPin = ((CRemotePin*)This)->remote_pin;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
606 (*pPin)->vt->AddRef((IUnknown*)(*pPin));
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
607 return 0;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
608 }
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
609
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
610 static long STDCALL CRemotePin_QueryDirection(IPin* This,
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
611 /* [out] */ PIN_DIRECTION* pPinDir)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
612 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
613 Debug printf("CRemotePin_QueryDirection(%p) called\n", This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
614 if (!pPinDir)
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
615 return E_INVALIDARG;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
616 *pPinDir=PINDIR_INPUT;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
617 return 0;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
618 }
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
619
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
620 static long STDCALL CRemotePin_ConnectionMediaType(IPin* This, /* [out] */ AM_MEDIA_TYPE* pmt)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
621 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
622 Debug unimplemented("CRemotePin_ConnectionMediaType", This);
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
623 return E_NOTIMPL;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
624 }
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
625
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
626 static long STDCALL CRemotePin_QueryPinInfo(IPin* This, /* [out] */ PIN_INFO* pInfo)
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
627 {
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
628 CBaseFilter* lparent = ((CRemotePin*)This)->parent;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
629 Debug printf("CRemotePin_QueryPinInfo(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
630 pInfo->dir= PINDIR_INPUT;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
631 pInfo->pFilter = (IBaseFilter*) lparent;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
632 lparent->vt->AddRef((IUnknown*)lparent);
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
633 pInfo->achName[0]=0;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
634 return 0;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
635 }
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
636
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
637 static void CRemotePin_Destroy(CRemotePin* This)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
638 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
639 Debug printf("CRemotePin_Destroy(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
640 free(This->vt);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
641 free(This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
642 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
643
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
644 IMPLEMENT_IUNKNOWN(CRemotePin)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
645
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
646 CRemotePin* CRemotePinCreate(CBaseFilter* pt, IPin* rpin)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
647 {
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
648 CRemotePin* This = (CRemotePin*) malloc(sizeof(CRemotePin));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
649 Debug printf("CRemotePinCreate() called -> %p\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
650
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
651 This->parent = pt;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
652 This->remote_pin = rpin;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
653 This->refcount = 1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
654
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
655 This->vt = (IPin_vt*) malloc(sizeof(IPin_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
656 memset(This->vt, 0, sizeof(IPin_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
657 This->vt->QueryInterface = CRemotePin_QueryInterface;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
658 This->vt->AddRef = CRemotePin_AddRef;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
659 This->vt->Release = CRemotePin_Release;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
660 This->vt->QueryDirection = CRemotePin_QueryDirection;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
661 This->vt->ConnectedTo = CRemotePin_ConnectedTo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
662 This->vt->ConnectionMediaType = CRemotePin_ConnectionMediaType;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
663 This->vt->QueryPinInfo = CRemotePin_QueryPinInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
664
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
665 This->interfaces[0] = IID_IUnknown;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
666
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
667 return This;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
668 }
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
669
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
670
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
671 /*************
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
672 * CRemotePin2
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
673 *************/
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
674
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
675
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
676 static long STDCALL CRemotePin2_QueryPinInfo(IPin* This,
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
677 /* [out] */ PIN_INFO* pInfo)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
678 {
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
679 CBaseFilter2* lparent=((CRemotePin2*)This)->parent;
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
680 Debug printf("CRemotePin2_QueryPinInfo(%p) called\n", This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
681 pInfo->pFilter=(IBaseFilter*)lparent;
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
682 lparent->vt->AddRef((IUnknown*)lparent);
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
683 pInfo->dir=PINDIR_OUTPUT;
168
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
684 pInfo->achName[0]=0;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
685 return 0;
bdc4a8fc04d8 Initial revision
arpi_esp
parents:
diff changeset
686 }
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
687
3130
623cdb771e97 avifile sync. seems to some bugs fixed...
arpi
parents: 3056
diff changeset
688 // FIXME - not being released!
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
689 static void CRemotePin2_Destroy(CRemotePin2* This)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
690 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
691 Debug printf("CRemotePin2_Destroy(%p) called\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
692 free(This->vt);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
693 free(This);
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
694 }
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
695
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
696 IMPLEMENT_IUNKNOWN(CRemotePin2)
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
697
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
698 CRemotePin2* CRemotePin2Create(CBaseFilter2* p)
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
699 {
3056
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
700 CRemotePin2* This = (CRemotePin2*) malloc(sizeof(CRemotePin2));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
701 Debug printf("CRemotePin2Create() called -> %p\n", This);
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
702
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
703 This->parent = p;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
704 This->refcount = 1;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
705
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
706 This->vt = (IPin_vt*) malloc(sizeof(IPin_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
707 memset(This->vt, 0, sizeof(IPin_vt));
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
708 This->vt->QueryInterface = CRemotePin2_QueryInterface;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
709 This->vt->AddRef = CRemotePin2_AddRef;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
710 This->vt->Release = CRemotePin2_Release;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
711 This->vt->QueryPinInfo = CRemotePin2_QueryPinInfo;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
712
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
713 This->interfaces[0] = IID_IUnknown;
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
714
213b35f84cf3 C++ -> C (import from avifile cvs)
arpi
parents: 2069
diff changeset
715 return This;
1545
da26060c81ef big avifile sync - from now we have common code
arpi
parents: 168
diff changeset
716 }