|
libcamera v0.7.2+rpt20260817
Supporting cameras in Linux since 2019
|
Implementation of a bayesian auto white balance algorithm. More...


Public Member Functions | |
| int | init (const ValueNode &tuningData) override |
| Initialize the algorithm by parsing tuningData. | |
| AwbImplementation::Result | calculateAwb (const AwbStats &stats, unsigned int lux, std::array< double, 2 > range) override |
| Calculate AWB data from the given statistics. | |
| std::optional< RGB< double > > | gainsFromColourTemperature (double temperatureK) override |
| Compute white balance gains from a colour temperature. | |
Public Member Functions inherited from libcamera::ipa::AwbImplementation | |
| virtual | ~AwbImplementation ()=default |
| Virtual class destructor. | |
Implementation of a bayesian auto white balance algorithm.
In a bayesian AWB algorithm the auto white balance estimation is improved by taking the likelihood of a given lightsource based on the estimated lux level into account. E.g. If it is very bright we can assume that we are outside and that colour temperatures around 6500 are preferred.
The second part of this algorithm is the search for the most likely colour temperature. It is implemented in AwbBayes::coarseSearch() and in AwbBayes::fineSearch(). The search works very well without prior likelihoods and therefore the algorithm itself provides very good results even without prior likelihoods.
|
overridevirtual |
Calculate AWB data from the given statistics.
| [in] | stats | The statistics to use for the calculation |
| [in] | lux | The lux value of the scene |
| [in] | range | The colour temperature search limits |
Calculate an AwbResult object from the given statistics and lux value. A lux value of 0 means it is unknown or invalid and the algorithm shall ignore it.
Implements libcamera::ipa::AwbImplementation.
|
overridevirtual |
Compute white balance gains from a colour temperature.
| [in] | colourTemperature | The colour temperature in Kelvin |
Compute the white balance gains from a colourTemperature. This function does not take any statistics into account. It simply interpolates the colour gains curve on a new colour temperature.
Implements libcamera::ipa::AwbImplementation.
|
overridevirtual |
Initialize the algorithm by parsing tuningData.
| [in] | tuningData |
Implements libcamera::ipa::AwbImplementation.