How to split a mkv(AVC+AAC) file to pure video and audio files by using gst-launch?
t.i.m at zen.co.uk
Fri Nov 25 04:19:44 PST 2011
On Fri, 2011-11-25 at 03:59 -0800, Raymond18 wrote:
> According to your describing, The following command should create a file
> with H.264 data that can be read without a container. But something wrong
> after executing. Do I use a wrong pipeline?
> $ gst-launch-0.10 filesrc location=/home/test.mkv ! matroskademux !
> h264parse ! 'video/x-h264,stream-format=byte-stream' ! filesink
> ERROR: from element /GstPipeline:pipeline0/GstMatroskaDemux:matroskademux0:
> GStreamer encountered a general stream error.
> Additional debug info:
> matroska-demux.c(6090): gst_matroska_demux_loop ():
> stream stopped, reason not-negotiated
it depends a bit on the version of the plugins you're using. The above
works fine for me with git, but the h264parsers have gone through some
changes over time.
With older versions you might have to set the output format via a
property (instead of forcing it via the caps), try these:
.. ! matroskademux ! h264parse output-format=byte ! filesink ...
.. ! matroskademux ! legacyh264parse output-format=byte ! filesink ...
More information about the gstreamer-devel