[Bug 775962] Occassional addition of codec_data to caps when stream-format: byte-stream

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon Dec 12 15:25:23 UTC 2016


https://bugzilla.gnome.org/show_bug.cgi?id=775962

--- Comment #5 from minfrin at sharp.fm ---
I tried as follows:

diff --git a/omx/gstomxh264enc.c b/omx/gstomxh264enc.c
index aa33ae5..1996610 100644
--- a/omx/gstomxh264enc.c
+++ b/omx/gstomxh264enc.c
@@ -546,6 +595,16 @@ gst_omx_h264_enc_handle_output_frame (GstOMXVideoEnc *
enc, GstOMXPort * port,
   GstOMXH264Enc *self = GST_OMX_H264_ENC (enc);

   if (buf->omx_buf->nFlags & OMX_BUFFERFLAG_CODECCONFIG) {
+
+    if (buf->omx_buf->nFilledLen >= 4) {
+      GST_ERROR_OBJECT (self, "OMX_BUFFERFLAG_CODECCONFIG: length %d, bytes
%08x", buf->omx_buf->nFilledLen, GST_READ_UINT32_BE (buf->omx_buf->pBuffer +
+              buf->omx_buf->nOffset));
+    }
+    else {
+      GST_ERROR_OBJECT (self, "OMX_BUFFERFLAG_CODECCONFIG: length %d",
buf->omx_buf->nFilledLen);
+    }
+
+
     /* The codec data is SPS/PPS with a startcode => bytestream stream format
      * For bytestream stream format the SPS/PPS is only in-stream and not
      * in the caps!

And got results as follows:

0:06:56.050027453 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 9, bytes 00000001
0:06:56.072296135 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 19, bytes 00000001
0:06:56.072925658 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 9, bytes 00000001
0:06:56.111636218 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 19, bytes 00000001
0:06:56.112307095 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 9, bytes 00000001
0:06:56.131532481 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 12, bytes 00000001
0:06:56.132180754 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 7, bytes 09361803

// we're definitely not 00000001, and therefore...

/GstPipeline:pipeline0/GstTranscoder:transcoder/GstEncodeBin:encodebin0/GstOMXH264Enc-omxh264enc:omxh264enc-omxh264enc0.GstPad:src:
caps = video/x-h264, stream-format=(string)byte-stream, alignment=(string)au,
profile=(string)high, level=(string)4, width=(int)544, height=(int)576,
pixel-aspect-ratio=(fraction)64/33, framerate=(fraction)25/1,
codec_data=(buffer)09361803c489a8, interlace-mode=(string)progressive,
colorimetry=(string)bt601, chroma-site=(string)jpeg
/GstPipeline:pipeline0/GstTranscoder:transcoder/GstEncodeBin:encodebin0/GstStreamCombiner:streamcombiner0.GstPad:src:
caps = video/x-h264, stream-format=(string)byte-stream, alignment=(string)au,
profile=(string)high, level=(string)4, width=(int)544, height=(int)576,
pixel-aspect-ratio=(fraction)64/33, framerate=(fraction)25/1,
codec_data=(buffer)09361803c489a8, interlace-mode=(string)progressive,
colorimetry=(string)bt601, chroma-site=(string)jpeg
0:06:56.134679004 24259 0x73fe0920 ERROR             omxh264enc
gstomxh264enc.c:601:gst_omx_h264_enc_handle_output_frame:<omxh264enc-omxh264enc0>
OMX_BUFFERFLAG_CODECCONFIG: length 9, bytes 00000001
/GstPipeline:pipeline0/GstTranscoder:transcoder/GstEncodeBin:encodebin0/GstStreamCombiner:streamcombiner0.GstStreamCombinerPad:encodingsink:
caps = video/x-h264, stream-format=(string)byte-stream, alignment=(string)au,
profile=(string)high, level=(string)4, width=(int)544, height=(int)576,
pixel-aspect-ratio=(fraction)64/33, framerate=(fraction)25/1,
codec_data=(buffer)09361803c489a8, interlace-mode=(string)progressive,
colorimetry=(string)bt601, chroma-site=(string)jpeg
ERROR: from element
/GstPipeline:pipeline0/GstTranscoder:transcoder/GstEncodeBin:encodebin0/GstOMXH264Enc-omxh264enc:omxh264enc-omxh264enc0:
Internal data stream error.
Additional debug info:
gstomxvideoenc.c(845): gst_omx_video_enc_loop ():
/GstPipeline:pipeline0/GstTranscoder:transcoder/GstEncodeBin:encodebin0/GstOMXH264Enc-omxh264enc:omxh264enc-omxh264enc0:
stream stopped, reason not-negotiated
Execution ended after 0:06:55.163305257
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list