{"id":14379,"url":"https://patchwork.libcamera.org/api/patches/14379/?format=json","web_url":"https://patchwork.libcamera.org/patch/14379/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20211028084646.453775-4-naush@raspberrypi.com>","date":"2021-10-28T08:46:39","name":"[libcamera-devel,v4,03/10] libcamera: formats: Add R10_CSI2P format","commit_ref":null,"pull_url":null,"state":"superseded","archived":false,"hash":"b825d243e35416f2ac88f6fb37ffc5e9ad2ab75d","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/people/34/?format=json","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/14379/mbox/","series":[{"id":2671,"url":"https://patchwork.libcamera.org/api/series/2671/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=2671","date":"2021-10-28T08:46:36","name":"Raspberry Pi: Conversion to media controller","version":4,"mbox":"https://patchwork.libcamera.org/series/2671/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/14379/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/14379/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 CEE44C324E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 28 Oct 2021 08:47:00 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 7E02860103;\n\tThu, 28 Oct 2021 10:47:00 +0200 (CEST)","from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com\n\t[IPv6:2a00:1450:4864:20::32c])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 6967C600C1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 28 Oct 2021 10:46:55 +0200 (CEST)","by mail-wm1-x32c.google.com with SMTP id\n\tg191-20020a1c9dc8000000b0032fbf912885so400029wme.4\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 28 Oct 2021 01:46:55 -0700 (PDT)","from naush-laptop.pitowers.org\n\t([2a00:1098:3142:14:b894:feb0:b828:13b])\n\tby smtp.gmail.com with ESMTPSA id\n\tz2sm1955281wmk.19.2021.10.28.01.46.54\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 28 Oct 2021 01:46:54 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"k5WurwBq\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=4gQklNV8u9ONgLGzJ6qWEeraVIm9dy+r6zmPAgc0niU=;\n\tb=k5WurwBqIzupnYPozqQGhulwXvwMuRmkD3Y6RQbOFGcnRSwlFD+eHDr7ZnvW9TKNnD\n\tE2BFmJFtSqmtxw5W2lENeKj9l120wLtkW9LHsY/iZiVRVefIMY8mdMnVGkaQI5E5O9VI\n\tnpw34zvSvKpxNMcq1BaNgQzv9cEmA+rNK2gC1RnKlSddxCirjD96/AVxk5O/KbGIaxXx\n\t8ZWO8orwKfkoNVOMwOz/ppIOvE8jObXW19S7Zdbck+mod3PIHrFYFMGUwgvFCN4cOALi\n\tQNGaBe0B4x/9j158X6HIcUwnZG7XV7Px0atoCmTKu11cPROPFDGmgomE86ybv9qITeS7\n\twIug==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=4gQklNV8u9ONgLGzJ6qWEeraVIm9dy+r6zmPAgc0niU=;\n\tb=DoJH+cJUp4wnSzYehPtQT5oC1hTMlWQSY8c2GCt68Zgj1TlkneNU4ruxg28T5wO0xT\n\tTdJsLqMlqPbPxOAZNVKLv8LZBmKl0rAEAT2OiVA7Pa0jM17Pk73XhgKEs+8O2k5MJBHs\n\tlhgcp8jw7UQIANrUTfTqos6EQ/xT9+SBjG0ux851SMcWI0rOLZ+LK9xl0UE04qm8gKh1\n\t9Xgy1vyGOJfGk8cLfcPEDHxJhBj6SDgONBTOoOQDZPRm3eqs3HvKQVidRrwaVAp6twDu\n\tgXtLQz6QTWj1R9dryTC25Lcuc7Kv3UI3y/bAiG7qZhPRaygNf9XjE2ExIVFM9VE8XcjX\n\tC5jQ==","X-Gm-Message-State":"AOAM530Hl8qRt0h6ocwtDNIgZd1ikZAUuS6EUO7Gnrm/E5eub8R/h/rp\n\tGxqJVixmn2tuqE7sdCheRVlMwio1bfvdtmsQ","X-Google-Smtp-Source":"ABdhPJzyM/BdTZQuOxYuHA+s52esfbJsueFZhUASvSE4M/HT6CFhNallhrm/wPi+UdW0G8bWWOir0Q==","X-Received":"by 2002:a05:600c:1d05:: with SMTP id\n\tl5mr3019192wms.97.1635410814889; \n\tThu, 28 Oct 2021 01:46:54 -0700 (PDT)","From":"Naushir Patuck <naush@raspberrypi.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Thu, 28 Oct 2021 09:46:39 +0100","Message-Id":"<20211028084646.453775-4-naush@raspberrypi.com>","X-Mailer":"git-send-email 2.25.1","In-Reply-To":"<20211028084646.453775-1-naush@raspberrypi.com>","References":"<20211028084646.453775-1-naush@raspberrypi.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH v4 03/10] libcamera: formats: Add\n\tR10_CSI2P format","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":"This new formats corresponds to the V4L2 V4L2_PIX_FMT_Y10P format, and is a\nCSI2-packed version of the DRM_FORMAT_R10 format.\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\n---\n src/libcamera/formats.cpp  | 13 +++++++++++++\n src/libcamera/formats.yaml |  4 ++++\n 2 files changed, 17 insertions(+)","diff":"diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp\nindex d4781dfb3874..9b6ccdca0663 100644\n--- a/src/libcamera/formats.cpp\n+++ b/src/libcamera/formats.cpp\n@@ -510,6 +510,19 @@ const std::map<PixelFormat, PixelFormatInfo> pixelFormatInfo{\n \t\t.pixelsPerGroup = 1,\n \t\t.planes = {{ { 2, 1 }, { 0, 0 }, { 0, 0 } }},\n \t} },\n+\t{ formats::R10_CSI2P, {\n+\t\t.name = \"R10_CSI2P\",\n+\t\t.format = formats::R10,\n+\t\t.v4l2Formats = {\n+\t\t\t.single = V4L2PixelFormat(V4L2_PIX_FMT_Y10P),\n+\t\t\t.multi = V4L2PixelFormat(),\n+\t\t},\n+\t\t.bitsPerPixel = 10,\n+\t\t.colourEncoding = PixelFormatInfo::ColourEncodingYUV,\n+\t\t.packed = true,\n+\t\t.pixelsPerGroup = 1,\n+\t\t.planes = {{ { 2, 1 }, { 0, 0 }, { 0, 0 } }},\n+\t} },\n \n \t/* Bayer formats. */\n \t{ formats::SBGGR8, {\ndiff --git a/src/libcamera/formats.yaml b/src/libcamera/formats.yaml\nindex 22a8e473a183..1f3f043302c3 100644\n--- a/src/libcamera/formats.yaml\n+++ b/src/libcamera/formats.yaml\n@@ -109,6 +109,10 @@ formats:\n   - SBGGR16:\n       fourcc: DRM_FORMAT_SBGGR16\n \n+  - R10_CSI2P:\n+      fourcc: DRM_FORMAT_R10\n+      mod: MIPI_FORMAT_MOD_CSI2_PACKED\n+\n   - SRGGB10_CSI2P:\n       fourcc: DRM_FORMAT_SRGGB10\n       mod: MIPI_FORMAT_MOD_CSI2_PACKED\n","prefixes":["libcamera-devel","v4","03/10"]}