]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
media: v4l: doc: Clarify v4l2_mbus_fmt height definition
authorKieran Bingham <kieran.bingham@ideasonboard.com>
Mon, 8 Jan 2018 17:55:23 +0000 (12:55 -0500)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Mon, 26 Feb 2018 13:15:50 +0000 (08:15 -0500)
The v4l2_mbus_fmt width and height corresponds directly with the
v4l2_pix_format definitions, yet the differences in documentation make
it ambiguous what to do in the event of field heights.

Clarify this using the same text as is provided for the v4l2_pix_format
which is explicit on the matter, and by matching the terminology of
'image height' rather than the misleading 'frame height'.

Signed-off-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Documentation/media/uapi/v4l/subdev-formats.rst
include/uapi/linux/v4l2-mediabus.h

index b1eea44550e1f4562bc1fc90d87702dde27302d7..9fcabe7f9367ee5be82fa6f4a8fe5f92de2b46b6 100644 (file)
@@ -16,10 +16,14 @@ Media Bus Formats
 
     * - __u32
       - ``width``
-      - Image width, in pixels.
+      - Image width in pixels.
     * - __u32
       - ``height``
-      - Image height, in pixels.
+      - Image height in pixels. If ``field`` is one of ``V4L2_FIELD_TOP``,
+       ``V4L2_FIELD_BOTTOM`` or ``V4L2_FIELD_ALTERNATE`` then height
+       refers to the number of lines in the field, otherwise it refers to
+       the number of lines in the frame (which is twice the field height
+       for interlaced formats).
     * - __u32
       - ``code``
       - Format code, from enum
index 6e20de63ec59a34c37975741d10eac212d8237ac..123a231001a848c0ed60b6466dc7118d3704205a 100644 (file)
@@ -18,8 +18,8 @@
 
 /**
  * struct v4l2_mbus_framefmt - frame format on the media bus
- * @width:     frame width
- * @height:    frame height
+ * @width:     image width
+ * @height:    image height
  * @code:      data format code (from enum v4l2_mbus_pixelcode)
  * @field:     used interlacing type (from enum v4l2_field)
  * @colorspace:        colorspace of the data (from enum v4l2_colorspace)