2 * Implementation of IMediaPosition for FilterGraph.
6 * hidenori@a2.ctktv.ne.jp
20 #include "debugtools.h"
21 DEFAULT_DEBUG_CHANNEL(quartz
);
23 #include "quartz_private.h"
28 IMediaPosition_fnQueryInterface(IMediaPosition
* iface
,REFIID riid
,void** ppobj
)
30 CFilterGraph_THIS(iface
,mediaposition
);
32 TRACE("(%p)->()\n",This
);
34 return IUnknown_QueryInterface(This
->unk
.punkControl
,riid
,ppobj
);
38 IMediaPosition_fnAddRef(IMediaPosition
* iface
)
40 CFilterGraph_THIS(iface
,mediaposition
);
42 TRACE("(%p)->()\n",This
);
44 return IUnknown_AddRef(This
->unk
.punkControl
);
48 IMediaPosition_fnRelease(IMediaPosition
* iface
)
50 CFilterGraph_THIS(iface
,mediaposition
);
52 TRACE("(%p)->()\n",This
);
54 return IUnknown_Release(This
->unk
.punkControl
);
58 IMediaPosition_fnGetTypeInfoCount(IMediaPosition
* iface
,UINT
* pcTypeInfo
)
60 CFilterGraph_THIS(iface
,mediaposition
);
62 TRACE("(%p)->()\n",This
);
64 return IDispatch_GetTypeInfoCount(
65 CFilterGraph_IDispatch(This
),pcTypeInfo
);
69 IMediaPosition_fnGetTypeInfo(IMediaPosition
* iface
,UINT iTypeInfo
, LCID lcid
, ITypeInfo
** ppobj
)
71 CFilterGraph_THIS(iface
,mediaposition
);
73 TRACE("(%p)->()\n",This
);
75 return IDispatch_GetTypeInfo(
76 CFilterGraph_IDispatch(This
),iTypeInfo
,lcid
,ppobj
);
80 IMediaPosition_fnGetIDsOfNames(IMediaPosition
* iface
,REFIID riid
, LPOLESTR
* ppwszName
, UINT cNames
, LCID lcid
, DISPID
* pDispId
)
82 CFilterGraph_THIS(iface
,mediaposition
);
84 TRACE("(%p)->()\n",This
);
86 return IDispatch_GetIDsOfNames(
87 CFilterGraph_IDispatch(This
),riid
,ppwszName
,cNames
,lcid
,pDispId
);
91 IMediaPosition_fnInvoke(IMediaPosition
* iface
,DISPID DispId
, REFIID riid
, LCID lcid
, WORD wFlags
, DISPPARAMS
* pDispParams
, VARIANT
* pVarRes
, EXCEPINFO
* pExcepInfo
, UINT
* puArgErr
)
93 CFilterGraph_THIS(iface
,mediaposition
);
95 TRACE("(%p)->()\n",This
);
97 return IDispatch_Invoke(
98 CFilterGraph_IDispatch(This
),
99 DispId
,riid
,lcid
,wFlags
,pDispParams
,pVarRes
,pExcepInfo
,puArgErr
);
103 static HRESULT WINAPI
104 IMediaPosition_fnget_Duration(IMediaPosition
* iface
,REFTIME
* prefTime
)
106 CFilterGraph_THIS(iface
,mediaposition
);
108 FIXME("(%p)->() stub!\n",This
);
113 static HRESULT WINAPI
114 IMediaPosition_fnput_CurrentPosition(IMediaPosition
* iface
,REFTIME refTime
)
116 CFilterGraph_THIS(iface
,mediaposition
);
118 FIXME("(%p)->() stub!\n",This
);
123 static HRESULT WINAPI
124 IMediaPosition_fnget_CurrentPosition(IMediaPosition
* iface
,REFTIME
* prefTime
)
126 CFilterGraph_THIS(iface
,mediaposition
);
128 FIXME("(%p)->() stub!\n",This
);
133 static HRESULT WINAPI
134 IMediaPosition_fnget_StopTime(IMediaPosition
* iface
,REFTIME
* prefTime
)
136 CFilterGraph_THIS(iface
,mediaposition
);
138 FIXME("(%p)->() stub!\n",This
);
143 static HRESULT WINAPI
144 IMediaPosition_fnput_StopTime(IMediaPosition
* iface
,REFTIME refTime
)
146 CFilterGraph_THIS(iface
,mediaposition
);
148 FIXME("(%p)->() stub!\n",This
);
153 static HRESULT WINAPI
154 IMediaPosition_fnget_PrerollTime(IMediaPosition
* iface
,REFTIME
* prefTime
)
156 CFilterGraph_THIS(iface
,mediaposition
);
158 FIXME("(%p)->() stub!\n",This
);
163 static HRESULT WINAPI
164 IMediaPosition_fnput_PrerollTime(IMediaPosition
* iface
,REFTIME refTime
)
166 CFilterGraph_THIS(iface
,mediaposition
);
168 FIXME("(%p)->() stub!\n",This
);
173 static HRESULT WINAPI
174 IMediaPosition_fnput_Rate(IMediaPosition
* iface
,double dblRate
)
176 CFilterGraph_THIS(iface
,mediaposition
);
178 FIXME("(%p)->() stub!\n",This
);
183 static HRESULT WINAPI
184 IMediaPosition_fnget_Rate(IMediaPosition
* iface
,double* pdblRate
)
186 CFilterGraph_THIS(iface
,mediaposition
);
188 FIXME("(%p)->() stub!\n",This
);
193 static HRESULT WINAPI
194 IMediaPosition_fnCanSeekForward(IMediaPosition
* iface
,LONG
* pCanSeek
)
196 CFilterGraph_THIS(iface
,mediaposition
);
198 FIXME("(%p)->() stub!\n",This
);
203 static HRESULT WINAPI
204 IMediaPosition_fnCanSeekBackward(IMediaPosition
* iface
,LONG
* pCanSeek
)
206 CFilterGraph_THIS(iface
,mediaposition
);
208 FIXME("(%p)->() stub!\n",This
);
214 static ICOM_VTABLE(IMediaPosition
) imediaposition
=
216 ICOM_MSVTABLE_COMPAT_DummyRTTIVALUE
217 /* IUnknown fields */
218 IMediaPosition_fnQueryInterface
,
219 IMediaPosition_fnAddRef
,
220 IMediaPosition_fnRelease
,
221 /* IDispatch fields */
222 IMediaPosition_fnGetTypeInfoCount
,
223 IMediaPosition_fnGetTypeInfo
,
224 IMediaPosition_fnGetIDsOfNames
,
225 IMediaPosition_fnInvoke
,
226 /* IMediaPosition fields */
227 IMediaPosition_fnget_Duration
,
228 IMediaPosition_fnput_CurrentPosition
,
229 IMediaPosition_fnget_CurrentPosition
,
230 IMediaPosition_fnget_StopTime
,
231 IMediaPosition_fnput_StopTime
,
232 IMediaPosition_fnget_PrerollTime
,
233 IMediaPosition_fnput_PrerollTime
,
234 IMediaPosition_fnput_Rate
,
235 IMediaPosition_fnget_Rate
,
236 IMediaPosition_fnCanSeekForward
,
237 IMediaPosition_fnCanSeekBackward
,
241 HRESULT
CFilterGraph_InitIMediaPosition( CFilterGraph
* pfg
)
244 ICOM_VTBL(&pfg
->mediaposition
) = &imediaposition
;
249 void CFilterGraph_UninitIMediaPosition( CFilterGraph
* pfg
)