If I have a pipeline like:
gst-launch filesrc location="/home/dk/Music/Vangelis - Alpha.mp3" !
decodebin2 name=dec !
queue ! ffmpegcolorspace ! autovideosink dec. !
queue ! audioconvert ! audioresample ! autoaudiosink
How to I get it to play when there is no video in the input source, but play video if there is? All I get is:
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
You can just set autovideosink's async-handling
property to true:
... ! autovideosink async-handling=true
This will allow audiosink to play sound while videosink is waiting.
Its a one kind of bug of decodebin2
see i have tested some pipelines and get to know following things
pipeline1:
gst-launch filesrc location="filename" !
decodebin2 name=dec !
queue ! ffmpegcolorspace ! autovideosink dec. !
queue ! audioconvert ! audioresample ! autoaudiosink
this pipeline1 works fine with all container formats like .mkv,.mp4,ogg
but when you give codec extencion file then it create problem which you have said
i have tested it with .h264 file
pipeline2:
gst-launch filesrc location="smal.h264" ! decodebin2 name=dec ! queue !
autovideosink dec. ! queue ! autoaudiosink
pipeline3:
gst-launch filesrc location="smal.aac" ! decodebin2 name=dec ! queue !
autovideosink dec. ! queue ! autoaudiosink
all has same problem they are unable to preloading ahaead and unable to showing error of invalid pad connection
if you try only single valid pad connection then they works fine
pipeline4:
gst-launch filesrc location="smal.h264" ! decodebin2 ! autovideosink
pipeline5:
gst-launch filesrc location="smal.aac" ! decodebin2 ! autoaudiosink
pipeline 4 and 5 works fine
even
gst-launch filesrc location="/home/dk/Music/Vangelis - Alpha.mp3" !
decodebin2 ! audioconvert ! audioresample ! autoaudiosink
this will also works fine....
Now to understand this bug more and fixing it we need to study and change decodebin2 source code.........>!!!!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With