[{"id":36276,"web_url":"https://patchwork.libcamera.org/comment/36276/","msgid":"<176056809381.162040.7647785666767256073@ping.linuxembedded.co.uk>","date":"2025-10-15T22:41:33","subject":"Re: [PATCH v3 21/39] libcamera: software_isp: ccm: Populate CCM\n\ttable to Debayer params structure","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Bryan O'Donoghue (2025-10-15 02:22:33)\n> Populate the DebayerParams CCM table during ccm::prepare(). A copy is made\n> of the CCM into the DebayerParams structure.\n\nI think I would squash this down into\n[PATCH v3 18/39] libcamera: software_isp: debayer: Extend DebayerParams struct to hold a copy of per-frame CCM values\n\nas they are so closely related.\n\n> \n> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>\n> ---\n>  src/ipa/simple/algorithms/ccm.cpp | 4 +++-\n>  1 file changed, 3 insertions(+), 1 deletion(-)\n> \n> diff --git a/src/ipa/simple/algorithms/ccm.cpp b/src/ipa/simple/algorithms/ccm.cpp\n> index 0a98406c..cb023878 100644\n> --- a/src/ipa/simple/algorithms/ccm.cpp\n> +++ b/src/ipa/simple/algorithms/ccm.cpp\n> @@ -14,6 +14,7 @@\n>  #include <libcamera/control_ids.h>\n>  \n>  #include \"libcamera/internal/matrix.h\"\n> +#include \"libcamera/internal/software_isp/debayer_params.h\"\n>  \n>  namespace {\n>  \n> @@ -84,7 +85,7 @@ void Ccm::applySaturation(Matrix<float, 3, 3> &ccm, float saturation)\n>  }\n>  \n>  void Ccm::prepare(IPAContext &context, const uint32_t frame,\n> -                 IPAFrameContext &frameContext, [[maybe_unused]] DebayerParams *params)\n> +                 IPAFrameContext &frameContext, DebayerParams *params)\n>  {\n>         auto &saturation = context.activeState.knobs.saturation;\n>  \n> @@ -108,6 +109,7 @@ void Ccm::prepare(IPAContext &context, const uint32_t frame,\n>         context.activeState.ccm.ccm = ccm;\n>         frameContext.ccm.ccm = ccm;\n>         frameContext.saturation = saturation;\n> +       params->ccm = ccm;\n>         context.activeState.ccm.changed = true;\n>  }\n>  \n> -- \n> 2.51.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 1EC45BE080\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 15 Oct 2025 22:41:38 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id CE5F66063D;\n\tThu, 16 Oct 2025 00:41:37 +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 8D004605F3\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 16 Oct 2025 00:41:36 +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 18356558;\n\tThu, 16 Oct 2025 00:39:57 +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=\"vdCAgwK3\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1760567997;\n\tbh=6kqQarU/AP0yOaYP70kt7Z7ZGBM0xENOQV6jhF32fJ4=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=vdCAgwK3fXPBhJqNr6qu584n9GPFi2mgbN2pGSpzyo0GoaT/BBp87PcmUNYd1bpxY\n\tgLgagoBDwuon3Hy6fZRxKhpQ9XzghcjgiSLz/mhENG50rcWMtn1XtpPh02zkcB5m3w\n\tpSACvjH/NZLoSFVke6HfOQqadU6kAOcnXiDkDqAc=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20251015012251.17508-22-bryan.odonoghue@linaro.org>","References":"<20251015012251.17508-1-bryan.odonoghue@linaro.org>\n\t<20251015012251.17508-22-bryan.odonoghue@linaro.org>","Subject":"Re: [PATCH v3 21/39] libcamera: software_isp: ccm: Populate CCM\n\ttable to Debayer params structure","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"hdegoede@redhat.com, mzamazal@redhat.com, bryan.odonoghue@linaro.org,\n\tbod.linux@nxsw.ie","To":"Bryan O'Donoghue <bryan.odonoghue@linaro.org>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Wed, 15 Oct 2025 23:41:33 +0100","Message-ID":"<176056809381.162040.7647785666767256073@ping.linuxembedded.co.uk>","User-Agent":"alot/0.9.1","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":36307,"web_url":"https://patchwork.libcamera.org/comment/36307/","msgid":"<855xcffbgl.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","date":"2025-10-16T09:22:02","subject":"Re: [PATCH v3 21/39] libcamera: software_isp: ccm: Populate CCM\n\ttable to Debayer params structure","submitter":{"id":177,"url":"https://patchwork.libcamera.org/api/people/177/","name":"Milan Zamazal","email":"mzamazal@redhat.com"},"content":"Bryan O'Donoghue <bryan.odonoghue@linaro.org> writes:\n\n> Populate the DebayerParams CCM table during ccm::prepare(). A copy is made\n> of the CCM into the DebayerParams structure.\n>\n> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>\n\nReviewed-by: Milan Zamazal <mzamazal@redhat.com>\n\n> ---\n>  src/ipa/simple/algorithms/ccm.cpp | 4 +++-\n>  1 file changed, 3 insertions(+), 1 deletion(-)\n>\n> diff --git a/src/ipa/simple/algorithms/ccm.cpp b/src/ipa/simple/algorithms/ccm.cpp\n> index 0a98406c..cb023878 100644\n> --- a/src/ipa/simple/algorithms/ccm.cpp\n> +++ b/src/ipa/simple/algorithms/ccm.cpp\n> @@ -14,6 +14,7 @@\n>  #include <libcamera/control_ids.h>\n>  \n>  #include \"libcamera/internal/matrix.h\"\n> +#include \"libcamera/internal/software_isp/debayer_params.h\"\n>  \n>  namespace {\n>  \n> @@ -84,7 +85,7 @@ void Ccm::applySaturation(Matrix<float, 3, 3> &ccm, float saturation)\n>  }\n>  \n>  void Ccm::prepare(IPAContext &context, const uint32_t frame,\n> -\t\t  IPAFrameContext &frameContext, [[maybe_unused]] DebayerParams *params)\n> +\t\t  IPAFrameContext &frameContext, DebayerParams *params)\n>  {\n>  \tauto &saturation = context.activeState.knobs.saturation;\n>  \n> @@ -108,6 +109,7 @@ void Ccm::prepare(IPAContext &context, const uint32_t frame,\n>  \tcontext.activeState.ccm.ccm = ccm;\n>  \tframeContext.ccm.ccm = ccm;\n>  \tframeContext.saturation = saturation;\n> +\tparams->ccm = ccm;\n>  \tcontext.activeState.ccm.changed = true;\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 252CCC3259\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 16 Oct 2025 09:22:10 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id C0B0F6067B;\n\tThu, 16 Oct 2025 11:22:09 +0200 (CEST)","from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.133.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 915BC60669\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 16 Oct 2025 11:22:07 +0200 (CEST)","from mail-ej1-f71.google.com (mail-ej1-f71.google.com\n\t[209.85.218.71]) by relay.mimecast.com with ESMTP with STARTTLS\n\t(version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n\tus-mta-494-tHZTT06UOYeTJyehe-jTmQ-1; Thu, 16 Oct 2025 05:22:05 -0400","by mail-ej1-f71.google.com with SMTP id\n\ta640c23a62f3a-b5ad0887b1bso44251766b.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 16 Oct 2025 02:22:05 -0700 (PDT)","from mzamazal-thinkpadp1gen7.tpbc.csb\n\t(ip-77-48-47-2.net.vodafone.cz. [77.48.47.2])\n\tby smtp.gmail.com with ESMTPSA id\n\ta640c23a62f3a-b5cb965c4dasm458521166b.9.2025.10.16.02.22.02\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 16 Oct 2025 02:22:03 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=redhat.com header.i=@redhat.com\n\theader.b=\"dMkepBOL\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1760606526;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=8PKyzBsSN2KoP0XLn/1SHcvxv+qwzDxn9jr4xMqYx9o=;\n\tb=dMkepBOLLSu+Nx2edpvJErrBS5kQMyHKIZtTx0qAb2/SpOc8EJ7BEzMI0kAXMeTV3twS7l\n\t5p+kPlSxAh8KtJWL/nU0rG2Tr1CNevhKKVU38q1zn/fecHuohtsSg/Z+E8dJrS1nhRvoqv\n\tj9auHFuTDn5PMAccm0Tk9Ctf0WPq4Kg=","X-MC-Unique":"tHZTT06UOYeTJyehe-jTmQ-1","X-Mimecast-MFC-AGG-ID":"tHZTT06UOYeTJyehe-jTmQ_1760606524","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1760606524; x=1761211324;\n\th=mime-version:user-agent:message-id:date:references:in-reply-to\n\t:subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=8PKyzBsSN2KoP0XLn/1SHcvxv+qwzDxn9jr4xMqYx9o=;\n\tb=QsL2R954yHURE3WSEFFXLnD/XQHoY/5ZIupJVFM3QDD+JPf3kwC0uxN+RL5pVvZV/J\n\tslhTnNbbByCRiZhYA3sH4P/3j0ZtwARbUzhz5giJAqg9y/uMS6c/R5AxzhjjcqrayebR\n\tuy0ZBcdXoj3HAzb1A3Bl+KLoedH2a68h8zmTiB8l6rKg5/2MxBjYi65D/rF5lQYer+EC\n\t3aRl9poYnPnLQS0pdP4zyMRn2RDHqo2tvlswFnjKO1xCUL/PGhnfLSCInufI9FpoK8nW\n\tDTdZabqmq0I4XsOTYTURwPlhH8nkKZDcEUbvMsQiZWNAo0C6veeuOs+NpyQm6qObo1ip\n\tVW+g==","X-Gm-Message-State":"AOJu0YwVzQnWq0Ppg889LUkSMF/+qhqXRlX/LOOIObds4k4LQTAdTHaK\n\t/DmamiocW+QQ3LgzNN3n7Y3VqA6q8OEDAOE2vePmgtdprCC1vErlftyKfrAZxoeIZxlPZjIxQiB\n\tiRN49ak+Rg9EKjqtnWYlErFl17jwiU0WyC6CuZ22w1ZOhMvk3zrR5Pscuxxou2ph/V1OsTktQQ5\n\t0=","X-Gm-Gg":"ASbGncu4CbDd8Zn82GGdiLmIpmYXlVAE5hLJsl16+DWPdhAWFdPGCwKqHbNs0gJnO7n\n\ty7zQvrgxlfv3wPumx/DNxk3BF81YlLB3qXjWBX4AjLcHs7TViyCRatE/R9jMfysviA4fJ4qzLk7\n\tDdN56RukzV3k27mizyRVWbgSQxKGVJONmO6NMG18vJcwxfk5iLgLoqKeC99VV3AE3aESVXmflE3\n\txQxcro3PuTotas2xKeN8rM+Ncdr6kDbuI3Iq5WlvO+/Xb1k/jjCsXzAqAO+FLu2diPXg5uQKSMn\n\tlc41FErSb3CkAnXgDf4KxObhyIUbHlVbaQI8saPUsveNfTSLORnwTEXB5/28HPFCczphUTQdfsO\n\tNDH5fHcJsZv0xQK3K67fj2CC6agi1/jz2rs3veUzBXALW3YR5awkV","X-Received":["by 2002:a17:906:eec8:b0:afa:1d2c:bbd1 with SMTP id\n\ta640c23a62f3a-b6053f1e71dmr403574766b.30.1760606524111; \n\tThu, 16 Oct 2025 02:22:04 -0700 (PDT)","by 2002:a17:906:eec8:b0:afa:1d2c:bbd1 with SMTP id\n\ta640c23a62f3a-b6053f1e71dmr403571566b.30.1760606523660; \n\tThu, 16 Oct 2025 02:22:03 -0700 (PDT)"],"X-Google-Smtp-Source":"AGHT+IEMIZyvwFmcwUHHL+OKKDy05/VCqDk5sQi1YbjtQI3jTljYeLwRn4PmdSZrpEDRYGsP8enpRQ==","From":"Milan Zamazal <mzamazal@redhat.com>","To":"Bryan O'Donoghue <bryan.odonoghue@linaro.org>","Cc":"libcamera-devel@lists.libcamera.org,  hdegoede@redhat.com,\n\tbod.linux@nxsw.ie","Subject":"Re: [PATCH v3 21/39] libcamera: software_isp: ccm: Populate CCM\n\ttable to Debayer params structure","In-Reply-To":"<20251015012251.17508-22-bryan.odonoghue@linaro.org> (Bryan\n\tO'Donoghue's message of \"Wed, 15 Oct 2025 02:22:33 +0100\")","References":"<20251015012251.17508-1-bryan.odonoghue@linaro.org>\n\t<20251015012251.17508-22-bryan.odonoghue@linaro.org>","Date":"Thu, 16 Oct 2025 11:22:02 +0200","Message-ID":"<855xcffbgl.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","User-Agent":"Gnus/5.13 (Gnus v5.13)","MIME-Version":"1.0","X-Mimecast-Spam-Score":"0","X-Mimecast-MFC-PROC-ID":"XZoukEGRZzld-M0CBAZHOorfx_YIpAJImAjy7WTV_AM_1760606524","X-Mimecast-Originator":"redhat.com","Content-Type":"text/plain","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>"}}]