[{"id":33802,"web_url":"https://patchwork.libcamera.org/comment/33802/","msgid":"<174344346008.3394313.6573952115737939198@ping.linuxembedded.co.uk>","date":"2025-03-31T17:51:00","subject":"Re: [PATCH v2 15/17] ipa: rkisp1: awb: Set rgb mean limits to 180","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Stefan Klug (2025-03-19 16:11:20)\n> Set the mean limits to 180 to get reasonably good results from the rgb\n> estimations. This is only for internal development as there is no code\n> path to enable rgb estimations at runtime.\n> \n\nAcked-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n> Signed-off-by: Stefan Klug <stefan.klug@ideasonboard.com>\n> \n> ---\n> \n> Changes in v2:\n> - None\n> ---\n>  src/ipa/rkisp1/algorithms/awb.cpp | 6 +++---\n>  1 file changed, 3 insertions(+), 3 deletions(-)\n> \n> diff --git a/src/ipa/rkisp1/algorithms/awb.cpp b/src/ipa/rkisp1/algorithms/awb.cpp\n> index 149c6aa59c8d..324bc14b42a0 100644\n> --- a/src/ipa/rkisp1/algorithms/awb.cpp\n> +++ b/src/ipa/rkisp1/algorithms/awb.cpp\n> @@ -261,9 +261,9 @@ void Awb::prepare(IPAContext &context, const uint32_t frame,\n>                  * awb_ref_cr, awb_min_y and awb_ref_cb respectively. The other\n>                  * values are not used, set them to 0.\n>                  */\n> -               awbConfig->awb_ref_cr = 250;\n> -               awbConfig->min_y = 250;\n> -               awbConfig->awb_ref_cb = 250;\n> +               awbConfig->awb_ref_cr = 180;\n> +               awbConfig->min_y = 180;\n> +               awbConfig->awb_ref_cb = 180;\n>  \n>                 awbConfig->max_y = 0;\n>                 awbConfig->min_c = 0;\n> -- \n> 2.43.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 14F85C3213\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 31 Mar 2025 17:51:05 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id AF4FC68986;\n\tMon, 31 Mar 2025 19:51:04 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 0FDE868981\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 31 Mar 2025 19:51:03 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust6594.18-1.cable.virginm.net [86.31.185.195])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 7AE8D703;\n\tMon, 31 Mar 2025 19:49:11 +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=\"NvMVYILt\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1743443351;\n\tbh=CS3F01A5QzAn5nl+3NwQknHKXRra9Qct5K6D5IbwJwM=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=NvMVYILtwWK9rmT7AclDf+qrO2EAaGxW3sqHbtX/SaLe5CfIn8vbWGa3p7vtUS9N3\n\tjST90Ppsvj0P0i1qDZNJH8HguUKSHNbskkU3HyUlEeICxHQZOVIVv23vn3MzBxbo47\n\th+W/OdZlF3Pxnyv0fbINQO21/FOsXRpvaY6Grsoo=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20250319161152.63625-16-stefan.klug@ideasonboard.com>","References":"<20250319161152.63625-1-stefan.klug@ideasonboard.com>\n\t<20250319161152.63625-16-stefan.klug@ideasonboard.com>","Subject":"Re: [PATCH v2 15/17] ipa: rkisp1: awb: Set rgb mean limits to 180","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Stefan Klug <stefan.klug@ideasonboard.com>","To":"Stefan Klug <stefan.klug@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Mon, 31 Mar 2025 18:51:00 +0100","Message-ID":"<174344346008.3394313.6573952115737939198@ping.linuxembedded.co.uk>","User-Agent":"alot/0.10","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":33833,"web_url":"https://patchwork.libcamera.org/comment/33833/","msgid":"<20250401014315.GW14432@pendragon.ideasonboard.com>","date":"2025-04-01T01:43:15","subject":"Re: [PATCH v2 15/17] ipa: rkisp1: awb: Set rgb mean limits to 180","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Stefan,\n\nThank you for the patch.\n\nOn Wed, Mar 19, 2025 at 05:11:20PM +0100, Stefan Klug wrote:\n> Set the mean limits to 180 to get reasonably good results from the rgb\n> estimations. This is only for internal development as there is no code\n> path to enable rgb estimations at runtime.\n> \n> Signed-off-by: Stefan Klug <stefan.klug@ideasonboard.com>\n\nCould you add a short explanation here about why 180 is better than 250\n?\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n> ---\n> \n> Changes in v2:\n> - None\n> ---\n>  src/ipa/rkisp1/algorithms/awb.cpp | 6 +++---\n>  1 file changed, 3 insertions(+), 3 deletions(-)\n> \n> diff --git a/src/ipa/rkisp1/algorithms/awb.cpp b/src/ipa/rkisp1/algorithms/awb.cpp\n> index 149c6aa59c8d..324bc14b42a0 100644\n> --- a/src/ipa/rkisp1/algorithms/awb.cpp\n> +++ b/src/ipa/rkisp1/algorithms/awb.cpp\n> @@ -261,9 +261,9 @@ void Awb::prepare(IPAContext &context, const uint32_t frame,\n>  \t\t * awb_ref_cr, awb_min_y and awb_ref_cb respectively. The other\n>  \t\t * values are not used, set them to 0.\n>  \t\t */\n> -\t\tawbConfig->awb_ref_cr = 250;\n> -\t\tawbConfig->min_y = 250;\n> -\t\tawbConfig->awb_ref_cb = 250;\n> +\t\tawbConfig->awb_ref_cr = 180;\n> +\t\tawbConfig->min_y = 180;\n> +\t\tawbConfig->awb_ref_cb = 180;\n>  \n>  \t\tawbConfig->max_y = 0;\n>  \t\tawbConfig->min_c = 0;","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 84E38C3213\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue,  1 Apr 2025 01:43:43 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 97D726897E;\n\tTue,  1 Apr 2025 03:43:42 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 7767B62C66\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue,  1 Apr 2025 03:43:40 +0200 (CEST)","from pendragon.ideasonboard.com (85-76-147-224-nat.elisa-mobile.fi\n\t[85.76.147.224])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 152166F9;\n\tTue,  1 Apr 2025 03:41:48 +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=\"toXZvk/E\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1743471708;\n\tbh=64/+q7nacl6EH1C0qSgFm9iMU83RxbHbsj6A2h07xKY=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=toXZvk/EzrnjJ7y1kK4qqb0FVCfm3VPN/fKge7elMBFZ+HNyvMPnGfbpORUancmT2\n\tZpPb84zQLmbqdXX2ANIJ98Zy/tITXdzv32XZPThMn+qSG49KyLn8OMSjY6Xwr+JOhl\n\t2mnFpdmfC0sG7/RZEUgiBtED/PDrJy0mashOpgIw=","Date":"Tue, 1 Apr 2025 04:43:15 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Stefan Klug <stefan.klug@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH v2 15/17] ipa: rkisp1: awb: Set rgb mean limits to 180","Message-ID":"<20250401014315.GW14432@pendragon.ideasonboard.com>","References":"<20250319161152.63625-1-stefan.klug@ideasonboard.com>\n\t<20250319161152.63625-16-stefan.klug@ideasonboard.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20250319161152.63625-16-stefan.klug@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>"}}]