amstream: Don't load the stream file. AddSourceFilter does it already.
This commit is contained in:
parent
873c92bed8
commit
682379059f
|
@ -305,7 +305,6 @@ static HRESULT WINAPI IAMMultiMediaStreamImpl_OpenFile(IAMMultiMediaStream* ifac
|
|||
{
|
||||
IAMMultiMediaStreamImpl *This = impl_from_IAMMultiMediaStream(iface);
|
||||
HRESULT ret = S_OK;
|
||||
IFileSourceFilter *SourceFilter = NULL;
|
||||
IBaseFilter *BaseFilter = NULL;
|
||||
IEnumPins *EnumPins = NULL;
|
||||
IPin *ipin;
|
||||
|
@ -320,12 +319,6 @@ static HRESULT WINAPI IAMMultiMediaStreamImpl_OpenFile(IAMMultiMediaStream* ifac
|
|||
if (SUCCEEDED(ret))
|
||||
ret = IGraphBuilder_AddSourceFilter(This->pFilterGraph, pszFileName, pszFileName, &BaseFilter);
|
||||
|
||||
if (SUCCEEDED(ret))
|
||||
ret = IBaseFilter_QueryInterface(BaseFilter, &IID_IFileSourceFilter, (void**)&SourceFilter);
|
||||
|
||||
if (SUCCEEDED(ret))
|
||||
ret = IFileSourceFilter_Load(SourceFilter, pszFileName, NULL);
|
||||
|
||||
if (SUCCEEDED(ret))
|
||||
ret = IBaseFilter_EnumPins(BaseFilter, &EnumPins);
|
||||
|
||||
|
@ -343,8 +336,6 @@ static HRESULT WINAPI IAMMultiMediaStreamImpl_OpenFile(IAMMultiMediaStream* ifac
|
|||
IEnumPins_Release(EnumPins);
|
||||
if (BaseFilter)
|
||||
IBaseFilter_Release(BaseFilter);
|
||||
if (SourceFilter)
|
||||
IFileSourceFilter_Release(SourceFilter);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue