Skip to content

Commit 1230f78

Browse files
committed
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: ea8fd63 ("ipa: rpi: awb: Add a bias to the AWB search") Signed-off-by: Naushir Patuck <[email protected]> Reviewed-by: David Plowman <[email protected]> Reviewed-by: Kieran Bingham <[email protected]>
1 parent 75fe515 commit 1230f78

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ipa/rpi/controller/rpi/awb.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,10 +459,11 @@ void Awb::prepareStats()
459459
* LSC has already been applied to the stats in this pipeline, so stop
460460
* any LSC compensation. We also ignore config_.fast in this version.
461461
*/
462+
const double biasCtR = config_.bayes ? config_.ctR.eval(config_.biasCT) : 0;
463+
const double biasCtB = config_.bayes ? config_.ctB.eval(config_.biasCT) : 0;
462464
generateStats(zones_, statistics_, config_.minPixels,
463465
config_.minG, getGlobalMetadata(),
464-
config_.biasProportion, config_.ctR.eval(config_.biasCT),
465-
config_.ctB.eval(config_.biasCT));
466+
config_.biasProportion, biasCtR, biasCtB);
466467
/*
467468
* apply sensitivities, so values appear to come from our "canonical"
468469
* sensor.

0 commit comments

Comments
 (0)