Commit a63451ec authored by Youness Alaoui's avatar Youness Alaoui Committed by Sebastian Dröge
Browse files

v4l2src: Add H264 encoded stream support to the caps

This is not enough to properly support H264 cameras, but it will
allow an H264 stream to be generated by v4l2src using the default
settings of the camera. If used with the pre-set-format signal, the
H264 encoder can be fully configured.


parent 06d64c77
......@@ -880,6 +880,8 @@ static const GstV4L2FormatDesc gst_v4l2_formats[] = {
{V4L2_PIX_FMT_H264, TRUE},
/* Vendor-specific formats */
......@@ -1199,6 +1201,9 @@ gst_v4l2_object_v4l2fourcc_to_structure (guint32 fourcc)
case V4L2_PIX_FMT_HI240: /* 8 8-bit color */
/* FIXME: get correct fourccs here */
case V4L2_PIX_FMT_H264: /* H.264 */
structure = gst_structure_new ("video/x-h264", NULL);
case V4L2_PIX_FMT_RGB332:
case V4L2_PIX_FMT_RGB555X:
case V4L2_PIX_FMT_RGB565X:
......@@ -1471,6 +1476,8 @@ gst_v4l2_object_get_caps_info (GstV4l2Object * v4l2object, GstCaps * caps,
fourcc = V4L2_PIX_FMT_DV;
} else if (g_str_equal (mimetype, "image/jpeg")) {
fourcc = V4L2_PIX_FMT_JPEG;
} else if (g_str_equal (mimetype, "video/x-h264")) {
fourcc = V4L2_PIX_FMT_H264;
#ifdef V4L2_PIX_FMT_SBGGR8
} else if (g_str_equal (mimetype, "video/x-bayer")) {
fourcc = V4L2_PIX_FMT_SBGGR8;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment