65#define MAX_ITF_CACHE_ENTRIES 3
181 IEnumFilters_AddRef(*
out = iface);
222 TRACE(
"enum_filters %p, count %lu, filters %p, fetched %p.\n",
311 IUnknown_AddRef(
graph->outer_unk);
332 if (
graph->media_event_window)
362 *ppvObj = &
This->IUnknown_inner;
363 TRACE(
" returning IUnknown interface (%p)\n", *ppvObj);
367 *ppvObj = &
This->IFilterGraph2_iface;
368 TRACE(
" returning IGraphBuilder interface (%p)\n", *ppvObj);
370 *ppvObj = &
This->IMediaControl_iface;
371 TRACE(
" returning IMediaControl interface (%p)\n", *ppvObj);
373 *ppvObj = &
This->IMediaSeeking_iface;
374 TRACE(
" returning IMediaSeeking interface (%p)\n", *ppvObj);
376 *ppvObj = &
This->IBasicAudio_iface;
377 TRACE(
" returning IBasicAudio interface (%p)\n", *ppvObj);
380 *ppvObj = &
This->IBasicVideo2_iface;
381 TRACE(
" returning IBasicVideo2 interface (%p)\n", *ppvObj);
383 *ppvObj = &
This->IVideoWindow_iface;
384 TRACE(
" returning IVideoWindow interface (%p)\n", *ppvObj);
387 *ppvObj = &
This->IMediaEventEx_iface;
388 TRACE(
" returning IMediaEvent(Ex) interface (%p)\n", *ppvObj);
391 *ppvObj = &
This->IMediaFilter_iface;
392 TRACE(
" returning IMediaFilter interface (%p)\n", *ppvObj);
394 *ppvObj = &
This->IMediaEventSink_iface;
395 TRACE(
" returning IMediaEventSink interface (%p)\n", *ppvObj);
397 *ppvObj = &
This->IGraphConfig_iface;
398 TRACE(
" returning IGraphConfig interface (%p)\n", *ppvObj);
400 *ppvObj = &
This->IMediaPosition_iface;
401 TRACE(
" returning IMediaPosition interface (%p)\n", *ppvObj);
403 *ppvObj = &
This->IObjectWithSite_iface;
404 TRACE(
" returning IObjectWithSite interface (%p)\n", *ppvObj);
406 TRACE(
" requesting IFilterMapper interface from aggregated filtermapper (%p)\n", *ppvObj);
407 return IUnknown_QueryInterface(
This->punkFilterMapper2,
riid, ppvObj);
409 TRACE(
" returning IFilterMapper2 interface from aggregated filtermapper (%p)\n", *ppvObj);
410 return IUnknown_QueryInterface(
This->punkFilterMapper2,
riid, ppvObj);
412 TRACE(
" returning IFilterMapper3 interface from aggregated filtermapper (%p)\n", *ppvObj);
413 return IUnknown_QueryInterface(
This->punkFilterMapper2,
riid, ppvObj);
415 *ppvObj = &
This->IGraphVersion_iface;
416 TRACE(
" returning IGraphVersion interface (%p)\n", *ppvObj);
418 *ppvObj = &
This->IVideoFrameStep_iface;
419 TRACE(
" returning IVideoFrameStep interface (%p)\n", *ppvObj);
426 IUnknown_AddRef((
IUnknown *)*ppvObj);
435 TRACE(
"%p increasing refcount to %lu.\n",
graph, refcount);
446 TRACE(
"%p decreasing refcount to %lu.\n",
This, refcount);
454 IMediaControl_Stop(&
This->IMediaControl_iface);
464 IReferenceClock_Release(
This->refClock);
466 for (
i = 0;
i <
This->nItfCacheEntries;
i++)
468 if (
This->ItfCacheEntries[
i].iface)
469 IUnknown_Release(
This->ItfCacheEntries[
i].iface);
472 IUnknown_Release(
This->punkFilterMapper2);
474 if (
This->pSite) IUnknown_Release(
This->pSite);
489 This->event_cs.DebugInfo->Spare[0] = 0;
491 This->cs.DebugInfo->Spare[0] = 0;
506 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
512 return IUnknown_AddRef(
graph->outer_unk);
518 return IUnknown_Release(
graph->outer_unk);
543 while (IEnumPins_Next(enumpins, 1, &pin,
NULL) ==
S_OK)
545 IPin_QueryDirection(pin, &
dir);
549 IEnumPins_Release(enumpins);
554 IEnumPins_Release(enumpins);
572 if (IMediaSeeking_IsFormatSupported(
seeking, &TIME_FORMAT_MEDIA_TIME) ==
S_OK)
575 IMediaSeeking_Release(
seeking);
582 IMediaPosition *media_position;
590 IAMFilterMiscFlags_Release(
flags);
592 else if (
SUCCEEDED(IBaseFilter_QueryInterface(
filter->
filter, &IID_IMediaPosition, (
void **)&media_position)))
596 IMediaPosition_Release(media_position);
632 duplicate_name =
TRUE;
634 if (!
name || duplicate_name)
636 for (
i = 0;
i < 10000 ; ++
i)
643 graph->name_index = (
graph->name_index + 1) % 10000;
667 IBaseFilter_SetSyncSource(
filter,
graph->refClock);
686 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pFilter);
690 if (
entry->filter == pFilter)
694 if (
This->defaultclock &&
This->refClockProvider == pFilter)
696 IMediaFilter_SetSyncSource(&
This->IMediaFilter_iface,
NULL);
702 hr = IBaseFilter_EnumPins(pFilter, &penumpins);
705 while(IEnumPins_Next(penumpins, 1, &ppin,
NULL) ==
S_OK)
710 IPin_ConnectedTo(ppin, &peer);
713 if (
FAILED(
hr = IPin_Disconnect(peer)))
715 WARN(
"Failed to disconnect peer %p, hr %#lx.\n", peer,
hr);
718 IEnumPins_Release(penumpins);
723 if (
FAILED(
hr = IPin_Disconnect(ppin)))
725 WARN(
"Failed to disconnect pin %p, hr %#lx.\n", ppin,
hr);
727 IEnumPins_Release(penumpins);
733 IEnumPins_Release(penumpins);
736 hr = IBaseFilter_JoinFilterGraph(pFilter,
NULL,
NULL);
739 IBaseFilter_SetSyncSource(pFilter,
NULL);
740 IBaseFilter_Release(pFilter);
742 IMediaSeeking_Release(
entry->seeking);
748 for (
i = 0;
i <
This->nItfCacheEntries;
i++)
749 if (pFilter ==
This->ItfCacheEntries[
i].filter)
751 IUnknown_Release(
This->ItfCacheEntries[
i].iface);
785 IBaseFilter_AddRef(*
filter);
794 IPin *upstream_source, *upstream_sink;
799 hr = IPin_QueryPinInfo(
sink, &sink_info);
802 ERR(
"Failed to query pin, hr %#lx.\n",
hr);
805 IBaseFilter_Release(sink_info.pFilter);
807 hr = IPin_QueryPinInfo(
source, &source_info);
810 ERR(
"Failed to query pin, hr %#lx.\n",
hr);
814 if (sink_info.pFilter == source_info.pFilter)
816 WARN(
"Cyclic connection detected; returning VFW_E_CIRCULAR_GRAPH.\n");
817 IBaseFilter_Release(source_info.pFilter);
821 hr = IBaseFilter_EnumPins(source_info.pFilter, &enumpins);
824 ERR(
"Failed to enumerate pins, hr %#lx.\n",
hr);
825 IBaseFilter_Release(source_info.pFilter);
829 while ((
hr = IEnumPins_Next(enumpins, 1, &upstream_sink,
NULL)) ==
S_OK)
833 IPin_QueryDirection(upstream_sink, &
dir);
837 IPin_Release(upstream_source);
840 IPin_Release(upstream_sink);
841 IEnumPins_Release(enumpins);
842 IBaseFilter_Release(source_info.pFilter);
846 IPin_Release(upstream_sink);
848 IEnumPins_Release(enumpins);
850 IBaseFilter_Release(source_info.pFilter);
869 struct filter *peer_filter;
883 while (IEnumPins_Next(enumpins, 1, &pin,
NULL) ==
S_OK)
885 IPin_QueryDirection(pin, &
dir);
889 IPin_QueryPinInfo(peer, &
info);
893 IBaseFilter_Release(
info.pFilter);
898 IEnumPins_Release(enumpins);
928 TRACE(
"(%p/%p)->(%p, %p, %p)\n",
This, iface, ppinIn, ppinOut, pmt);
937 hr = IPin_QueryPinInfo(ppinIn, &PinInfo);
941 TRACE(
"Filter owning ppinIn(%p) => %p\n", ppinIn, PinInfo.pFilter);
942 IBaseFilter_Release(PinInfo.pFilter);
944 hr = IPin_QueryPinInfo(ppinOut, &PinInfo);
948 TRACE(
"Filter owning ppinOut(%p) => %p\n", ppinOut, PinInfo.pFilter);
949 IBaseFilter_Release(PinInfo.pFilter);
952 hr = IPin_QueryDirection(ppinIn, &
dir);
959 hr = IPin_Connect(ppinOut, ppinIn, pmt);
965 hr = IPin_Connect(ppinIn, ppinOut, pmt);
978 return IFilterGraph2_ReconnectEx(iface, pin,
NULL);
985 TRACE(
"(%p/%p)->(%p)\n",
This, iface, ppin);
990 return IPin_Disconnect(ppin);
1000 TRACE(
"(%p/%p)->() live sources not handled properly!\n",
This, iface);
1006 if (IBaseFilter_QueryInterface(
filter->
filter, &IID_IReferenceClock, (
void **)&pClock) ==
S_OK)
1023 hr = IMediaFilter_SetSyncSource(&
This->IMediaFilter_iface, pClock);
1025 IReferenceClock_Release(pClock);
1073 if (
graph->threaded)
1092 BOOL render_to_existing,
unsigned int recursion_depth);
1096 BOOL render_to_existing,
unsigned int recursion_depth)
1099 IPin *middle_source, *peer;
1105 TRACE(
"Trying to autoplug %p to %p through %p.\n",
source,
sink, middle_sink);
1107 IPin_QueryDirection(middle_sink, &
dir);
1111 if (IPin_ConnectedTo(middle_sink, &peer) ==
S_OK)
1123 while (IEnumPins_Next(source_enum, 1, &middle_source,
NULL) ==
S_OK)
1125 IPin_QueryPinInfo(middle_source, &
info);
1126 IBaseFilter_Release(
info.pFilter);
1129 IPin_Release(middle_source);
1132 if (
info.achName[0] ==
'~')
1135 IPin_Release(middle_source);
1138 if (IPin_ConnectedTo(middle_source, &peer) ==
S_OK)
1141 IPin_Release(middle_source);
1146 IPin_Release(middle_source);
1149 IEnumPins_Release(source_enum);
1157 IEnumPins_Release(source_enum);
1175 unsigned int recursion_depth)
1186 while (IEnumPins_Next(sink_enum, 1, &filter_sink,
NULL) ==
S_OK)
1189 render_to_existing, recursion_depth);
1190 IPin_Release(filter_sink);
1193 IEnumPins_Release(sink_enum);
1197 IEnumPins_Release(sink_enum);
1203 unsigned int i, mt_count = 0, mt_capacity = 16;
1211 ERR(
"Failed to enumerate media types, hr %#lx.\n",
hr);
1219 if (!(mts =
realloc(mts, mt_capacity *
sizeof(*mts))))
1225 if (
FAILED(
hr = IEnumMediaTypes_Next(enummt, mt_capacity - mt_count, mts + mt_count, &
count)))
1227 ERR(
"Failed to get media types, hr %#lx.\n",
hr);
1244 for (
i = 0;
i < mt_count; ++
i)
1246 types[
i * 2] = mts[
i]->majortype;
1247 types[
i * 2 + 1] = mts[
i]->subtype;
1251 *ret_count = mt_count;
1257 IEnumMediaTypes_Release(enummt);
1264 BOOL render_to_existing,
unsigned int recursion_depth)
1267 struct filter *graph_filter;
1269 unsigned int type_count;
1276 TRACE(
"Trying to autoplug %p to %p, recursion depth %u.\n",
source,
sink, recursion_depth);
1278 if (recursion_depth >= 5)
1280 WARN(
"Recursion depth has reached 5; aborting.\n");
1300 sink, render_to_existing, recursion_depth)))
1304 IUnknown_QueryInterface(
graph->punkFilterMapper2, &IID_IFilterMapper2, (
void **)&mapper);
1308 IFilterMapper2_Release(mapper);
1313 IUnknown_QueryInterface(
graph->pSite, &IID_IAMGraphBuilderCallback, (
void **)&
callback);
1315 if (
FAILED(
hr = IFilterMapper2_EnumMatchingFilters(mapper, &enummoniker,
1327 hr = IPropertyBag_Read(bag,
L"FriendlyName", &
var,
NULL);
1328 IPropertyBag_Release(bag);
1337 TRACE(
"Filter rejected by IAMGraphBuilderCallback::SelectedFilter(), hr %#lx.\n",
hr);
1353 TRACE(
"Filter rejected by IAMGraphBuilderCallback::CreatedFilter(), hr %#lx.\n",
hr);
1354 IBaseFilter_Release(
filter);
1362 ERR(
"Failed to add filter, hr %#lx.\n",
hr);
1363 IBaseFilter_Release(
filter);
1370 IBaseFilter_Release(
filter);
1375 IBaseFilter_Release(
filter);
1377 IEnumMoniker_Release(enummoniker);
1384 IFilterMapper2_Release(mapper);
1406 TRACE(
"Directions seem backwards, swapping pins\n");
1419 TRACE(
"Returning %#lx.\n",
hr);
1436 TRACE(
"Returning %#lx.\n",
hr);
1454 if (lpcwstrPlayList !=
NULL)
1457 hr = IFilterGraph2_AddSourceFilter(iface, lpcwstrFile,
L"Reader", &preader);
1461 hr = IBaseFilter_EnumPins(preader, &penumpins);
1464 while (IEnumPins_Next(penumpins, 1, &ppinreader,
NULL) ==
S_OK)
1468 IPin_QueryDirection(ppinreader, &
dir);
1471 hr = IFilterGraph2_Render(iface, ppinreader);
1473 TRACE(
"Filters in chain:\n");
1482 IPin_Release(ppinreader);
1484 IEnumPins_Release(penumpins);
1488 if (
FAILED(
hr = IFilterGraph2_RemoveFilter(iface, preader)))
1489 ERR(
"Failed to remove source filter, hr %#lx.\n",
hr);
1501 IBaseFilter_Release(preader);
1503 TRACE(
"Returning %#lx.\n",
hr);
1516 TRACE(
"graph %p, filename %s, filter_name %s, ret_filter %p.\n",
1523 clsid = CLSID_AsyncReader;
1529 WARN(
"Failed to create filter, hr %#lx.\n",
hr);
1533 if (
FAILED(
hr = IBaseFilter_QueryInterface(
filter, &IID_IFileSourceFilter, (
void **)&filesource)))
1535 WARN(
"Failed to get IFileSourceFilter, hr %#lx.\n",
hr);
1536 IBaseFilter_Release(
filter);
1541 IFileSourceFilter_Release(filesource);
1544 WARN(
"Failed to load file, hr %#lx.\n",
hr);
1545 IBaseFilter_Release(
filter);
1549 if (
FAILED(
hr = IFilterGraph2_AddFilter(iface,
filter, filter_name)))
1551 IBaseFilter_Release(
filter);
1573 TRACE(
"(%p/%p)->(): stub !!!\n",
This, iface);
1582 TRACE(
"(%p/%p)->(): stub !!!\n",
This, iface);
1595 TRACE(
"(%p/%p)->(%p %p %s %p)\n",
This, iface, pMoniker, pCtx,
debugstr_w(lpcwstrFilterName), ppFilter);
1599 WARN(
"Failed to bind moniker, hr %#lx.\n",
hr);
1603 hr = IFilterGraph2_AddFilter(iface, pfilter, lpcwstrFilterName);
1605 WARN(
"Failed to add filter, hr %#lx.\n",
hr);
1606 IBaseFilter_Release(pfilter);
1611 *ppFilter = pfilter;
1612 else IBaseFilter_Release(pfilter);
1624 TRACE(
"graph %p, pin %p, mt %p.\n",
graph, pin, mt);
1626 if (
FAILED(
hr = IPin_ConnectedTo(pin, &peer)))
1629 IPin_QueryDirection(pin, &
dir);
1630 IFilterGraph2_Disconnect(iface, peer);
1631 IFilterGraph2_Disconnect(iface, pin);
1634 hr = IFilterGraph2_ConnectDirect(iface, peer, pin, mt);
1636 hr = IFilterGraph2_ConnectDirect(iface, pin, peer, mt);
1658 TRACE(
"Returning %#lx.\n",
hr);
1696 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
1702 return IUnknown_AddRef(
graph->outer_unk);
1708 return IUnknown_Release(
graph->outer_unk);
1714 TRACE(
"iface %p, count %p.\n", iface,
count);
1732 TRACE(
"iface %p, iid %s, names %p, count %u, lcid %#lx, ids %p.\n",
1749 TRACE(
"iface %p, id %ld, iid %s, lcid %#lx, flags %#x, params %p, result %p, excepinfo %p, error_arg %p.\n",
1765 graph->nRenderers = 0;
1769 ++
graph->nRenderers;
1782 graph->EcCompleteCount = 0;
1800 if (!stream_start &&
graph->refClock)
1802 IReferenceClock_GetTime(
graph->refClock, &
graph->stream_start);
1803 stream_start =
graph->stream_start -
graph->stream_elapsed;
1806 stream_start += 200 * 10000;
1809 if (
SUCCEEDED(IMediaSeeking_GetStopPosition(&
graph->IMediaSeeking_iface, &stream_stop)))
1810 graph->stream_stop = stream_stop;
1821 WARN(
"Failed to start stream, hr %#lx.\n",
hr);
1833 TRACE(
"Performing asynchronous state change.\n");
1847 if (!
graph->needs_async_run)
1869 IBaseFilter_GetState(async_filter, 10, &
state);
1876 graph->needs_async_run = 0;
1894 if (
graph->state == State_Running)
1906 if (
graph->state == State_Stopped)
1922 need_async_run =
FALSE;
1928 WARN(
"Failed to pause, hr %#lx.\n",
hr);
1933 graph->state = State_Running;
1937 if (
hr !=
S_OK && need_async_run)
1939 if (!
graph->async_run_work)
1941 graph->needs_async_run = 1;
1960 return IMediaFilter_Pause(&
graph->IMediaFilter_iface);
1969 return IMediaFilter_Stop(&
graph->IMediaFilter_iface);
1980 return IMediaFilter_GetState(&
graph->IMediaFilter_iface,
timeout, (FILTER_STATE *)
state);
1989 return IFilterGraph2_RenderFile(&
This->IFilterGraph2_iface, strFilename,
NULL);
1997 FIXME(
"(%p/%p)->(%s (%p), %p): stub !!!\n",
This, iface,
debugstr_w(strFilename), strFilename, ppUnk);
2006 FIXME(
"(%p/%p)->(%p): stub !!!\n",
This, iface, ppUnk);
2015 FIXME(
"(%p/%p)->(%p): stub !!!\n",
This, iface, ppUnk);
2023 OAFilterState
state;
2027 ERR(
"Failed to get paused state, hr %#lx.\n",
hr);
2030 ERR(
"Failed to stop, hr %#lx.\n",
hr);
2033 ERR(
"Failed to get paused state, hr %#lx.\n",
hr);
2035 IMediaControl_Release(
control);
2041 OAFilterState
state;
2045 ERR(
"Failed to get state, hr %#lx.\n",
hr);
2047 IMediaControl_Release(
control);
2058 hr = IMediaControl_Pause(iface);
2063 IMediaControl_AddRef(iface);
2068 hr = IMediaControl_Stop(iface);
2073 IMediaControl_AddRef(iface);
2110 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
2116 return IUnknown_AddRef(
graph->outer_unk);
2122 return IUnknown_Release(
graph->outer_unk);
2154 hr = IMediaSeeking_GetCapabilities(
seek, &caps);
2159 *(
DWORD*)pcaps &= caps;
2170 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pCapabilities);
2176 *pCapabilities = 0xffffffff;
2190 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pCapabilities);
2196 originalcaps = *pCapabilities;
2203 if (!*pCapabilities)
2205 if (*pCapabilities != originalcaps)
2219 if (!
IsEqualGUID(&TIME_FORMAT_MEDIA_TIME, pFormat))
2235 FIXME(
"(%p/%p)->(%p): semi-stub !!!\n",
This, iface, pFormat);
2236 memcpy(pFormat, &TIME_FORMAT_MEDIA_TIME,
sizeof(
GUID));
2248 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pFormat);
2258 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pFormat);
2277 if (!
IsEqualGUID(&TIME_FORMAT_MEDIA_TIME, pFormat))
2293 TRACE(
"graph %p, duration %p.\n",
graph, duration);
2308 filter_hr = IMediaSeeking_GetDuration(
filter->
seeking, &filter_duration);
2312 *duration =
max(*duration, filter_duration);
2323 TRACE(
"Returning hr %#lx, duration %s (%s seconds).\n",
hr,
2350 filter_hr = IMediaSeeking_GetStopPosition(
filter->
seeking, &filter_stop);
2354 *stop =
max(*stop, filter_stop);
2381 if (
graph->got_ec_complete)
2385 else if (
graph->state == State_Running && !
graph->needs_async_run &&
graph->refClock)
2388 IReferenceClock_GetTime(
graph->refClock, &
time);
2410 pSourceFormat = &
This->timeformatseek;
2413 pTargetFormat = &
This->timeformatseek;
2431 TRACE(
"graph %p, current %s, current_flags %#lx, stop %s, stop_flags %#lx.\n",
graph,
2435 TRACE(
"Setting current position to %s (%s seconds).\n",
2438 TRACE(
"Setting stop position to %s (%s seconds).\n",
2443 FIXME(
"Unhandled current_flags %#lx.\n", current_flags & 0x7);
2447 FIXME(
"Unhandled stop_flags %#lx.\n", stop_flags & 0x7);
2452 if (
state == State_Running && !
graph->needs_async_run)
2453 IMediaControl_Pause(&
graph->IMediaControl_iface);
2457 LONGLONG current = current_ptr ? *current_ptr : 0, stop = stop_ptr ? *stop_ptr : 0;
2484 IReferenceClock_GetTime(
graph->refClock, &
graph->stream_start);
2485 graph->stream_elapsed = 0;
2488 if (
state == State_Running && !
graph->needs_async_run)
2489 IMediaControl_Run(&
graph->IMediaControl_iface);
2504 hr = IMediaSeeking_GetCurrentPosition(iface,
current);
2506 hr = IMediaSeeking_GetStopPosition(iface, stop);
2516 FIXME(
"(%p/%p)->(%p, %p): stub !!!\n",
This, iface, pEarliest, pLatest);
2525 FIXME(
"(%p/%p)->(%f): stub !!!\n",
This, iface, dRate);
2534 FIXME(
"(%p/%p)->(%p): stub !!!\n",
This, iface, pdRate);
2548 FIXME(
"(%p/%p)->(%p): stub !!!\n",
This, iface, pllPreroll);
2587 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
2593 return IUnknown_AddRef(
graph->outer_unk);
2599 return IUnknown_Release(
graph->outer_unk);
2604 TRACE(
"iface %p, count %p.\n", iface,
count);
2622 TRACE(
"iface %p, iid %s, names %p, count %u, lcid %#lx, ids %p.\n",
2639 TRACE(
"iface %p, id %ld, iid %s, lcid %#lx, flags %#x, params %p, result %p, excepinfo %p, error_arg %p.\n",
2658 if (!
IsEqualGUID(&TIME_FORMAT_MEDIA_TIME, &time_format))
2660 FIXME(
"Unsupported time format.\n");
2664 *time_out = (
LONGLONG) (time_in * 10000000);
2676 if (!
IsEqualGUID(&TIME_FORMAT_MEDIA_TIME, &time_format))
2678 FIXME(
"Unsupported time format.\n");
2682 *time_out = (
REFTIME)time_in / 10000000;
2691 HRESULT hr = IMediaSeeking_GetDuration(&
This->IMediaSeeking_iface, &duration);
2706 return IMediaSeeking_SetPositions(&
This->IMediaSeeking_iface, &reftime,
2716 hr = IMediaSeeking_GetCurrentPosition(&
This->IMediaSeeking_iface, &
pos);
2726 HRESULT hr = IMediaSeeking_GetStopPosition(&
This->IMediaSeeking_iface, &
pos);
2747 FIXME(
"(%p)->(%p) stub!\n", iface, pllTime);
2753 FIXME(
"(%p)->(%f) stub!\n", iface, llTime);
2760 return IMediaSeeking_SetRate(&
This->IMediaSeeking_iface, dRate);
2766 return IMediaSeeking_GetRate(&
This->IMediaSeeking_iface, pdRate);
2771 FIXME(
"(%p)->(%p) stub!\n", iface, pCanSeekForward);
2777 FIXME(
"(%p)->(%p) stub!\n", iface, pCanSeekBackward);
2813 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
2819 return IUnknown_AddRef(
graph->outer_unk);
2825 return IUnknown_Release(
graph->outer_unk);
2835 if (
This->pSite) IUnknown_Release(
This->pSite);
2836 This->pSite = pUnkSite;
2837 IUnknown_AddRef(
This->pSite);
2851 return IUnknown_QueryInterface(
This->pSite,
riid, ppvSite);
2884 FIXME(
"Not enough space to store interface in the cache\n");
2916 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
2922 return IUnknown_AddRef(
graph->outer_unk);
2928 return IUnknown_Release(
graph->outer_unk);
2933 TRACE(
"iface %p, count %p.\n", iface,
count);
2951 TRACE(
"iface %p, iid %s, names %p, count %u, lcid %#lx, ids %p.\n",
2968 TRACE(
"iface %p, id %ld, iid %s, lcid %#lx, flags %#x, params %p, result %p, excepinfo %p, error_arg %p.\n",
2983 IBasicAudio* pBasicAudio;
2986 TRACE(
"graph %p, volume %ld.\n",
This, lVolume);
2993 hr = IBasicAudio_put_Volume(pBasicAudio, lVolume);
3003 IBasicAudio* pBasicAudio;
3006 TRACE(
"(%p/%p)->(%p)\n",
This, iface, plVolume);
3013 hr = IBasicAudio_get_Volume(pBasicAudio, plVolume);
3023 IBasicAudio* pBasicAudio;
3026 TRACE(
"graph %p, balance %ld.\n",
This, lBalance);
3033 hr = IBasicAudio_put_Balance(pBasicAudio, lBalance);
3043 IBasicAudio* pBasicAudio;
3046 TRACE(
"(%p/%p)->(%p)\n",
This, iface, plBalance);
3053 hr = IBasicAudio_get_Balance(pBasicAudio, plBalance);
3083 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
3089 return IUnknown_AddRef(
graph->outer_unk);
3095 return IUnknown_Release(
graph->outer_unk);
3100 TRACE(
"iface %p, count %p.\n", iface,
count);
3118 TRACE(
"iface %p, iid %s, names %p, count %u, lcid %#lx, ids %p.\n",
3135 TRACE(
"iface %p, id %ld, iid %s, lcid %#lx, flags %#x, params %p, result %p, excepinfo %p, error_arg %p.\n",
3150 IBasicVideo *pBasicVideo;
3153 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pAvgTimePerFrame);
3160 hr = IBasicVideo_get_AvgTimePerFrame(pBasicVideo, pAvgTimePerFrame);
3170 IBasicVideo *pBasicVideo;
3173 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pBitRate);
3180 hr = IBasicVideo_get_BitRate(pBasicVideo, pBitRate);
3190 IBasicVideo *pBasicVideo;
3193 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pBitErrorRate);
3200 hr = IBasicVideo_get_BitErrorRate(pBasicVideo, pBitErrorRate);
3210 IBasicVideo *pBasicVideo;
3213 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pVideoWidth);
3220 hr = IBasicVideo_get_VideoWidth(pBasicVideo, pVideoWidth);
3230 IBasicVideo *pBasicVideo;
3233 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pVideoHeight);
3240 hr = IBasicVideo_get_VideoHeight(pBasicVideo, pVideoHeight);
3250 IBasicVideo *pBasicVideo;
3253 TRACE(
"graph %p, left %ld.\n",
This, SourceLeft);
3260 hr = IBasicVideo_put_SourceLeft(pBasicVideo, SourceLeft);
3270 IBasicVideo *pBasicVideo;
3273 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pSourceLeft);
3280 hr = IBasicVideo_get_SourceLeft(pBasicVideo, pSourceLeft);
3290 IBasicVideo *pBasicVideo;
3310 IBasicVideo *pBasicVideo;
3313 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pSourceWidth);
3320 hr = IBasicVideo_get_SourceWidth(pBasicVideo, pSourceWidth);
3330 IBasicVideo *pBasicVideo;
3333 TRACE(
"graph %p, top %ld.\n",
This, SourceTop);
3340 hr = IBasicVideo_put_SourceTop(pBasicVideo, SourceTop);
3350 IBasicVideo *pBasicVideo;
3353 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pSourceTop);
3360 hr = IBasicVideo_get_SourceTop(pBasicVideo, pSourceTop);
3370 IBasicVideo *pBasicVideo;
3390 IBasicVideo *pBasicVideo;
3393 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pSourceHeight);
3400 hr = IBasicVideo_get_SourceHeight(pBasicVideo, pSourceHeight);
3410 IBasicVideo *pBasicVideo;
3413 TRACE(
"graph %p, left %ld.\n",
This, DestinationLeft);
3420 hr = IBasicVideo_put_DestinationLeft(pBasicVideo, DestinationLeft);
3430 IBasicVideo *pBasicVideo;
3433 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pDestinationLeft);
3440 hr = IBasicVideo_get_DestinationLeft(pBasicVideo, pDestinationLeft);
3450 IBasicVideo *pBasicVideo;
3453 TRACE(
"graph %p, width %ld.\n",
This, DestinationWidth);
3460 hr = IBasicVideo_put_DestinationWidth(pBasicVideo, DestinationWidth);
3470 IBasicVideo *pBasicVideo;
3473 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pDestinationWidth);
3480 hr = IBasicVideo_get_DestinationWidth(pBasicVideo, pDestinationWidth);
3490 IBasicVideo *pBasicVideo;
3493 TRACE(
"graph %p, top %ld.\n",
This, DestinationTop);
3500 hr = IBasicVideo_put_DestinationTop(pBasicVideo, DestinationTop);
3510 IBasicVideo *pBasicVideo;
3513 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pDestinationTop);
3520 hr = IBasicVideo_get_DestinationTop(pBasicVideo, pDestinationTop);
3530 IBasicVideo *pBasicVideo;
3533 TRACE(
"graph %p, height %ld.\n",
This, DestinationHeight);
3540 hr = IBasicVideo_put_DestinationHeight(pBasicVideo, DestinationHeight);
3548 LONG *pDestinationHeight)
3551 IBasicVideo *pBasicVideo;
3554 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pDestinationHeight);
3561 hr = IBasicVideo_get_DestinationHeight(pBasicVideo, pDestinationHeight);
3572 IBasicVideo *pBasicVideo;
3593 IBasicVideo *pBasicVideo;
3596 TRACE(
"(%p/%p)->(%p, %p, %p, %p)\n",
This, iface, pLeft, pTop, pWidth, pHeight);
3603 hr = IBasicVideo_GetSourcePosition(pBasicVideo, pLeft, pTop, pWidth, pHeight);
3613 IBasicVideo *pBasicVideo;
3623 hr = IBasicVideo_SetDefaultSourcePosition(pBasicVideo);
3634 IBasicVideo *pBasicVideo;
3644 hr = IBasicVideo_SetDestinationPosition(pBasicVideo, Left,
Top,
Width,
Height);
3655 IBasicVideo *pBasicVideo;
3658 TRACE(
"(%p/%p)->(%p, %p, %p, %p)\n",
This, iface, pLeft, pTop, pWidth, pHeight);
3665 hr = IBasicVideo_GetDestinationPosition(pBasicVideo, pLeft, pTop, pWidth, pHeight);
3675 IBasicVideo *pBasicVideo;
3685 hr = IBasicVideo_SetDefaultDestinationPosition(pBasicVideo);
3695 IBasicVideo *pBasicVideo;
3698 TRACE(
"(%p/%p)->(%p, %p)\n",
This, iface, pWidth, pHeight);
3705 hr = IBasicVideo_GetVideoSize(pBasicVideo, pWidth, pHeight);
3716 IBasicVideo *pBasicVideo;
3719 TRACE(
"graph %p, start_index %ld, count %ld, ret_count %p, entries %p.\n",
3727 hr = IBasicVideo_GetVideoPaletteEntries(pBasicVideo, StartIndex,
Entries, pRetrieved, pPalette);
3738 IBasicVideo *pBasicVideo;
3748 hr = IBasicVideo_GetCurrentImage(pBasicVideo,
pBufferSize, pDIBImage);
3758 IBasicVideo *pBasicVideo;
3768 hr = IBasicVideo_IsUsingDefaultSource(pBasicVideo);
3778 IBasicVideo *pBasicVideo;
3788 hr = IBasicVideo_IsUsingDefaultDestination(pBasicVideo);
3799 IBasicVideo2 *pBasicVideo2;
3868 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
3874 return IUnknown_AddRef(
graph->outer_unk);
3880 return IUnknown_Release(
graph->outer_unk);
3885 TRACE(
"iface %p, count %p.\n", iface,
count);
3903 TRACE(
"iface %p, iid %s, names %p, count %u, lcid %#lx, ids %p.\n",
3920 TRACE(
"iface %p, id %ld, iid %s, lcid %#lx, flags %#x, params %p, result %p, excepinfo %p, error_arg %p.\n",
3935 IVideoWindow *pVideoWindow;
3945 hr = IVideoWindow_put_Caption(pVideoWindow, strCaption);
3955 IVideoWindow *pVideoWindow;
3958 TRACE(
"(%p/%p)->(%p)\n",
This, iface, strCaption);
3965 hr = IVideoWindow_get_Caption(pVideoWindow, strCaption);
3975 IVideoWindow *pVideoWindow;
3978 TRACE(
"graph %p, style %#lx.\n",
This, WindowStyle);
3985 hr = IVideoWindow_put_WindowStyle(pVideoWindow, WindowStyle);
3995 IVideoWindow *pVideoWindow;
3998 TRACE(
"(%p/%p)->(%p)\n",
This, iface, WindowStyle);
4005 hr = IVideoWindow_get_WindowStyle(pVideoWindow, WindowStyle);
4015 IVideoWindow *pVideoWindow;
4018 TRACE(
"graph %p, style %#lx.\n",
This, WindowStyleEx);
4025 hr = IVideoWindow_put_WindowStyleEx(pVideoWindow, WindowStyleEx);
4035 IVideoWindow *pVideoWindow;
4038 TRACE(
"(%p/%p)->(%p)\n",
This, iface, WindowStyleEx);
4045 hr = IVideoWindow_get_WindowStyleEx(pVideoWindow, WindowStyleEx);
4055 IVideoWindow *pVideoWindow;
4058 TRACE(
"graph %p, show %#lx.\n",
This, AutoShow);
4065 hr = IVideoWindow_put_AutoShow(pVideoWindow, AutoShow);
4075 IVideoWindow *pVideoWindow;
4078 TRACE(
"(%p/%p)->(%p)\n",
This, iface, AutoShow);
4085 hr = IVideoWindow_get_AutoShow(pVideoWindow, AutoShow);
4095 IVideoWindow *pVideoWindow;
4098 TRACE(
"graph %p, state %ld.\n",
This, WindowState);
4105 hr = IVideoWindow_put_WindowState(pVideoWindow, WindowState);
4115 IVideoWindow *pVideoWindow;
4118 TRACE(
"(%p/%p)->(%p)\n",
This, iface, WindowState);
4125 hr = IVideoWindow_get_WindowState(pVideoWindow, WindowState);
4135 IVideoWindow *pVideoWindow;
4138 TRACE(
"graph %p, palette %ld.\n",
This, BackgroundPalette);
4145 hr = IVideoWindow_put_BackgroundPalette(pVideoWindow, BackgroundPalette);
4153 LONG *pBackgroundPalette)
4156 IVideoWindow *pVideoWindow;
4159 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pBackgroundPalette);
4166 hr = IVideoWindow_get_BackgroundPalette(pVideoWindow, pBackgroundPalette);
4176 IVideoWindow *pVideoWindow;
4179 TRACE(
"graph %p, visible %ld.\n",
This, Visible);
4186 hr = IVideoWindow_put_Visible(pVideoWindow, Visible);
4196 IVideoWindow *pVideoWindow;
4199 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pVisible);
4206 hr = IVideoWindow_get_Visible(pVideoWindow, pVisible);
4216 IVideoWindow *pVideoWindow;
4219 TRACE(
"graph %p, left %ld.\n",
This, Left);
4226 hr = IVideoWindow_put_Left(pVideoWindow, Left);
4236 IVideoWindow *pVideoWindow;
4239 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pLeft);
4246 hr = IVideoWindow_get_Left(pVideoWindow, pLeft);
4256 IVideoWindow *pVideoWindow;
4266 hr = IVideoWindow_put_Width(pVideoWindow,
Width);
4276 IVideoWindow *pVideoWindow;
4279 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pWidth);
4286 hr = IVideoWindow_get_Width(pVideoWindow, pWidth);
4296 IVideoWindow *pVideoWindow;
4306 hr = IVideoWindow_put_Top(pVideoWindow,
Top);
4316 IVideoWindow *pVideoWindow;
4319 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pTop);
4326 hr = IVideoWindow_get_Top(pVideoWindow, pTop);
4336 IVideoWindow *pVideoWindow;
4346 hr = IVideoWindow_put_Height(pVideoWindow,
Height);
4356 IVideoWindow *pVideoWindow;
4359 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pHeight);
4366 hr = IVideoWindow_get_Height(pVideoWindow, pHeight);
4376 IVideoWindow *pVideoWindow;
4386 hr = IVideoWindow_put_Owner(pVideoWindow,
Owner);
4396 IVideoWindow *pVideoWindow;
4406 hr = IVideoWindow_get_Owner(pVideoWindow,
Owner);
4416 IVideoWindow *pVideoWindow;
4419 TRACE(
"graph %p, drain %#Ix.\n",
This, Drain);
4426 hr = IVideoWindow_put_MessageDrain(pVideoWindow, Drain);
4436 IVideoWindow *pVideoWindow;
4439 TRACE(
"(%p/%p)->(%p)\n",
This, iface, Drain);
4446 hr = IVideoWindow_get_MessageDrain(pVideoWindow, Drain);
4456 IVideoWindow *pVideoWindow;
4466 hr = IVideoWindow_get_BorderColor(pVideoWindow,
Color);
4476 IVideoWindow *pVideoWindow;
4486 hr = IVideoWindow_put_BorderColor(pVideoWindow,
Color);
4496 IVideoWindow *pVideoWindow;
4499 TRACE(
"(%p/%p)->(%p)\n",
This, iface, FullScreenMode);
4506 hr = IVideoWindow_get_FullScreenMode(pVideoWindow, FullScreenMode);
4521 IVideoWindow *pVideoWindow;
4524 TRACE(
"graph %p, fullscreen %ld.\n",
This, FullScreenMode);
4531 hr = IVideoWindow_put_FullScreenMode(pVideoWindow, FullScreenMode);
4543 IVideoWindow *pVideoWindow;
4546 TRACE(
"graph %p, focus %ld.\n",
This, Focus);
4553 hr = IVideoWindow_SetWindowForeground(pVideoWindow, Focus);
4564 IVideoWindow *pVideoWindow;
4585 IVideoWindow *pVideoWindow;
4595 hr = IVideoWindow_SetWindowPosition(pVideoWindow, Left,
Top,
Width,
Height);
4606 IVideoWindow *pVideoWindow;
4609 TRACE(
"(%p/%p)->(%p, %p, %p, %p)\n",
This, iface, pLeft, pTop, pWidth, pHeight);
4616 hr = IVideoWindow_GetWindowPosition(pVideoWindow, pLeft, pTop, pWidth, pHeight);
4627 IVideoWindow *pVideoWindow;
4630 TRACE(
"(%p/%p)->(%p, %p)\n",
This, iface, pWidth, pHeight);
4637 hr = IVideoWindow_GetMinIdealImageSize(pVideoWindow, pWidth, pHeight);
4648 IVideoWindow *pVideoWindow;
4651 TRACE(
"(%p/%p)->(%p, %p)\n",
This, iface, pWidth, pHeight);
4658 hr = IVideoWindow_GetMaxIdealImageSize(pVideoWindow, pWidth, pHeight);
4669 IVideoWindow *pVideoWindow;
4672 TRACE(
"(%p/%p)->(%p, %p, %p, %p)\n",
This, iface, pLeft, pTop, pWidth, pHeight);
4679 hr = IVideoWindow_GetRestorePosition(pVideoWindow, pLeft, pTop, pWidth, pHeight);
4689 IVideoWindow *pVideoWindow;
4692 TRACE(
"graph %p, hide %ld.\n",
This, HideCursor);
4699 hr = IVideoWindow_HideCursor(pVideoWindow, HideCursor);
4709 IVideoWindow *pVideoWindow;
4712 TRACE(
"(%p/%p)->(%p)\n",
This, iface, CursorHidden);
4719 hr = IVideoWindow_IsCursorHidden(pVideoWindow, CursorHidden);
4785 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
4791 return IUnknown_AddRef(
graph->outer_unk);
4797 return IUnknown_Release(
graph->outer_unk);
4802 TRACE(
"iface %p, count %p.\n", iface,
count);
4820 TRACE(
"iface %p, iid %s, names %p, count %u, lcid %#lx, ids %p.\n",
4837 TRACE(
"iface %p, id %ld, iid %s, lcid %#lx, flags %#x, params %p, result %p, excepinfo %p, error_arg %p.\n",
4854 *
event = (OAEVENT)
graph->media_event_handle;
4865 TRACE(
"graph %p, code %p, param1 %p, param2 %p, timeout %ld.\n",
graph,
code, param1, param2,
timeout);
4882 *
code =
event->code;
4883 *param1 =
event->param1;
4884 *param2 =
event->param2;
4896 TRACE(
"graph %p, timeout %ld, code %p.\n",
This, msTimeout, pEvCode);
4898 if (
This->state != State_Running)
4903 *pEvCode =
This->CompletionStatus;
4915 TRACE(
"graph %p, code %#lx.\n",
This, lEvCode);
4933 TRACE(
"graph %p, code %#lx.\n",
This, lEvCode);
4952 WARN(
"graph %p, code %#lx, param1 %Id, param2 %Id, stub!\n",
graph,
code, param1, param2);
4980 WARN(
"Invalid flags %#lx, returning E_INVALIDARG.\n",
flags);
5040 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
5047 return IUnknown_AddRef(
graph->outer_unk);
5054 return IUnknown_Release(
graph->outer_unk);
5059 FIXME(
"(%p): stub\n", pClassID);
5075 if (
graph->state == State_Stopped)
5083 if (
graph->state == State_Running)
5100 graph->state = State_Stopped;
5101 graph->needs_async_run = 0;
5102 work =
graph->async_run_work;
5103 graph->got_ec_complete = 0;
5106 IMediaSeeking_SetPositions(&
graph->IMediaSeeking_iface, &
graph->current_pos,
5128 if (
graph->state == State_Paused)
5143 if (
graph->state == State_Running && !
graph->needs_async_run &&
graph->refClock)
5146 IReferenceClock_GetTime(
graph->refClock, &
time);
5158 graph->state = State_Paused;
5159 graph->needs_async_run = 0;
5160 work =
graph->async_run_work;
5179 if (
graph->state == State_Running)
5189 graph->state = State_Running;
5190 graph->needs_async_run = 0;
5246 if (
graph->needs_async_run)
5249 ERR(
"Filter %p reported incorrect state %u (expected %u or %u).\n",
5255 ERR(
"Filter %p reported incorrect state %u (expected %u).\n",
5280 TRACE(
"(%p/%p)->(%p)\n",
This, iface, pClock);
5299 IReferenceClock_Release(
This->refClock);
5300 This->refClock = pClock;
5302 IReferenceClock_AddRef(
This->refClock);
5305 if (
This->HandleEcClockChanged)
5310 eshr = IMediaFilter_QueryInterface(iface, &IID_IMediaEventSink, (
void **)&pEventSink);
5314 IMediaEventSink_Release(pEventSink);
5328 TRACE(
"(%p/%p)->(%p)\n",
This, iface, ppClock);
5335 *ppClock =
This->refClock;
5337 IReferenceClock_AddRef(*ppClock);
5367 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
5374 return IUnknown_AddRef(
graph->outer_unk);
5381 return IUnknown_Release(
graph->outer_unk);
5389 TRACE(
"graph %p, code %#lx, param1 %#Ix, param2 %#Ix.\n",
graph,
code, param1, param2);
5395 if (++
graph->EcCompleteCount ==
graph->nRenderers)
5397 if (
graph->media_events_disabled)
5402 graph->got_ec_complete = 1;
5408 FIXME(
"EC_REPAINT is not handled.\n");
5410 else if (!
graph->media_events_disabled)
5436 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
5443 return IUnknown_AddRef(
graph->outer_unk);
5450 return IUnknown_Release(
graph->outer_unk);
5458 FIXME(
"graph %p, source %p, sink %p, mt %p, filter %p, abort_event %p, flags %#lx, stub!\n",
5471 TRACE(
"graph %p, callback %p, context %p, flags %#lx, abort_event %p.\n",
5475 FIXME(
"The parameter hAbortEvent is not handled!\n");
5490 FIXME(
"(%p)->(%p): stub!\n",
This, pFilter);
5499 FIXME(
"(%p)->(%p): stub!\n",
This, pEnum);
5508 FIXME(
"(%p)->(%p): stub!\n",
This, pFilter);
5517 FIXME(
"(%p)->(%p): stub!\n",
This, prtStart);
5527 FIXME(
"(%p)->(%p, %p, %p): stub!\n",
This, pOutputPin, pConnection, hEventAbort);
5586 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
5593 return IUnknown_AddRef(
graph->outer_unk);
5600 return IUnknown_Release(
graph->outer_unk);
5632 return IUnknown_QueryInterface(
graph->outer_unk, iid,
out);
5638 return IUnknown_AddRef(
graph->outer_unk);
5644 return IUnknown_Release(
graph->outer_unk);
5649 FIXME(
"iface %p, frame_count %lu, filter %p, stub!\n", iface, frame_count,
filter);
5655 FIXME(
"iface %p, multiple %ld, filter %p, stub!\n", iface, multiple,
filter);
5661 FIXME(
"iface %p, stub!\n", iface);
5689 if (!(
object =
calloc(1,
sizeof(*
object))))
5708 object->outer_unk =
outer ?
outer : &
object->IUnknown_inner;
5713 ERR(
"Failed to create filter mapper, hr %#lx.\n",
hr);
5719 object->cs.DebugInfo->Spare[0] = (
DWORD_PTR)(__FILE__
": filter_graph.cs");
5721 object->event_cs.DebugInfo->Spare[0] = (
DWORD_PTR)(__FILE__
": filter_graph.event_cs");
5723 object->defaultclock =
TRUE;
5728 object->HandleEcClockChanged =
TRUE;
5729 object->HandleEcComplete =
TRUE;
5730 object->HandleEcRepaint =
TRUE;
5733 object->name_index = 1;
5734 object->timeformatseek = TIME_FORMAT_MEDIA_TIME;
5747 TRACE(
"Created %sthreaded filter graph %p.\n",
threaded ?
"" :
"non-",
object);
5748 *
out = &
object->IUnknown_inner;
HRESULT WINAPI DECLSPEC_HOTPATCH SetThreadDescription(_In_ HANDLE hThread, _In_ PCWSTR lpThreadDescription)
static void * heap_alloc(size_t len)
static BOOL heap_free(void *mem)
#define InterlockedIncrement
#define InterlockedDecrement
@ AM_SEEKING_NoPositioning
@ AM_SEEKING_AbsolutePositioning
enum _PinDirection PIN_DIRECTION
@ AM_FILTER_MISC_FLAGS_IS_RENDERER
@ AM_RENDEREX_RENDERTOEXISTINGRENDERERS
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
static void list_remove(struct list_entry *entry)
static int list_empty(struct list_entry *head)
static void list_add_tail(struct list_entry *head, struct list_entry *entry)
static void list_add_head(struct list_entry *head, struct list_entry *entry)
static void list_init(struct list_entry *head)
const GUID IID_IBaseFilter
_Check_return_ _In_ D3DDDI_VIDEO_PRESENT_TARGET_ID _In_ PDXGKARG_SYSTEM_DISPLAY_ENABLE_FLAGS _Out_ UINT _Out_ UINT * Height
_Check_return_ _In_ D3DDDI_VIDEO_PRESENT_TARGET_ID _In_ PDXGKARG_SYSTEM_DISPLAY_ENABLE_FLAGS _Out_ UINT * Width
_In_ UINT _In_ UINT SourceHeight
static HINSTANCE instance
BOOL get_media_type(const WCHAR *filename, GUID *majortype, GUID *subtype, GUID *source_clsid)
static HRESULT WINAPI MediaPosition_Invoke(IMediaPosition *iface, DISPID id, REFIID iid, LCID lcid, WORD flags, DISPPARAMS *params, VARIANT *result, EXCEPINFO *excepinfo, UINT *error_arg)
static HRESULT WINAPI MediaPosition_put_StopTime(IMediaPosition *iface, REFTIME llTime)
HRESULT filter_graph_no_thread_create(IUnknown *outer, IUnknown **out)
static struct filter_graph * impl_from_IMediaEventEx(IMediaEventEx *iface)
static HRESULT WINAPI FilterGraph2_ReconnectEx(IFilterGraph2 *iface, IPin *pin, const AM_MEDIA_TYPE *mt)
static HRESULT WINAPI MediaEvent_SetNotifyWindow(IMediaEventEx *iface, OAHWND window, LONG message, LONG_PTR lparam)
static HRESULT WINAPI MediaSeeking_GetCapabilities(IMediaSeeking *iface, DWORD *pCapabilities)
static ULONG WINAPI ObjectWithSite_Release(IObjectWithSite *iface)
static HRESULT WINAPI BasicVideo_get_BitErrorRate(IBasicVideo2 *iface, LONG *pBitErrorRate)
static HRESULT WINAPI GraphConfig_Reconnect(IGraphConfig *iface, IPin *source, IPin *sink, const AM_MEDIA_TYPE *mt, IBaseFilter *filter, HANDLE abort_event, DWORD flags)
static HRESULT create_enum_filters(struct filter_graph *graph, struct list *cursor, IEnumFilters **out)
static HRESULT WINAPI MediaEventSink_Notify(IMediaEventSink *iface, LONG code, LONG_PTR param1, LONG_PTR param2)
static HRESULT WINAPI BasicAudio_QueryInterface(IBasicAudio *iface, REFIID iid, void **out)
static HRESULT WINAPI MediaPosition_CanSeekBackward(IMediaPosition *iface, LONG *pCanSeekBackward)
static HRESULT WINAPI BasicVideo_put_DestinationTop(IBasicVideo2 *iface, LONG DestinationTop)
static HRESULT WINAPI VideoWindow_put_Height(IVideoWindow *iface, LONG Height)
static HRESULT WINAPI VideoWindow_get_FullScreenMode(IVideoWindow *iface, LONG *FullScreenMode)
static void sort_filters(struct filter_graph *graph)
static HRESULT WINAPI ObjectWithSite_QueryInterface(IObjectWithSite *iface, REFIID iid, void **out)
static HRESULT WINAPI FilterGraph2_EnumFilters(IFilterGraph2 *iface, IEnumFilters **out)
static ULONG WINAPI MediaPosition_AddRef(IMediaPosition *iface)
static HRESULT WINAPI BasicVideo_SetDefaultSourcePosition(IBasicVideo2 *iface)
static ULONG WINAPI MediaEventSink_Release(IMediaEventSink *iface)
static ULONG WINAPI MediaEvent_Release(IMediaEventEx *iface)
static ULONG WINAPI ObjectWithSite_AddRef(IObjectWithSite *iface)
static struct filter_graph * impl_from_IUnknown(IUnknown *iface)
static HRESULT autoplug(struct filter_graph *graph, IPin *source, IPin *sink, BOOL render_to_existing, unsigned int recursion_depth)
static HRESULT WINAPI BasicVideo_put_DestinationHeight(IBasicVideo2 *iface, LONG DestinationHeight)
static HRESULT WINAPI MediaControl_GetTypeInfoCount(IMediaControl *iface, UINT *count)
static ULONG WINAPI FilterGraph2_Release(IFilterGraph2 *iface)
static HRESULT WINAPI MediaPosition_put_Rate(IMediaPosition *iface, double dRate)
static HRESULT WINAPI VideoWindow_put_Width(IVideoWindow *iface, LONG Width)
static HRESULT WINAPI MediaFilter_GetState(IMediaFilter *iface, DWORD timeout, FILTER_STATE *state)
static HRESULT WINAPI MediaEvent_GetTypeInfo(IMediaEventEx *iface, UINT index, LCID lcid, ITypeInfo **typeinfo)
static HRESULT WINAPI EnumFilters_Skip(IEnumFilters *iface, ULONG count)
static HRESULT WINAPI MediaSeeking_GetAvailable(IMediaSeeking *iface, LONGLONG *pEarliest, LONGLONG *pLatest)
static ULONG WINAPI FilterGraph2_AddRef(IFilterGraph2 *iface)
static HRESULT WINAPI VideoWindow_put_Top(IVideoWindow *iface, LONG Top)
static HRESULT WINAPI GraphConfig_RemoveFilterFromCache(IGraphConfig *iface, IBaseFilter *pFilter)
static HRESULT WINAPI BasicVideo_GetTypeInfo(IBasicVideo2 *iface, UINT index, LCID lcid, ITypeInfo **typeinfo)
static const IMediaEventExVtbl IMediaEventEx_VTable
static HRESULT WINAPI BasicAudio_GetTypeInfo(IBasicAudio *iface, UINT index, LCID lcid, ITypeInfo **typeinfo)
static BOOL is_renderer(struct filter *filter)
static HRESULT WINAPI VideoWindow_SetWindowForeground(IVideoWindow *iface, LONG Focus)
HRESULT WINAPI VideoWindow_GetTypeInfo(IVideoWindow *iface, UINT index, LCID lcid, ITypeInfo **typeinfo)
static HRESULT WINAPI MediaControl_RenderFile(IMediaControl *iface, BSTR strFilename)
HRESULT(WINAPI * fnFoundSeek)(struct filter_graph *This, IMediaSeeking *, DWORD_PTR arg)
static ULONG WINAPI MediaFilter_AddRef(IMediaFilter *iface)
static HRESULT WINAPI MediaFilter_Pause(IMediaFilter *iface)
static HRESULT WINAPI BasicVideo_put_DestinationLeft(IBasicVideo2 *iface, LONG DestinationLeft)
static HRESULT WINAPI VideoWindow_put_MessageDrain(IVideoWindow *iface, OAHWND Drain)
static HRESULT WINAPI MediaControl_GetState(IMediaControl *iface, LONG timeout, OAFilterState *state)
static HRESULT WINAPI VideoWindow_put_WindowState(IVideoWindow *iface, LONG WindowState)
static HRESULT WINAPI EnumFilters_QueryInterface(IEnumFilters *iface, REFIID iid, void **out)
static HRESULT WINAPI BasicVideo_GetTypeInfoCount(IBasicVideo2 *iface, UINT *count)
static HRESULT WINAPI VideoWindow_put_WindowStyleEx(IVideoWindow *iface, LONG WindowStyleEx)
static void CALLBACK async_run_cb(TP_CALLBACK_INSTANCE *instance, void *context, TP_WORK *work)
static ULONG WINAPI BasicVideo_AddRef(IBasicVideo2 *iface)
static HRESULT WINAPI GraphConfig_RemoveFilterEx(IGraphConfig *iface, IBaseFilter *filter, DWORD flags)
static void flush_media_events(struct filter_graph *graph)
static void update_seeking(struct filter *filter)
static HRESULT WINAPI MediaControl_Run(IMediaControl *iface)
static ULONG WINAPI MediaControl_Release(IMediaControl *iface)
static HRESULT WINAPI MediaControl_AddSourceFilter(IMediaControl *iface, BSTR strFilename, IDispatch **ppUnk)
static HRESULT WINAPI FilterGraph2_RenderFile(IFilterGraph2 *iface, LPCWSTR lpcwstrFile, LPCWSTR lpcwstrPlayList)
static HRESULT create_filter(struct filter_graph *graph, IMoniker *moniker, IBaseFilter **filter)
static HRESULT WINAPI VideoWindow_get_Left(IVideoWindow *iface, LONG *pLeft)
static struct filter_graph * impl_from_IVideoFrameStep(IVideoFrameStep *iface)
static HRESULT WINAPI MediaPosition_get_Duration(IMediaPosition *iface, REFTIME *plength)
static HRESULT WINAPI FilterGraph2_SetLogFile(IFilterGraph2 *iface, DWORD_PTR file)
static HRESULT WINAPI VideoWindow_put_Owner(IVideoWindow *iface, OAHWND Owner)
static HRESULT WINAPI MediaControl_QueryInterface(IMediaControl *iface, REFIID iid, void **out)
static HRESULT WINAPI MediaSeeking_IsFormatSupported(IMediaSeeking *iface, const GUID *pFormat)
static HRESULT WINAPI MediaFilter_Run(IMediaFilter *iface, REFERENCE_TIME start)
static HRESULT WINAPI FoundCapabilities(struct filter_graph *This, IMediaSeeking *seek, DWORD_PTR pcaps)
static HRESULT WINAPI BasicVideo_get_DestinationLeft(IBasicVideo2 *iface, LONG *pDestinationLeft)
static struct filter_graph * impl_from_IBasicVideo2(IBasicVideo2 *iface)
static const IBasicAudioVtbl IBasicAudio_VTable
static HRESULT WINAPI MediaControl_get_RegFilterCollection(IMediaControl *iface, IDispatch **ppUnk)
static HRESULT WINAPI MediaSeeking_GetPositions(IMediaSeeking *iface, LONGLONG *current, LONGLONG *stop)
static HRESULT WINAPI BasicVideo_GetVideoPaletteEntries(IBasicVideo2 *iface, LONG StartIndex, LONG Entries, LONG *pRetrieved, LONG *pPalette)
static HRESULT WINAPI VideoWindow_put_FullScreenMode(IVideoWindow *iface, LONG FullScreenMode)
static HRESULT WINAPI MediaControl_get_FilterCollection(IMediaControl *iface, IDispatch **ppUnk)
static HRESULT WINAPI MediaFilter_GetSyncSource(IMediaFilter *iface, IReferenceClock **ppClock)
HRESULT WINAPI VideoWindow_GetIDsOfNames(IVideoWindow *iface, REFIID iid, LPOLESTR *names, UINT count, LCID lcid, DISPID *ids)
static HRESULT WINAPI MediaEvent_GetNotifyFlags(IMediaEventEx *iface, LONG *flags)
static HRESULT WINAPI BasicVideo_IsUsingDefaultDestination(IBasicVideo2 *iface)
static HRESULT WINAPI BasicVideo_IsUsingDefaultSource(IBasicVideo2 *iface)
static HRESULT WINAPI FilterGraph2_Abort(IFilterGraph2 *iface)
static HRESULT WINAPI MediaControl_GetIDsOfNames(IMediaControl *iface, REFIID iid, LPOLESTR *names, UINT count, LCID lcid, DISPID *ids)
static HRESULT WINAPI ObjectWithSite_GetSite(IObjectWithSite *iface, REFIID riid, PVOID *ppvSite)
static ULONG WINAPI GraphConfig_Release(IGraphConfig *iface)
static struct filter_graph * impl_from_IMediaFilter(IMediaFilter *iface)
static ULONG WINAPI VideoFrameStep_AddRef(IVideoFrameStep *iface)
static HRESULT WINAPI VideoWindow_SetWindowPosition(IVideoWindow *iface, LONG Left, LONG Top, LONG Width, LONG Height)
static struct filter * find_sorted_filter(struct filter_graph *graph, IBaseFilter *iface)
static HRESULT WINAPI GraphConfig_SetFilterFlags(IGraphConfig *iface, IBaseFilter *filter, DWORD flags)
static HRESULT filter_graph_common_create(IUnknown *outer, IUnknown **out, BOOL threaded)
static HRESULT WINAPI MediaSeeking_CheckCapabilities(IMediaSeeking *iface, DWORD *pCapabilities)
static HRESULT WINAPI GraphConfig_AddFilterToCache(IGraphConfig *iface, IBaseFilter *pFilter)
static ULONG WINAPI FilterGraphInner_Release(IUnknown *iface)
static HRESULT WINAPI BasicVideo_put_SourceLeft(IBasicVideo2 *iface, LONG SourceLeft)
static BOOL has_output_pins(IBaseFilter *filter)
static HRESULT WINAPI MediaSeeking_IsUsingTimeFormat(IMediaSeeking *iface, const GUID *pFormat)
static HANDLE message_thread_ret
static HRESULT WINAPI BasicVideo_put_DestinationWidth(IBasicVideo2 *iface, LONG DestinationWidth)
static HRESULT WINAPI BasicAudio_get_Volume(IBasicAudio *iface, LONG *plVolume)
static HRESULT WINAPI MediaEvent_FreeEventParams(IMediaEventEx *iface, LONG code, LONG_PTR param1, LONG_PTR param2)
static HRESULT WINAPI VideoWindow_IsCursorHidden(IVideoWindow *iface, LONG *CursorHidden)
static HRESULT WINAPI BasicVideo_GetIDsOfNames(IBasicVideo2 *iface, REFIID iid, LPOLESTR *names, UINT count, LCID lcid, DISPID *ids)
static HRESULT WINAPI BasicVideo_SetDestinationPosition(IBasicVideo2 *iface, LONG Left, LONG Top, LONG Width, LONG Height)
static HRESULT WINAPI MediaSeeking_GetPreroll(IMediaSeeking *iface, LONGLONG *pllPreroll)
static HRESULT WINAPI MediaFilter_QueryInterface(IMediaFilter *iface, REFIID iid, void **out)
static HRESULT WINAPI FilterGraph2_AddSourceFilterForMoniker(IFilterGraph2 *iface, IMoniker *pMoniker, IBindCtx *pCtx, LPCWSTR lpcwstrFilterName, IBaseFilter **ppFilter)
static HRESULT WINAPI BasicVideo_GetCurrentImage(IBasicVideo2 *iface, LONG *pBufferSize, LONG *pDIBImage)
static ULONG WINAPI MediaEventSink_AddRef(IMediaEventSink *iface)
static HRESULT WINAPI BasicVideo_get_VideoHeight(IBasicVideo2 *iface, LONG *pVideoHeight)
static HRESULT WINAPI VideoWindow_HideCursor(IVideoWindow *iface, LONG HideCursor)
static HRESULT WINAPI MediaPosition_GetIDsOfNames(IMediaPosition *iface, REFIID iid, LPOLESTR *names, UINT count, LCID lcid, DISPID *ids)
static HRESULT WINAPI MediaPosition_get_PrerollTime(IMediaPosition *iface, REFTIME *pllTime)
static const IFilterGraph2Vtbl IFilterGraph2_VTable
static HRESULT WINAPI BasicVideo_SetDefaultDestinationPosition(IBasicVideo2 *iface)
static HRESULT WINAPI MediaSeeking_SetRate(IMediaSeeking *iface, double dRate)
static HRESULT WINAPI VideoWindow_get_Visible(IVideoWindow *iface, LONG *pVisible)
static HRESULT WINAPI BasicAudio_GetTypeInfoCount(IBasicAudio *iface, UINT *count)
static HRESULT WINAPI VideoFrameStep_QueryInterface(IVideoFrameStep *iface, REFIID iid, void **out)
static HRESULT WINAPI BasicVideo_GetVideoSize(IBasicVideo2 *iface, LONG *pWidth, LONG *pHeight)
static HRESULT WINAPI BasicVideo_SetSourcePosition(IBasicVideo2 *iface, LONG Left, LONG Top, LONG Width, LONG Height)
static ULONG WINAPI GraphVersion_Release(IGraphVersion *iface)
static HRESULT WINAPI BasicVideo_get_DestinationHeight(IBasicVideo2 *iface, LONG *pDestinationHeight)
static void CALLBACK wait_pause_cb(TP_CALLBACK_INSTANCE *instance, void *context)
static HRESULT WINAPI VideoWindow_put_AutoShow(IVideoWindow *iface, LONG AutoShow)
static HRESULT WINAPI BasicVideo_GetDestinationPosition(IBasicVideo2 *iface, LONG *pLeft, LONG *pTop, LONG *pWidth, LONG *pHeight)
static struct filter_graph * impl_from_IVideoWindow(IVideoWindow *iface)
static HRESULT WINAPI VideoWindow_get_Height(IVideoWindow *iface, LONG *pHeight)
static HRESULT WINAPI GraphConfig_GetFilterFlags(IGraphConfig *iface, IBaseFilter *pFilter, DWORD *dwFlags)
static HRESULT WINAPI BasicVideo_get_SourceWidth(IBasicVideo2 *iface, LONG *pSourceWidth)
static const IEnumFiltersVtbl EnumFilters_vtbl
static HRESULT WINAPI MediaControl_Pause(IMediaControl *iface)
static HRESULT WINAPI BasicVideo_get_SourceLeft(IBasicVideo2 *iface, LONG *pSourceLeft)
static HRESULT WINAPI BasicAudio_GetIDsOfNames(IBasicAudio *iface, REFIID iid, LPOLESTR *names, UINT count, LCID lcid, DISPID *ids)
static HRESULT WINAPI MediaSeeking_GetDuration(IMediaSeeking *iface, LONGLONG *duration)
static HRESULT WINAPI VideoWindow_get_WindowStyle(IVideoWindow *iface, LONG *WindowStyle)
struct _ITF_CACHE_ENTRY ITF_CACHE_ENTRY
static HRESULT WINAPI MediaEvent_GetIDsOfNames(IMediaEventEx *iface, REFIID iid, LPOLESTR *names, UINT count, LCID lcid, DISPID *ids)
static HRESULT WINAPI VideoWindow_GetWindowPosition(IVideoWindow *iface, LONG *pLeft, LONG *pTop, LONG *pWidth, LONG *pHeight)
static HRESULT WINAPI VideoWindow_get_BorderColor(IVideoWindow *iface, LONG *Color)
static HRESULT WINAPI BasicVideo_put_SourceHeight(IBasicVideo2 *iface, LONG SourceHeight)
static const IMediaSeekingVtbl IMediaSeeking_VTable
static HRESULT WINAPI MediaFilter_Stop(IMediaFilter *iface)
static HRESULT WINAPI BasicAudio_put_Volume(IBasicAudio *iface, LONG lVolume)
static HRESULT WINAPI VideoWindow_get_Caption(IVideoWindow *iface, BSTR *strCaption)
static ULONG WINAPI EnumFilters_AddRef(IEnumFilters *iface)
static HRESULT WINAPI VideoWindow_Invoke(IVideoWindow *iface, DISPID id, REFIID iid, LCID lcid, WORD flags, DISPPARAMS *params, VARIANT *result, EXCEPINFO *excepinfo, UINT *error_arg)
static HRESULT WINAPI VideoWindow_put_BorderColor(IVideoWindow *iface, LONG Color)
static HRESULT WINAPI VideoWindow_GetMinIdealImageSize(IVideoWindow *iface, LONG *pWidth, LONG *pHeight)
static const IMediaControlVtbl IMediaControl_VTable
static HRESULT WINAPI MediaSeeking_GetRate(IMediaSeeking *iface, double *pdRate)
static HRESULT WINAPI VideoWindow_get_BackgroundPalette(IVideoWindow *iface, LONG *pBackgroundPalette)
static HRESULT WINAPI VideoWindow_get_Owner(IVideoWindow *iface, OAHWND *Owner)
static HRESULT WINAPI GraphVersion_QueryVersion(IGraphVersion *iface, LONG *version)
HRESULT WINAPI VideoWindow_GetTypeInfoCount(IVideoWindow *iface, UINT *count)
static const IMediaEventSinkVtbl IMediaEventSink_VTable
static ULONG WINAPI EnumFilters_Release(IEnumFilters *iface)
static HRESULT WINAPI VideoWindow_get_Width(IVideoWindow *iface, LONG *pWidth)
static HRESULT WINAPI MediaSeeking_QueryInterface(IMediaSeeking *iface, REFIID iid, void **out)
static HRESULT WINAPI MediaControl_Stop(IMediaControl *iface)
static HRESULT WINAPI MediaPosition_put_PrerollTime(IMediaPosition *iface, REFTIME llTime)
static struct filter_graph * impl_from_IGraphConfig(IGraphConfig *iface)
static HRESULT WINAPI MediaEvent_GetEvent(IMediaEventEx *iface, LONG *code, LONG_PTR *param1, LONG_PTR *param2, LONG timeout)
static struct filter_graph * impl_from_IObjectWithSite(IObjectWithSite *iface)
static ULONG WINAPI VideoWindow_Release(IVideoWindow *iface)
static IBaseFilter * find_filter_by_name(struct filter_graph *graph, const WCHAR *name)
static HRESULT WINAPI VideoWindow_get_MessageDrain(IVideoWindow *iface, OAHWND *Drain)
static HRESULT WINAPI VideoWindow_put_Caption(IVideoWindow *iface, BSTR strCaption)
static HRESULT WINAPI BasicVideo_Invoke(IBasicVideo2 *iface, DISPID id, REFIID iid, LCID lcid, WORD flags, DISPPARAMS *params, VARIANT *result, EXCEPINFO *excepinfo, UINT *error_arg)
static HRESULT WINAPI GraphConfig_QueryInterface(IGraphConfig *iface, REFIID iid, void **out)
static ULONG WINAPI GraphVersion_AddRef(IGraphVersion *iface)
static HRESULT WINAPI VideoWindow_GetRestorePosition(IVideoWindow *iface, LONG *pLeft, LONG *pTop, LONG *pWidth, LONG *pHeight)
static HRESULT WINAPI MediaEvent_WaitForCompletion(IMediaEventEx *iface, LONG msTimeout, LONG *pEvCode)
#define MAX_ITF_CACHE_ENTRIES
static HRESULT autoplug_through_sink(struct filter_graph *graph, IPin *source, IBaseFilter *filter, IPin *middle_sink, IPin *sink, BOOL render_to_existing, unsigned int recursion_depth)
static struct filter_graph * impl_from_IMediaControl(IMediaControl *iface)
static HRESULT WINAPI VideoFrameStep_CanStep(IVideoFrameStep *iface, LONG multiple, IUnknown *filter)
static HRESULT WINAPI VideoWindow_QueryInterface(IVideoWindow *iface, REFIID iid, void **out)
static HRESULT WINAPI BasicVideo_put_SourceWidth(IBasicVideo2 *iface, LONG SourceWidth)
static struct filter_graph * impl_from_IGraphVersion(IGraphVersion *iface)
static HRESULT WINAPI BasicAudio_put_Balance(IBasicAudio *iface, LONG lBalance)
static HRESULT WINAPI BasicVideo_get_VideoWidth(IBasicVideo2 *iface, LONG *pVideoWidth)
static ULONG WINAPI GraphConfig_AddRef(IGraphConfig *iface)
static HRESULT WINAPI EnumFilters_Next(IEnumFilters *iface, ULONG count, IBaseFilter **filters, ULONG *fetched)
static struct filter_graph * impl_from_IMediaPosition(IMediaPosition *iface)
static HRESULT WINAPI MediaEvent_Invoke(IMediaEventEx *iface, DISPID id, REFIID iid, LCID lcid, WORD flags, DISPPARAMS *params, VARIANT *result, EXCEPINFO *excepinfo, UINT *error_arg)
static HRESULT WINAPI BasicVideo_get_SourceHeight(IBasicVideo2 *iface, LONG *pSourceHeight)
static HRESULT WINAPI BasicVideo2_GetPreferredAspectRatio(IBasicVideo2 *iface, LONG *plAspectX, LONG *plAspectY)
static HRESULT ConvertFromREFTIME(IMediaSeeking *seek, REFTIME time_in, LONGLONG *time_out)
static HRESULT WINAPI GraphConfig_Reconfigure(IGraphConfig *iface, IGraphConfigCallback *callback, void *context, DWORD flags, HANDLE abort_event)
static HRESULT WINAPI MediaFilter_SetSyncSource(IMediaFilter *iface, IReferenceClock *pClock)
static HRESULT WINAPI VideoWindow_put_Visible(IVideoWindow *iface, LONG Visible)
static HRESULT graph_start(struct filter_graph *graph, REFERENCE_TIME stream_start)
static ULONG WINAPI MediaSeeking_AddRef(IMediaSeeking *iface)
static HRESULT WINAPI VideoWindow_get_WindowStyleEx(IVideoWindow *iface, LONG *WindowStyleEx)
static HRESULT WINAPI MediaControl_StopWhenReady(IMediaControl *iface)
static HRESULT WINAPI MediaPosition_get_StopTime(IMediaPosition *iface, REFTIME *pllTime)
static HRESULT WINAPI MediaPosition_get_CurrentPosition(IMediaPosition *iface, REFTIME *pllTime)
static HRESULT WINAPI MediaEventSink_QueryInterface(IMediaEventSink *iface, REFIID iid, void **out)
static const IVideoWindowVtbl IVideoWindow_VTable
static HRESULT WINAPI MediaEvent_GetTypeInfoCount(IMediaEventEx *iface, UINT *count)
static HRESULT GetTargetInterface(struct filter_graph *pGraph, REFIID riid, LPVOID *ppvObj)
static HANDLE message_thread
static const IVideoFrameStepVtbl VideoFrameStep_vtbl
static HRESULT WINAPI MediaEvent_RestoreDefaultHandling(IMediaEventEx *iface, LONG lEvCode)
static ULONG WINAPI BasicAudio_AddRef(IBasicAudio *iface)
static HRESULT WINAPI MediaSeeking_SetTimeFormat(IMediaSeeking *iface, const GUID *pFormat)
static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *source, IPin *sink)
static HRESULT WINAPI FilterGraph2_Render(IFilterGraph2 *iface, IPin *source)
static DWORD message_thread_id
static ULONG WINAPI MediaControl_AddRef(IMediaControl *iface)
static HRESULT WINAPI MediaEvent_QueryInterface(IMediaEventEx *iface, REFIID iid, void **out)
static ULONG WINAPI FilterGraphInner_AddRef(IUnknown *iface)
static HRESULT WINAPI BasicVideo_put_SourceTop(IBasicVideo2 *iface, LONG SourceTop)
static HRESULT WINAPI VideoWindow_put_Left(IVideoWindow *iface, LONG Left)
static HRESULT WINAPI VideoFrameStep_Step(IVideoFrameStep *iface, DWORD frame_count, IUnknown *filter)
static HRESULT WINAPI ObjectWithSite_SetSite(IObjectWithSite *iface, IUnknown *pUnkSite)
static void sort_filter_recurse(struct filter_graph *graph, struct filter *filter, struct list *sorted)
static void update_render_count(struct filter_graph *graph)
HRESULT filter_graph_create(IUnknown *outer, IUnknown **out)
static HRESULT WINAPI FilterGraph2_ShouldOperationContinue(IFilterGraph2 *iface)
static HRESULT WINAPI MediaSeeking_GetTimeFormat(IMediaSeeking *iface, GUID *pFormat)
static unsigned int message_thread_refcount
static HRESULT WINAPI EnumFilters_Reset(IEnumFilters *iface)
static HRESULT WINAPI BasicAudio_get_Balance(IBasicAudio *iface, LONG *plBalance)
static HRESULT WINAPI MediaEvent_CancelDefaultHandling(IMediaEventEx *iface, LONG lEvCode)
static HRESULT WINAPI MediaSeeking_SetPositions(IMediaSeeking *iface, LONGLONG *current_ptr, DWORD current_flags, LONGLONG *stop_ptr, DWORD stop_flags)
static HRESULT all_renderers_seek(struct filter_graph *This, fnFoundSeek FoundSeek, DWORD_PTR arg)
static HRESULT get_autoplug_types(IPin *source, unsigned int *ret_count, GUID **ret_types)
static ULONG WINAPI MediaFilter_Release(IMediaFilter *iface)
static struct filter_graph * impl_from_IMediaEventSink(IMediaEventSink *iface)
static HRESULT WINAPI FilterGraph2_AddSourceFilter(IFilterGraph2 *iface, const WCHAR *filename, const WCHAR *filter_name, IBaseFilter **ret_filter)
static HRESULT WINAPI MediaSeeking_QueryPreferredFormat(IMediaSeeking *iface, GUID *pFormat)
static HRESULT WINAPI GraphConfig_EnumCacheFilter(IGraphConfig *iface, IEnumFilters **pEnum)
static const IBasicVideo2Vtbl IBasicVideo_VTable
static HRESULT WINAPI VideoWindow_get_WindowState(IVideoWindow *iface, LONG *WindowState)
static HRESULT WINAPI MediaControl_Invoke(IMediaControl *iface, DISPID id, REFIID iid, LCID lcid, WORD flags, DISPPARAMS *params, VARIANT *result, EXCEPINFO *excepinfo, UINT *error_arg)
static HRESULT WINAPI FilterGraph2_ConnectDirect(IFilterGraph2 *iface, IPin *ppinIn, IPin *ppinOut, const AM_MEDIA_TYPE *pmt)
static HRESULT WINAPI GraphConfig_PushThroughData(IGraphConfig *iface, IPin *pOutputPin, IPinConnection *pConnection, HANDLE hEventAbort)
static const IMediaPositionVtbl IMediaPosition_VTable
static ULONG WINAPI MediaSeeking_Release(IMediaSeeking *iface)
static ULONG WINAPI MediaEvent_AddRef(IMediaEventEx *iface)
static HRESULT WINAPI MediaSeeking_GetCurrentPosition(IMediaSeeking *iface, LONGLONG *current)
static HRESULT WINAPI VideoWindow_put_BackgroundPalette(IVideoWindow *iface, LONG BackgroundPalette)
static HRESULT WINAPI MediaPosition_put_CurrentPosition(IMediaPosition *iface, REFTIME llTime)
static HRESULT WINAPI MediaSeeking_GetStopPosition(IMediaSeeking *iface, LONGLONG *stop)
static HRESULT check_cyclic_connection(IPin *source, IPin *sink)
static HRESULT WINAPI BasicVideo_get_DestinationTop(IBasicVideo2 *iface, LONG *pDestinationTop)
static HRESULT WINAPI MediaPosition_GetTypeInfo(IMediaPosition *iface, UINT index, LCID lcid, ITypeInfo **typeinfo)
static ULONG WINAPI VideoFrameStep_Release(IVideoFrameStep *iface)
static HRESULT WINAPI MediaPosition_QueryInterface(IMediaPosition *iface, REFIID iid, void **out)
static HRESULT WINAPI FilterGraph2_SetDefaultSyncSource(IFilterGraph2 *iface)
static HRESULT WINAPI MediaEvent_SetNotifyFlags(IMediaEventEx *iface, LONG flags)
static HRESULT WINAPI VideoWindow_NotifyOwnerMessage(IVideoWindow *iface, OAHWND hwnd, LONG uMsg, LONG_PTR wParam, LONG_PTR lParam)
static ULONG WINAPI BasicVideo_Release(IBasicVideo2 *iface)
static struct filter_graph * impl_from_IMediaSeeking(IMediaSeeking *iface)
static BOOL queue_media_event(struct filter_graph *graph, LONG code, LONG_PTR param1, LONG_PTR param2)
static HRESULT WINAPI VideoWindow_get_AutoShow(IVideoWindow *iface, LONG *AutoShow)
static HRESULT WINAPI MediaPosition_CanSeekForward(IMediaPosition *iface, LONG *pCanSeekForward)
static HRESULT WINAPI BasicVideo_GetSourcePosition(IBasicVideo2 *iface, LONG *pLeft, LONG *pTop, LONG *pWidth, LONG *pHeight)
static const IGraphVersionVtbl IGraphVersion_VTable
static HRESULT WINAPI FilterGraph2_QueryInterface(IFilterGraph2 *iface, REFIID iid, void **out)
static HRESULT WINAPI GraphConfig_GetStartTime(IGraphConfig *iface, REFERENCE_TIME *prtStart)
static HRESULT WINAPI GraphVersion_QueryInterface(IGraphVersion *iface, REFIID iid, void **out)
static HRESULT ConvertToREFTIME(IMediaSeeking *seek, LONGLONG time_in, REFTIME *time_out)
static HRESULT WINAPI BasicVideo_get_BitRate(IBasicVideo2 *iface, LONG *pBitRate)
static HRESULT WINAPI FilterGraph2_AddFilter(IFilterGraph2 *iface, IBaseFilter *filter, const WCHAR *name)
static ULONG WINAPI VideoWindow_AddRef(IVideoWindow *iface)
static HRESULT WINAPI VideoWindow_get_Top(IVideoWindow *iface, LONG *pTop)
static const IGraphConfigVtbl IGraphConfig_VTable
static HRESULT WINAPI FilterGraph2_FindFilterByName(IFilterGraph2 *iface, const WCHAR *name, IBaseFilter **filter)
static HRESULT WINAPI EnumFilters_Clone(IEnumFilters *iface, IEnumFilters **out)
static struct filter_graph * impl_from_IBasicAudio(IBasicAudio *iface)
static HRESULT WINAPI VideoWindow_put_WindowStyle(IVideoWindow *iface, LONG WindowStyle)
static HRESULT WINAPI BasicVideo_get_SourceTop(IBasicVideo2 *iface, LONG *pSourceTop)
static HRESULT WINAPI MediaSeeking_ConvertTimeFormat(IMediaSeeking *iface, LONGLONG *pTarget, const GUID *pTargetFormat, LONGLONG Source, const GUID *pSourceFormat)
static HRESULT WINAPI MediaEvent_GetEventHandle(IMediaEventEx *iface, OAEVENT *event)
static const IMediaFilterVtbl IMediaFilter_VTable
static struct filter_graph * impl_from_IFilterGraph2(IFilterGraph2 *iface)
static HRESULT WINAPI BasicAudio_Invoke(IBasicAudio *iface, DISPID id, REFIID iid, LCID lcid, WORD flags, DISPPARAMS *params, VARIANT *result, EXCEPINFO *excepinfo, UINT *error_arg)
static HRESULT WINAPI BasicVideo_QueryInterface(IBasicVideo2 *iface, REFIID iid, void **out)
static HRESULT WINAPI MediaPosition_GetTypeInfoCount(IMediaPosition *iface, UINT *count)
static HRESULT WINAPI FilterGraph2_RemoveFilter(IFilterGraph2 *iface, IBaseFilter *pFilter)
static HRESULT WINAPI FilterGraph2_RenderEx(IFilterGraph2 *iface, IPin *source, DWORD flags, DWORD *context)
static const IUnknownVtbl IInner_VTable
static HRESULT WINAPI FilterGraphInner_QueryInterface(IUnknown *iface, REFIID riid, void **ppvObj)
static HRESULT WINAPI FilterGraph2_Disconnect(IFilterGraph2 *iface, IPin *ppin)
static void CALLBACK wait_stop_cb(TP_CALLBACK_INSTANCE *instance, void *context)
static HRESULT WINAPI VideoWindow_GetMaxIdealImageSize(IVideoWindow *iface, LONG *pWidth, LONG *pHeight)
static DWORD WINAPI message_thread_run(void *ctx)
static struct enum_filters * impl_from_IEnumFilters(IEnumFilters *iface)
static HRESULT WINAPI BasicVideo_get_DestinationWidth(IBasicVideo2 *iface, LONG *pDestinationWidth)
static HRESULT autoplug_through_filter(struct filter_graph *graph, IPin *source, IBaseFilter *filter, IPin *sink, BOOL render_to_existing, unsigned int recursion_depth)
static HRESULT WINAPI MediaControl_GetTypeInfo(IMediaControl *iface, UINT index, LCID lcid, ITypeInfo **typeinfo)
static HRESULT WINAPI MediaPosition_get_Rate(IMediaPosition *iface, double *pdRate)
static HRESULT WINAPI MediaFilter_GetClassID(IMediaFilter *iface, CLSID *pClassID)
static ULONG WINAPI MediaPosition_Release(IMediaPosition *iface)
static HRESULT WINAPI VideoFrameStep_CancelStep(IVideoFrameStep *iface)
static const IObjectWithSiteVtbl IObjectWithSite_VTable
static HRESULT WINAPI BasicVideo_get_AvgTimePerFrame(IBasicVideo2 *iface, REFTIME *pAvgTimePerFrame)
static HRESULT WINAPI FilterGraph2_Reconnect(IFilterGraph2 *iface, IPin *pin)
static ULONG WINAPI BasicAudio_Release(IBasicAudio *iface)
const char * qzdebugstr_guid(const GUID *id)
HRESULT WINAPI DECLSPEC_HOTPATCH CoInitializeEx(void *reserved, DWORD model)
void WINAPI DECLSPEC_HOTPATCH CoUninitialize(void)
HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance(REFCLSID rclsid, IUnknown *outer, DWORD cls_context, REFIID riid, void **obj)
void *WINAPI CoTaskMemAlloc(SIZE_T size)
void WINAPI CoTaskMemFree(void *ptr)
static __inline const char * wine_dbgstr_longlong(ULONGLONG ll)
static const WCHAR version[]
HANDLE WINAPI DECLSPEC_HOTPATCH CreateThread(IN LPSECURITY_ATTRIBUTES lpThreadAttributes, IN DWORD dwStackSize, IN LPTHREAD_START_ROUTINE lpStartAddress, IN LPVOID lpParameter, IN DWORD dwCreationFlags, OUT LPDWORD lpThreadId)
BOOL WINAPI InitializeCriticalSectionEx(OUT LPCRITICAL_SECTION lpCriticalSection, IN DWORD dwSpinCount, IN DWORD flags)
BOOL WINAPI DECLSPEC_HOTPATCH TrySubmitThreadpoolCallback(PTP_SIMPLE_CALLBACK callback, PVOID userdata, TP_CALLBACK_ENVIRON *environment)
PTP_WORK WINAPI DECLSPEC_HOTPATCH CreateThreadpoolWork(PTP_WORK_CALLBACK callback, PVOID userdata, TP_CALLBACK_ENVIRON *environment)
ULONG WINAPI DECLSPEC_HOTPATCH GetTickCount(void)
_ACRTIMP size_t __cdecl wcslen(const wchar_t *)
_ACRTIMP int __cdecl wcscmp(const wchar_t *, const wchar_t *)
_ACRTIMP int __cdecl memcmp(const void *, const void *, size_t)
static void list_move_tail(struct list_head *list, struct list_head *head)
_Must_inspect_result_ _In_ ULONG _Out_writes_bytes_ pBufferSize PVOID _Inout_ PULONG pBufferSize
GLuint GLuint GLsizei count
GLsizei GLenum GLboolean sink
GLenum const GLfloat * params
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define memcpy(s1, s2, n)
struct task_struct * current
static const ENTRY Entries[]
static IPrintDialogCallback callback
const IID IID_IObjectWithSite
static IHTMLWindow2 * window
static EXCEPINFO excepinfo
static VARIANTARG static DISPID
static DWORD filter_state
_In_ UINT _In_ UINT _In_ PNDIS_PACKET Source
_Out_writes_bytes_to_opt_ AbsoluteSecurityDescriptorSize PSECURITY_DESCRIPTOR _Inout_ PULONG _Out_writes_bytes_to_opt_ DaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ SaclSize PACL _Inout_ PULONG _Out_writes_bytes_to_opt_ OwnerSize PSID Owner
_In_ LPWSTR _In_ DWORD _In_ DWORD _In_ DWORD dwFlags
const GUID IID_IPropertyBag
#define IsEqualGUID(rguid1, rguid2)
BOOL WINAPI TranslateMessage(_In_ const MSG *)
BOOL WINAPI GetMessageW(_Out_ LPMSG, _In_opt_ HWND, _In_ UINT, _In_ UINT)
BOOL WINAPI PostMessageW(_In_opt_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI PeekMessageW(_Out_ LPMSG, _In_opt_ HWND, _In_ UINT, _In_ UINT, _In_ UINT)
BOOL WINAPI PostThreadMessageW(_In_ DWORD, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
LRESULT WINAPI DispatchMessageW(_In_ const MSG *)
#define DECLARE_CRITICAL_SECTION(cs)
#define LIST_FOR_EACH_ENTRY(elem, list, type, field)
#define LIST_FOR_EACH_ENTRY_SAFE(cursor, cursor2, list, type, field)
__WINE_SERVER_LIST_INLINE struct list * list_next(const struct list *list, const struct list *elem)
__WINE_SERVER_LIST_INLINE struct list * list_tail(const struct list *list)
int seek(void *fd, ulong off, int mode)
static const char * debugstr_time(REFERENCE_TIME time)
HRESULT strmbase_get_typeinfo(enum strmbase_type_id tid, ITypeInfo **typeinfo)
void strmbase_dump_media_type(const AM_MEDIA_TYPE *mt)
void WINAPI DeleteMediaType(AM_MEDIA_TYPE *pMediaType)
struct filter_graph * graph
IEnumFilters IEnumFilters_iface
IMediaEventSink IMediaEventSink_iface
IBaseFilter * refClockProvider
IMediaControl IMediaControl_iface
IMediaFilter IMediaFilter_iface
REFERENCE_TIME stream_start
ITF_CACHE_ENTRY ItfCacheEntries[MAX_ITF_CACHE_ENTRIES]
REFERENCE_TIME stream_stop
HANDLE media_event_handle
IMediaEventEx IMediaEventEx_iface
IObjectWithSite IObjectWithSite_iface
unsigned int needs_async_run
IReferenceClock * refClock
IVideoWindow IVideoWindow_iface
IVideoFrameStep IVideoFrameStep_iface
IBasicAudio IBasicAudio_iface
IMediaSeeking IMediaSeeking_iface
IGraphVersion IGraphVersion_iface
IFilterGraph2 IFilterGraph2_iface
REFERENCE_TIME stream_elapsed
IGraphConfig IGraphConfig_iface
LPARAM media_event_lparam
CRITICAL_SECTION event_cs
IBasicVideo2 IBasicVideo2_iface
unsigned int media_events_disabled
IMediaPosition IMediaPosition_iface
IUnknown * punkFilterMapper2
unsigned int got_ec_complete
IFilterGraph2 IFilterGraph2_iface
PSYMCRYPT_PARALLEL_HASH_OPERATION next
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateEventW(IN LPSECURITY_ATTRIBUTES lpEventAttributes OPTIONAL, IN BOOL bManualReset, IN BOOL bInitialState, IN LPCWSTR lpName OPTIONAL)
BOOL WINAPI DECLSPEC_HOTPATCH SetEvent(IN HANDLE hEvent)
BOOL WINAPI DECLSPEC_HOTPATCH ResetEvent(IN HANDLE hEvent)
WINBASEAPI VOID WINAPI WaitForThreadpoolWorkCallbacks(_Inout_ PTP_WORK pwk, _In_ BOOL fCancelPendingCallbacks)
WINBASEAPI VOID WINAPI SubmitThreadpoolWork(_Inout_ PTP_WORK pwk)
TW_UINT32 TW_UINT16 TW_UINT16 MSG
#define CONTAINING_RECORD(address, type, field)
HRESULT WINAPI DECLSPEC_HOTPATCH VariantClear(VARIANTARG *pVarg)
void WINAPI VariantInit(VARIANTARG *pVarg)
#define VFW_E_CIRCULAR_GRAPH
#define VFW_E_DUPLICATE_NAME
#define VFW_E_WRONG_STATE
#define VFW_S_PARTIAL_RENDER
#define VFW_S_STATE_INTERMEDIATE
#define VFW_E_ENUM_OUT_OF_SYNC
#define VFW_E_NO_AUDIO_HARDWARE
#define VFW_E_CANNOT_CONNECT
#define VFW_S_DUPLICATE_NAME
#define VFW_E_NOT_CONNECTED
#define VFW_E_CANNOT_RENDER
wchar_t tm const _CrtWcstime_Writes_and_advances_ptr_ count wchar_t ** out
HANDLE WINAPI GetCurrentThread(void)
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
#define RTL_CRITICAL_SECTION_FLAG_FORCE_DEBUG_INFO
struct _TP_CALLBACK_INSTANCE TP_CALLBACK_INSTANCE