@@ -969,6 +969,36 @@ const std::map<PixelFormat, PixelFormatInfo> pixelFormatInfo{
.pixelsPerGroup = 2,
.planes = {{ { 2, 1 }, { 0, 0 }, { 0, 0 } }},
} },
+ { formats::RAW10_CRU, {
+ .name = "RAW10_CRU",
+ .format = formats::RAW10_CRU,
+ .v4l2Formats = { V4L2PixelFormat(V4L2_PIX_FMT_RAW_CRU10), },
+ .bitsPerPixel = 10,
+ .colourEncoding = PixelFormatInfo::ColourEncodingRAW,
+ .packed = true,
+ .pixelsPerGroup = 6,
+ .planes = {{ { 8, 1 }, { 0, 0 }, { 0, 0 } }},
+ } },
+ { formats::RAW12_CRU, {
+ .name = "RAW12_CRU",
+ .format = formats::RAW12_CRU,
+ .v4l2Formats = { V4L2PixelFormat(V4L2_PIX_FMT_RAW_CRU12), },
+ .bitsPerPixel = 12,
+ .colourEncoding = PixelFormatInfo::ColourEncodingRAW,
+ .packed = true,
+ .pixelsPerGroup = 5,
+ .planes = {{ { 8, 1 }, { 0, 0 }, { 0, 0 } }},
+ } },
+ { formats::RAW14_CRU, {
+ .name = "RAW14_CRU",
+ .format = formats::RAW14_CRU,
+ .v4l2Formats = { V4L2PixelFormat(V4L2_PIX_FMT_RAW_CRU14), },
+ .bitsPerPixel = 14,
+ .colourEncoding = PixelFormatInfo::ColourEncodingRAW,
+ .packed = true,
+ .pixelsPerGroup = 4,
+ .planes = {{ { 8, 1 }, { 0, 0 }, { 0, 0 } }},
+ } },
/* Compressed formats. */
{ formats::MJPEG, {
.name = "MJPEG",
@@ -209,4 +209,17 @@ formats:
- MONO_PISP_COMP1:
fourcc: DRM_FORMAT_R16
mod: PISP_FORMAT_MOD_COMPRESS_MODE1
+
+ - RAW10_CRU:
+ fourcc: DRM_FORMAT_RAW10
+ mod: RENESAS_CRU_FORMAT_MOD_PACKED
+ - RAW12_CRU:
+ fourcc: DRM_FORMAT_RAW12
+ mod: RENESAS_CRU_FORMAT_MOD_PACKED
+ - RAW14_CRU:
+ fourcc: DRM_FORMAT_RAW14
+ mod: RENESAS_CRU_FORMAT_MOD_PACKED
+ - RAW20_CRU:
+ fourcc: DRM_FORMAT_RAW20
+ mod: RENESAS_CRU_FORMAT_MOD_PACKED
...
Add libcamera formats for the CRU-packed, bayer order agnostic CRU pixel formats that map to the V4L2 Pixel Formats in the kernel header. Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com> --- src/libcamera/formats.cpp | 30 ++++++++++++++++++++++++++++++ src/libcamera/formats.yaml | 13 +++++++++++++ 2 files changed, 43 insertions(+)