mux h264 and wav to mp4

Jesper Larsen knorr.jesper at gmail.com
Wed Oct 21 03:47:38 PDT 2015


mp4mux does not support raw audio. You can see which input/output caps an
element supports using gst-inspect-1.0, i.e.

gst-inspect-1.0 mp4mux

You can perhaps use qtmux instead.

Note that you instantiate two seperate muxers in your pipeline. For the
audio part, you should request a pad from the same muxer you use for the
video.
You should also add the argument "-e" to gst-launch-1.0. This will ensure
that the file is finished properly if you shutdown (i.e. Ctrl+C).

Try something like this

gst-launch-1.0 -e filesrc location="/test/input.h264" ! h264parse ! qtmux
name=mux ! filesink location="/test/output.mp4" filesrc
location="/test/input.wav"
! wavparse ! mux.

Best Regards
Jesper

On Wed, Oct 21, 2015 at 6:20 AM, mouse9093 <mouse9093 at hotmail.com> wrote:

> gst-launch-1.0 filesrc location="/test/input.h264" ! video/x-h264 !
> h264parse
> ! queue ! mp4mux ! filesink location="/test/output.mp4" filesrc
> location="/test/input.wav" ! wavparse ! queue ! mp4mux
>
> Q/Problem
>
> have error, how can I fix this:
>
> Pipeline is PREROLLED ...
>
> Setting pipeline to PLAYING ...
>
> New clock: GstSystemClock
>
> /GstPipeline:pipeline0/GstWavParse:wavparse0.GstPad:src: caps =
> audio/x-raw,
> format=(string)S16LE, layout=(string)interleaved, channels=(int)2,
> channel-mask=(bitmask)0x0000000000000003, rate=(int)44100
>
> ERROR: from element /GstPipeline:pipeline0/GstWavParse:wavparse0: Internal
> data flow error.
>
> Additional debug info:
>
> gstwavparse.c(2468): gst_wavparse_loop
> ():/GstPipeline:pipeline0/GstWavParse:wavparse0:streaming task paused,
> reason not-negotiated (-4)
>
> Execution ended after 0:00:00.011385019
>
> Setting pipeline to PAUSED ...
>
> Setting pipeline to READY ...
>
> Setting pipeline to NULL ...
>
> Freeing pipeline ...
>
> Thanks
>
>
>
> --
> View this message in context:
> http://gstreamer-devel.966125.n4.nabble.com/mux-h264-and-wav-to-mp4-tp4674182.html
> Sent from the GStreamer-devel mailing list archive at Nabble.com.
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20151021/e6ecdb48/attachment.html>


More information about the gstreamer-devel mailing list