openwrt/target/linux/bcm27xx/patches-5.15/950-0754-staging-vc04_servi...

31 lines
1.1 KiB
Diff

From 64bab887e1861c3db19a37cfab41a45e296e2cc1 Mon Sep 17 00:00:00 2001
From: David Plowman <david.plowman@raspberrypi.com>
Date: Mon, 7 Mar 2022 10:00:33 +0000
Subject: [PATCH] staging: vc04_services: codec: Add support for
V4L2_PIX_FMT_RGBA32 format
We already support V4L2_PIX_FMT_BGR32 which is the same thing with red
and blue swapped, so it makes sense to include this variant as well.
Signed-off-by: David Plowman <david.plowman@raspberrypi.com>
---
.../vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c | 7 +++++++
1 file changed, 7 insertions(+)
--- a/drivers/staging/vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c
+++ b/drivers/staging/vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c
@@ -241,6 +241,13 @@ static const struct bcm2835_codec_fmt su
.mmal_fmt = MMAL_ENCODING_BGRA,
.size_multiplier_x2 = 2,
}, {
+ .fourcc = V4L2_PIX_FMT_RGBA32,
+ .depth = 32,
+ .bytesperline_align = { 32, 32, 32, 32 },
+ .flags = 0,
+ .mmal_fmt = MMAL_ENCODING_RGBA,
+ .size_multiplier_x2 = 2,
+ }, {
/* Bayer formats */
/* 8 bit */
.fourcc = V4L2_PIX_FMT_SRGGB8,