From c2bfe003e788c2e7cc95fe9b273af0596f5d725f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20S=C3=B6derlund?= Date: Tue, 23 Jun 2020 04:00:26 +0200 Subject: libcamera: formats: Add formats for IPU3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When replacing DRM FourCCs with libcamera formats IPU3 format descriptors where missing resulting in RAW capture not being possible. Fix this by adding the missing descriptors. Fixes: 56c99424edd64c5a ("libcamera: pipeline: Replace explicit DRM FourCCs with libcamera formats") Signed-off-by: Niklas Söderlund Reviewed-by: Laurent Pinchart --- src/libcamera/formats.cpp | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'src') diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp index c0b53ce7..151e7cc0 100644 --- a/src/libcamera/formats.cpp +++ b/src/libcamera/formats.cpp @@ -435,6 +435,34 @@ const std::map pixelFormatInfo{ .colourEncoding = PixelFormatInfo::ColourEncodingRAW, .packed = true, } }, + { formats::SBGGR10_IPU3, { + .format = formats::SBGGR10_IPU3, + .v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_IPU3_SBGGR10), + .bitsPerPixel = 10, + .colourEncoding = PixelFormatInfo::ColourEncodingRAW, + .packed = true, + } }, + { formats::SGBRG10_IPU3, { + .format = formats::SGBRG10_IPU3, + .v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_IPU3_SGBRG10), + .bitsPerPixel = 10, + .colourEncoding = PixelFormatInfo::ColourEncodingRAW, + .packed = true, + } }, + { formats::SGRBG10_IPU3, { + .format = formats::SGRBG10_IPU3, + .v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_IPU3_SGRBG10), + .bitsPerPixel = 10, + .colourEncoding = PixelFormatInfo::ColourEncodingRAW, + .packed = true, + } }, + { formats::SRGGB10_IPU3, { + .format = formats::SRGGB10_IPU3, + .v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_IPU3_SRGGB10), + .bitsPerPixel = 10, + .colourEncoding = PixelFormatInfo::ColourEncodingRAW, + .packed = true, + } }, /* Compressed formats. */ { formats::MJPEG, { -- cgit v1.2.1