Patch Detail
Show a patch.
GET /api/patches/25305/?format=api
{ "id": 25305, "url": "https://patchwork.libcamera.org/api/patches/25305/?format=api", "web_url": "https://patchwork.libcamera.org/patch/25305/", "project": { "id": 1, "url": "https://patchwork.libcamera.org/api/projects/1/?format=api", "name": "libcamera", "link_name": "libcamera", "list_id": "libcamera_core", "list_email": "libcamera-devel@lists.libcamera.org", "web_url": "", "scm_url": "", "webscm_url": "" }, "msgid": "<20251202133157.661407-20-bryan.odonoghue@linaro.org>", "date": "2025-12-02T13:31:50", "name": "[v3,19/22] libcamera: software_isp: lut: Make CCM available in debayer params", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "f9a37f61045bc5413e56d460d2e1b8c1956e3e48", "submitter": { "id": 175, "url": "https://patchwork.libcamera.org/api/people/175/?format=api", "name": "Bryan O'Donoghue", "email": "bryan.odonoghue@linaro.org" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/25305/mbox/", "series": [ { "id": 5630, "url": "https://patchwork.libcamera.org/api/series/5630/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=5630", "date": "2025-12-02T13:31:31", "name": "GPUISP precursor series", "version": 3, "mbox": "https://patchwork.libcamera.org/series/5630/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/25305/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/25305/checks/", "tags": {}, "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 E4318C32F6\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 2 Dec 2025 13:32:36 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 2D6E860D2E;\n\tTue, 2 Dec 2025 14:32:36 +0100 (CET)", "from mail-wm1-x329.google.com (mail-wm1-x329.google.com\n\t[IPv6:2a00:1450:4864:20::329])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 5F94C60C8C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 2 Dec 2025 14:32:23 +0100 (CET)", "by mail-wm1-x329.google.com with SMTP id\n\t5b1f17b1804b1-4779adb38d3so40879445e9.2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 02 Dec 2025 05:32:23 -0800 (PST)", "from inspiron14p-linux.ht.home (188-141-3-146.dynamic.upc.ie.\n\t[188.141.3.146]) by smtp.gmail.com with ESMTPSA id\n\tffacd0b85a97d-42e1c5c30c4sm33363322f8f.9.2025.12.02.05.32.21\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tTue, 02 Dec 2025 05:32:22 -0800 (PST)" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key;\n\tunprotected) header.d=linaro.org header.i=@linaro.org\n\theader.b=\"SVTXga2A\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=linaro.org; s=google; t=1764682343; x=1765287143;\n\tdarn=lists.libcamera.org; \n\th=content-transfer-encoding:mime-version:references:in-reply-to\n\t:message-id:date:subject:cc:to:from:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=gUmuV/z7G3dP1f3bLqB1UdRo5tMX4cRhpEPrzATFtaw=;\n\tb=SVTXga2AA4MzR1tVEDcKkia2d/XLqZ0BjCKycyf0JaYa+HMvvKi3wIW/46YbVtUL2U\n\tEZvU3tfCUf7Cf6y9HvjqN0m6wLJNr3SC6IwcDI+AhPbEQDdp7s1AI3wVNuFIZvUOK1Ny\n\tddUxSArMq4tIsRSb+6RNO0NR3tPicv/hIFMfljUFBpw8Etst+EE0VBDTDU/+/ArowdnK\n\tJyUeoh8dGcOiSWoYEJ3ZWqg5CsEM7vzlBCAyDFK+Rbf873/v+NG5tP3cN8Fhl8ObxA5c\n\tORtgd6MFT1SX1ueRZhenj9ghobhggpySmsvymvNBEuu0EoP5iH9u7kMSEhgWGnSc+r3Z\n\twSWg==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1764682343; x=1765287143;\n\th=content-transfer-encoding:mime-version:references:in-reply-to\n\t:message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n\t:to:cc:subject:date:message-id:reply-to;\n\tbh=gUmuV/z7G3dP1f3bLqB1UdRo5tMX4cRhpEPrzATFtaw=;\n\tb=hYY6sb/93GoqqZALNUEee2/I9kaj1clUZxwZyhx4KzbNImD/vPC/Y/xb1F+QxHK8Z8\n\tD7dU/A4IezmhbH9X5BKjy2UCABdS1xS02Os2Ibk+IZKZO4iqse3LDz99+3Jrle2HpQ6J\n\tmGqApOYe62Fv+0GKKUZ+qCRfMhCrR+XXmKFaWslaKPn/HNiXEoWr6pWiLp5ehb2QXz1a\n\t/CGBqDjhwTHIaXqqNllf7Sz0MOn3R3PwrCrB14cbyF4h8hPPyuJUru6Rpp8QsQfSqtoG\n\tpvVnwbiVmx8LCAU9IspisOwITgRlpg5hP5HHgUvEAGZhBPTzxYSe9mIJEYtyyWauIywg\n\thZDA==", "X-Gm-Message-State": "AOJu0Yx9C7M+yo2e3jtHKh78KGJO6uSGip6PzUlRHEOLcSbTVMiajnz3\n\tQ115a7/qJ3UA2PojZgBRPgz4iFdqPZpFvLQGK8Gi2SYPgZCuAJDdK4DLUVOmQb+Od6ECtbYbjXB\n\tP0Yoe", "X-Gm-Gg": "ASbGncspYXmK1a/JWoWrHY2AG71zcoiXUUz+OyPuTnS8vEVXkvXeAY7FyTjCwGpBmoJ\n\tlTrFDzYiENBlBh1RqljWNVOH0UNLxn8LTAseNoblTQFydFYOleV6wYCqMP8m8In5kDWdw4xNG3s\n\t0hqyaz1VnqtRaaKZLWqY10Jn9QS5LEtbg8WsL8e6kA9OIqM53lEji51PK/gcTxj8S/Gr0tpd52z\n\tMQYNvpQGl9cVl6jhYhorNnBvZaZPVH+Zntk7l0KPaXD3UgIqvPo8yBRe7ihpCrvJHExUtWt/PQ7\n\tWEh+1y1u/ChjEyN1VY9dvfPMSvt3dK18zlILdBbp9tDK9DMUlIKiabxq5zlxwWJI9jhDGFOs7Bx\n\tlfh8kjyvjwq615tVHMWJr4GnkOp3WgPivuwjqXChAOdXNsi50rl0TN3nIo8wctXbtGOX01A0m6H\n\tvFRwYNcxzEZKx1aQAjkh+jEc9cLcteSaRl7AEVFw5kIT/xvLOFINZmt4QpYYxWfanXcZzU9LfcM\n\tjPqCQ==", "X-Google-Smtp-Source": "AGHT+IHb7tLrpITkVqdYAQ7qoPKz9D2P6xJ9vZlNWYU6UOiV853XtpDbSbAvNA6vOaZj/D5/SbGUdQ==", "X-Received": "by 2002:adf:b30a:0:b0:42b:3592:1b92 with SMTP id\n\tffacd0b85a97d-42e0f34fdd3mr24491080f8f.47.1764682342564; \n\tTue, 02 Dec 2025 05:32:22 -0800 (PST)", "From": "Bryan O'Donoghue <bryan.odonoghue@linaro.org>", "To": "libcamera-devel@lists.libcamera.org", "Cc": "pavel@ucw.cz, Bryan O'Donoghue <bryan.odonoghue@linaro.org>,\n\tKieran Bingham <kieran.bingham@ideasonboard.com>", "Subject": "[PATCH v3 19/22] libcamera: software_isp: lut: Make CCM available in\n\tdebayer params", "Date": "Tue, 2 Dec 2025 13:31:50 +0000", "Message-ID": "<20251202133157.661407-20-bryan.odonoghue@linaro.org>", "X-Mailer": "git-send-email 2.52.0", "In-Reply-To": "<20251202133157.661407-1-bryan.odonoghue@linaro.org>", "References": "<20251202133157.661407-1-bryan.odonoghue@linaro.org>", "MIME-Version": "1.0", "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>" }, "content": "Provide the CCM calculated in LUT to the debayer params structure for\nconsumption in the debayer shaders.\n\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\nSigned-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>\n---\n include/libcamera/internal/software_isp/debayer_params.h | 7 +++++++\n src/ipa/simple/algorithms/lut.cpp | 1 +\n src/libcamera/software_isp/debayer.cpp | 5 +++++\n 3 files changed, 13 insertions(+)", "diff": "diff --git a/include/libcamera/internal/software_isp/debayer_params.h b/include/libcamera/internal/software_isp/debayer_params.h\nindex 217cd5d92..4b203e211 100644\n--- a/include/libcamera/internal/software_isp/debayer_params.h\n+++ b/include/libcamera/internal/software_isp/debayer_params.h\n@@ -13,6 +13,8 @@\n #include <array>\n #include <stdint.h>\n \n+#include \"libcamera/internal/matrix.h\"\n+\n namespace libcamera {\n \n struct DebayerParams {\n@@ -49,6 +51,11 @@ struct DebayerParams {\n \tCcmLookupTable greenCcm;\n \tCcmLookupTable blueCcm;\n \tLookupTable gammaLut;\n+\n+\t/*\n+\t * Per frame corrections as calculated by the IPA\n+\t */\n+\tMatrix<float, 3, 3> ccm;\n };\n \n } /* namespace libcamera */\ndiff --git a/src/ipa/simple/algorithms/lut.cpp b/src/ipa/simple/algorithms/lut.cpp\nindex d4a79e101..49482d711 100644\n--- a/src/ipa/simple/algorithms/lut.cpp\n+++ b/src/ipa/simple/algorithms/lut.cpp\n@@ -133,6 +133,7 @@ void Lut::prepare(IPAContext &context,\n \t\tauto &red = params->redCcm;\n \t\tauto &green = params->greenCcm;\n \t\tauto &blue = params->blueCcm;\n+\t\tparams->ccm = ccm;\n \t\tfor (unsigned int i = 0; i < DebayerParams::kRGBLookupSize; i++) {\n \t\t\tred[i].r = ccmValue(i, ccm[0][0]);\n \t\t\tred[i].g = ccmValue(i, ccm[1][0]);\ndiff --git a/src/libcamera/software_isp/debayer.cpp b/src/libcamera/software_isp/debayer.cpp\nindex dae1f12d9..f5c94bb8c 100644\n--- a/src/libcamera/software_isp/debayer.cpp\n+++ b/src/libcamera/software_isp/debayer.cpp\n@@ -100,6 +100,11 @@ namespace libcamera {\n * \\brief Gamma lookup table used with color correction matrix\n */\n \n+/**\n+ * \\var DebayerParams::ccm\n+ * \\brief Per frame colour correction matrix for GPUISP\n+ */\n+\n /**\n * \\class Debayer\n * \\brief Base debayering class\n", "prefixes": [ "v3", "19/22" ] }