24#include "wmcodecdsp.h"
42 && !
memcmp(
a->pbFormat,
b->pbFormat,
a->cbFormat);
74 return IUnknown_Release(
unknown);
87 IBaseFilter_QueryInterface(
reader, &IID_IFileSourceFilter, (
void **)&filesource);
91 &IID_IFilterGraph2, (
void **)&
graph);
93 IFilterGraph2_AddFilter(
graph, splitter,
NULL);
95 IBaseFilter_FindPin(splitter,
L"input pin", &
sink);
103 IBaseFilter_Release(
reader);
104 IFileSourceFilter_Release(filesource);
108#define check_interface(a, b, c) check_interface_(__LINE__, a, b, c)
117 hr = IUnknown_QueryInterface(iface, iid, (
void **)&unk);
120 IUnknown_Release(unk);
148 IBaseFilter_FindPin(
filter,
L"input pin", &pin);
160 IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
173 IBaseFilter_Release(
filter);
174 IFilterGraph2_Release(
graph);
230 ok(unk != &
test_outer,
"Returned IUnknown should not be outer IUnknown.\n");
232 ok(
ref == 1,
"Got unexpected refcount %ld.\n",
ref);
234 ref = IUnknown_AddRef(unk);
235 ok(
ref == 2,
"Got unexpected refcount %ld.\n",
ref);
238 ref = IUnknown_Release(unk);
239 ok(
ref == 1,
"Got unexpected refcount %ld.\n",
ref);
244 ok(unk2 == unk,
"Got unexpected IUnknown %p.\n", unk2);
245 IUnknown_Release(unk2);
252 ok(unk2 == (
IUnknown *)0xdeadbeef,
"Got unexpected IUnknown %p.\n", unk2);
256 ok(filter2 == (
IBaseFilter *)0xdeadbeef,
"Got unexpected IBaseFilter %p.\n", filter2);
258 hr = IUnknown_QueryInterface(unk, &
test_iid, (
void **)&unk2);
260 ok(!unk2,
"Got unexpected IUnknown %p.\n", unk2);
264 ok(unk2 == (
IUnknown *)0xdeadbeef,
"Got unexpected IUnknown %p.\n", unk2);
266 IBaseFilter_Release(
filter);
267 ref = IUnknown_Release(unk);
268 ok(!
ref,
"Got unexpected refcount %ld.\n",
ref);
284 ok(
ref == 1,
"Got unexpected refcount %ld.\n",
ref);
289 hr = IBaseFilter_EnumPins(
filter, &enum1);
292 ok(
ref == 2,
"Got unexpected refcount %ld.\n",
ref);
294 ok(
ref == 1,
"Got unexpected refcount %ld.\n",
ref);
299 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
302 ok(
ref == 3,
"Got unexpected refcount %ld.\n",
ref);
304 ok(
ref == 3,
"Got unexpected refcount %ld.\n",
ref);
306 ok(
ref == 1,
"Got unexpected refcount %ld.\n",
ref);
307 IPin_Release(pins[0]);
309 ok(
ref == 2,
"Got unexpected refcount %ld.\n",
ref);
311 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
314 hr = IEnumPins_Reset(enum1);
317 hr = IEnumPins_Next(enum1, 1, pins, &
count);
320 IPin_Release(pins[0]);
322 hr = IEnumPins_Next(enum1, 1, pins, &
count);
326 hr = IEnumPins_Reset(enum1);
329 hr = IEnumPins_Next(enum1, 2, pins,
NULL);
332 hr = IEnumPins_Next(enum1, 2, pins, &
count);
335 IPin_Release(pins[0]);
337 hr = IEnumPins_Reset(enum1);
340 hr = IEnumPins_Clone(enum1, &enum2);
343 hr = IEnumPins_Skip(enum1, 2);
346 hr = IEnumPins_Skip(enum1, 1);
349 hr = IEnumPins_Skip(enum1, 1);
352 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
355 hr = IEnumPins_Next(enum2, 1, pins,
NULL);
357 IPin_Release(pins[0]);
359 IEnumPins_Release(enum2);
363 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
366 hr = IEnumPins_Reset(enum1);
369 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
371 IPin_Release(pins[0]);
373 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
375 IPin_Release(pins[0]);
377 hr = IEnumPins_Next(enum1, 1, pins,
NULL);
380 hr = IEnumPins_Reset(enum1);
383 hr = IEnumPins_Next(enum1, 2, pins, &
count);
386 IPin_Release(pins[0]);
387 IPin_Release(pins[1]);
389 hr = IEnumPins_Reset(enum1);
392 hr = IEnumPins_Next(enum1, 3, pins, &
count);
395 IPin_Release(pins[0]);
396 IPin_Release(pins[1]);
398 IEnumPins_Release(enum1);
399 IFilterGraph2_Release(
graph);
401 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
417 hr = IBaseFilter_FindPin(
filter,
L"input pin", &pin);
421 hr = IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
424 hr = IBaseFilter_FindPin(
filter,
L"Input", &pin);
435 hr = IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
437 ok(pin == pin2,
"Expected pin %p, got %p.\n", pin2, pin);
444 hr = IBaseFilter_FindPin(
filter,
L"input pin", &pin);
446 ok(pin == pin2,
"Expected pin %p, got %p.\n", pin2, pin);
451 IFilterGraph2_Release(
graph);
453 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
473 hr = IBaseFilter_FindPin(
filter,
L"input pin", &pin);
479 hr = IPin_QueryPinInfo(pin, &
info);
488 IBaseFilter_Release(
info.pFilter);
490 hr = IPin_QueryDirection(pin, &
dir);
494 hr = IPin_QueryId(pin, &
id);
501 hr = IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
507 hr = IPin_QueryPinInfo(pin, &
info);
512 IBaseFilter_Release(
info.pFilter);
514 hr = IPin_QueryDirection(pin, &
dir);
518 hr = IPin_QueryId(pin, &
id);
525 IFilterGraph2_Release(
graph);
527 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
538 .bmiHeader.biWidth = 32,
539 .bmiHeader.biHeight = 24,
540 .bmiHeader.biPlanes = 1,
541 .bmiHeader.biBitCount = 12,
542 .bmiHeader.biCompression =
mmioFOURCC(
'I',
'4',
'2',
'0'),
543 .bmiHeader.biSizeImage = 32 * 24 * 12 / 8,
557 IBaseFilter_FindPin(
filter,
L"input pin", &pin);
559 hr = IPin_EnumMediaTypes(pin, &enummt);
562 hr = IEnumMediaTypes_Next(enummt, 1, &pmt,
NULL);
565 IEnumMediaTypes_Release(enummt);
567 mt.majortype = MEDIATYPE_Stream;
568 mt.subtype = MEDIASUBTYPE_Avi;
569 hr = IPin_QueryAccept(pin, &mt);
572 mt.bFixedSizeSamples =
TRUE;
573 mt.bTemporalCompression =
TRUE;
574 mt.lSampleSize = 123;
575 mt.formattype = FORMAT_WaveFormatEx;
576 hr = IPin_QueryAccept(pin, &mt);
580 hr = IPin_QueryAccept(pin, &mt);
582 mt.majortype = MEDIATYPE_Stream;
585 hr = IPin_QueryAccept(pin, &mt);
587 mt.subtype = MEDIASUBTYPE_Avi;
591 hr = IPin_EnumMediaTypes(pin, &enummt);
594 hr = IEnumMediaTypes_Next(enummt, 1, &pmt,
NULL);
597 IEnumMediaTypes_Release(enummt);
600 IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
602 hr = IPin_EnumMediaTypes(pin, &enummt);
605 hr = IEnumMediaTypes_Next(enummt, 1, &pmt,
NULL);
607 ok(
IsEqualGUID(&pmt->majortype, &MEDIATYPE_Video),
"Got major type %s\n",
609 ok(
IsEqualGUID(&pmt->subtype, &MEDIASUBTYPE_I420),
"Got subtype %s\n",
611 ok(!pmt->bFixedSizeSamples,
"Got fixed size %d.\n", pmt->bFixedSizeSamples);
612 todo_wine ok(!pmt->bTemporalCompression,
"Got temporal compression %d.\n", pmt->bTemporalCompression);
613 ok(pmt->lSampleSize == 1,
"Got sample size %lu.\n", pmt->lSampleSize);
614 ok(
IsEqualGUID(&pmt->formattype, &FORMAT_VideoInfo),
"Got format type %s.\n",
616 ok(!pmt->pUnk,
"Got pUnk %p.\n", pmt->pUnk);
617 ok(pmt->cbFormat ==
sizeof(
VIDEOINFOHEADER),
"Got format size %lu.\n", pmt->cbFormat);
620 hr = IPin_QueryAccept(pin, pmt);
623 pmt->bFixedSizeSamples =
TRUE;
624 pmt->bTemporalCompression =
TRUE;
625 pmt->lSampleSize = 123;
626 hr = IPin_QueryAccept(pin, pmt);
630 hr = IPin_QueryAccept(pin, pmt);
632 pmt->majortype = MEDIATYPE_Video;
635 hr = IPin_QueryAccept(pin, pmt);
637 pmt->subtype = MEDIASUBTYPE_I420;
640 hr = IPin_QueryAccept(pin, pmt);
642 pmt->formattype = FORMAT_None;
643 hr = IPin_QueryAccept(pin, pmt);
645 pmt->formattype = FORMAT_VideoInfo;
650 hr = IPin_QueryAccept(pin, pmt);
655 hr = IPin_QueryAccept(pin, pmt);
660 hr = IPin_QueryAccept(pin, pmt);
665 hr = IPin_QueryAccept(pin, pmt);
672 hr = IEnumMediaTypes_Next(enummt, 1, &pmt,
NULL);
675 IEnumMediaTypes_Release(enummt);
678 IFilterGraph2_Release(
graph);
680 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
697 IBaseFilter_FindPin(
filter,
L"input pin", &pin);
699 hr = IPin_EnumMediaTypes(pin, &enum1);
702 hr = IEnumMediaTypes_Next(enum1, 1, mts,
NULL);
705 hr = IEnumMediaTypes_Next(enum1, 1, mts, &
count);
709 hr = IEnumMediaTypes_Reset(enum1);
712 hr = IEnumMediaTypes_Next(enum1, 1, mts,
NULL);
715 hr = IEnumMediaTypes_Clone(enum1, &enum2);
718 hr = IEnumMediaTypes_Skip(enum1, 1);
721 hr = IEnumMediaTypes_Next(enum2, 1, mts,
NULL);
724 IEnumMediaTypes_Release(enum1);
725 IEnumMediaTypes_Release(enum2);
728 IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
730 hr = IPin_EnumMediaTypes(pin, &enum1);
733 hr = IEnumMediaTypes_Next(enum1, 1, mts,
NULL);
738 hr = IEnumMediaTypes_Next(enum1, 1, mts,
NULL);
741 hr = IEnumMediaTypes_Reset(enum1);
744 hr = IEnumMediaTypes_Next(enum1, 1, mts, &
count);
750 hr = IEnumMediaTypes_Next(enum1, 1, mts, &
count);
754 hr = IEnumMediaTypes_Reset(enum1);
757 hr = IEnumMediaTypes_Next(enum1, 2, mts, &
count);
763 hr = IEnumMediaTypes_Reset(enum1);
766 hr = IEnumMediaTypes_Clone(enum1, &enum2);
769 hr = IEnumMediaTypes_Skip(enum1, 2);
772 hr = IEnumMediaTypes_Skip(enum1, 1);
775 hr = IEnumMediaTypes_Reset(enum1);
778 hr = IEnumMediaTypes_Skip(enum1, 1);
781 hr = IEnumMediaTypes_Skip(enum1, 1);
784 hr = IEnumMediaTypes_Next(enum1, 1, mts,
NULL);
787 hr = IEnumMediaTypes_Next(enum2, 1, mts,
NULL);
792 IEnumMediaTypes_Release(enum1);
793 IEnumMediaTypes_Release(enum2);
796 IFilterGraph2_Release(
graph);
798 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
824 return &
filter->source.pin;
843 filter->new_segment_count = 0;
874 iface->
pin.peer = peer;
878 if (
FAILED(
hr = IPin_ReceiveConnection(peer, &iface->
pin.IPin_iface,
mt)))
926 hr = IPin_ConnectedTo(peer, &peer2);
928 ok(peer2 == &iface->
pin.IPin_iface,
"Peer didn't match.\n");
931 hr = IPin_ConnectionMediaType(peer, &mt2);
954 ok(
filter->new_segment_count,
"Expected NewSegment() before Receive().\n");
956 IPin_QueryInterface(iface->
pin.peer, &IID_IMediaSeeking, (
void **)&seeking);
957 hr = IMediaSeeking_GetPositions(seeking, &
start, &
end);
960 ok(
end ==
filter->seek_end,
"Expected end position %I64u, got %I64u.\n",
filter->seek_end,
end);
961 IMediaSeeking_Release(seeking);
991 ++
filter->new_segment_count;
993 IPin_QueryInterface(iface->
pin.peer, &IID_IMediaSeeking, (
void **)&seeking);
994 hr = IMediaSeeking_GetPositions(seeking, &
filter->seek_start, &
filter->seek_end);
996 IMediaSeeking_Release(seeking);
1101 filter->segment_end = 50000000;
1106 OAFilterState
state;
1160 .majortype = MEDIATYPE_Stream,
1161 .subtype = MEDIASUBTYPE_Avi,
1162 .formattype = FORMAT_None,
1179 &IID_IFilterGraph2, (
void **)&
graph);
1183 IFilterGraph2_AddFilter(
graph, &testsource.
filter.IBaseFilter_iface,
L"source");
1186 IFilterGraph2_QueryInterface(
graph, &IID_IMediaControl, (
void **)&
control);
1190 IBaseFilter_QueryInterface(
reader, &IID_IFileSourceFilter, (
void **)&filesource);
1192 IFileSourceFilter_Release(filesource);
1199 peer = (
IPin *)0xdeadbeef;
1200 hr = IPin_ConnectedTo(
sink, &peer);
1202 ok(!peer,
"Got peer %p.\n", peer);
1204 hr = IPin_ConnectionMediaType(
sink, &
mt);
1209 hr = IFilterGraph2_ConnectDirect(
graph, &testsource.
source.pin.IPin_iface,
sink, &req_mt);
1214 req_mt.majortype = MEDIATYPE_Video;
1215 hr = IFilterGraph2_ConnectDirect(
graph, &testsource.
source.pin.IPin_iface,
sink, &req_mt);
1217 req_mt.majortype = MEDIATYPE_Stream;
1219 req_mt.subtype = MEDIASUBTYPE_RGB8;
1220 hr = IFilterGraph2_ConnectDirect(
graph, &testsource.
source.pin.IPin_iface,
sink, &req_mt);
1222 req_mt.subtype = MEDIASUBTYPE_Avi;
1224 hr = IFilterGraph2_ConnectDirect(
graph, &testsource.
source.pin.IPin_iface,
sink, &req_mt);
1227 hr = IPin_ConnectedTo(
sink, &peer);
1229 ok(peer == &testsource.
source.pin.IPin_iface,
"Got peer %p.\n", peer);
1232 hr = IPin_ConnectionMediaType(
sink, &
mt);
1249 peer = (
IPin *)0xdeadbeef;
1250 hr = IPin_ConnectedTo(
source, &peer);
1252 ok(!peer,
"Got peer %p.\n", peer);
1259 IPin_EnumMediaTypes(
source, &enummt);
1261 IEnumMediaTypes_Release(enummt);
1276 hr = IPin_ConnectedTo(
source, &peer);
1278 ok(peer == &
testsink.sink.
pin.IPin_iface,
"Got peer %p.\n", peer);
1301 req_mt.lSampleSize = 999;
1302 req_mt.bTemporalCompression = req_mt.bFixedSizeSamples =
TRUE;
1309 req_mt.majortype = MEDIATYPE_Stream;
1312 req_mt.majortype = MEDIATYPE_Video;
1314 req_mt.subtype = MEDIASUBTYPE_RGB32;
1320 req_mt.subtype = MEDIASUBTYPE_I420;
1337 req_mt.subtype = MEDIASUBTYPE_RGB32;
1348 req_mt.formattype = FORMAT_None;
1352 req_mt.majortype = MEDIATYPE_Video;
1353 req_mt.subtype = MEDIASUBTYPE_I420;
1361 req_mt.subtype = MEDIASUBTYPE_RGB32;
1372 req_mt.majortype = MEDIATYPE_Audio;
1382 req_mt.majortype = MEDIATYPE_Video;
1383 req_mt.subtype = MEDIASUBTYPE_I420;
1384 req_mt.formattype = FORMAT_VideoInfo;
1385 req_mt.lSampleSize = 444;
1395 ok(testsource.
source.pin.peer ==
sink,
"Got peer %p.\n", testsource.
source.pin.peer);
1396 IFilterGraph2_Disconnect(
graph, &testsource.
source.pin.IPin_iface);
1402 IAsyncReader_Release(testsource.
reader);
1404 IMediaControl_Release(
control);
1405 ref = IFilterGraph2_Release(
graph);
1406 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1408 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1410 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1411 ref = IBaseFilter_Release(&testsource.
filter.IBaseFilter_iface);
1412 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1414 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1473 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1499 {&TIME_FORMAT_MEDIA_TIME,
S_OK},
1500 {&TIME_FORMAT_FRAME,
S_OK},
1504 {&TIME_FORMAT_SAMPLE,
S_FALSE},
1505 {&TIME_FORMAT_FIELD,
S_FALSE},
1509 IBaseFilter_FindPin(
filter,
L"Stream 00", &pin);
1510 IPin_QueryInterface(pin, &IID_IMediaSeeking, (
void **)&seeking);
1512 hr = IMediaSeeking_GetCapabilities(seeking, &caps);
1519 hr = IMediaSeeking_CheckCapabilities(seeking, &caps);
1524 hr = IMediaSeeking_CheckCapabilities(seeking, &caps);
1529 hr = IMediaSeeking_CheckCapabilities(seeking, &caps);
1531 ok(!caps,
"Got caps %#lx.\n", caps);
1534 hr = IMediaSeeking_CheckCapabilities(seeking, &caps);
1536 ok(!caps,
"Got caps %#lx.\n", caps);
1540 hr = IMediaSeeking_IsFormatSupported(seeking, format_tests[
i].
guid);
1545 hr = IMediaSeeking_QueryPreferredFormat(seeking, &
format);
1549 hr = IMediaSeeking_GetTimeFormat(seeking, &
format);
1553 hr = IMediaSeeking_IsUsingTimeFormat(seeking, &TIME_FORMAT_MEDIA_TIME);
1555 hr = IMediaSeeking_IsUsingTimeFormat(seeking, &TIME_FORMAT_FRAME);
1558 hr = IMediaSeeking_SetTimeFormat(seeking, &TIME_FORMAT_SAMPLE);
1560 hr = IMediaSeeking_SetTimeFormat(seeking, &TIME_FORMAT_FRAME);
1563 hr = IMediaSeeking_GetTimeFormat(seeking, &
format);
1567 hr = IMediaSeeking_IsUsingTimeFormat(seeking, &TIME_FORMAT_MEDIA_TIME);
1569 hr = IMediaSeeking_IsUsingTimeFormat(seeking, &TIME_FORMAT_FRAME);
1572 hr = IMediaSeeking_SetTimeFormat(seeking, &TIME_FORMAT_MEDIA_TIME);
1576 hr = IMediaSeeking_GetDuration(seeking, &duration);
1578 ok(duration == 50000000,
"Got duration %I64d.\n", duration);
1581 hr = IMediaSeeking_GetStopPosition(seeking, &stop);
1583 ok(stop == duration,
"Expected time %s, got %s.\n",
1585 hr = IMediaSeeking_GetCurrentPosition(seeking, &
current);
1589 hr = IMediaSeeking_GetPositions(seeking, &
current, &stop);
1592 ok(stop == duration,
"Expected time %s, got %s.\n",
1596 hr = IMediaSeeking_ConvertTimeFormat(seeking, &
time, &TIME_FORMAT_MEDIA_TIME, 0x123456789a,
NULL);
1600 hr = IMediaSeeking_ConvertTimeFormat(seeking, &
time,
NULL, 0x123456789a, &TIME_FORMAT_MEDIA_TIME);
1604 hr = IMediaSeeking_ConvertTimeFormat(seeking, &
time,
NULL, 123, &TIME_FORMAT_FRAME);
1608 earliest = latest = 0xdeadbeef;
1609 hr = IMediaSeeking_GetAvailable(seeking, &earliest, &latest);
1612 ok(latest == duration,
"Expected time %s, got %s.\n",
1616 hr = IMediaSeeking_GetRate(seeking, &
rate);
1620 hr = IMediaSeeking_SetRate(seeking, 200.0);
1623 hr = IMediaSeeking_GetRate(seeking, &
rate);
1627 hr = IMediaSeeking_SetRate(seeking, -1.0);
1630 hr = IMediaSeeking_GetPreroll(seeking, &
time);
1634 stop = 3500 * 10000;
1642 hr = IMediaSeeking_GetPositions(seeking, &
current, &stop);
1649 stop = 3500 * 10000;
1656 hr = IMediaSeeking_GetStopPosition(seeking, &prev_stop);
1665 hr = IMediaSeeking_GetPositions(seeking, &
current, &stop);
1668 ok(stop == prev_stop,
"Expected time %s, got %s.\n",
1671 IMediaSeeking_Release(seeking);
1673 IFilterGraph2_Release(
graph);
1675 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1698 IFilterGraph2_QueryInterface(
graph, &IID_IMediaControl, (
void **)&
control);
1700 IPin_QueryInterface(
source, &IID_IMediaSeeking, (
void **)&seeking);
1712 ok(
testsink.sample_count,
"Expected at least one sample.\n");
1721 ok(
testsink.sample_count,
"Expected at least one sample.\n");
1724 testsink.segment_start = 1500 * 10000;
1725 testsink.segment_end = 3500 * 10000;
1732 ok(
testsink.sample_count,
"Expected at least one sample.\n");
1735 hr = IMediaSeeking_GetPositions(seeking, &
start, &
end);
1747 ok(
testsink.sample_count,
"Expected at least one sample.\n");
1750 hr = IMediaSeeking_GetPositions(seeking, &
start, &
end);
1755 IMediaSeeking_Release(seeking);
1757 IMediaControl_Release(
control);
1758 ref = IFilterGraph2_Release(
graph);
1759 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1761 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1763 ok(!
ref,
"Got outstanding refcount %ld.\n",
ref);
1779 skip(
"Failed to create AVI splitter.\n");
1782 IBaseFilter_Release(
filter);
#define InterlockedIncrement
#define InterlockedDecrement
static HRESULT WINAPI async_reader_WaitForNext(IAsyncReader *iface, DWORD timeout, IMediaSample **sample, DWORD_PTR *cookie)
static HRESULT WINAPI async_reader_SyncRead(IAsyncReader *iface, LONGLONG position, LONG length, BYTE *buffer)
static BOOL compare_media_types(const AM_MEDIA_TYPE *a, const AM_MEDIA_TYPE *b)
static HRESULT testsink_query_interface(struct strmbase_pin *iface, REFIID iid, void **out)
static void testfilter_destroy(struct strmbase_filter *iface)
static const IUnknownVtbl outer_vtbl
static HRESULT WINAPI async_reader_SyncReadAligned(IAsyncReader *iface, IMediaSample *sample)
static const struct strmbase_sink_ops testsink_ops
static void test_aggregation(void)
static HRESULT testsink_connect(struct strmbase_sink *iface, IPin *peer, const AM_MEDIA_TYPE *mt)
static void check_interface_(unsigned int line, void *iface_ptr, REFIID iid, BOOL supported)
static ULONG WINAPI outer_AddRef(IUnknown *iface)
static HRESULT WINAPI outer_QueryInterface(IUnknown *iface, REFIID iid, void **out)
static HRESULT WINAPI async_reader_Length(IAsyncReader *iface, LONGLONG *total, LONGLONG *available)
static struct testfilter * impl_from_strmbase_filter(struct strmbase_filter *iface)
static ULONG get_refcount(void *iface)
static const struct IAsyncReaderVtbl async_reader_vtbl
static HRESULT WINAPI async_reader_BeginFlush(IAsyncReader *iface)
static void test_pin_info(void)
static HRESULT WINAPI async_reader_EndFlush(IAsyncReader *iface)
static HRESULT testsource_query_interface(struct strmbase_pin *iface, REFIID iid, void **out)
static IUnknown test_outer
static HRESULT WINAPI async_reader_RequestAllocator(IAsyncReader *iface, IMemAllocator *preferred, ALLOCATOR_PROPERTIES *props, IMemAllocator **allocator)
static void test_find_pin(void)
static IFilterGraph2 * connect_input(IBaseFilter *splitter, const WCHAR *filename)
static HRESULT testsink_new_segment(struct strmbase_sink *iface, REFERENCE_TIME start, REFERENCE_TIME end, double rate)
static ULONG WINAPI async_reader_Release(IAsyncReader *iface)
static HRESULT testsink_eos(struct strmbase_sink *iface)
static const struct strmbase_source_ops testsource_ops
static void test_enum_media_types(void)
static HRESULT WINAPI async_reader_Request(IAsyncReader *iface, IMediaSample *sample, DWORD_PTR cookie)
static void test_interfaces(void)
static void test_connect_pin(void)
static void test_media_types(void)
static HRESULT WINAPI testsource_AttemptConnection(struct strmbase_source *iface, IPin *peer, const AM_MEDIA_TYPE *mt)
static struct strmbase_pin * testfilter_get_pin(struct strmbase_filter *iface, unsigned int index)
static void test_enum_pins(void)
static HRESULT testfilter_init_stream(struct strmbase_filter *iface)
static HRESULT WINAPI testsink_Receive(struct strmbase_sink *iface, IMediaSample *sample)
static ULONG WINAPI async_reader_AddRef(IAsyncReader *iface)
static void test_seeking(void)
static HRESULT WINAPI async_reader_QueryInterface(IAsyncReader *iface, REFIID iid, void **out)
static IBaseFilter * create_avi_splitter(void)
static const GUID testguid
#define check_interface(a, b, c)
static const struct strmbase_filter_ops testfilter_ops
static void test_unconnected_filter_state(void)
static const GUID test_iid
static struct testfilter * impl_from_IAsyncReader(IAsyncReader *iface)
static HRESULT testsink_get_media_type(struct strmbase_pin *iface, unsigned int index, AM_MEDIA_TYPE *mt)
static void testfilter_init(struct testfilter *filter)
static ULONG WINAPI outer_Release(IUnknown *iface)
@ AM_SEEKING_CanGetDuration
@ AM_SEEKING_CanGetCurrentPos
@ AM_SEEKING_CanSeekBackwards
@ AM_SEEKING_CanSeekForwards
@ AM_SEEKING_CanSeekAbsolute
@ AM_SEEKING_CanGetStopPos
@ AM_SEEKING_NoPositioning
@ AM_SEEKING_AbsolutePositioning
enum _PinDirection PIN_DIRECTION
const GUID IID_IKsPropertySet
const GUID IID_IBaseFilter
const GUID IID_IAsyncReader
void WINAPI DECLSPEC_HOTPATCH CoUninitialize(void)
HRESULT WINAPI DECLSPEC_HOTPATCH CoCreateInstance(REFCLSID rclsid, IUnknown *outer, DWORD cls_context, REFIID riid, void **obj)
void WINAPI CoTaskMemFree(void *ptr)
static WCHAR available[MAX_STRING_RESOURCE_LEN]
static WCHAR unknown[MAX_STRING_RESOURCE_LEN]
#define INVALID_HANDLE_VALUE
static __inline const char * wine_dbgstr_longlong(ULONGLONG ll)
BOOL WINAPI DeleteFileW(IN LPCWSTR lpFileName)
BOOL WINAPI WriteFile(_In_ HANDLE hFile, _In_reads_bytes_opt_(nNumberOfBytesToWrite) LPCVOID lpBuffer, _In_ DWORD nNumberOfBytesToWrite, _Out_opt_ LPDWORD lpNumberOfBytesWritten, _Inout_opt_ LPOVERLAPPED lpOverlapped)
HMODULE WINAPI DECLSPEC_HOTPATCH GetModuleHandleA(LPCSTR lpModuleName)
DWORD WINAPI GetTempPathW(IN DWORD count, OUT LPWSTR path)
HRSRC WINAPI FindResourceW(HINSTANCE hModule, LPCWSTR name, LPCWSTR type)
DWORD WINAPI SizeofResource(HINSTANCE hModule, HRSRC hRsrc)
LPVOID WINAPI LockResource(HGLOBAL handle)
HGLOBAL WINAPI LoadResource(HINSTANCE hModule, HRSRC hRsrc)
_ACRTIMP int __cdecl wcscmp(const wchar_t *, const wchar_t *)
_ACRTIMP int __cdecl memcmp(const void *, const void *, size_t)
HRESULT WINAPI CoInitialize(LPVOID lpReserved)
GLuint GLuint GLsizei count
GLboolean GLboolean GLboolean b
GLuint GLsizei GLsizei * length
GLsizei GLenum GLboolean sink
GLboolean GLboolean GLboolean GLboolean a
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 todo_wine_if(is_todo)
void __cdecl void __cdecl void __cdecl void __cdecl void __cdecl void winetest_pop_context(void)
void __cdecl void __cdecl void __cdecl void __cdecl void __cdecl winetest_push_context(const char *fmt,...) __WINE_PRINTF_ATTR(1
#define mmioFOURCC(c0, c1, c2, c3)
struct task_struct * current
#define load_resource(a, b, c)
static const WCHAR pathW[]
static void test_filter_state(void)
static void test_streaming(void)
const GUID IID_IPersistPropertyBag
#define IsEqualGUID(rguid1, rguid2)
BOOL WINAPI SetRect(_Out_ LPRECT, _In_ int, _In_ int, _In_ int, _In_ int)
#define offsetof(TYPE, MEMBER)
static __inline const char * wine_dbgstr_guid(const GUID *id)
HRESULT WINAPI CopyMediaType(AM_MEDIA_TYPE *pDest, const AM_MEDIA_TYPE *pSrc)
void WINAPI FreeMediaType(AM_MEDIA_TYPE *pMediaType)
void strmbase_source_init(struct strmbase_source *pin, struct strmbase_filter *filter, const WCHAR *name, const struct strmbase_source_ops *func_table)
void strmbase_sink_cleanup(struct strmbase_sink *pin)
void strmbase_sink_init(struct strmbase_sink *pin, struct strmbase_filter *filter, const WCHAR *name, const struct strmbase_sink_ops *ops, IMemAllocator *allocator)
void strmbase_filter_cleanup(struct strmbase_filter *filter)
void strmbase_source_cleanup(struct strmbase_source *pin)
void strmbase_filter_init(struct strmbase_filter *filter, IUnknown *outer, const CLSID *clsid, const struct strmbase_filter_ops *func_table)
struct strmbase_filter * filter
IAsyncReader IAsyncReader_iface
REFERENCE_TIME segment_end
REFERENCE_TIME seek_start
REFERENCE_TIME segment_start
unsigned int new_segment_count
struct strmbase_source source
struct strmbase_filter filter
unsigned int sample_count
struct strmbase_filter filter
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)
#define CONTAINING_RECORD(address, type, field)
#define VFW_E_TYPE_NOT_ACCEPTED
#define VFW_E_NOT_STOPPED
#define VFW_S_NO_STOP_TIME
#define VFW_E_NO_ACCEPTABLE_TYPES
#define VFW_S_NO_MORE_ITEMS
#define VFW_E_NOT_CONNECTED
static const WCHAR props[]
wchar_t tm const _CrtWcstime_Writes_and_advances_ptr_ count wchar_t ** out
DWORD WINAPI GetLastError(void)
DWORD WINAPI GetCurrentThreadId(void)