<div dir="ltr"><div dir="ltr">Hi David,<div><br></div><div>Thank you for your work.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, 10 Feb 2021 at 11:17, David Plowman <<a href="mailto:david.plowman@raspberrypi.com">david.plowman@raspberrypi.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">The variable frame_count2_ is not needed as Prepare() and Process()<br>
always run in lock step one after the other.<br>
<br>
Signed-off-by: David Plowman <<a href="mailto:david.plowman@raspberrypi.com" target="_blank">david.plowman@raspberrypi.com</a>><br></blockquote><div><br></div><div>Looks good!</div><div><br></div><div>Reviewed-by: Naushir Patuck <<a href="mailto:naush@raspberrypi.com">naush@raspberrypi.com</a>></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
---<br>
 src/ipa/raspberrypi/controller/rpi/awb.cpp | 6 ++----<br>
 src/ipa/raspberrypi/controller/rpi/awb.hpp | 1 -<br>
 2 files changed, 2 insertions(+), 5 deletions(-)<br>
<br>
diff --git a/src/ipa/raspberrypi/controller/rpi/awb.cpp b/src/ipa/raspberrypi/controller/rpi/awb.cpp<br>
index 791b5108..1c65eda8 100644<br>
--- a/src/ipa/raspberrypi/controller/rpi/awb.cpp<br>
+++ b/src/ipa/raspberrypi/controller/rpi/awb.cpp<br>
@@ -153,7 +153,7 @@ void Awb::Read(boost::property_tree::ptree const &params)<br>
<br>
 void Awb::Initialise()<br>
 {<br>
-       frame_count2_ = frame_count_ = frame_phase_ = 0;<br>
+       frame_count_ = frame_phase_ = 0;<br>
        // Put something sane into the status that we are filtering towards,<br>
        // just in case the first few frames don't have anything meaningful in<br>
        // them.<br>
@@ -288,11 +288,9 @@ void Awb::Process(StatisticsPtr &stats, Metadata *image_metadata)<br>
        // Count frames since we last poked the async thread.<br>
        if (frame_phase_ < (int)config_.frame_period)<br>
                frame_phase_++;<br>
-       if (frame_count2_ < (int)config_.startup_frames)<br>
-               frame_count2_++;<br>
        LOG(RPiAwb, Debug) << "frame_phase " << frame_phase_;<br>
        if (frame_phase_ >= (int)config_.frame_period ||<br>
-           frame_count2_ < (int)config_.startup_frames) {<br>
+           frame_count_ < (int)config_.startup_frames) {<br>
                // Update any settings and any image metadata that we need.<br>
                struct LuxStatus lux_status = {};<br>
                lux_status.lux = 400; // in case no metadata<br>
diff --git a/src/ipa/raspberrypi/controller/rpi/awb.hpp b/src/ipa/raspberrypi/controller/rpi/awb.hpp<br>
index 1b39ab4b..f113c642 100644<br>
--- a/src/ipa/raspberrypi/controller/rpi/awb.hpp<br>
+++ b/src/ipa/raspberrypi/controller/rpi/awb.hpp<br>
@@ -130,7 +130,6 @@ private:<br>
        // counts up to frame_period before restarting the async thread<br>
        int frame_phase_;<br>
        int frame_count_; // counts up to startup_frames<br>
-       int frame_count2_; // counts up to startup_frames for Process method<br>
        AwbStatus sync_results_;<br>
        AwbStatus prev_sync_results_;<br>
        std::string mode_name_;<br>
-- <br>
2.20.1<br>
<br>
_______________________________________________<br>
libcamera-devel mailing list<br>
<a href="mailto:libcamera-devel@lists.libcamera.org" target="_blank">libcamera-devel@lists.libcamera.org</a><br>
<a href="https://lists.libcamera.org/listinfo/libcamera-devel" rel="noreferrer" target="_blank">https://lists.libcamera.org/listinfo/libcamera-devel</a><br>
</blockquote></div></div>