From df7b9826d7522b7328069c9765e6ba646a050a5e Mon Sep 17 00:00:00 2001 From: Quentin Schulz Date: Thu, 12 May 2022 10:42:43 +0200 Subject: ipa: rkisp1: awb: Add support for RGB means RkISP actually supports two modes for color means, RGB and YCbCr. The variables where the means are stored are identically named regardless of the color means mode that's been selected. Since the gains are computed in RGB mode, a conversion needs to be done when the mode is YCbCr, which is unnecessary when RGB mode is selected. This adds support for RGB means mode too, by checking at runtime which mode is selected at a given time. The default is still set to YCbCr mode for now. Cc: Quentin Schulz Signed-off-by: Quentin Schulz Signed-off-by: Laurent Pinchart Reviewed-by: Kieran Bingham Reviewed-by: Jacopo Mondi --- src/ipa/rkisp1/algorithms/awb.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/ipa/rkisp1/algorithms/awb.h') diff --git a/src/ipa/rkisp1/algorithms/awb.h b/src/ipa/rkisp1/algorithms/awb.h index 6d4a3946..d76b5382 100644 --- a/src/ipa/rkisp1/algorithms/awb.h +++ b/src/ipa/rkisp1/algorithms/awb.h @@ -16,7 +16,7 @@ namespace ipa::rkisp1::algorithms { class Awb : public Algorithm { public: - Awb() = default; + Awb(); ~Awb() = default; int configure(IPAContext &context, const IPACameraSensorInfo &configInfo) override; @@ -32,6 +32,8 @@ public: private: uint32_t estimateCCT(double red, double green, double blue); + + bool rgbMode_; }; } /* namespace ipa::rkisp1::algorithms */ -- cgit v1.2.1