Problem with adding elements to a running pipeline

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Problem with adding elements to a running pipeline

Jonathan
Hello,

I'm trying to implement a pipeline which can encode a video stream and at will, trigger the display of the stream without loosing frames in the encoding.

So I made a application out of this prototype :
gst-launch videotestsrc num-buffers=100 ! tee name="splitter" ! queue ! ffmpegcolorspace ! x264enc byte-stream=true ! avimux ! filesink location=videotestsrc.avi splitter. ! queue leaky=1 ! autovideosink

With the branch :
videotestsrc num-buffers=100 ! tee name="splitter" ! queue ! ffmpegcolorspace ! x264enc byte-stream=true ! avimux ! filesink location=videotestsrc.avi
Created at startup

and :
splitter. ! queue leaky=1 ! autovideosink
when an event appears.


I'm able to trigger the "display branch" but I must go through the GST_STATE_READY. By doing so, I will lost frames.

I've already try to create two separate bins with a ghost pad but it doesn't help.
A solution that I haven't tried is to play with blocked pad.
I've already read this document :
http://cgit.freedesktop.org/gstreamer/gstreamer/tree/docs/design/part-block.txt
but I'm not sure where I should block the pad to be as efficient as possible (the final solution will be embedded).

Is it possible to plug this display toolchain to the running encoding ?
Sould I create the "display queue" also on startup and blocked the pad between the splitter and this queue as long as the window is not wanted ?

Thank you,

Jonathan

_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel