Re: GMFBridge problem: how to re-bridge after un-bridge?
- From: Geraint Davies <geraintd@xxxxxxxxxx>
- Date: Tue, 11 Dec 2007 10:22:28 +0000
On Mon, 10 Dec 2007 21:15:32 -0800 (PST), tinh <xuantinh@xxxxxxxxx>
wrote:
On Dec 10, 5:25 pm, Geraint Davies <gerai...@xxxxxxxxxx> wrote:
I think the issue is that after the Bridge(NULL, NULL), the bridge hasI'm afraid I can't do this, I have GMFBridge source code, but it's in
no upstream sink to check the types with -- you can verify this by
setting a breakpoint in the source output CheckMediaType method.
VC++, I use DirectShow.NET with C# in my app. If you know how to setup
this, I'd love to hear it from you.
In the project options in vs2005, under debug, you can set an option
to permit native / unmanaged code debugging and then if you have built
and registered a debug version of gmfbridge you will be able to step
into it.
If you call InsertSourceFilter when there is no current bridge, itHow can I know if there is no bridge in use?
will set the source graph pointer so that the negotiations can
proceed. If you build a graph, call Bridge(NULL, NULL), and then try
to reconnect the sink graph source output pin, the negotiations will
fail.
You create a single bridge controller with a specified number of
streams. Then you can create any number of source and sink filters,
each with the same number of streams, but you can have only a single
source and sink connected to the bridge controller at once. When I
said "when there is no current bridge", I meant that the source and
sink on the bridge controller were both NULL because you have called
Bridge(NULL, NULL).
Do you call InsertSourceFilter each time?Yes, I call this every time I create a new render/capture graph. I
also keep a reference of the sourceGraphSinkFilter from the source
graph to reuse in the InsertSourceFilter method of the
bridgeController.
Hmm. Then I don't understand why the sample works and your code
doesn't. What's the difference between your code and the sample?
One more question, I create the bridge in the discard mode, I also set
the minimum buffer in the bridge controller, will my data be discarded
regardless the minimum buffer, or the bridge just keep the lastest
bits from the stream with the size of the mininum buffer?
In discard mode, when data arrives at the input of the bridge, if
there is no connection to an output graph the data is immediately
discarded. In suspend mode, the Receive call will block at the source
graph sink input pin until the bridge is connected.
The minimum buffer is used in the render graph output pin and is
useful in playback cases. Often the decoder delivers a frame to the
renderer only just before it is needed for rendering. If the decoder
is in the source graph and the renderer is the other side of the
bridge, you do not have much time to switch the source to a different
graph. Increasing the buffering at the bridge means that after the
source graph has reached the end of the clip, there is an increased
buffer in the render graph (200ms perhaps) which can continue to play
out while you connect a new source graph or rewind the existing one.
G
.
- Follow-Ups:
- References:
- GMFBridge problem: how to re-bridge after un-bridge?
- From: tinh
- Re: GMFBridge problem: how to re-bridge after un-bridge?
- From: Geraint Davies
- Re: GMFBridge problem: how to re-bridge after un-bridge?
- From: tinh
- GMFBridge problem: how to re-bridge after un-bridge?
- Prev by Date: Re: Windows CE 6 - DMO registration & instanciation
- Next by Date: Stride Issues & DirectX CAPs
- Previous by thread: Re: GMFBridge problem: how to re-bridge after un-bridge?
- Next by thread: Re: GMFBridge problem: how to re-bridge after un-bridge?
- Index(es):
Relevant Pages
|