Show a patch.

GET /api/patches/27076/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 27076,
    "url": "https://patchwork.libcamera.org/api/patches/27076/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/27076/",
    "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": "<20260629094216.747340-4-naush@raspberrypi.com>",
    "date": "2026-06-29T08:36:42",
    "name": "[v2,3/3] libcamera: formats: Add NV12MT_COL128 8/10-bit pixel formats",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "bed9047ca24fa845d15ffea48fa47a16b37aa11d",
    "submitter": {
        "id": 34,
        "url": "https://patchwork.libcamera.org/api/people/34/?format=api",
        "name": "Naushir Patuck",
        "email": "naush@raspberrypi.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/27076/mbox/",
    "series": [
        {
            "id": 6023,
            "url": "https://patchwork.libcamera.org/api/series/6023/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=6023",
            "date": "2026-06-29T08:36:39",
            "name": "Add NV12MT_COL128 8/10-bit pixel formats",
            "version": 2,
            "mbox": "https://patchwork.libcamera.org/series/6023/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/27076/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/27076/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 97410C3303\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 29 Jun 2026 09:42:32 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5A4A665F11;\n\tMon, 29 Jun 2026 11:42:29 +0200 (CEST)",
            "from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com\n\t[IPv6:2a00:1450:4864:20::32a])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 92535658B4\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 29 Jun 2026 11:42:26 +0200 (CEST)",
            "by mail-wm1-x32a.google.com with SMTP id\n\t5b1f17b1804b1-490791a3e92so1564325e9.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 29 Jun 2026 02:42:26 -0700 (PDT)",
            "from naush-dell.pitowers.org\n\t([2a00:1098:3142:1f:496e:3dec:bc78:809f])\n\tby smtp.gmail.com with ESMTPSA id\n\t5b1f17b1804b1-49268f700c0sm345499125e9.0.2026.06.29.02.42.25\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tMon, 29 Jun 2026 02:42:25 -0700 (PDT)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"R0IgBfQb\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google; t=1782726146; x=1783330946;\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:content-type;\n\tbh=h1rClfaffIT3DE8I5/juRuLpsPmXkec9YylWUf+GqM4=;\n\tb=R0IgBfQbQTcT7fAKRMWkG8BeC7faLP9aBwjF/QGLIQm/ojPzembEDIvbTwLJU2cMIn\n\t1Me3Z/nKWQJDhtCB5BC+Aij5nI9Iwx3eU0t+rjmgu6MTfLoWLyBKmEwcY2IGEKEaIasI\n\tj3vK1DQaSuEwfplMp8Qhd5RzvW+d0H1e553tPLTYFeB/7nE2eJ4aPuouNnHEOP8bWJLm\n\t3j1KGCXM02mu/0jqozX9WCdIHINGwCJCiHd24aBkrrStskx0L0FrZ4LKMPHSzQ+qf5dc\n\tevzwxAb2pEtVeXrCdY9tBnCdstJyp25yg44luMZ3fII7TTHwrPvjo/DWWukKqyr8hOBF\n\tDnEw==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20251104; t=1782726146; x=1783330946;\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:content-type;\n\tbh=h1rClfaffIT3DE8I5/juRuLpsPmXkec9YylWUf+GqM4=;\n\tb=OnzjNaf2N2Rm4630Jrc8Xr2mOkutwuyjyszw7u2xec8eqqTgYstO3AmGgo/H8BV34Z\n\twRLEASFSTiGkKjIAzG/z1ArHkTwc6DCm3jL+TJ0+8RgHmt3vGsRzSNR93cdnzrUchq+c\n\tIHckQOBR0Acek1H9xBkQvXG0pEqkAYRqQB3f6LctYFzBkMkDulsshYmP41u3FQW+WSZ9\n\tjc7SjrT/ZtRsaAWjfCFx6ldjgk1ekesqv3iHvD5tKsuOeP0XXVEPouTR6ii/k0hTN6a+\n\tDlg/dCVE6s2M7f7tP02ia/0GEobS9XI4nYmc8McCwFEDlqeWKVKukuusE6NVGjdM2Xjq\n\tfYAw==",
        "X-Gm-Message-State": "AOJu0YxuP6HV4Up+hVKF0LCJQMCZVDJu507vpcmHcBo8/QT9jafytwew\n\toD61r5wmUH9uuzPRZvzZEn1uk6MRlC6bzLJ+QTi9mV2qp+ifI56vHQOhlLAf4nC16vrSI4eR/AS\n\tfKIm0iq4=",
        "X-Gm-Gg": "AfdE7cm7l4LYvRRAMXus+1i8+dPBS8i+rNHixCT0JJjpW5syK0rJ1NkdHbqPUHUNlyc\n\tUVldBDXq0kWBULgpsQ++O7kQK5VkuFMcxLSJCApnRl44CraALegy7x8bbwqDFquJ2QhKtmaLXY3\n\tr4+EOAYhtJ3RSOzcw966HSPxNv7fW75lpgLMhedDhYM8ck9FfXLs6T3eRjfPj4ZrWr1yVJCJH0C\n\tCKKduNpK8zSickFUoN32tO2qe6lx+9e3lPbV4OjqWVHUOH3zOZeVLOT46tmJdH3rOp7zeFLNHsv\n\tWcTd7u2DcYybZ9RXdRK9VZE6v7DUdgkUnmcAh6AkdifZPDa11nte7InQ4qcrKnJAYFw7w8NKMDJ\n\t/Fe6eLwipKrODjz7bUBTQJx3UQGU+NVieP673OtKTR+RU5qntVvVLQda2dvxDMTo3uMc5lg7CRs\n\t6i7rftdMjzLU8u5eCVO+DwS7tOhXp8MPkp9eFEcjUXT4OW9VC5oeFD/wZQGRcSQ9UmdLGm8YGrh\n\tZfewans27VYFuFTa38mFJu6ZDZHN1nXGwavpmViGFi/8CKyFjTisD1VfRWzsA/S1ujE25+vkBp4\n\tI7jFbrIbRqzR6tefSaaK",
        "X-Received": "by 2002:a05:600c:4714:b0:490:e919:7bba with SMTP id\n\t5b1f17b1804b1-492668b80a8mr120274055e9.8.1782726146045; \n\tMon, 29 Jun 2026 02:42:26 -0700 (PDT)",
        "From": "Naushir Patuck <naush@raspberrypi.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Cc": "Naushir Patuck <naush@raspberrypi.com>",
        "Subject": "[PATCH v2 3/3] libcamera: formats: Add NV12MT_COL128 8/10-bit pixel\n\tformats",
        "Date": "Mon, 29 Jun 2026 09:36:42 +0100",
        "Message-ID": "<20260629094216.747340-4-naush@raspberrypi.com>",
        "X-Mailer": "git-send-email 2.53.0",
        "In-Reply-To": "<20260629094216.747340-1-naush@raspberrypi.com>",
        "References": "<20260629094216.747340-1-naush@raspberrypi.com>",
        "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": "Add the NV12MT_COL128 (NV12 8-bit) and NV12MT_10_COL128 (P030 10-bit)\ncolumn layout pixel formats available from the PiSP Backend hardware.\n\nMap the matching V4L2 FourCCs to the libcamera::formats conversion table.\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\n---\n src/libcamera/formats.cpp          | 20 ++++++++++++++++++++\n src/libcamera/formats.yaml         |  6 ++++++\n src/libcamera/v4l2_pixelformat.cpp |  4 ++++\n 3 files changed, 30 insertions(+)",
    "diff": "diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp\nindex bfcdfc08960d..c407802ea135 100644\n--- a/src/libcamera/formats.cpp\n+++ b/src/libcamera/formats.cpp\n@@ -366,6 +366,26 @@ const std::map<PixelFormat, PixelFormatInfo> pixelFormatInfo{\n \t\t.pixelsPerGroup = 2,\n \t\t.planes = {{ { 2, 1 }, { 2, 2 }, { 0, 0 } }},\n \t} },\n+\t{ formats::NV12MT_COL128, {\n+\t\t.name = \"NV12MT_COL128\",\n+\t\t.format = formats::NV12MT_COL128,\n+\t\t.v4l2Formats = { V4L2PixelFormat(V4L2_PIX_FMT_NV12MT_COL128), },\n+\t\t.bitsPerPixel = 12,\n+\t\t.colourEncoding = PixelFormatInfo::ColourEncodingYUV,\n+\t\t.packed = false,\n+\t\t.pixelsPerGroup = 2,\n+\t\t.planes = {{ { 2, 1 }, { 2, 2 }, { 0, 0 } }},\n+\t} },\n+\t{ formats::NV12MT_10_COL128, {\n+\t\t.name = \"NV12MT_10_COL128\",\n+\t\t.format = formats::NV12MT_10_COL128,\n+\t\t.v4l2Formats = { V4L2PixelFormat(V4L2_PIX_FMT_NV12MT_10_COL128), },\n+\t\t.bitsPerPixel = 15,\n+\t\t.colourEncoding = PixelFormatInfo::ColourEncodingYUV,\n+\t\t.packed = true,\n+\t\t.pixelsPerGroup = 6,\n+\t\t.planes = {{ { 8, 1 }, { 8, 2 }, { 0, 0 } }},\n+\t} },\n \t{ formats::NV21, {\n \t\t.name = \"NV21\",\n \t\t.format = formats::NV21,\ndiff --git a/src/libcamera/formats.yaml b/src/libcamera/formats.yaml\nindex 2d54d391ca01..3bf010c47aa6 100644\n--- a/src/libcamera/formats.yaml\n+++ b/src/libcamera/formats.yaml\n@@ -73,6 +73,12 @@ formats:\n       fourcc: DRM_FORMAT_NV24\n   - NV42:\n       fourcc: DRM_FORMAT_NV42\n+  - NV12MT_COL128:\n+      fourcc: DRM_FORMAT_NV12\n+      mod: DRM_FORMAT_MOD_BROADCOM_SAND128\n+  - NV12MT_10_COL128:\n+      fourcc: DRM_FORMAT_P030\n+      mod: DRM_FORMAT_MOD_BROADCOM_SAND128\n \n   - YUV420:\n       fourcc: DRM_FORMAT_YUV420\ndiff --git a/src/libcamera/v4l2_pixelformat.cpp b/src/libcamera/v4l2_pixelformat.cpp\nindex e8b3eb9c1394..bfd662b0de47 100644\n--- a/src/libcamera/v4l2_pixelformat.cpp\n+++ b/src/libcamera/v4l2_pixelformat.cpp\n@@ -103,6 +103,10 @@ const std::map<V4L2PixelFormat, V4L2PixelFormat::Info> vpf2pf{\n \t\t{ formats::NV12, \"Y/CbCr 4:2:0\" } },\n \t{ V4L2PixelFormat(V4L2_PIX_FMT_NV12M),\n \t\t{ formats::NV12, \"Y/CbCr 4:2:0 (N-C)\" } },\n+\t{ V4L2PixelFormat(V4L2_PIX_FMT_NV12MT_COL128),\n+\t\t{ formats::NV12MT_COL128, \"Y/CbCr 4:2:0 (128 col)\" } },\n+\t{ V4L2PixelFormat(V4L2_PIX_FMT_NV12MT_10_COL128),\n+\t\t{ formats::NV12MT_10_COL128, \"10-bit Y/CbCr 4:2:0 (128 col)\" } },\n \t{ V4L2PixelFormat(V4L2_PIX_FMT_NV21),\n \t\t{ formats::NV21, \"Y/CrCb 4:2:0\" } },\n \t{ V4L2PixelFormat(V4L2_PIX_FMT_NV21M),\n",
    "prefixes": [
        "v2",
        "3/3"
    ]
}