Hi Tim,<br><br>Thank you for the quick and precise answers. <br><br>I have another fundamental question. When should I use g_signal_x or gst_message_x in my plug-in to emit a signal? I guess only difference at the application is handling the signal at specific callback function or bus message handler. <br>
<br>The gstreamer app. developers' guide said, bus message passing is asynchronous to pipeline. Which means time critical operation should not be controlled through bus messages. Then, what about the g_signal_ ? Does it guarantee the synchronization between pipeline and application? (execute a callback function within the pipeline thread?)<br>
<br>I am very new to linux and gobject programing. Please teach me.<br><br>Thank you,<br>Jusitn<br><br><br><br><br><div class="gmail_quote">On Thu, Jun 25, 2009 at 1:31 AM, Tim-Philipp Müller <span dir="ltr"><<a href="mailto:t.i.m@zen.co.uk">t.i.m@zen.co.uk</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">On Wed, 2009-06-24 at 17:27 -0700, joh wrote:<br>
<br>
Hi,<br>
<div class="im"><br>
> I am writing a plugin which processes multiple streams upon request of<br>
> application.<br>
><br>
> For example, my plugin has a list which contains three video streams.<br>
> Initially, the plugin processes one stream, but not all of them. When<br>
</div>> my application "some how" requests other streams to the plugin, then<br>
<div class="im">> it should start to running the other streams.<br>
<br>
</div>It sounds like request pads might be what you're looking for. You should<br>
be able to add/remove request sink pads while the pipeline is running if<br>
implemented properly. tee, adder and videomixer support that, for<br>
example (IIRC).<br>
<div class="im"><br>
<br>
> Here is the question: how can I let the plugin start to work while<br>
> main pipeline is running?<br>
> I was thinking about the way setting a property, so that it triggers<br>
> the action. However, the property is not supposed to be used for this<br>
> purpose. Right? Are there better ways to do this?<br>
<br>
</div>It depends. You could use it for this purpose (it could be an 'active<br>
streams' bitmask, for example, which isn't really much different from<br>
setting the active audio stream in playbin via a property).<br>
<br>
An alternative are 'action signals' where the app/caller uses<br>
g_signal_emit_by_name (element, "do-something", arguments) -<br>
appsrc/appsink in -base and camerabin in -bad use these to trigger<br>
certain actions, for example.<br>
<br>
If it's a static plugin/element that is part of your application (and<br>
not installed into the system gstreamer plugin directory) then you may<br>
just as well expose API/functions to control it directly though. Nothing<br>
wrong with that IMHO.<br>
<br>
Cheers<br>
-Tim<br>
<br>
<br>
<br>
------------------------------------------------------------------------------<br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.sourceforge.net">gstreamer-devel@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br>
</blockquote></div><br>