Signed-off-by: Zebediah Figura z.figura12@gmail.com --- dlls/qcap/vfwcapture.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/dlls/qcap/vfwcapture.c b/dlls/qcap/vfwcapture.c index f0a985d5f4b..5c1ce9af980 100644 --- a/dlls/qcap/vfwcapture.c +++ b/dlls/qcap/vfwcapture.c @@ -344,8 +344,14 @@ static HRESULT WINAPI AMStreamConfig_GetFormat(IAMStreamConfig *iface, AM_MEDIA_ if (!(*mt = CoTaskMemAlloc(sizeof(**mt)))) return E_OUTOFMEMORY;
- if (SUCCEEDED(hr = capture_funcs->get_format(filter->device, *mt))) + EnterCriticalSection(&filter->filter.csFilter); + + if (filter->source.pin.peer) + hr = CopyMediaType(*mt, &filter->source.pin.mt); + else if (SUCCEEDED(hr = capture_funcs->get_format(filter->device, *mt))) strmbase_dump_media_type(*mt); + + LeaveCriticalSection(&filter->filter.csFilter); return hr; }