diff options
Diffstat (limited to 'src/ipa/rkisp1/algorithms/awb.h')
-rw-r--r-- | src/ipa/rkisp1/algorithms/awb.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/ipa/rkisp1/algorithms/awb.h b/src/ipa/rkisp1/algorithms/awb.h index 9d45a442..02651cc7 100644 --- a/src/ipa/rkisp1/algorithms/awb.h +++ b/src/ipa/rkisp1/algorithms/awb.h @@ -2,11 +2,16 @@ /* * Copyright (C) 2021-2022, Ideas On Board * - * awb.h - AWB control algorithm + * AWB control algorithm */ #pragma once +#include "libcamera/internal/vector.h" + +#include "libipa/awb.h" +#include "libipa/interpolator.h" + #include "algorithm.h" namespace libcamera { @@ -19,20 +24,24 @@ public: Awb(); ~Awb() = default; + int init(IPAContext &context, const YamlObject &tuningData) override; int configure(IPAContext &context, const IPACameraSensorInfo &configInfo) override; void queueRequest(IPAContext &context, const uint32_t frame, IPAFrameContext &frameContext, const ControlList &controls) override; void prepare(IPAContext &context, const uint32_t frame, IPAFrameContext &frameContext, - rkisp1_params_cfg *params) override; + RkISP1Params *params) override; void process(IPAContext &context, const uint32_t frame, IPAFrameContext &frameContext, const rkisp1_stat_buffer *stats, ControlList &metadata) override; private: - uint32_t estimateCCT(double red, double green, double blue); + RGB<double> calculateRgbMeans(const IPAFrameContext &frameContext, + const rkisp1_cif_isp_awb_stat *awb) const; + + std::unique_ptr<AwbAlgorithm> awbAlgo_; bool rgbMode_; }; |