Patch Detail
Show a patch.
GET /api/1.1/patches/24024/?format=api
{ "id": 24024, "url": "https://patchwork.libcamera.org/api/1.1/patches/24024/?format=api", "web_url": "https://patchwork.libcamera.org/patch/24024/", "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": "<20250729153915.159243-2-uajain@igalia.com>", "date": "2025-07-29T15:39:13", "name": "[v5,1/3] gstreamer: Split value_set_rectangle() GValue helper", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "97aac087d4541a4b40f1f6f4e77305daabe1e82b", "submitter": { "id": 232, "url": "https://patchwork.libcamera.org/api/1.1/people/232/?format=api", "name": "Umang Jain", "email": "uajain@igalia.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/24024/mbox/", "series": [ { "id": 5346, "url": "https://patchwork.libcamera.org/api/1.1/series/5346/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=5346", "date": "2025-07-29T15:39:12", "name": "gstreamer: Report camera properties as device properties", "version": 5, "mbox": "https://patchwork.libcamera.org/series/5346/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/24024/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/24024/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 7BD55BDCC1\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 29 Jul 2025 15:39:23 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5DF76691EA;\n\tTue, 29 Jul 2025 17:39:19 +0200 (CEST)", "from fanzine2.igalia.com (fanzine2.igalia.com [213.97.179.56])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 8C64C691DA\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 29 Jul 2025 17:39:14 +0200 (CEST)", "from [49.36.71.87] (helo=uajain) by fanzine2.igalia.com with\n\tesmtpsa \n\t(Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256)\n\t(Exim) id 1ugmQ5-005UrS-HJ; Tue, 29 Jul 2025 17:39:13 +0200" ], "Authentication-Results": "lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=igalia.com header.i=@igalia.com\n\theader.b=\"Bz0s1LK9\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com;\n\ts=20170329;\n\th=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To:\n\tMessage-ID:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID:\n\tContent-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc\n\t:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe:\n\tList-Post:List-Owner:List-Archive;\n\tbh=sVZAg6thdnSiFRJYsLla6vN7DmdHXrAeqYK4TQ2Nw7k=;\n\tb=Bz0s1LK9Lg/8s2w8CCOV499jor\n\tuyjzObo7VMza/64BAUm9tPUEhJGIpjf+woRrLiqKyNC0eub1KlReSYZ+x6Xx4hHL6T8PZeXpDSScC\n\tsU+AzyenkAZdMBNUPTcw1eC8NpvxARdCTxR4/NmEauyfedZbIYa6soow00Uj6f/Qt+UMjyj6XuEBj\n\tF5pUcABYSKuMZY3E0Pua9e8JqBaglnQYwMQn7jPqcxCVLgZR6gsjOuELB3aUPMP+QLT+P9CxFD93+\n\t79VwsbZ4Pqpe6019lGG960P0ocOJe6GXM8Ms5CqHDgYkE1UBK94IOjkicurUSurBipLdY3JvsgneV\n\tpK8TBotw==;", "From": "Umang Jain <uajain@igalia.com>", "To": "libcamera-devel@lists.libcamera.org", "Cc": "Jaslo Ziska <jaslo@ziska.de>,\n\tNicolas Dufresne <nicolas.dufresne@collabora.com>,\n\tUmang Jain <uajain@igalia.com>", "Subject": "[PATCH v5 1/3] gstreamer: Split value_set_rectangle() GValue helper", "Date": "Tue, 29 Jul 2025 21:09:13 +0530", "Message-ID": "<20250729153915.159243-2-uajain@igalia.com>", "X-Mailer": "git-send-email 2.50.0", "In-Reply-To": "<20250729153915.159243-1-uajain@igalia.com>", "References": "<20250729153915.159243-1-uajain@igalia.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": "Split the value_set_rectangle() GValue helper into further\nhelpers pertaining to libcamera::Point and libcamera::Size.\nThis would help to cover additional cases where helpers\nare needed for Point and Size individually (in subsequent commits).\n\nThe libcamera::Rectangle's GValue helper can be easily\nconstructed with the new Point and Size helpers. Hence,\nthis patch does not introduce any functional changes.\n\nSigned-off-by: Umang Jain <uajain@igalia.com>\nReviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>\n---\n src/gstreamer/gstlibcamera-controls.cpp.in | 18 ++++++++++++------\n 1 file changed, 12 insertions(+), 6 deletions(-)", "diff": "diff --git a/src/gstreamer/gstlibcamera-controls.cpp.in b/src/gstreamer/gstlibcamera-controls.cpp.in\nindex 2a16b39a..1bc781cc 100644\n--- a/src/gstreamer/gstlibcamera-controls.cpp.in\n+++ b/src/gstreamer/gstlibcamera-controls.cpp.in\n@@ -17,21 +17,21 @@\n \n using namespace libcamera;\n \n-static void value_set_rectangle(GValue *value, const Rectangle &rect)\n+static void value_set_point(GValue *value, const Point &point)\n {\n-\tPoint top_left = rect.topLeft();\n-\tSize size = rect.size();\n-\n \tGValue x = G_VALUE_INIT;\n \tg_value_init(&x, G_TYPE_INT);\n-\tg_value_set_int(&x, top_left.x);\n+\tg_value_set_int(&x, point.x);\n \tgst_value_array_append_and_take_value(value, &x);\n \n \tGValue y = G_VALUE_INIT;\n \tg_value_init(&y, G_TYPE_INT);\n-\tg_value_set_int(&y, top_left.y);\n+\tg_value_set_int(&y, point.y);\n \tgst_value_array_append_and_take_value(value, &y);\n+}\n \n+static void value_set_size(GValue *value, const Size &size)\n+{\n \tGValue width = G_VALUE_INIT;\n \tg_value_init(&width, G_TYPE_INT);\n \tg_value_set_int(&width, size.width);\n@@ -43,6 +43,12 @@ static void value_set_rectangle(GValue *value, const Rectangle &rect)\n \tgst_value_array_append_and_take_value(value, &height);\n }\n \n+static void value_set_rectangle(GValue *value, const Rectangle &rect)\n+{\n+\tvalue_set_point(value, rect.topLeft());\n+\tvalue_set_size(value, rect.size());\n+}\n+\n static Rectangle value_get_rectangle(const GValue *value)\n {\n \tconst GValue *r;\n", "prefixes": [ "v5", "1/3" ] }