Go to the source code of this file.
|
| | WINE_DEFAULT_DEBUG_CHANNEL (quartz) |
| |
| static SourceSeeking * | impl_from_IMediaSeeking (IMediaSeeking *iface) |
| |
| HRESULT | strmbase_seeking_init (SourceSeeking *pSeeking, const IMediaSeekingVtbl *Vtbl, SourceSeeking_ChangeStop fnChangeStop, SourceSeeking_ChangeStart fnChangeStart, SourceSeeking_ChangeRate fnChangeRate) |
| |
| void | strmbase_seeking_cleanup (SourceSeeking *seeking) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetCapabilities (IMediaSeeking *iface, DWORD *pCapabilities) |
| |
| HRESULT WINAPI | SourceSeekingImpl_CheckCapabilities (IMediaSeeking *iface, DWORD *pCapabilities) |
| |
| HRESULT WINAPI | SourceSeekingImpl_IsFormatSupported (IMediaSeeking *iface, const GUID *pFormat) |
| |
| HRESULT WINAPI | SourceSeekingImpl_QueryPreferredFormat (IMediaSeeking *iface, GUID *pFormat) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetTimeFormat (IMediaSeeking *iface, GUID *pFormat) |
| |
| HRESULT WINAPI | SourceSeekingImpl_IsUsingTimeFormat (IMediaSeeking *iface, const GUID *pFormat) |
| |
| HRESULT WINAPI | SourceSeekingImpl_SetTimeFormat (IMediaSeeking *iface, const GUID *pFormat) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetDuration (IMediaSeeking *iface, LONGLONG *pDuration) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetStopPosition (IMediaSeeking *iface, LONGLONG *pStop) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetCurrentPosition (IMediaSeeking *iface, LONGLONG *pCurrent) |
| |
| HRESULT WINAPI | SourceSeekingImpl_ConvertTimeFormat (IMediaSeeking *iface, LONGLONG *pTarget, const GUID *pTargetFormat, LONGLONG Source, const GUID *pSourceFormat) |
| |
| static LONGLONG | Adjust (LONGLONG value, const LONGLONG *pModifier, DWORD dwFlags) |
| |
| HRESULT WINAPI | SourceSeekingImpl_SetPositions (IMediaSeeking *iface, LONGLONG *pCurrent, DWORD dwCurrentFlags, LONGLONG *pStop, DWORD dwStopFlags) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetPositions (IMediaSeeking *iface, LONGLONG *pCurrent, LONGLONG *pStop) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetAvailable (IMediaSeeking *iface, LONGLONG *pEarliest, LONGLONG *pLatest) |
| |
| HRESULT WINAPI | SourceSeekingImpl_SetRate (IMediaSeeking *iface, double dRate) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetRate (IMediaSeeking *iface, double *dRate) |
| |
| HRESULT WINAPI | SourceSeekingImpl_GetPreroll (IMediaSeeking *iface, LONGLONG *pPreroll) |
| |
◆ Adjust()
Definition at line 202 of file seeking.c.
203{
205 {
209 return *pModifier;
212 return value + *pModifier;
213 default:
215 return 0;
216 }
217}
@ AM_SEEKING_RelativePositioning
@ AM_SEEKING_IncrementalPositioning
@ AM_SEEKING_NoPositioning
@ AM_SEEKING_PositioningBitsMask
@ AM_SEEKING_AbsolutePositioning
_In_ LPWSTR _In_ DWORD _In_ DWORD _In_ DWORD dwFlags
Referenced by AdjustPacket(), ft_glyphslot_preset_bitmap(), and SourceSeekingImpl_SetPositions().
◆ impl_from_IMediaSeeking()
Definition at line 26 of file seeking.c.
27{
29}
#define CONTAINING_RECORD(address, type, field)
Referenced by SourceSeekingImpl_CheckCapabilities(), SourceSeekingImpl_ConvertTimeFormat(), SourceSeekingImpl_GetAvailable(), SourceSeekingImpl_GetCapabilities(), SourceSeekingImpl_GetCurrentPosition(), SourceSeekingImpl_GetDuration(), SourceSeekingImpl_GetPositions(), SourceSeekingImpl_GetRate(), SourceSeekingImpl_GetStopPosition(), SourceSeekingImpl_GetTimeFormat(), SourceSeekingImpl_IsUsingTimeFormat(), SourceSeekingImpl_SetPositions(), SourceSeekingImpl_SetRate(), and SourceSeekingImpl_SetTimeFormat().
◆ SourceSeekingImpl_CheckCapabilities()
Definition at line 75 of file seeking.c.
76{
80
81 TRACE(
"(%p)\n", pCapabilities);
82
83 if (!pCapabilities)
85
86 dwCommonCaps = *pCapabilities &
This->dwCapabilities;
87
88 if (!dwCommonCaps)
90 else
92 *pCapabilities = dwCommonCaps;
94}
static SourceSeeking * impl_from_IMediaSeeking(IMediaSeeking *iface)
◆ SourceSeekingImpl_ConvertTimeFormat()
Definition at line 186 of file seeking.c.
187{
189 if (!pTargetFormat)
190 pTargetFormat = &
This->timeformat;
191 if (!pSourceFormat)
192 pSourceFormat = &
This->timeformat;
193 if (
IsEqualIID(pTargetFormat, &TIME_FORMAT_MEDIA_TIME) &&
IsEqualIID(pSourceFormat, &TIME_FORMAT_MEDIA_TIME))
194 {
197 }
198
200}
_In_ UINT _In_ UINT _In_ PNDIS_PACKET Source
#define IsEqualIID(riid1, riid2)
◆ SourceSeekingImpl_GetAvailable()
Definition at line 272 of file seeking.c.
273{
275
276 TRACE(
"(%p, %p)\n", pEarliest, pLatest);
277
279 *pEarliest = 0;
280 *pLatest =
This->llDuration;
282
284}
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
◆ SourceSeekingImpl_GetCapabilities()
Definition at line 64 of file seeking.c.
65{
67
68 TRACE(
"(%p)\n", pCapabilities);
69
70 *pCapabilities =
This->dwCapabilities;
71
73}
◆ SourceSeekingImpl_GetCurrentPosition()
Definition at line 173 of file seeking.c.
174{
176
177 TRACE(
"(%p)\n", pCurrent);
178
180 *pCurrent =
This->llCurrent;
182
184}
◆ SourceSeekingImpl_GetDuration()
Definition at line 146 of file seeking.c.
147{
149
150 TRACE(
"(%p)\n", pDuration);
151
153 *pDuration =
This->llDuration;
155
157}
◆ SourceSeekingImpl_GetPositions()
Definition at line 258 of file seeking.c.
259{
261
262 TRACE(
"(%p, %p)\n", pCurrent, pStop);
263
265 IMediaSeeking_GetCurrentPosition(iface, pCurrent);
266 IMediaSeeking_GetStopPosition(iface, pStop);
268
270}
◆ SourceSeekingImpl_GetPreroll()
Definition at line 323 of file seeking.c.
324{
325 TRACE(
"(%p)\n", pPreroll);
326
327 *pPreroll = 0;
329}
◆ SourceSeekingImpl_GetRate()
Definition at line 309 of file seeking.c.
310{
312
313 TRACE(
"(%p)\n", dRate);
314
316
317 *dRate =
This->dRate;
319
321}
◆ SourceSeekingImpl_GetStopPosition()
Definition at line 159 of file seeking.c.
160{
162
163 TRACE(
"(%p)\n", pStop);
164
166 *pStop =
This->llStop;
168
170}
◆ SourceSeekingImpl_GetTimeFormat()
Definition at line 111 of file seeking.c.
112{
115
117 *pFormat =
This->timeformat;
119
121}
◆ SourceSeekingImpl_IsFormatSupported()
◆ SourceSeekingImpl_IsUsingTimeFormat()
◆ SourceSeekingImpl_QueryPreferredFormat()
Definition at line 103 of file seeking.c.
104{
106
107 *pFormat = TIME_FORMAT_MEDIA_TIME;
109}
◆ SourceSeekingImpl_SetPositions()
Definition at line 219 of file seeking.c.
220{
224
225 TRACE(
"iface %p, current %s, current_flags %#lx, stop %s, stop_flags %#lx.\n", iface,
226 pCurrent ?
debugstr_time(*pCurrent) :
"<null>", dwCurrentFlags,
228
230
231 llNewCurrent =
Adjust(
This->llCurrent, pCurrent, dwCurrentFlags);
232 llNewStop =
Adjust(
This->llStop, pStop, dwStopFlags);
233
234 if (pCurrent)
235 bChangeCurrent =
TRUE;
236 if (llNewStop !=
This->llStop)
238
240
241 This->llCurrent = llNewCurrent;
242 This->llStop = llNewStop;
243
245 *pCurrent = llNewCurrent;
247 *pStop = llNewStop;
249
250 if (bChangeCurrent)
251 This->fnChangeStart(iface);
252 if (bChangeStop)
253 This->fnChangeStop(iface);
254
256}
static LONGLONG Adjust(LONGLONG value, const LONGLONG *pModifier, DWORD dwFlags)
static const char * debugstr_time(REFERENCE_TIME time)
◆ SourceSeekingImpl_SetRate()
Definition at line 286 of file seeking.c.
287{
289 BOOL bChangeRate = (dRate !=
This->dRate);
291
292 TRACE(
"(%e)\n", dRate);
293
294 if (dRate > 100 || dRate < .001)
295 {
296 FIXME(
"Excessive rate %e, ignoring\n", dRate);
298 }
299
302 if (bChangeRate)
303 hr =
This->fnChangeRate(iface);
305
307}
#define VFW_E_UNSUPPORTED_AUDIO
◆ SourceSeekingImpl_SetTimeFormat()
◆ strmbase_seeking_cleanup()
Definition at line 58 of file seeking.c.
59{
62}
PRTL_CRITICAL_SECTION_DEBUG DebugInfo
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
◆ strmbase_seeking_init()
Definition at line 31 of file seeking.c.
34{
35 assert(fnChangeStop && fnChangeStart && fnChangeRate);
36
50 pSeeking->
dRate = 1.0;
56}
@ AM_SEEKING_CanGetDuration
@ AM_SEEKING_CanSeekBackwards
@ AM_SEEKING_CanSeekForwards
@ AM_SEEKING_CanSeekAbsolute
@ AM_SEEKING_CanGetStopPos
BOOL WINAPI InitializeCriticalSectionEx(OUT LPCRITICAL_SECTION lpCriticalSection, IN DWORD dwSpinCount, IN DWORD flags)
SourceSeeking_ChangeRate fnChangeRate
SourceSeeking_ChangeStart fnChangeStart
SourceSeeking_ChangeStop fnChangeStop
IMediaSeeking IMediaSeeking_iface
VOID WINAPI InitializeCriticalSection(OUT LPCRITICAL_SECTION lpCriticalSection)
#define RTL_CRITICAL_SECTION_FLAG_FORCE_DEBUG_INFO
◆ WINE_DEFAULT_DEBUG_CHANNEL()
| WINE_DEFAULT_DEBUG_CHANNEL |
( |
quartz |
| ) |
|