Skip to content

Commit 0c6ddbc

Browse files
6by9popcornmix
authored andcommitted
BCM2835-V4L2: Correctly denote key frames in encoded data
Forward MMAL key frame flags to the V4L2 buffers. Signed-off-by: Dave Stevenson <[email protected]>
1 parent 357ad58 commit 0c6ddbc

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/media/platform/bcm2835/bcm2835-camera.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,6 +413,9 @@ static void buffer_cb(struct vchiq_mmal_instance *instance,
413413
dev->capture.last_timestamp = buf->vb.vb2_buf.timestamp;
414414

415415
vb2_set_plane_payload(&buf->vb.vb2_buf, 0, length);
416+
if (mmal_flags & MMAL_BUFFER_HEADER_FLAG_KEYFRAME)
417+
buf->vb.flags |= V4L2_BUF_FLAG_KEYFRAME;
418+
416419
v4l2_dbg(1, bcm2835_v4l2_debug, &dev->v4l2_dev,
417420
"Buffer has ts %llu",
418421
dev->capture.last_timestamp);

0 commit comments

Comments
 (0)