Commit c56dc3b7 authored by Paul Chitescu's avatar Paul Chitescu Committed by Alexandre Julliard

qedit: In output pin's IPin_Connect call ReceiveConnection on the receiver pin…

qedit: In output pin's IPin_Connect call ReceiveConnection on the receiver pin to properly negotiate media type.
parent 2b1ff010
......@@ -988,6 +988,7 @@ static HRESULT WINAPI
SampleGrabber_Out_IPin_Connect(IPin *iface, IPin *receiver, const AM_MEDIA_TYPE *type)
{
SG_Pin *This = (SG_Pin *)iface;
HRESULT hr;
TRACE("(%p)->(%p, %p)\n", This, receiver, type);
if (!receiver)
return E_POINTER;
......@@ -1011,6 +1012,11 @@ SampleGrabber_Out_IPin_Connect(IPin *iface, IPin *receiver, const AM_MEDIA_TYPE
!IsEqualGUID(&This->sg->mtype.formattype,&type->formattype))
return VFW_E_TYPE_NOT_ACCEPTED;
}
else
type = &This->sg->mtype;
hr = IPin_ReceiveConnection(receiver,(IPin*)&This->lpVtbl,type);
if (FAILED(hr))
return hr;
This->pair = receiver;
if (This->sg->memOutput) {
IMemInputPin_Release(This->sg->memOutput);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment