libcamera v0.5.1
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
21class AwbGrey : public AwbAlgorithm
22{
23public:
24 AwbGrey() = default;
25
26 int init(const YamlObject &tuningData) override;
27 AwbResult calculateAwb(const AwbStats &stats, unsigned int lux) override;
28 std::optional<RGB<double>> gainsFromColourTemperature(double colourTemperature) override;
29
30private:
31 std::optional<Interpolator<Vector<double, 2>>> colourGainCurve_;
32};
33
34} /* namespace ipa */
35
36} /* namespace libcamera */
A class representing the tree structure of the YAML content.
Definition yaml_parser.h:28
A base class for auto white balance algorithms.
Definition awb.h:37
std::optional< RGB< double > > gainsFromColourTemperature(double colourTemperature) override
Compute white balance gains from a colour temperature.
Definition awb_grey.cpp:101
int init(const YamlObject &tuningData) override
Initialize the algorithm with the given tuning data.
Definition awb_grey.cpp:44
AwbResult calculateAwb(const AwbStats &stats, unsigned int lux) override
Calculate AWB data from the given statistics.
Definition awb_grey.cpp:73
Helper class for linear interpolating a set of objects.
Base classes for AWB algorithms.
The IPA (Image Processing Algorithm) namespace.
Definition af.cpp:58
Top-level libcamera namespace.
Definition backtrace.h:17
The result of an AWB calculation.
Definition awb.h:23
An abstraction class wrapping hardware-specific AWB statistics.
Definition awb.h:28
Vector class.