Patch Detail
Show a patch.
GET /api/1.1/patches/8943/?format=api
{ "id": 8943, "url": "https://patchwork.libcamera.org/api/1.1/patches/8943/?format=api", "web_url": "https://patchwork.libcamera.org/patch/8943/", "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": "<20200723233852.17415-1-laurent.pinchart@ideasonboard.com>", "date": "2020-07-23T23:38:52", "name": "[libcamera-devel] libcamera: formats: Remove unnecessary explicit constructor calls", "commit_ref": "7145d15e043a9066a7e0a6a53ba95b1b1af851d5", "pull_url": null, "state": "accepted", "archived": false, "hash": "c57cc49e63f1c17780f7d8849cf3ffee07a7c02f", "submitter": { "id": 2, "url": "https://patchwork.libcamera.org/api/1.1/people/2/?format=api", "name": "Laurent Pinchart", "email": "laurent.pinchart@ideasonboard.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/8943/mbox/", "series": [ { "id": 1131, "url": "https://patchwork.libcamera.org/api/1.1/series/1131/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=1131", "date": "2020-07-23T23:38:52", "name": "[libcamera-devel] libcamera: formats: Remove unnecessary explicit constructor calls", "version": 1, "mbox": "https://patchwork.libcamera.org/series/1131/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/8943/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/8943/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 F0429BD86F\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 23 Jul 2020 23:39:08 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 737166117A;\n\tFri, 24 Jul 2020 01:39:08 +0200 (CEST)", "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 E5FDA60539\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 24 Jul 2020 01:39:06 +0200 (CEST)", "from pendragon.bb.dnainternet.fi (81-175-216-236.bb.dnainternet.fi\n\t[81.175.216.236])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 6C261279\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 24 Jul 2020 01:39:06 +0200 (CEST)" ], "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=\"rkMLcWA/\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1595547546;\n\tbh=szy+itzWBdb9K54qSYEspsiAoYBmDFbFIJ/7rP/Lzbg=;\n\th=From:To:Subject:Date:From;\n\tb=rkMLcWA/dLW0bwG4x11CkdgcJ5lil//dLwyUhyMX+A3DIwvbUYksf7bZ7xcdVvikN\n\the/2wV/EQItO2Sd+GhejucoogWNPsWd9yA44nID8035E7YFGKdchitwdc1+gtRodsd\n\tVH0C6TxEPvy/kXQrywk9zfi+bYltt/HeTS1o7oGU=", "From": "Laurent Pinchart <laurent.pinchart@ideasonboard.com>", "To": "libcamera-devel@lists.libcamera.org", "Date": "Fri, 24 Jul 2020 02:38:52 +0300", "Message-Id": "<20200723233852.17415-1-laurent.pinchart@ideasonboard.com>", "X-Mailer": "git-send-email 2.27.0", "MIME-Version": "1.0", "Subject": "[libcamera-devel] [PATCH] libcamera: formats: Remove unnecessary\n\texplicit constructor calls", "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>", "Content-Type": "text/plain; charset=\"us-ascii\"", "Content-Transfer-Encoding": "7bit", "Errors-To": "libcamera-devel-bounces@lists.libcamera.org", "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>" }, "content": "When initializing the PixelFormatInfo::format field with a PixelFormat,\nthere's no need to cal the PixelFormat (copy) constructor explicitly.\nRemove the unnecessary calls.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n---\n src/libcamera/formats.cpp | 6 +++---\n 1 file changed, 3 insertions(+), 3 deletions(-)", "diff": "diff --git a/src/libcamera/formats.cpp b/src/libcamera/formats.cpp\nindex 60b42ce23c21..11774b0cfb12 100644\n--- a/src/libcamera/formats.cpp\n+++ b/src/libcamera/formats.cpp\n@@ -321,7 +321,7 @@ const std::map<PixelFormat, PixelFormatInfo> pixelFormatInfo{\n \t} },\n \t{ formats::YUV420, {\n \t\t.name = \"YUV420\",\n-\t\t.format = PixelFormat(formats::YUV420),\n+\t\t.format = formats::YUV420,\n \t\t.v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_YUV420),\n \t\t.bitsPerPixel = 12,\n \t\t.colourEncoding = PixelFormatInfo::ColourEncodingYUV,\n@@ -331,7 +331,7 @@ const std::map<PixelFormat, PixelFormatInfo> pixelFormatInfo{\n \t} },\n \t{ formats::YVU420, {\n \t\t.name = \"YVU420\",\n-\t\t.format = PixelFormat(formats::YVU420),\n+\t\t.format = formats::YVU420,\n \t\t.v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_YVU420),\n \t\t.bitsPerPixel = 12,\n \t\t.colourEncoding = PixelFormatInfo::ColourEncodingYUV,\n@@ -341,7 +341,7 @@ const std::map<PixelFormat, PixelFormatInfo> pixelFormatInfo{\n \t} },\n \t{ formats::YUV422, {\n \t\t.name = \"YUV422\",\n-\t\t.format = PixelFormat(formats::YUV422),\n+\t\t.format = formats::YUV422,\n \t\t.v4l2Format = V4L2PixelFormat(V4L2_PIX_FMT_YUV422P),\n \t\t.bitsPerPixel = 16,\n \t\t.colourEncoding = PixelFormatInfo::ColourEncodingYUV,\n", "prefixes": [ "libcamera-devel" ] }