Intelligent connect - GraphBuilder connect vs render

1

I have a movie which is represented in a graph as source filter with mediatype MEDIATYPE_Stream/MEDIASUBTYPE_MPEG1Video. Furthermore I insert VMR or EVR into the graph.

Trying to connect (GraphBuilder -> Connect) output pin of source filter to input pin of video renderer fails (0x80040217 - VFW_E_CANNOT_CONNECT). However, rendering the source filter's output pin (GraphBuilder -> Render) succeeds. It inserts the MPEG-2 splitter (NOT the MPEG-2 demuxer). And a decoder of course. But it must be related to the splitter, because when I insert this manually and then try to connect the source filter output pin to the video renderer it works via GraphBuilder -> Connect by making use of the splitter.

The reason why I would like to use Connect instead of Render is, that the video renderer needs a special configuration (custom presenter).

So, on the one hand I'm interested in why "connect" and "render" behave differently. On the other hand I'm seeking advice how to handle this problem.

It probably would be possible to insert the MPEG-2 splitter beforehand by default, but I don't like this. There might be a better suited filter with higher merit that would be ignored. And MSDN says MPEG-2 splitter is deprecated.

Edit: Unfortunately LAVSplitter is no solution as well. It's rather slow in positioning inside the file. And sometimes it seems to play with a reduced rate (burnt in timecode falls back from reported position - rather strange, but that's another story).

directshow
asked on Stack Overflow Aug 30, 2016 by JeffRSon • edited Aug 30, 2016 by JeffRSon

1 Answer

1

MPEG2 Splitter's filter merit is set to "normal - 1", but since it is deprecated, it might not get enumerated during the intelligent connect. On the other hand when you add it manually filter graph uses it during the intelligent connect, because it first tries to utilize the filters already added to the graph. I'm afraid that the only solution in this case for you would be to add the MPEG2 Splitter manually.

answered on Stack Overflow Sep 21, 2016 by VuVirt

User contributions licensed under CC BY-SA 3.0