<div dir="ltr"><div dir="ltr">Hi Jacopo,<div><br></div><div>Thank you for your work.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, 19 Apr 2021 at 14:14, Jacopo Mondi <<a href="mailto:jacopo@jmondi.org" target="_blank">jacopo@jmondi.org</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">This commit applies to the RaspberryPi pipeline handler the same change<br>
applied to IPU3 in commit 13a7ed7b1f1f ("libcamera: ipu3: Do not<br>
over-write metadata").<br>
<br>
When a Request is completed upon receiving the IPA produced metadata,<br>
the metadata associated with the Request are over-written, deleting<br>
the information set at output buffer completion, such as the<br>
SensorTimestamp.<br>
<br>
Signed-off-by: Jacopo Mondi <<a href="mailto:jacopo@jmondi.org" target="_blank">jacopo@jmondi.org</a>><br></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">---<br>
 src/libcamera/pipeline/raspberrypi/raspberrypi.cpp | 10 ++++++++--<br>
 1 file changed, 8 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp<br>
index f22e286ed87a..d1902bfc3393 100644<br>
--- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp<br>
+++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp<br>
@@ -1312,9 +1312,15 @@ void RPiCameraData::statsMetadataComplete(uint32_t bufferId, const ControlList &<br>
<br>
        handleStreamBuffer(buffer, &isp_[Isp::Stats]);<br>
<br>
-       /* Fill the Request metadata buffer with what the IPA has provided */<br>
+       /*<br>
+        * Add to the Request metadata buffer what the IPA has provided.<br>
+        *<br>
+        * Do not overwrite controls set by the pipeline handler, in example<br></blockquote><div><br></div><div>s/in example/for example/?</div><div><br></div><div>Apart from that,</div><div>Reviewed-by: Naushir Patuck <<a href="mailto:naush@raspberrypi.com">naush@raspberrypi.com</a>><br></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">
+        * SensorTimestamp.<br>
+        */<br>
        Request *request = requestQueue_.front();<br>
-       request->metadata() = controls;<br>
+       for (const auto &ctrl : controls)<br>
+               request->metadata().set(ctrl.first, ctrl.second);<br>
<br>
        /*<br>
         * Also update the ScalerCrop in the metadata with what we actually<br>
-- <br>
2.31.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>