Skip to contentSkip to conversation

Generic line based metadata support

RFC New Sakari Ailus 1 participant 3 messages Aug 24, 2023 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

cover Generic line based metadata support

Hi folks,

This set adds the generic line based metadata support for yavta. Untested, hence posting this as RFC.

Sakari Ailus (2):
Update kernel headers
Add support for generic metadata formats

 include/linux/v4l2-common.h   |   39 -
 include/linux/v4l2-controls.h | 1545 ++++++++++++++++++++++++++++++++-
 include/linux/videodev2.h     |  102 ++-
 yavta.c                       |   10 +
 4 files changed, 1611 insertions(+), 85 deletions(-)
Signature · 1 line
2.39.2
#1 lore raw

RFC 1/2 Update kernel headers

Update kernel headers to v6.5 media tree + metadata patches.

---
 include/linux/v4l2-common.h   |   39 -
 include/linux/v4l2-controls.h | 1545 ++++++++++++++++++++++++++++++++-
 include/linux/videodev2.h     |  102 ++-
 3 files changed, 1601 insertions(+), 85 deletions(-)
include/linux/v4l2-common.h +0 -39
index 14de1731b39c..c3ca11e3e2e0 100644
@@ -10,45 +10,6 @@
  *
  * Copyright (C) 2012 Nokia Corporation
  * Contact: Sakari Ailus <[email protected]>
- *
- *  This program is free software; you can redistribute it and/or modify
- *  it under the terms of the GNU General Public License as published by
- *  the Free Software Foundation; either version 2 of the License, or
- *  (at your option) any later version.
- *
- *  This program is distributed in the hope that it will be useful,
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- *  GNU General Public License for more details.
- *
- *  Alternatively you can redistribute this file under the terms of the
- *  BSD license as stated below:
- *
- *  Redistribution and use in source and binary forms, with or without
- *  modification, are permitted provided that the following conditions
- *  are met:
- *  1. Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer.
- *  2. Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in
- *     the documentation and/or other materials provided with the
- *     distribution.
- *  3. The names of its contributors may not be used to endorse or promote
- *     products derived from this software without specific prior written
- *     permission.
- *
- *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- *  "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- *  LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- *  A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- *  OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- *  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
- *  TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- *  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
- *  LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
- *  NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- *  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
  */
 
 #ifndef __V4L2_COMMON__
include/linux/v4l2-controls.h +1503 -42

1,616 lines not on this page · raw message

include/linux/videodev2.h +98 -4

250 lines not on this page · raw message

Signature · 1 line
2.39.2
#2 lore raw

RFC 2/2 Add support for generic metadata formats

In reply to Sakari Ailus
---
 yavta.c | 10 ++++++++++
 1 file changed, 10 insertions(+)
yavta.c +10 -0
index d5628632c1f8..fb91b146a6c7 100644
@@ -278,6 +278,7 @@ static struct v4l2_format_info {
 	unsigned int fourcc;
 	unsigned char n_planes;
 } pixel_formats[] = {
+	/* Pixel data formats */
 	{ "RGB332", V4L2_PIX_FMT_RGB332, 1 },
 	{ "RGB444", V4L2_PIX_FMT_RGB444, 1 },
 	{ "ARGB444", V4L2_PIX_FMT_ARGB444, 1 },
@@ -359,6 +360,15 @@ static struct v4l2_format_info {
 	{ "DV", V4L2_PIX_FMT_DV, 1 },
 	{ "MJPEG", V4L2_PIX_FMT_MJPEG, 1 },
 	{ "MPEG", V4L2_PIX_FMT_MPEG, 1 },
+	/* Metadata formats */
+	{ "GENERIC_8", V4L2_META_FMT_GENERIC_8, 1 },
+	{ "GENERIC_CSI2_10", V4L2_META_FMT_GENERIC_CSI2_10, 1 },
+	{ "GENERIC_CSI2_12", V4L2_META_FMT_GENERIC_CSI2_12, 1 },
+	{ "GENERIC_CSI2_14", V4L2_META_FMT_GENERIC_CSI2_14, 1 },
+	{ "GENERIC_CSI2_16", V4L2_META_FMT_GENERIC_CSI2_16, 1 },
+	{ "GENERIC_CSI2_20", V4L2_META_FMT_GENERIC_CSI2_20, 1 },
+	{ "GENERIC_CSI2_24", V4L2_META_FMT_GENERIC_CSI2_24, 1 },
+	{ "GENERIC_CSI2_2_24", V4L2_META_FMT_GENERIC_CSI2_2_24, 1 },
 };
 
 static void list_formats(void)
Signature · 1 line
2.39.2