Show a patch.

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

{
    "id": 19147,
    "url": "https://patchwork.libcamera.org/api/1.1/patches/19147/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/19147/",
    "project": {
        "id": 1,
        "url": "https://patchwork.libcamera.org/api/1.1/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": "<20231019115220.4473-1-david.plowman@raspberrypi.com>",
    "date": "2023-10-19T11:52:20",
    "name": "[libcamera-devel,v3] libcamera: controls: Add controls for HDR",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "23b8f3b0ecb9029517e720d2efcfc310a5ba0839",
    "submitter": {
        "id": 42,
        "url": "https://patchwork.libcamera.org/api/1.1/people/42/?format=api",
        "name": "David Plowman",
        "email": "david.plowman@raspberrypi.com"
    },
    "delegate": null,
    "mbox": "https://patchwork.libcamera.org/patch/19147/mbox/",
    "series": [
        {
            "id": 4052,
            "url": "https://patchwork.libcamera.org/api/1.1/series/4052/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=4052",
            "date": "2023-10-19T11:52:20",
            "name": "[libcamera-devel,v3] libcamera: controls: Add controls for HDR",
            "version": 3,
            "mbox": "https://patchwork.libcamera.org/series/4052/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/19147/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/19147/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 4A294BDCBD\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 19 Oct 2023 11:52:27 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id A9BCB61DD2;\n\tThu, 19 Oct 2023 13:52:26 +0200 (CEST)",
            "from mail-wm1-x336.google.com (mail-wm1-x336.google.com\n\t[IPv6:2a00:1450:4864:20::336])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 749816055B\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 19 Oct 2023 13:52:25 +0200 (CEST)",
            "by mail-wm1-x336.google.com with SMTP id\n\t5b1f17b1804b1-405361bb94eso82310615e9.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 19 Oct 2023 04:52:25 -0700 (PDT)",
            "from pi5-davidp.pitowers.org\n\t([2a00:1098:3142:14:183e:6cc8:a436:a27c])\n\tby smtp.gmail.com with ESMTPSA id\n\tj20-20020a05600c1c1400b004065daba6casm4313789wms.46.2023.10.19.04.52.23\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 19 Oct 2023 04:52:23 -0700 (PDT)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1697716346;\n\tbh=r+WpUHdyhKOum5FUgcQGtMvWPAjhPTGCbKVC65+rC+4=;\n\th=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post:\n\tList-Help:List-Subscribe:From:Reply-To:From;\n\tb=VmwsGF7TBnt8MysJujsViKFYHQP1yS4Spl/cSLIO6lMMj+XPtJaD/dj1MwriN1Ier\n\t30Q1YTILRSDMRcTtgblgCnAEEGY7dfNBtUdNTNoN74CGaydw7gu9LJn7fK2LZoXYiB\n\tU+VohdoAlIAEf6cDnygcx6qeEech0LalmZ/OM9D67UIxSJxYNv5kndZi6pchPT1Kvg\n\tbYClJrgNv+MIC9i5df+4k/3WuRvdFtgl6Zrs04c/YQeM9GvTEcX0HPpwE9ll0qSAYe\n\tV+o/rtOJvTNl+bMI+CvwJmCmJAhWgoKYCScPHK04IGuZko3YX3K2RXTln1pNZA10sv\n\tQ4C0GzNkXrx3A==",
            "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google; t=1697716344; x=1698321144;\n\tdarn=lists.libcamera.org; \n\th=content-transfer-encoding:mime-version:message-id:date:subject:cc\n\t:to:from:from:to:cc:subject:date:message-id:reply-to;\n\tbh=qurrxL0MpuGh55LWDIGOT3M5T99WOrLm3HHCn2AnTCw=;\n\tb=b9Da24dl938ct2wRefP2fomDUfSK7QbdUxv+FDL/3NDJXYNVFaVq2UivE0AFsGFVMK\n\tDP78qAKdndgdnp1nbtdQijJKErbQ3XWmpOt9S8nGU1LwWVJCaJTevWZaunb5b2gE0J0X\n\tFgWeYQlD7qt8X8UT+dwx1GUog/sCTWjtLIojA66ay8oh0zGpo6EqFgn8ZYmJYZi+8mze\n\tdj7dp05R8fXG/ifpPMawmIzcZ8l9bGG83vepXu++KE3l+s3aw4A442bwt0+TGQyxNW0c\n\t+53tX1gzesGk7hY861BFKUdSy/wN5FJSO2+EasHWADAS/PUQqWqFIYPvWhFDrOjBsAee\n\tWg/w=="
        ],
        "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key; \n\tunprotected) header.d=raspberrypi.com\n\theader.i=@raspberrypi.com\n\theader.b=\"b9Da24dl\"; dkim-atps=neutral",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1697716344; x=1698321144;\n\th=content-transfer-encoding:mime-version:message-id:date:subject:cc\n\t:to:from:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=qurrxL0MpuGh55LWDIGOT3M5T99WOrLm3HHCn2AnTCw=;\n\tb=kAxASBYYu5uv5YtuRy6YdJuL0BdiDj6Qngdvi0gcMxfWgaI7r/7XS3l2VYi4C+hMN8\n\tA744U6KDkR62qtamVqDLbT5LeYd7FQ0PDwrLo6KylzUpQ9p6Okf+kC1FXbnS9FUkewAd\n\tz8e2snE5nFnuBzjTyaEsNdnoNTY39QWqnMXHxUA45jI84qane3BWlIYWUNWbAyXMRC8D\n\tq1OcgXhmIJu9qd3iDlaXFqI5qf5ae6YmE56FVqnJjTOx5v4RDV8+l5MuD4iAhgCkgVM2\n\t0koyLwvd40tPMHcnn5IXYYMwmjVtjLWyhs3XP3RowvvN6bUpPZ605bKm4dbtTNxcBj5E\n\tI7Iw==",
        "X-Gm-Message-State": "AOJu0Yzw1K7euQxz4nw5YiKWUMbQLSpwyUki2i0iX5xAa63eTL30zBCv\n\tgdQhyNnEu5qbMHBDQwKhybQtgPywkdLcRG/vIaI=",
        "X-Google-Smtp-Source": "AGHT+IHcOm1E2j2goUAYnTJQPUfVap2fMMqPl5AHToHSVv2jLzRyg8O+5N/wtauSUyR8Qm5dZoZBEg==",
        "X-Received": "by 2002:a05:600c:4f91:b0:407:4944:76dc with SMTP id\n\tn17-20020a05600c4f9100b00407494476dcmr1633357wmq.20.1697716344449; \n\tThu, 19 Oct 2023 04:52:24 -0700 (PDT)",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Thu, 19 Oct 2023 12:52:20 +0100",
        "Message-Id": "<20231019115220.4473-1-david.plowman@raspberrypi.com>",
        "X-Mailer": "git-send-email 2.39.2",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH v3] libcamera: controls: Add controls for\n\tHDR",
        "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>",
        "From": "David Plowman via libcamera-devel <libcamera-devel@lists.libcamera.org>",
        "Reply-To": "David Plowman <david.plowman@raspberrypi.com>",
        "Errors-To": "libcamera-devel-bounces@lists.libcamera.org",
        "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"
    },
    "content": "We add an HdrMode control (to enable and disable HDR processing)\nand an HdrChannel, which indicates what kind of HDR frame (short, long\nor medium) has just arrived.\n\nCurrently the HdrMode supports the following values:\n\n* Off - no HDR processing at all.\n* MultiExposureUnmerged - frames at multiple different exposures are\n  produced, but not merged together. They are returned \"as is\".\n* MultiExposure - frames at multiple different exposures are merged\n  to create HDR images.\n* SingleExposure - multiple frames all at the same exposure are\n  merged to create HDR images.\n* Night - multiple frames will be combined to create \"night mode\"\n  images.\n\nSigned-off-by: David Plowman <david.plowman@raspberrypi.com>\nReviewed-by: Naushir Patuck <naush@raspberrypi.com>\n---\n src/libcamera/control_ids.yaml | 75 ++++++++++++++++++++++++++++++++++\n 1 file changed, 75 insertions(+)",
    "diff": "diff --git a/src/libcamera/control_ids.yaml b/src/libcamera/control_ids.yaml\nindex f2e542f4..c3232abf 100644\n--- a/src/libcamera/control_ids.yaml\n+++ b/src/libcamera/control_ids.yaml\n@@ -774,6 +774,81 @@ controls:\n             Continuous AF is paused. No further state changes or lens movements\n             will occur until the AfPauseResume control is sent.\n \n+  - HdrMode:\n+      type: int32_t\n+      description: |\n+        Control to set the mode to be used for High Dynamic Range (HDR)\n+        imaging. HDR techniques typically include multiple exposure, image\n+        fusion and tone mapping techniques to improve the dynamic range of the\n+        resulting images.\n+\n+        When using an HDR mode, images are tagged to indicate which HDR channel\n+        (long, medium or short) they come from.\n+\n+        \\sa HdrChannel\n+\n+      enum:\n+        - name: HdrModeOff\n+          value: 0\n+          description: |\n+            HDR is disabled. The HDR channel, if present, will report\n+            HdrChannelNone.\n+        - name: HdrModeMultiExposureUnmerged\n+          value: 1\n+          description: |\n+            Multiple exposures will be generated in an alternating fashion.\n+            However, they will not be merged together and will be returned to\n+            the application as they are. Each image will be tagged with the\n+            correct HDR channel, indicating what kind of exposure (long, medium\n+            or short) it is.  The expectation is that, if necessary, the\n+            application can merge them to create HDR images for itself.\n+        - name: HdrModeMultiExposure\n+          value: 2\n+          description: |\n+            Multiple exposures will be generated and merged to create HDR\n+            images. Each image will be tagged with the HDR channel (long, medium\n+            or short) that arrived and which caused this image to be output.\n+        - name: HdrModeSingleExposure\n+          value: 3\n+          description: |\n+            Multiple frames all at a single exposure will be used to create HDR\n+            images. These images should be reported as all corresponding to the\n+            HDR short channel.\n+        - name: HdrModeNight\n+          value: 4\n+          description: |\n+            Multiple frames will be combined to produce \"night mode\"\n+            images. Images will be tagged as belonging either to the long,\n+            medium or short HDR channel according to the implementation.\n+\n+  - HdrChannel:\n+      type: int32_t\n+      description: |\n+        This value is reported back to the application so that it can discover\n+        whether this capture corresponds to the short or long exposure image (or\n+        any other image used by the HDR procedure). An application can monitor\n+        the HDR channel to discover when the differently exposed images have\n+        arrived.\n+\n+      enum:\n+        - name: HdrChannelNone\n+          value: 0\n+          description: |\n+            This image does not correspond to any of the captures used to create\n+            an HDR image.\n+        - name: HdrChannelShort\n+          value: 1\n+          description: |\n+            This is a short exposure image.\n+        - name: HdrChannelMedium\n+          value: 2\n+          description: |\n+            This is a medium exposure image.\n+        - name: HdrChannelLong\n+          value: 3\n+          description: |\n+            This is a long exposure image.\n+\n   # ----------------------------------------------------------------------------\n   # Draft controls section\n \n",
    "prefixes": [
        "libcamera-devel",
        "v3"
    ]
}