[gst-devel] Stopping playback

Christoffer Nyborg christoffer.nyborg at gmail.com
Thu Feb 8 22:16:32 CET 2007


Hi again, thanks for the reply.

On 2/8/07, Stefan Kost <ensonic at hora-obscura.de> wrote:
>
> hi,
> Christoffer Nyborg wrote:
> > Hi
> >
> > I'm writing an application where I might need to interrupt playback.
> > From what I've read I'm supposed to change the state with
> > gst_element_set_state (pipeline, GST_STATE_NULL);
> > but I'm unable to because
> > g_main_loop_run (loop);
> > is blocking. How can I solve this? Can I throw the call
> > g_main_loop_run (loop);
> > into another thread or something?
> >
> Once the mainloop run, all signal handlers will be triggered. E.g. if you
> run a
> UI, you can do the
> gst_element_set_state (pipeline, GST_STATE_NULL);
> call, when the user presses a button. If you do a commandline application,
> you
> have to handle that on your own.


Yes, because I'm developing a command line application that is my problem, I
don't know how to handle it.
If anyone have a suggestion I'd greatly appreciate it.

>
> > Regards
> > Christoffer Nyborg
> >
> Stefan
>

Regards
Christoffer Nyborg
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20070208/a88dc9b1/attachment.htm>


More information about the gstreamer-devel mailing list