libcamera/include
Umang Jain 4aa71c2cd2 libcamera: color_space: Move color space adjustment to ColorSpace class
The CameraConfiguration::validateColorSpaces() function performs color
space validation on a camera configuration, by validating the color
space of each stream individually, and optionally ensuring that all
streams share the same color space. The individual validation is very
basic, limited to ensuring that raw formats use a raw color space.

Color spaces are more constrained than that:

- The Y'CbCr encoding and quantization range for RGB formats must be
  YcbcrEncoding::None and Range::Full respectively.
- The Y'CbCr encoding for YUV formats must not be YcbcrEncoding::None.

Instead of open-coding these constraints in the validateColorSpaces()
function, create a new ColorSpace::adjust() function to centralize color
space validation and adjustment, and use it in validateColorSpaces().

Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Umang Jain <umang.jain@ideasonboard.com>
Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
2022-09-01 16:49:59 +05:30
..
android android: Update Android headers 2021-05-31 19:26:59 +03:00
libcamera libcamera: color_space: Move color space adjustment to ColorSpace class 2022-09-01 16:49:59 +05:30
linux include: linux: Add V4L2 subdev internal routing API 2022-08-03 17:00:46 +03:00
meson.build libcamera: Fix base and ipa include dir 2021-09-28 20:09:39 +03:00