Commit fb6c88e2 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

quartz/filtergraph: Don't prevent the same filter from being used multiple times…

quartz/filtergraph: Don't prevent the same filter from being used multiple times in IGraphBuilder_Connect(). This reverts part of 6301fec0. Signed-off-by: 's avatarZebediah Figura <z.figura12@gmail.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent 452dd940
...@@ -1091,7 +1091,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut, ...@@ -1091,7 +1091,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut,
GUID tab[2]; GUID tab[2];
IMoniker* pMoniker; IMoniker* pMoniker;
PIN_INFO PinInfo; PIN_INFO PinInfo;
CLSID FilterCLSID;
PIN_DIRECTION dir; PIN_DIRECTION dir;
IFilterMapper2 *pFilterMapper2 = NULL; IFilterMapper2 *pFilterMapper2 = NULL;
...@@ -1184,15 +1183,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut, ...@@ -1184,15 +1183,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut,
IEnumPins_Release(penumpins); IEnumPins_Release(penumpins);
} }
hr = IPin_QueryPinInfo(ppinIn, &PinInfo);
if (FAILED(hr))
goto out;
hr = IBaseFilter_GetClassID(PinInfo.pFilter, &FilterCLSID);
IBaseFilter_Release(PinInfo.pFilter);
if (FAILED(hr))
goto out;
/* Find the appropriate transform filter than can transform the minor media type of output pin of the upstream /* Find the appropriate transform filter than can transform the minor media type of output pin of the upstream
* filter to the minor mediatype of input pin of the renderer */ * filter to the minor mediatype of input pin of the renderer */
hr = IPin_EnumMediaTypes(ppinOut, &penummt); hr = IPin_EnumMediaTypes(ppinOut, &penummt);
...@@ -1236,7 +1226,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut, ...@@ -1236,7 +1226,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut,
while (IEnumMoniker_Next(pEnumMoniker, 1, &pMoniker, NULL) == S_OK) while (IEnumMoniker_Next(pEnumMoniker, 1, &pMoniker, NULL) == S_OK)
{ {
VARIANT var; VARIANT var;
GUID clsid;
IPin* ppinfilter = NULL; IPin* ppinfilter = NULL;
IBaseFilter* pfilter = NULL; IBaseFilter* pfilter = NULL;
IAMGraphBuilderCallback *callback = NULL; IAMGraphBuilderCallback *callback = NULL;
...@@ -1254,20 +1243,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut, ...@@ -1254,20 +1243,6 @@ static HRESULT WINAPI FilterGraph2_Connect(IFilterGraph2 *iface, IPin *ppinOut,
goto error; goto error;
} }
hr = IBaseFilter_GetClassID(pfilter, &clsid);
if (FAILED(hr))
{
IBaseFilter_Release(pfilter);
goto error;
}
if (IsEqualGUID(&clsid, &FilterCLSID)) {
/* Skip filter (same as the one the output pin belongs to) */
IBaseFilter_Release(pfilter);
pfilter = NULL;
goto error;
}
if (This->pSite) if (This->pSite)
{ {
IUnknown_QueryInterface(This->pSite, &IID_IAMGraphBuilderCallback, (LPVOID*)&callback); IUnknown_QueryInterface(This->pSite, &IID_IAMGraphBuilderCallback, (LPVOID*)&callback);
......
...@@ -1271,6 +1271,7 @@ static ULONG WINAPI testfilter_Release(IBaseFilter *iface) ...@@ -1271,6 +1271,7 @@ static ULONG WINAPI testfilter_Release(IBaseFilter *iface)
static HRESULT WINAPI testfilter_GetClassID(IBaseFilter *iface, CLSID *clsid) static HRESULT WINAPI testfilter_GetClassID(IBaseFilter *iface, CLSID *clsid)
{ {
if (winetest_debug > 1) trace("%p->GetClassID()\n", iface); if (winetest_debug > 1) trace("%p->GetClassID()\n", iface);
memset(clsid, 0xde, sizeof(*clsid));
return S_OK; return S_OK;
} }
......
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