ipa: rkisp1: agc: Read histogram weights from tuning file

Add support to the rkisp1 AGC to read histogram weights from the tuning
file. As controls for selecting the metering mode are not yet supported,
for now hardcode the matrix metering mode, which is the same as what the
AGC previously hardcoded.

Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
Reviewed-by: Stefan Klug <stefan.klug@ideasonboard.com>
Reviewed-by: Daniel Scally <dan.scally@ideasonboard.com>
This commit is contained in:
Paul Elder 2024-03-01 22:16:02 +09:00
parent 1b91725618
commit 35233938ee
2 changed files with 103 additions and 3 deletions

View file

@ -44,11 +44,17 @@ public:
ControlList &metadata) override;
private:
int parseMeteringModes(IPAContext &context, const YamlObject &tuningData);
uint8_t computeHistogramPredivider(Size &size,
enum rkisp1_cif_isp_histogram_mode mode);
void fillMetadata(IPAContext &context, IPAFrameContext &frameContext,
ControlList &metadata);
double estimateLuminance(double gain) const override;
Span<const uint8_t> expMeans_;
std::map<int32_t, std::vector<uint8_t>> meteringModes_;
};
} /* namespace ipa::rkisp1::algorithms */