DirectSho GMFBridge not working as expected
Posted
by
user1327407
on Stack Overflow
See other posts from Stack Overflow
or by user1327407
Published on 2012-09-28T15:36:29Z
Indexed on
2012/09/28
15:37 UTC
Read the original article
Hit count: 523
.NET
|directshow
I am trying to understand why wont the source filter connect with VMR9?
mediaController.InsertSourceFilter(sinkFilter, m_pRenderGraph, out sourceFilter);
var vmr = new VideoMixingRenderer9();
m_pRenderGraph.AddFilter(vmr as IBaseFilter, "VMR");
IBaseFilter vmrBase = FilterGraphTools.FindFilterByClsid(m_pRenderGraph, Clsid.VideoMixingRenderer9);
IVMRFilterConfig9 xd = vmrBase as IVMRFilterConfig9;
if (xd != null)
{
int status = xd.SetRenderingMode(VMR9Mode.Windowless);
}
FilterGraphTools.ConnectFilters(m_pRenderGraph, sourceFilter, vmrBase, true);
mediaController.BridgeGraphs(sinkFilter, sourceFilter);
Without going into too much detail:
- Line „ConnectFilters“ fails because no intermediate filters are found to make that connection work.
- When trying to debug, I can clearly see that Source filter is not spitting out anything useful. (It’s like that the sink<-->source transfer never works), so that’s why it wont connect.
- However, when I get source filter „Output 1“ pin, and then use myGraph.Render(source_output_pin), it works. Data is being sent from sink to source and everything connects automatically. However the problem is that the wrong VMR is inserted there. It’s VMR Renderer. I would like to have VMR9, that’s why im doing it. Why wont it work with VMR9 and why does source filter not show correct media type.
Thank you.
© Stack Overflow or respective owner