summaryrefslogtreecommitdiff
path: root/src/ipa/rpi
diff options
context:
space:
mode:
authorNaushir Patuck <naush@raspberrypi.com>2024-11-19 10:14:52 +0000
committerKieran Bingham <kieran.bingham@ideasonboard.com>2024-11-19 11:00:14 +0000
commit934bbfce24f961c04132b8bb8bd66ea1ae999394 (patch)
treec5e6920baf02e2cb4557207f4e3d0491fdb5712b /src/ipa/rpi
parentd5217b16020c659145f9d6dbf5849129b8500967 (diff)
ipa: rpi: awb: Disable CT search bias for Grey World AWB
If grey world AWB is setup in the tuning file, the CT curve will either be missing or invalid. Disable biasing the statistics for the search in such cases. Fixes: ea8fd63d936f ("ipa: rpi: awb: Add a bias to the AWB search") Signed-off-by: Naushir Patuck <naush@raspberrypi.com> Reviewed-by: David Plowman <david.plowman@raspberrypi.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Diffstat (limited to 'src/ipa/rpi')
-rw-r--r--src/ipa/rpi/controller/rpi/awb.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/ipa/rpi/controller/rpi/awb.cpp b/src/ipa/rpi/controller/rpi/awb.cpp
index 9d8e170d..c277a176 100644
--- a/src/ipa/rpi/controller/rpi/awb.cpp
+++ b/src/ipa/rpi/controller/rpi/awb.cpp
@@ -459,10 +459,11 @@ void Awb::prepareStats()
* LSC has already been applied to the stats in this pipeline, so stop
* any LSC compensation. We also ignore config_.fast in this version.
*/
+ const double biasCtR = config_.bayes ? config_.ctR.eval(config_.biasCT) : 0;
+ const double biasCtB = config_.bayes ? config_.ctB.eval(config_.biasCT) : 0;
generateStats(zones_, statistics_, config_.minPixels,
config_.minG, getGlobalMetadata(),
- config_.biasProportion, config_.ctR.eval(config_.biasCT),
- config_.ctB.eval(config_.biasCT));
+ config_.biasProportion, biasCtR, biasCtB);
/*
* apply sensitivities, so values appear to come from our "canonical"
* sensor.