[{"id":34565,"web_url":"https://patchwork.libcamera.org/comment/34565/","msgid":"<4wfycqtksl2rxfoc2o4scvgykhgq2dj4h4ilz5mujpv4bnb47x@cd2ka4cqy7ko>","date":"2025-06-19T11:23:13","subject":"Re: [RFC PATCH v1 13/23] libcamera: camera: Introduce\n\tmetadataAvailable signal","submitter":{"id":143,"url":"https://patchwork.libcamera.org/api/people/143/","name":"Jacopo Mondi","email":"jacopo.mondi@ideasonboard.com"},"content":"Hi Barnabás\n\nOn Fri, Jun 06, 2025 at 06:41:46PM +0200, Barnabás Pőcze wrote:\n> From: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n>\n> Add a new signal to the Camera class that allows applications to\n> receive notifications for early completion of metadata results.\n>\n> To avoid expensive copies of the metadata results the signal\n> transports the ids of the metadata keys that are ready. Applications\n> can use these ids to access the metadata results from\n> Request::metadata().\n>\n> The signal is an opt-in feature for applications and the sum of\n> all metadata results notified through this signal is available\n> in Request::metadata() at request completion time.\n\nThis paragraph doesn't apply anymore ;)\n\n>\n> Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n> [Use `MetadataList::Diff`, change documentation accordingly.]\n> Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>\n> ---\n> Original: https://patchwork.libcamera.org/patch/22227/\n> ---\n>  include/libcamera/camera.h |  1 +\n>  src/libcamera/camera.cpp   | 54 ++++++++++++++++++++++++++++++++++++++\n>  2 files changed, 55 insertions(+)\n>\n> diff --git a/include/libcamera/camera.h b/include/libcamera/camera.h\n> index 94cee7bd8..bf5623ddf 100644\n> --- a/include/libcamera/camera.h\n> +++ b/include/libcamera/camera.h\n> @@ -122,6 +122,7 @@ public:\n>\n>  \tconst std::string &id() const;\n>\n> +\tSignal<Request *, MetadataList::Diff> metadataAvailable;\n>  \tSignal<Request *, FrameBuffer *> bufferCompleted;\n>  \tSignal<Request *> requestCompleted;\n>  \tSignal<> disconnected;\n> diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp\n> index 31f5ad94b..2c87c3274 100644\n> --- a/src/libcamera/camera.cpp\n> +++ b/src/libcamera/camera.cpp\n> @@ -902,6 +902,60 @@ const std::string &Camera::id() const\n>  \treturn _d()->id_;\n>  }\n>\n> +/**\n> + * \\var Camera::metadataAvailable\n> + * \\brief Signal emitted when metadata for a request is available\n> + *\n> + * The metadataAvailable signal notifies applications about the availability\n> + * of metadata for a request before the request completes.\n> + *\n> + * As metadata results could be large in size, the signal transports only a view\n> + * object via which the newly completed metadata items can be accessed. Similarly\n> + * to the metadata list itself, this object is thread-safe, and can be sent to other\n> + * threads for deferred processing. The view object is valid until the request is\n> + * destroyed or reused, whichever happens first.\n> + *\n> + * Applications can access the value of the newly available metadata results as follows:\n> + *\n> + * \\code\n> +\n> +\tvoid metadataAvailableHandler(Request *request, MetadataList::Diff update)\n> +\t{\n> +\t\t// The object can be iterated...\n> +\t\tfor (auto &&[id, data] : update) {\n> +\t\t\t// `id` is the numeric identifier\n> +\t\t\t// `data` is a `ControlValueView` object\n> +\t\t}\n> +\n> +\t\t// ...or individual items can be looked up.\n> +\t\tif (auto x = update.get(controls::SensorTimestamp)) {\n> +\t\t\t// `SensorTimestamp` will only be found if it is part of this\n> +\t\t\t// particular update; metadata items completed earlier will\n> +\t\t\t// not be found.\n> +\t\t}\n> +\t}\n> +   \\endcode\n> + *\n> + * This signal is emitted multiple times for the same request, it is in fact\n> + * emitted by the framework every time a new metadata list is made available\n\ns/a new metadata list is/new metadata are/\n\n?\n\n> + * by the Camera to the application.\n> + *\n> + * The sum of all metadata lists reported through this signal is equal to\n\ns/lists// ?\n\n> + * Request::metadata() list when the Request completes.\n> + *\n> + * Application can opt-in to handle this signal to receive fast notifications\n> + * of metadata availability or can equally access the full metadata list\n> + * at Request complete time through Request::metadata() if they have no interest\n> + * in early metadata notification.\n> + *\n> + * \\note The received MetadataList::Diff object is merely a view, it is only valid until\n> + *       the associated Request is destroyed or \\ref Request::reuse() \"reused\". However,\n> + *       during its valid lifetime, an application is free to create copies and access the\n> + *       completed metadata items from separate thread by iteration or MetadataList::Diff::get().\n> + *\n> + * \\sa ControlValueView\n      \\sa MetadataList\n      ?\n\nJust minors\nReviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n\nThanks\n  j\n\n> + */\n> +\n>  /**\n>   * \\var Camera::bufferCompleted\n>   * \\brief Signal emitted when a buffer for a request queued to the camera has\n> --\n> 2.49.0\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 70681BDE6B\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 19 Jun 2025 11:23:20 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 2B1EB68DE9;\n\tThu, 19 Jun 2025 13:23:19 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id F27ED68DE1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 19 Jun 2025 13:23:16 +0200 (CEST)","from ideasonboard.com (93-61-96-190.ip145.fastwebnet.it\n\t[93.61.96.190])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id F319A346;\n\tThu, 19 Jun 2025 13:23:02 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"e5bCYQm4\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1750332183;\n\tbh=+umhG3XFrPtxBgnPzGC+MlV53Z3VX8uDywKPWjIGRwE=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=e5bCYQm4g+w35f2a+4YctMajWjcWDymvsYddxre+uI0RGEHVo/LICxmB+t2AAnLW9\n\tKbhr+gDwIz93Gm77HKYi7kUXzCsbQ7k0UPmCKp8BMjaGZ692kis8tN6A8FM1wHooW8\n\tbDshoGsfbWhYb82WmcPyFffk6EmbyFBPGg37xa4k=","Date":"Thu, 19 Jun 2025 13:23:13 +0200","From":"Jacopo Mondi <jacopo.mondi@ideasonboard.com>","To":"=?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= <barnabas.pocze@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org, \n\tJacopo Mondi <jacopo.mondi@ideasonboard.com>","Subject":"Re: [RFC PATCH v1 13/23] libcamera: camera: Introduce\n\tmetadataAvailable signal","Message-ID":"<4wfycqtksl2rxfoc2o4scvgykhgq2dj4h4ilz5mujpv4bnb47x@cd2ka4cqy7ko>","References":"<20250606164156.1442682-1-barnabas.pocze@ideasonboard.com>\n\t<20250606164156.1442682-14-barnabas.pocze@ideasonboard.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<20250606164156.1442682-14-barnabas.pocze@ideasonboard.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":34573,"web_url":"https://patchwork.libcamera.org/comment/34573/","msgid":"<be0cd2ac-28f3-4372-be64-aada33bfa80d@ideasonboard.com>","date":"2025-06-19T12:30:53","subject":"Re: [RFC PATCH v1 13/23] libcamera: camera: Introduce\n\tmetadataAvailable signal","submitter":{"id":216,"url":"https://patchwork.libcamera.org/api/people/216/","name":"Barnabás Pőcze","email":"barnabas.pocze@ideasonboard.com"},"content":"Hi\n\n2025. 06. 19. 13:23 keltezéssel, Jacopo Mondi írta:\n> Hi Barnabás\n> \n> On Fri, Jun 06, 2025 at 06:41:46PM +0200, Barnabás Pőcze wrote:\n>> From: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n>>\n>> Add a new signal to the Camera class that allows applications to\n>> receive notifications for early completion of metadata results.\n>>\n>> To avoid expensive copies of the metadata results the signal\n>> transports the ids of the metadata keys that are ready. Applications\n>> can use these ids to access the metadata results from\n>> Request::metadata().\n>>\n>> The signal is an opt-in feature for applications and the sum of\n>> all metadata results notified through this signal is available\n>> in Request::metadata() at request completion time.\n> \n> This paragraph doesn't apply anymore ;)\n\nWhy not? I think it still true. The paragraph above this is\nindeed not true anymore. I will change it to:\n\n   To avoid expensive copies of the metadata results the signal\n   transports a view object of metadata items that are ready.\n\n\n> \n>>\n>> Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n>> [Use `MetadataList::Diff`, change documentation accordingly.]\n>> Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>\n>> ---\n>> Original: https://patchwork.libcamera.org/patch/22227/\n>> ---\n>>   include/libcamera/camera.h |  1 +\n>>   src/libcamera/camera.cpp   | 54 ++++++++++++++++++++++++++++++++++++++\n>>   2 files changed, 55 insertions(+)\n>>\n>> diff --git a/include/libcamera/camera.h b/include/libcamera/camera.h\n>> index 94cee7bd8..bf5623ddf 100644\n>> --- a/include/libcamera/camera.h\n>> +++ b/include/libcamera/camera.h\n>> @@ -122,6 +122,7 @@ public:\n>>\n>>   \tconst std::string &id() const;\n>>\n>> +\tSignal<Request *, MetadataList::Diff> metadataAvailable;\n>>   \tSignal<Request *, FrameBuffer *> bufferCompleted;\n>>   \tSignal<Request *> requestCompleted;\n>>   \tSignal<> disconnected;\n>> diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp\n>> index 31f5ad94b..2c87c3274 100644\n>> --- a/src/libcamera/camera.cpp\n>> +++ b/src/libcamera/camera.cpp\n>> @@ -902,6 +902,60 @@ const std::string &Camera::id() const\n>>   \treturn _d()->id_;\n>>   }\n>>\n>> +/**\n>> + * \\var Camera::metadataAvailable\n>> + * \\brief Signal emitted when metadata for a request is available\n>> + *\n>> + * The metadataAvailable signal notifies applications about the availability\n>> + * of metadata for a request before the request completes.\n>> + *\n>> + * As metadata results could be large in size, the signal transports only a view\n>> + * object via which the newly completed metadata items can be accessed. Similarly\n>> + * to the metadata list itself, this object is thread-safe, and can be sent to other\n>> + * threads for deferred processing. The view object is valid until the request is\n>> + * destroyed or reused, whichever happens first.\n>> + *\n>> + * Applications can access the value of the newly available metadata results as follows:\n>> + *\n>> + * \\code\n>> +\n>> +\tvoid metadataAvailableHandler(Request *request, MetadataList::Diff update)\n>> +\t{\n>> +\t\t// The object can be iterated...\n>> +\t\tfor (auto &&[id, data] : update) {\n>> +\t\t\t// `id` is the numeric identifier\n>> +\t\t\t// `data` is a `ControlValueView` object\n>> +\t\t}\n>> +\n>> +\t\t// ...or individual items can be looked up.\n>> +\t\tif (auto x = update.get(controls::SensorTimestamp)) {\n>> +\t\t\t// `SensorTimestamp` will only be found if it is part of this\n>> +\t\t\t// particular update; metadata items completed earlier will\n>> +\t\t\t// not be found.\n>> +\t\t}\n>> +\t}\n>> +   \\endcode\n>> + *\n>> + * This signal is emitted multiple times for the same request, it is in fact\n>> + * emitted by the framework every time a new metadata list is made available\n> \n> s/a new metadata list is/new metadata are/\n\nI changed it to \"a new set of metadata\"\n\n\n> \n> ?\n> \n>> + * by the Camera to the application.\n>> + *\n>> + * The sum of all metadata lists reported through this signal is equal to\n> \n> s/lists// ?\n\nDone.\n\n\n> \n>> + * Request::metadata() list when the Request completes.\n>> + *\n>> + * Application can opt-in to handle this signal to receive fast notifications\n>> + * of metadata availability or can equally access the full metadata list\n>> + * at Request complete time through Request::metadata() if they have no interest\n>> + * in early metadata notification.\n>> + *\n>> + * \\note The received MetadataList::Diff object is merely a view, it is only valid until\n>> + *       the associated Request is destroyed or \\ref Request::reuse() \"reused\". However,\n>> + *       during its valid lifetime, an application is free to create copies and access the\n>> + *       completed metadata items from separate thread by iteration or MetadataList::Diff::get().\n>> + *\n>> + * \\sa ControlValueView\n>        \\sa MetadataList\n>        ?\n> \n> Just minors\n> Reviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n> \n> Thanks\n>    j\n> \n>> + */\n>> +\n>>   /**\n>>    * \\var Camera::bufferCompleted\n>>    * \\brief Signal emitted when a buffer for a request queued to the camera has\n>> --\n>> 2.49.0\n>>\n\n\nRegards,\nBarnabás Pőcze","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 41874C3237\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 19 Jun 2025 12:30:59 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 6BDE568DE3;\n\tThu, 19 Jun 2025 14:30:58 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 68AB768DDB\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 19 Jun 2025 14:30:57 +0200 (CEST)","from [192.168.33.22] (185.221.143.107.nat.pool.zt.hu\n\t[185.221.143.107])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 8AA7999F;\n\tThu, 19 Jun 2025 14:30:43 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"LTVf0rIk\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1750336243;\n\tbh=3RFc2LXZ2yE2Jy1kDNNqGPDkkmIFW/Apo6qcEwlDKSc=;\n\th=Date:Subject:To:Cc:References:From:In-Reply-To:From;\n\tb=LTVf0rIkDFCwbasTufUPB4ekZ/74aQuqrERqOUR3qH7wTCYLUPvsNsNaCiYZaQmn4\n\tQNPfhyXdfGYFK2C5f726WD7wncADN65rcpdrcjtgioPk+YyzPgahTqhvTqX6Fbf3C6\n\t+pXxIHbPodhRhfRJYb29g+g/RYOOvmMAR3365GCc=","Message-ID":"<be0cd2ac-28f3-4372-be64-aada33bfa80d@ideasonboard.com>","Date":"Thu, 19 Jun 2025 14:30:53 +0200","MIME-Version":"1.0","User-Agent":"Mozilla Thunderbird","Subject":"Re: [RFC PATCH v1 13/23] libcamera: camera: Introduce\n\tmetadataAvailable signal","To":"Jacopo Mondi <jacopo.mondi@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","References":"<20250606164156.1442682-1-barnabas.pocze@ideasonboard.com>\n\t<20250606164156.1442682-14-barnabas.pocze@ideasonboard.com>\n\t<4wfycqtksl2rxfoc2o4scvgykhgq2dj4h4ilz5mujpv4bnb47x@cd2ka4cqy7ko>","From":"=?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= <barnabas.pocze@ideasonboard.com>","Content-Language":"en-US, hu-HU","In-Reply-To":"<4wfycqtksl2rxfoc2o4scvgykhgq2dj4h4ilz5mujpv4bnb47x@cd2ka4cqy7ko>","Content-Type":"text/plain; charset=UTF-8; format=flowed","Content-Transfer-Encoding":"8bit","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":34580,"web_url":"https://patchwork.libcamera.org/comment/34580/","msgid":"<ojds5e7uvhmslt2ycumh2wvrjty6555nedowneranu3aue5dgw@5onq2ckmfckd>","date":"2025-06-19T14:13:57","subject":"Re: [RFC PATCH v1 13/23] libcamera: camera: Introduce\n\tmetadataAvailable signal","submitter":{"id":143,"url":"https://patchwork.libcamera.org/api/people/143/","name":"Jacopo Mondi","email":"jacopo.mondi@ideasonboard.com"},"content":"Hi Barnabás\n\nOn Thu, Jun 19, 2025 at 02:30:53PM +0200, Barnabás Pőcze wrote:\n> Hi\n>\n> 2025. 06. 19. 13:23 keltezéssel, Jacopo Mondi írta:\n> > Hi Barnabás\n> >\n> > On Fri, Jun 06, 2025 at 06:41:46PM +0200, Barnabás Pőcze wrote:\n> > > From: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n> > >\n> > > Add a new signal to the Camera class that allows applications to\n> > > receive notifications for early completion of metadata results.\n> > >\n> > > To avoid expensive copies of the metadata results the signal\n> > > transports the ids of the metadata keys that are ready. Applications\n> > > can use these ids to access the metadata results from\n> > > Request::metadata().\n> > >\n> > > The signal is an opt-in feature for applications and the sum of\n> > > all metadata results notified through this signal is available\n> > > in Request::metadata() at request completion time.\n> >\n> > This paragraph doesn't apply anymore ;)\n>\n> Why not? I think it still true. The paragraph above this is\n> indeed not true anymore. I will change it to:\n>\n>   To avoid expensive copies of the metadata results the signal\n>   transports a view object of metadata items that are ready.\n>\n\nSorry, I went a paragraph to low.\n\nI meant\n\n> > > To avoid expensive copies of the metadata results the signal\n> > > transports the ids of the metadata keys that are ready. Applications\n> > > can use these ids to access the metadata results from\n> > > Request::metadata().\n\nThis doesn't apply, as my original patch transported ids, while we now\nhave a proper object.\n\nYour proposal of\n\n>   To avoid expensive copies of the metadata results the signal\n>   transports a view object of metadata items that are ready.\n\nsounds good\n\n\n>\n> >\n> > >\n> > > Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n> > > [Use `MetadataList::Diff`, change documentation accordingly.]\n> > > Signed-off-by: Barnabás Pőcze <barnabas.pocze@ideasonboard.com>\n> > > ---\n> > > Original: https://patchwork.libcamera.org/patch/22227/\n> > > ---\n> > >   include/libcamera/camera.h |  1 +\n> > >   src/libcamera/camera.cpp   | 54 ++++++++++++++++++++++++++++++++++++++\n> > >   2 files changed, 55 insertions(+)\n> > >\n> > > diff --git a/include/libcamera/camera.h b/include/libcamera/camera.h\n> > > index 94cee7bd8..bf5623ddf 100644\n> > > --- a/include/libcamera/camera.h\n> > > +++ b/include/libcamera/camera.h\n> > > @@ -122,6 +122,7 @@ public:\n> > >\n> > >   \tconst std::string &id() const;\n> > >\n> > > +\tSignal<Request *, MetadataList::Diff> metadataAvailable;\n> > >   \tSignal<Request *, FrameBuffer *> bufferCompleted;\n> > >   \tSignal<Request *> requestCompleted;\n> > >   \tSignal<> disconnected;\n> > > diff --git a/src/libcamera/camera.cpp b/src/libcamera/camera.cpp\n> > > index 31f5ad94b..2c87c3274 100644\n> > > --- a/src/libcamera/camera.cpp\n> > > +++ b/src/libcamera/camera.cpp\n> > > @@ -902,6 +902,60 @@ const std::string &Camera::id() const\n> > >   \treturn _d()->id_;\n> > >   }\n> > >\n> > > +/**\n> > > + * \\var Camera::metadataAvailable\n> > > + * \\brief Signal emitted when metadata for a request is available\n> > > + *\n> > > + * The metadataAvailable signal notifies applications about the availability\n> > > + * of metadata for a request before the request completes.\n> > > + *\n> > > + * As metadata results could be large in size, the signal transports only a view\n> > > + * object via which the newly completed metadata items can be accessed. Similarly\n> > > + * to the metadata list itself, this object is thread-safe, and can be sent to other\n> > > + * threads for deferred processing. The view object is valid until the request is\n> > > + * destroyed or reused, whichever happens first.\n> > > + *\n> > > + * Applications can access the value of the newly available metadata results as follows:\n> > > + *\n> > > + * \\code\n> > > +\n> > > +\tvoid metadataAvailableHandler(Request *request, MetadataList::Diff update)\n> > > +\t{\n> > > +\t\t// The object can be iterated...\n> > > +\t\tfor (auto &&[id, data] : update) {\n> > > +\t\t\t// `id` is the numeric identifier\n> > > +\t\t\t// `data` is a `ControlValueView` object\n> > > +\t\t}\n> > > +\n> > > +\t\t// ...or individual items can be looked up.\n> > > +\t\tif (auto x = update.get(controls::SensorTimestamp)) {\n> > > +\t\t\t// `SensorTimestamp` will only be found if it is part of this\n> > > +\t\t\t// particular update; metadata items completed earlier will\n> > > +\t\t\t// not be found.\n> > > +\t\t}\n> > > +\t}\n> > > +   \\endcode\n> > > + *\n> > > + * This signal is emitted multiple times for the same request, it is in fact\n> > > + * emitted by the framework every time a new metadata list is made available\n> >\n> > s/a new metadata list is/new metadata are/\n>\n> I changed it to \"a new set of metadata\"\n>\n>\n> >\n> > ?\n> >\n> > > + * by the Camera to the application.\n> > > + *\n> > > + * The sum of all metadata lists reported through this signal is equal to\n> >\n> > s/lists// ?\n>\n> Done.\n>\n>\n> >\n> > > + * Request::metadata() list when the Request completes.\n> > > + *\n> > > + * Application can opt-in to handle this signal to receive fast notifications\n> > > + * of metadata availability or can equally access the full metadata list\n> > > + * at Request complete time through Request::metadata() if they have no interest\n> > > + * in early metadata notification.\n> > > + *\n> > > + * \\note The received MetadataList::Diff object is merely a view, it is only valid until\n> > > + *       the associated Request is destroyed or \\ref Request::reuse() \"reused\". However,\n> > > + *       during its valid lifetime, an application is free to create copies and access the\n> > > + *       completed metadata items from separate thread by iteration or MetadataList::Diff::get().\n> > > + *\n> > > + * \\sa ControlValueView\n> >        \\sa MetadataList\n> >        ?\n> >\n> > Just minors\n> > Reviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n> >\n> > Thanks\n> >    j\n> >\n> > > + */\n> > > +\n> > >   /**\n> > >    * \\var Camera::bufferCompleted\n> > >    * \\brief Signal emitted when a buffer for a request queued to the camera has\n> > > --\n> > > 2.49.0\n> > >\n>\n>\n> Regards,\n> Barnabás Pőcze","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id E6C46C3237\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 19 Jun 2025 14:14:03 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id D530568DE3;\n\tThu, 19 Jun 2025 16:14:02 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 819E368DDB\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 19 Jun 2025 16:14:00 +0200 (CEST)","from ideasonboard.com (93-61-96-190.ip145.fastwebnet.it\n\t[93.61.96.190])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 7B375107;\n\tThu, 19 Jun 2025 16:13:46 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"nDnQeoFe\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1750342426;\n\tbh=OK4ueYIhLPnkSHLgw/xh+UNj6+R3w3r3/5xAjwhzdL0=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=nDnQeoFen02eenjsdyNQFe7GT79IqFEY7gU1iYhibJo+meb1gtZE7P9kUBaM+Uhv9\n\tC+S8CgMe2Tf4lPMZbCBZYrSRrKAn7faJXEn04qp9O1ZhVxC6o+2MBhK0kajKPxrv4c\n\tWzy1+cpDsqFUqhg3DDPPZISYZoxT8v8QtaXTwudE=","Date":"Thu, 19 Jun 2025 16:13:57 +0200","From":"Jacopo Mondi <jacopo.mondi@ideasonboard.com>","To":"=?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= <barnabas.pocze@ideasonboard.com>","Cc":"Jacopo Mondi <jacopo.mondi@ideasonboard.com>, \n\tlibcamera-devel@lists.libcamera.org","Subject":"Re: [RFC PATCH v1 13/23] libcamera: camera: Introduce\n\tmetadataAvailable signal","Message-ID":"<ojds5e7uvhmslt2ycumh2wvrjty6555nedowneranu3aue5dgw@5onq2ckmfckd>","References":"<20250606164156.1442682-1-barnabas.pocze@ideasonboard.com>\n\t<20250606164156.1442682-14-barnabas.pocze@ideasonboard.com>\n\t<4wfycqtksl2rxfoc2o4scvgykhgq2dj4h4ilz5mujpv4bnb47x@cd2ka4cqy7ko>\n\t<be0cd2ac-28f3-4372-be64-aada33bfa80d@ideasonboard.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<be0cd2ac-28f3-4372-be64-aada33bfa80d@ideasonboard.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]