libcamera v0.7.2+rpt20260817
Supporting cameras in Linux since 2019
Loading...
Searching...
No Matches
awb_grey.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: LGPL-2.1-or-later */
2/*
3 * Copyright (C) 2024 Ideas on Board Oy
4 *
5 * AWB grey world algorithm
6 */
7
8#pragma once
9
10#include <optional>
11
13
14#include "awb.h"
15#include "interpolator.h"
16
17namespace libcamera {
18
19namespace ipa {
20
22{
23public:
24 AwbGrey() = default;
25
26 int init(const ValueNode &tuningData) override;
28 calculateAwb(const AwbStats &stats, unsigned int lux,
29 std::array<double, 2> range) override;
30 std::optional<RGB<double>> gainsFromColourTemperature(double colourTemperature) override;
31
32private:
33 std::optional<Interpolator<Vector<double, 2>>> colourGainCurve_;
34};
35
36} /* namespace ipa */
37
38} /* namespace libcamera */
A class representing a tree structure of values.
Definition value_node.h:27
A Grey world auto white balance algorithm.
Definition awb_grey.h:22
AwbImplementation::Result calculateAwb(const AwbStats &stats, unsigned int lux, std::array< double, 2 > range) override
Calculate AWB data from the given statistics.
Definition awb_grey.cpp:75
std::optional< RGB< double > > gainsFromColourTemperature(double colourTemperature) override
Compute white balance gains from a colour temperature.
Definition awb_grey.cpp:104
int init(const ValueNode &tuningData) override
Initialize the algorithm with the given tuning data.
Definition awb_grey.cpp:44
Pure virtual base class for AWB algorithms implementations.
Definition awb.h:54
Helper class for linear interpolating a set of objects.
libipa AWB implementation
Top-level libcamera namespace.
Definition backtrace.h:17
The result of an AWB computation.
Definition awb.h:56
An abstraction class wrapping hardware-specific AWB statistics.
Definition awb.h:44
Vector class.