[gst-devel] Re : Setting different states for subpipelines

Albert Costa costa_albert at yahoo.fr
Mon Dec 1 14:10:45 CET 2008


Thanks Yann,
I've done some testing, but none gave satisfaction up to now.. 
Basically what I tried is as follows (with different variations):
-set main pipeline to pause,
-lock state for filesrc1 
-set pipeline to ready
-change the filesrc2 location to new file, and set its seek event
-unlock state for filesrc1
-set pipeline to ready

What I usually end up with, is the program hanging for a state change, or a video freeze...
Any hint on good practices to follow?
Regards,
Al


________________________________
De : Yann Gilquin <ygilquin.dev at gmail.com>
À : Discussion of the development of GStreamer <gstreamer-devel at lists.sourceforge.net>
Envoyé le : Mercredi, 26 Novembre 2008, 10h43mn 52s
Objet : Re: [gst-devel] Setting different states for subpipelines

Hi Albert,
maybe gst_element_set_locked_state could be an entry point to solve your problem. It basically removes state dependency with the parent.

Yann Gilquin



2008/11/26 Albert Costa <costa_albert at yahoo.fr>

Hi gstreamer-devels,
I have a question concerning the change of states in the pipeline. 
I have my main pipeline containing 2 video branches:

(subpipeline1): filesrc1 - decodebin1 - ffmpegcolorspace1 - directdrawsink1
(subpipeline2): filesrc2 - decodebin2 - ffmpegcolorspace2 - directdrawsink2

I start each line with a different file and am able now to set a seek for each (thanks to previous gst-devel help). These 2 lines are supposed to run synchronously (the files are played in parallel). My problem now is that when one of the file ends (end of seek reached), I need to set a new file (with a new seek). To do this, I set my main pipeline to state READY, then set the new file name and seek in my branch and then set the state back to PLAYING. But doing so, the other subpipeline looses its position and starts over the file it was playing. I tried therefore to set the main pipeline to PAUSED, then only the subpipeline to be changed in READY (then i set its new file), and finally PLAYING again. But I can't have it working... Is it possible to have different subparts of the main pipeline in different states, or am I just going wrong direction?
Regards,
Al

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
gstreamer-devel mailing list
gstreamer-devel at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel


      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20081201/fcf134c8/attachment.htm>


More information about the gstreamer-devel mailing list