@@ -384,11 +384,24 @@ void Awb::calculateWBGains(const ipu3_uapi_stats_3a *stats)
}
}
+/**
+ * \brief Test the AF requested lock is exist.
+ */
+bool Awb::isAfRequestedLock(IPAContext context)
+{
+ if (context.configuration.af.requireAeAwbLock)
+ return true;
+ else
+ return false;
+}
+
/**
* \copydoc libcamera::ipa::Algorithm::process
*/
void Awb::process(IPAContext &context, const ipu3_uapi_stats_3a *stats)
{
+ if (isAfRequestedLock(context))
+ return;
calculateWBGains(stats);
/*
@@ -72,6 +72,7 @@ private:
void awbGreyWorld();
uint32_t estimateCCT(double red, double green, double blue);
static constexpr uint16_t threshold(float value);
+ bool isAfRequestedLock(IPAContext context);
std::vector<RGB> zones_;
Accumulator awbStats_[kAwbStatsSizeX * kAwbStatsSizeY];
When the AF starts to perform the scan, AWB will be suspended to stabilize the AF scene variance and improve the AF performance. Signed-off-by: Kate Hsuan <hpa@redhat.com> --- src/ipa/ipu3/algorithms/awb.cpp | 13 +++++++++++++ src/ipa/ipu3/algorithms/awb.h | 1 + 2 files changed, 14 insertions(+)