How to play two videos at the same time with gstreamer?

1.9k views Asked by At

I want to play two videos at the same time with gstreamer.But I have no idea with it.I use playbin2 as the pipeline,xvimagesink as the sink element.Now I want this pipeline to play two videos.Any solutions?

3

There are 3 answers

0
thiagoss On

You can't do that with playbin2, either use multiple playbin2 or create your own pipeline with multiple uridecodebin and link that to multiple sinks.

Also, gstreamer 0.10 is obsolete. Please move to the latest 1.0 version (currently 1.2.4)

0
Prasanth Kumar Arisetti On

For playing two videos you can use videomixer and videobox components. Advantage of these components is , both of the two videos will be played in a single window.

Or

You can use two sinks for those two videos, then those will be played in two different windows.

0
Sam On

gst-launch-1.0 videotestsrc ! video/x-raw,width=160,height=120 ! m.sink_0 \ videotestsrc ! video/x-raw,width=160,height=120 ! m.sink_1 \ videomixer name=m sink_1::xpos=160 ! video/x-raw,width=320,height=120 ! xvimagesink