Putting h264 file inside a container

iltaren iltaren at gmail.com
Sun Aug 3 17:02:14 PDT 2014


Thank you for fast answer.

gst-inspect-1.0 matroskamux | grep Version
  Version:              1.0.10

this is the version


giving the frame rate was change nothing,

pi at c01 ~/bin $ gst-launch-1.0 -v filesrc location=test.h264 ! h264parse !
video/x-h264,framerate=20/1 ! matroskamux ! filesink location=test.mkv
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/GstH264Parse:h264parse0.GstPad:src: caps =
video/x-h264, width=(int)1296, height=(int)972, parsed=(boolean)true,
stream-format=(string)avc, alignment=(string)au,
codec_data=(buffer)01640028ffe1000f27640028ac2b402883dfdc03c489a801000528ee05f2c0
ERROR: from element /GstPipeline:pipeline0/GstH264Parse:h264parse0:
GStreamer encountered a general stream error.
Additional debug info:
gstbaseparse.c(3038): gst_base_parse_loop ():
/GstPipeline:pipeline0/GstH264Parse:h264parse0:
streaming stopped, reason not-negotiated
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
Freeing pipeline ...
Freeing pipeline ...


With rpicamsrc
gst-launch-1.0 rpicamsrc vflip=true bitrate=1000000 !
video/x-h264,width=1284,height=972,framerate=20/1 ! h264parse ! matroskamux
! filesink location=test.mkv

with this command it worked , thank you really.

Then i figured plugin dont support quantisation mode, so i think maybe that
could be cause of that problem and i tested with bitrate. same issue when i
give h264 file. So is there a problem with h264 input from file or from
pipe ?

So far thank you, now my only problem is adding quantisation support,
because it is really low file size and good quality. any hint about this ?
or do i need to open raspivid codes and plugin codes and do some dirty
patching ?

Thanks for your fast answer and great support.

Best Regards,
Taylan Karaoğlu



On Mon, Aug 4, 2014 at 1:29 AM, Tim Müller <tim at centricular.com> wrote:

> On Mon, 2014-08-04 at 00:50 +0300, iltaren wrote:
>
> Hi,
>
> >
> >    Sorry probably i am asking really stupid question. But i am new to
> > gstreamer, I try to put h264 file inside matroska container without re
> > encoding.
> >
> > my commands was this
> > raspivid -vf -t 10000 -qp 21 -w 1296 -h 972 -fps 20 -n -ih -o
> > test.h264
> > gst-launch-1.0 -v filesrc location=test.h264 ! h264parse !
> > matroskamux ! filesink location=test.mkv
> > Setting pipeline to PAUSED ...
> > Pipeline is PREROLLING ...
> > /GstPipeline:pipeline0/GstH264Parse:h264parse0.GstPad:src: caps =
> > video/x-h264, width=(int)1296, height=(int)972, parsed=(boolean)true,
> > stream-format=(string)avc, alignment=(string)au,
> >
> codec_data=(buffer)01640028ffe1000f27640028ac2b402883dfdc03c489a801000528ee05f2c0
> > ERROR: from element /GstPipeline:pipeline0/GstH264Parse:h264parse0:
> > GStreamer encountered a general stream error.
> > Additional debug info:
> > gstbaseparse.c(3038): gst_base_parse_loop
> > (): /GstPipeline:pipeline0/GstH264Parse:h264parse0:
> > streaming stopped, reason not-negotiated
> > ERROR: pipeline doesn't want to preroll.
> > Setting pipeline to NULL ...
> > Freeing pipeline ...
> >
> >
> > i didnt understand what is wrong with putting inside container without
> > re enconding. (I tried without -ih flag for raspivid too) . With
> > another program copying stream to container work without problem.
>
> What's the output of
>
>   gst-inspect-1.0 matroskamux | grep Version
>
> ?
>
> Older versions of matroskamux required the framerate field to be present
> on the input video caps, but this was removed some time ago.
>
> You could try this:
>
>    .... h264parse ! video/x-h264,framerate=25/1 ! matroskamux ! ..
>
> or you could build this plugin:
>
> https://github.com/thaytan/gst-rpicamsrc
>
> which is a GStreamer source element that does more or less the same as
> raspivid, but you can feed the output directly to h264parse+matroskamux.
>
> Cheers
>  -Tim
>
> --
> Tim Müller, Centricular Ltd - http://www.centricular.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/20140804/c6299f4f/attachment.html>


More information about the gstreamer-devel mailing list