Show a patch.

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

{
    "id": 15241,
    "url": "https://patchwork.libcamera.org/api/patches/15241/?format=api",
    "web_url": "https://patchwork.libcamera.org/patch/15241/",
    "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": "<20220104065201.25744-3-umang.jain@ideasonboard.com>",
    "date": "2022-01-04T06:52:01",
    "name": "[libcamera-devel,2/2] android: camera_request: Lifetime of a Camera3RequestDescriptor",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "fe583c1dd98bd840461bb77248511487b6b873ad",
    "submitter": {
        "id": 86,
        "url": "https://patchwork.libcamera.org/api/people/86/?format=api",
        "name": "Umang Jain",
        "email": "umang.jain@ideasonboard.com"
    },
    "delegate": {
        "id": 12,
        "url": "https://patchwork.libcamera.org/api/users/12/?format=api",
        "username": "uajain",
        "first_name": "Umang",
        "last_name": "Jain",
        "email": "umang.jain@ideasonboard.com"
    },
    "mbox": "https://patchwork.libcamera.org/patch/15241/mbox/",
    "series": [
        {
            "id": 2874,
            "url": "https://patchwork.libcamera.org/api/series/2874/?format=api",
            "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=2874",
            "date": "2022-01-04T06:51:59",
            "name": "Document post-processing",
            "version": 1,
            "mbox": "https://patchwork.libcamera.org/series/2874/mbox/"
        }
    ],
    "comments": "https://patchwork.libcamera.org/api/patches/15241/comments/",
    "check": "pending",
    "checks": "https://patchwork.libcamera.org/api/patches/15241/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 1C41EBE080\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue,  4 Jan 2022 06:52:20 +0000 (UTC)",
            "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id C4A1F6091C;\n\tTue,  4 Jan 2022 07:52:19 +0100 (CET)",
            "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 5F5C2604F8\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue,  4 Jan 2022 07:52:18 +0100 (CET)",
            "from perceval.ideasonboard.com (unknown [27.57.188.152])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id A87D7501;\n\tTue,  4 Jan 2022 07:52:16 +0100 (CET)"
        ],
        "Authentication-Results": "lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"ElBj9DAa\"; dkim-atps=neutral",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1641279138;\n\tbh=U7uviNR4LnE0/CMD5qQ14DUMdvPt61nFHYd+j2wJrRI=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=ElBj9DAaUq5G1gGdzCpcOXEGQ43cTDT7Mg5nJ+XfoRKE8jqyrnCodRt+5b5bGpxh1\n\tZ/xH6gzVYZKeI6qvfEBxjgidYMOFzZ5STVE8X5uWOIeCSAgzyANh2TXEz+LgTXmXjx\n\tdqjHlj2w1QkprU8AKatABYQPffz353GQCF/b1YGc=",
        "From": "Umang Jain <umang.jain@ideasonboard.com>",
        "To": "libcamera-devel@lists.libcamera.org",
        "Date": "Tue,  4 Jan 2022 12:22:01 +0530",
        "Message-Id": "<20220104065201.25744-3-umang.jain@ideasonboard.com>",
        "X-Mailer": "git-send-email 2.31.1",
        "In-Reply-To": "<20220104065201.25744-1-umang.jain@ideasonboard.com>",
        "References": "<20220104065201.25744-1-umang.jain@ideasonboard.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=UTF-8",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[libcamera-devel] [PATCH 2/2] android: camera_request: Lifetime of\n\ta Camera3RequestDescriptor",
        "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 commit provides a sketch regarding Camera3RequestDescriptor\nwhich aids tracking each capture reuqest placed by the android\nframework to libcamera HAL.\n\nSigned-off-by: Umang Jain <umang.jain@ideasonboard.com>\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n src/android/camera_request.cpp | 88 ++++++++++++++++++++++++++++++++++\n 1 file changed, 88 insertions(+)",
    "diff": "diff --git a/src/android/camera_request.cpp b/src/android/camera_request.cpp\nindex 027b46d3..fceaa1f7 100644\n--- a/src/android/camera_request.cpp\n+++ b/src/android/camera_request.cpp\n@@ -18,6 +18,94 @@ using namespace libcamera;\n  *\n  * A utility class that groups information about a capture request to be later\n  * reused at request complete time to notify the framework.\n+ *\n+ *******************************************************************************\n+ * Lifetime of a Camera3RequestDescriptor tracking a capture request placed by\n+ * Android Framework\n+ *******************************************************************************\n+ *\n+ *\n+ *  Android Framework\n+ *     │\n+ *     │    ┌──────────────────────────────────┐\n+ *     │    │camera3_capture_request_t         │\n+ *     │    │                                  │\n+ *     │    │Requested output streams          │\n+ *     │    │  stream1   stream2   stream3 ... │\n+ *     │    └──────────────────────────────────┘\n+ *     ▼\n+ * ┌─────────────────────────────────────────────────────────────┐\n+ * │ libcamera HAL                                               │\n+ * ├─────────────────────────────────────────────────────────────┤\n+ * │  CameraDevice                                               │\n+ * │                                                             │\n+ * │  processCaptureRequest(camera3_capture_request_t request)   │\n+ * │                                                             │\n+ * │   - Create Camera3RequestDescriptor tracking this request   │\n+ * │   - Streams requiring post-processing are stored in the     │\n+ * │     pendingStreamsToProcess map                             │\n+ * │   - Add this Camera3RequestDescriptor to descriptors' queue │\n+ * │     CameraDevice::descriptors_                              │\n+ * │                                                             │ ┌─────────────────────────┐\n+ * │   - Queue the capture request to libcamera core ────────────┤►│libcamera core           │\n+ * │                                                             │ ├─────────────────────────┤\n+ * │                                                             │ │- Capture from Camera    │\n+ * │                                                             │ │                         │\n+ * │                                                             │ │- Emit                   │\n+ * │                                                             │ │  Camera::requestComplete│\n+ * │  requestCompleted(Request *request) ◄───────────────────────┼─┼────                     │\n+ * │                                                             │ │                         │\n+ * │   - Check request completion status                         │ └─────────────────────────┘\n+ * │                                                             │\n+ * │   - if (pendingStreamsToProcess > 0)                        │\n+ * │      Queue all entries from pendingStreamsToProcess         │\n+ * │    else                                   │                 │\n+ * │      completeDescriptor()                 │                 └──────────────────────┐\n+ * │                                           │                                        │\n+ * │                ┌──────────────────────────┴───┬──────────────────┐                 │\n+ * │                │                              │                  │                 │\n+ * │     ┌──────────▼────────────┐     ┌───────────▼─────────┐        ▼                 │\n+ * │     │CameraStream1          │     │CameraStream2        │      ....                │\n+ * │     ├┬───┬───┬──────────────┤     ├┬───┬───┬────────────┤                          │\n+ * │     ││   │   │              │     ││   │   │            │                          │\n+ * │     │▼───▼───▼──────────────┤     │▼───▼───▼────────────┤                          │\n+ * │     │PostProcessorWorker    │     │PostProcessorWorker  │                          │\n+ * │     │                       │     │                     │                          │\n+ * │     │ +------------------+  │     │ +------------------+│                          │\n+ * │     │ | PostProcessor    |  │     │ | PostProcessor    |│                          │\n+ * │     │ |     process()    |  │     │ |     process()    |│                          │\n+ * │     │ |                  |  │     │ |                  |│                          │\n+ * │     │ | Emit             |  │     │ | Emit             |│                          │\n+ * │     │ | processComplete  |  │     │ | processComplete  |│                          │\n+ * │     │ |                  |  │     │ |                  |│                          │\n+ * │     │ +--------------│---+  │     │ +--------------│---+│                          │\n+ * │     │                │      │     │                │    │                          │\n+ * │     │                │      │     │                │    │                          │\n+ * │     └────────────────┼──────┘     └────────────────┼────┘                          │\n+ * │                      │                             │                               │\n+ * │                      │                             │                               │\n+ * │                      │                             │                               │\n+ * │                      ▼                             ▼                               │\n+ * │ +---------------------------------------+     +--------------+                     │\n+ * │ | CameraDevice                          |     |              |                     │\n+ * │ |                                       |     |              |                     │\n+ * │ | streamProcessingComplete()            |     |              |                     │\n+ * │ |                                       |     |              |                     │\n+ * │ | - Check and set buffer status         |     |     ....     |                     │\n+ * │ | - Remove post+processing entry        |     |              |                     │\n+ * │ |   from pendingStreamsToProcess        |     |              |                     │\n+ * │ |                                       |     |              |                     │\n+ * │ | - if (pendingStreamsToProcess.empty())|     |              |                     │\n+ * │ |        completeDescriptor             |     |              |                     │\n+ * │ |                                       |     |              |                     │\n+ * │ +---------------------------------------+     +--------------+                     │\n+ * │                                                                                    │\n+ * └────────────────────────────────────────────────────────────────────────────────────┘\n+ *\n+ *   +-------------+\n+ *   |             | - PostProcessorWorker's thread\n+ *   |             |\n+ *   +-------------+\n  */\n \n Camera3RequestDescriptor::Camera3RequestDescriptor(\n",
    "prefixes": [
        "libcamera-devel",
        "2/2"
    ]
}