Reputation: 101
I would like to create a gstreamer pipeline to play two mp4 videos back to back. is it possible to play using gst-launch? can I use multifilesrc for this purpose ?
Please show me path to play two videos back to back.
Thanks in advance !
Upvotes: 0
Views: 4585
Reputation: 1143
There isn't really a way to do this using a single gst-launch command. The video decoder sends an end of stream event after the first video ends when you use multifilesrc.
If you are dead set on using gst-launch, you can wrap two gst-launch commands in a shell script:
#!/bin/sh
file1=$1
file2=$2
gst-launch filesrc location="$file1" ! decodebin2 ! autovideosink
gst-launch filesrc location="$file2" ! decodebin2 ! autovideosink
Another way to do this is to write a simple GStreamer application in C to create a pipeline for the first video, play it, create a new pipeline for the second application, and play that.
See the GStreamer application developers guide: http://gstreamer.freedesktop.org/data/doc/gstreamer/head/manual/html/
The section Hello World contains a functional example pipeline which I think would make a good starting point for you.
Upvotes: 2