mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 10:11:08 +00:00
rpicamsrc: mark buffers as header and keyframe/delta-unit
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/682>
This commit is contained in:
parent
9588108d6e
commit
987a332076
1 changed files with 7 additions and 0 deletions
|
@ -989,6 +989,13 @@ raspi_capture_fill_buffer(RASPIVID_STATE *state, GstBuffer **bufp,
|
|||
/* FIXME: Can we avoid copies and give MMAL our own buffers to fill? */
|
||||
gst_buffer_fill(buf, 0, buffer->data, buffer->length);
|
||||
|
||||
if ((buffer->flags & MMAL_BUFFER_HEADER_FLAG_CONFIG))
|
||||
GST_BUFFER_FLAG_SET (buf, GST_BUFFER_FLAG_HEADER);
|
||||
else if ((buffer->flags & MMAL_BUFFER_HEADER_FLAG_KEYFRAME))
|
||||
GST_BUFFER_FLAG_UNSET (buf, GST_BUFFER_FLAG_DELTA_UNIT);
|
||||
else
|
||||
GST_BUFFER_FLAG_SET (buf, GST_BUFFER_FLAG_DELTA_UNIT);
|
||||
|
||||
/* NAL_END is bogus and can't be trusted */
|
||||
if ((buffer->flags & MMAL_BUFFER_HEADER_FLAG_FRAME_END))
|
||||
ret = GST_FLOW_OK;
|
||||
|
|
Loading…
Reference in a new issue