Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- include/wine/strmbase.h | 1 + libs/strmbase/filter.c | 2 +- libs/strmbase/pin.c | 6 ++++-- 3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/include/wine/strmbase.h b/include/wine/strmbase.h index 3e92136b7f7..1b4cc3f7657 100644 --- a/include/wine/strmbase.h +++ b/include/wine/strmbase.h @@ -36,6 +36,7 @@ struct strmbase_pin struct strmbase_filter *filter; PIN_DIRECTION dir; WCHAR name[128]; + WCHAR id[128]; IPin *peer; AM_MEDIA_TYPE mt;
diff --git a/libs/strmbase/filter.c b/libs/strmbase/filter.c index 92b4f1cb4b6..ee41611a198 100644 --- a/libs/strmbase/filter.c +++ b/libs/strmbase/filter.c @@ -436,7 +436,7 @@ static HRESULT WINAPI filter_FindPin(IBaseFilter *iface, const WCHAR *id, IPin *
for (i = 0; (pin = filter->ops->filter_get_pin(filter, i)); ++i) { - if (!lstrcmpW(id, pin->name)) + if (!lstrcmpW(id, pin->id)) { IPin_AddRef(*ret = &pin->IPin_iface); return S_OK; diff --git a/libs/strmbase/pin.c b/libs/strmbase/pin.c index 1aecb7a8c98..03330837477 100644 --- a/libs/strmbase/pin.c +++ b/libs/strmbase/pin.c @@ -383,10 +383,10 @@ static HRESULT WINAPI pin_QueryId(IPin *iface, WCHAR **id)
TRACE("pin %p %s:%s, id %p.\n", pin, debugstr_w(pin->filter->name), debugstr_w(pin->name), id);
- if (!(*id = CoTaskMemAlloc((lstrlenW(pin->name) + 1) * sizeof(WCHAR)))) + if (!(*id = CoTaskMemAlloc((lstrlenW(pin->id) + 1) * sizeof(WCHAR)))) return E_OUTOFMEMORY;
- lstrcpyW(*id, pin->name); + lstrcpyW(*id, pin->id);
return S_OK; } @@ -770,6 +770,7 @@ void strmbase_source_init(struct strmbase_source *pin, struct strmbase_filter *f pin->pin.filter = filter; pin->pin.dir = PINDIR_OUTPUT; lstrcpyW(pin->pin.name, name); + lstrcpyW(pin->pin.id, name); pin->pin.ops = &func_table->base; pin->pFuncsTable = func_table; } @@ -1172,6 +1173,7 @@ void strmbase_sink_init(struct strmbase_sink *pin, struct strmbase_filter *filte pin->pin.filter = filter; pin->pin.dir = PINDIR_INPUT; lstrcpyW(pin->pin.name, name); + lstrcpyW(pin->pin.id, name); pin->pin.ops = &func_table->base; pin->pFuncsTable = func_table; pin->pAllocator = pin->preferred_allocator = allocator;
Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/qedit/samplegrabber.c | 3 +++ dlls/qedit/tests/samplegrabber.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/qedit/samplegrabber.c b/dlls/qedit/samplegrabber.c index a89229c4447..9b9780e564a 100644 --- a/dlls/qedit/samplegrabber.c +++ b/dlls/qedit/samplegrabber.c @@ -652,8 +652,11 @@ HRESULT sample_grabber_create(IUnknown *outer, IUnknown **out) object->IMemInputPin_iface.lpVtbl = &IMemInputPin_VTable;
strmbase_sink_init(&object->sink, &object->filter, L"In", &sink_ops, NULL); + wcscpy(object->sink.pin.name, L"Input");
strmbase_source_init(&object->source, &object->filter, L"Out", &source_ops); + wcscpy(object->source.pin.name, L"Output"); + strmbase_passthrough_init(&object->passthrough, (IUnknown *)&object->source.pin.IPin_iface); ISeekingPassThru_Init(&object->passthrough.ISeekingPassThru_iface, FALSE, &object->sink.pin.IPin_iface); diff --git a/dlls/qedit/tests/samplegrabber.c b/dlls/qedit/tests/samplegrabber.c index 32fcfc1eb2b..9daa67355b2 100644 --- a/dlls/qedit/tests/samplegrabber.c +++ b/dlls/qedit/tests/samplegrabber.c @@ -312,7 +312,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", wine_dbgstr_w(info.achName)); + ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", wine_dbgstr_w(info.achName)); IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir); @@ -336,7 +336,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_OUTPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"Output"), "Got name %s.\n", wine_dbgstr_w(info.achName)); + ok(!wcscmp(info.achName, L"Output"), "Got name %s.\n", wine_dbgstr_w(info.achName)); IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
Signed-off-by: Zebediah Figura zfigura@codeweavers.com
Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/qcap/avico.c | 3 +++ dlls/qcap/tests/avico.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/qcap/avico.c b/dlls/qcap/avico.c index 71d00c4e4ef..2a347bd2027 100644 --- a/dlls/qcap/avico.c +++ b/dlls/qcap/avico.c @@ -480,7 +480,10 @@ HRESULT avi_compressor_create(IUnknown *outer, IUnknown **out) object->IPersistPropertyBag_iface.lpVtbl = &PersistPropertyBagVtbl;
strmbase_sink_init(&object->sink, &object->filter, L"In", &sink_ops, NULL); + wcscpy(object->sink.pin.name, L"Input"); + strmbase_source_init(&object->source, &object->filter, L"Out", &source_ops); + wcscpy(object->source.pin.name, L"Output");
TRACE("Created AVI compressor %p.\n", object); *out = &object->filter.IUnknown_inner; diff --git a/dlls/qcap/tests/avico.c b/dlls/qcap/tests/avico.c index 7435815f012..abd4fa8e5e7 100644 --- a/dlls/qcap/tests/avico.c +++ b/dlls/qcap/tests/avico.c @@ -353,7 +353,7 @@ static void test_pin_info(IBaseFilter *filter) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!lstrcmpW(info.achName, L"Input"), "Got name %s.\n", wine_dbgstr_w(info.achName)); + ok(!lstrcmpW(info.achName, L"Input"), "Got name %s.\n", wine_dbgstr_w(info.achName)); IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir); @@ -374,7 +374,7 @@ static void test_pin_info(IBaseFilter *filter) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_OUTPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!lstrcmpW(info.achName, L"Output"), "Got name %s.\n", wine_dbgstr_w(info.achName)); + ok(!lstrcmpW(info.achName, L"Output"), "Got name %s.\n", wine_dbgstr_w(info.achName)); IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
Signed-off-by: Zebediah Figura zfigura@codeweavers.com
Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/quartz/acmwrapper.c | 3 +++ dlls/quartz/tests/acmwrapper.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/quartz/acmwrapper.c b/dlls/quartz/acmwrapper.c index cf8e7cd125d..8e1b5e6b773 100644 --- a/dlls/quartz/acmwrapper.c +++ b/dlls/quartz/acmwrapper.c @@ -520,8 +520,11 @@ HRESULT acm_wrapper_create(IUnknown *outer, IUnknown **out) strmbase_filter_init(&object->filter, outer, &CLSID_ACMWrapper, &filter_ops);
strmbase_sink_init(&object->sink, &object->filter, L"In", &sink_ops, NULL); + wcscpy(object->sink.pin.name, L"Input");
strmbase_source_init(&object->source, &object->filter, L"Out", &source_ops); + wcscpy(object->source.pin.name, L"Output"); + object->source_IQualityControl_iface.lpVtbl = &source_qc_vtbl; strmbase_passthrough_init(&object->passthrough, (IUnknown *)&object->source.pin.IPin_iface); ISeekingPassThru_Init(&object->passthrough.ISeekingPassThru_iface, FALSE, diff --git a/dlls/quartz/tests/acmwrapper.c b/dlls/quartz/tests/acmwrapper.c index 564daa3a6f9..caeca61ae50 100644 --- a/dlls/quartz/tests/acmwrapper.c +++ b/dlls/quartz/tests/acmwrapper.c @@ -380,7 +380,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", debugstr_w(info.achName)); + ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", debugstr_w(info.achName)); ref = get_refcount(filter); ok(ref == 3, "Got unexpected refcount %ld.\n", ref); ref = get_refcount(pin); @@ -411,7 +411,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_OUTPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"Output"), "Got name %s.\n", debugstr_w(info.achName)); + ok(!wcscmp(info.achName, L"Output"), "Got name %s.\n", debugstr_w(info.achName)); IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
Signed-off-by: Zebediah Figura zfigura@codeweavers.com
Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/quartz/avidec.c | 3 +++ dlls/quartz/tests/avidec.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/quartz/avidec.c b/dlls/quartz/avidec.c index f473c829cba..8cc729748c1 100644 --- a/dlls/quartz/avidec.c +++ b/dlls/quartz/avidec.c @@ -602,8 +602,11 @@ HRESULT avi_dec_create(IUnknown *outer, IUnknown **out) strmbase_filter_init(&object->filter, outer, &CLSID_AVIDec, &filter_ops);
strmbase_sink_init(&object->sink, &object->filter, L"In", &sink_ops, NULL); + wcscpy(object->sink.pin.name, L"XForm In");
strmbase_source_init(&object->source, &object->filter, L"Out", &source_ops); + wcscpy(object->source.pin.name, L"XForm Out"); + object->source_IQualityControl_iface.lpVtbl = &source_qc_vtbl; strmbase_passthrough_init(&object->passthrough, (IUnknown *)&object->source.pin.IPin_iface); ISeekingPassThru_Init(&object->passthrough.ISeekingPassThru_iface, FALSE, diff --git a/dlls/quartz/tests/avidec.c b/dlls/quartz/tests/avidec.c index 12d8daf3872..46ce5d9eeda 100644 --- a/dlls/quartz/tests/avidec.c +++ b/dlls/quartz/tests/avidec.c @@ -521,7 +521,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"XForm In"), "Got name %s.\n", wine_dbgstr_w(info.achName)); + ok(!wcscmp(info.achName, L"XForm In"), "Got name %s.\n", wine_dbgstr_w(info.achName)); ref = get_refcount(filter); ok(ref == 3, "Got unexpected refcount %ld.\n", ref); ref = get_refcount(pin); @@ -552,7 +552,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_OUTPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"XForm Out"), "Got name %s.\n", wine_dbgstr_w(info.achName)); + ok(!wcscmp(info.achName, L"XForm Out"), "Got name %s.\n", wine_dbgstr_w(info.achName)); IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
Signed-off-by: Zebediah Figura zfigura@codeweavers.com
Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/quartz/tests/videorenderer.c | 2 +- dlls/quartz/videorenderer.c | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/dlls/quartz/tests/videorenderer.c b/dlls/quartz/tests/videorenderer.c index c1a3266197b..282d1ef7b12 100644 --- a/dlls/quartz/tests/videorenderer.c +++ b/dlls/quartz/tests/videorenderer.c @@ -347,7 +347,7 @@ static void test_pin_info(void) ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter); ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir); - todo_wine ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", debugstr_w(info.achName)); + ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", debugstr_w(info.achName)); ref = get_refcount(filter); ok(ref == 3, "Got unexpected refcount %ld.\n", ref); ref = get_refcount(pin); diff --git a/dlls/quartz/videorenderer.c b/dlls/quartz/videorenderer.c index f44ce35dc59..f725a9998ce 100644 --- a/dlls/quartz/videorenderer.c +++ b/dlls/quartz/videorenderer.c @@ -481,6 +481,8 @@ HRESULT video_renderer_create(IUnknown *outer, IUnknown **out) return E_OUTOFMEMORY;
strmbase_renderer_init(&object->renderer, outer, &CLSID_VideoRenderer, L"In", &renderer_ops); + wcscpy(object->renderer.sink.pin.name, L"Input"); + object->IOverlay_iface.lpVtbl = &overlay_vtbl;
video_window_init(&object->window, &IVideoWindow_VTable,
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=111248
Your paranoid android.
=== w1064_tsign (32 bit report) ===
quartz: videorenderer.c:870: Test failed: Wait failed. videorenderer.c:871: Test failed: Got hr 0x103. videorenderer: Timeout
Signed-off-by: Zebediah Figura zfigura@codeweavers.com