Patch Detail
Show a patch.
GET /api/1.1/patches/24219/?format=api
{ "id": 24219, "url": "https://patchwork.libcamera.org/api/1.1/patches/24219/?format=api", "web_url": "https://patchwork.libcamera.org/patch/24219/", "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": "<20250824-b4-v0-5-2-gpuisp-v2-a-v2-37-96f4576c814e@linaro.org>", "date": "2025-08-24T00:48:49", "name": "[v2,37/37] libcamera: software_isp: Reduce statistics image area", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "004729b356fd26466e1c2e57f93a79313abf1c97", "submitter": { "id": 175, "url": "https://patchwork.libcamera.org/api/1.1/people/175/?format=api", "name": "Bryan O'Donoghue", "email": "bryan.odonoghue@linaro.org" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/24219/mbox/", "series": [ { "id": 5400, "url": "https://patchwork.libcamera.org/api/1.1/series/5400/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=5400", "date": "2025-08-24T00:48:12", "name": "Add GLES 2.0 GPUISP to libcamera", "version": 2, "mbox": "https://patchwork.libcamera.org/series/5400/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/24219/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/24219/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 BF533C332B\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSun, 24 Aug 2025 00:49:47 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 41B7269337;\n\tSun, 24 Aug 2025 02:49:47 +0200 (CEST)", "from mail-wm1-x335.google.com (mail-wm1-x335.google.com\n\t[IPv6:2a00:1450:4864:20::335])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id DCA106932C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSun, 24 Aug 2025 02:49:10 +0200 (CEST)", "by mail-wm1-x335.google.com with SMTP id\n\t5b1f17b1804b1-45a1b0bde14so18322595e9.2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tSat, 23 Aug 2025 17:49:10 -0700 (PDT)", "from [192.168.0.13] (188-141-3-146.dynamic.upc.ie. [188.141.3.146])\n\tby smtp.gmail.com with ESMTPSA id\n\t5b1f17b1804b1-45b4e1d530esm69347225e9.0.2025.08.23.17.49.09\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tSat, 23 Aug 2025 17:49:10 -0700 (PDT)" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key;\n\tunprotected) header.d=linaro.org header.i=@linaro.org\n\theader.b=\"vKS0OlIO\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=linaro.org; s=google; t=1755996550; x=1756601350;\n\tdarn=lists.libcamera.org; \n\th=cc:to:in-reply-to:references:message-id:content-transfer-encoding\n\t:mime-version:subject:date:from:from:to:cc:subject:date:message-id\n\t:reply-to; bh=2etWwA6J1SYpTDI5CoVSwI33oPVBanpyO7HgTRHCDS0=;\n\tb=vKS0OlIOp/J8EswmlDaTIH4rhprILb2HKUE6RSRZI7FH2OaFWGSiR6gGRQso2t18A5\n\t62RAabOsdmgcQ1GEKny0obAQyFeyXcn8wbZpoxT/2VOQMCLsud+52ETefu+GHbeag/eo\n\t8gFbHaI0RaVBmxDfLxDBRtlcyQybSeeEXs62pgY4SQB80J2xmUV38APEymES+SxdPaCy\n\tql4l6HfDWFJ1ud0zlD4q1oks4JyzkNnM7nOsVtoZ1wlO6HHb0wPaLMlnBy6Lu8erqoZ+\n\tvTbprfWt8r8Kdlg8vCHbI+B30nxY9f/Qf6SBW3zNd5v/wYVUxF+3xopwjfNVhquEjrjE\n\tj/ag==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1755996550; x=1756601350;\n\th=cc:to:in-reply-to:references:message-id:content-transfer-encoding\n\t:mime-version:subject:date:from:x-gm-message-state:from:to:cc\n\t:subject:date:message-id:reply-to;\n\tbh=2etWwA6J1SYpTDI5CoVSwI33oPVBanpyO7HgTRHCDS0=;\n\tb=OGDYh25fn2VWRrqcBVmdLrOBxipMU5Zoer+AyufTPqyGRiHcPrYd5vAFRVS+wV9x2I\n\tbruJMbwiWfaTNJQRXIrgMsKHHuUNmosMbZRD1+/kH1tjVYLVwpkz+PVMZEFvgVUHLt5t\n\tu0cEVGT8LdAmprGWutLBKuZt5l9PVtssp9xcX7MJDVmbnyNQf0WYKsXvao1JZP/VV86e\n\ti3dGqipwgQ+y5VPVPfxy1VwI31QchnMz4FukmRa9KD/GlwZu0R/rQOiuI+8XA92GaYXR\n\tdf0dPVshcrVVjFppQ/Ob3DfkCtimp/MXn8XH8ERKfNa9Ufwv8TjKa3PBMB3hij8U3wwY\n\tHSyQ==", "X-Gm-Message-State": "AOJu0Yx3uR5NkCvPJw0q9LWrV7Fuav5PWyaSSQr+0yLBVTrSvUUz2Cor\n\t4YA47jTKVz73Qy7eCaOKXzy7Q6IeJFmZcuwuNi+aTwOSZxK4eqkh91ZAJXJA0da4cgQ=", "X-Gm-Gg": "ASbGncuGtHfBHl3s/9CjqDWghzdJeE0n13GcSdYZqQ2dF5dm/GOiTd2lH1ODp2lkQ+7\n\tP3bneDDqiWXC10ZD5bJkXRVVPomObZxXySAhs/XZnwNx81V2u3cx0INnQO1bLxqTVaGPRY5ubli\n\t52Gt7KgJ4WMZj2/si8tlJNbRYkaku/SOsBp7TYZzrHZ3gqGqigbaYspK4jiNeIS2+lJn8bN5jrf\n\tOXseIHFdc54m0nhxj8Drk4yJh2Spafc+JvLXrc/xsdra1VzqGdti/ddItJTezQzYJMGeZX6KxK5\n\tZnqiJDEOJX+Xshr12wMqsA2o1A4PKMOR+j5BOwUUlZSjC8Shiu/tPgAt41u5ytZ1vj2/YgLrxH1\n\tMuG7VoyGpqiogSx05bfTTj5Xl18tyqjeAELZLJNk+8RCZfzSx5hASZHzya1TGgKu17AUCo2oXjt\n\tsWnVfzNmpRzgK2EbfrJqheKzKRwrbB0Y8=", "X-Google-Smtp-Source": "AGHT+IGYxZTEaWf1wZW5sT9kXdfmPIgF4YtTManMjAXTaOuv14+p6lTd9Idlb3dFaG+PUp3DdGmF4A==", "X-Received": "by 2002:a05:600c:46cb:b0:458:bf7c:f744 with SMTP id\n\t5b1f17b1804b1-45b517c2d5fmr54970585e9.32.1755996550418; \n\tSat, 23 Aug 2025 17:49:10 -0700 (PDT)", "From": "Bryan O'Donoghue <bryan.odonoghue@linaro.org>", "Date": "Sun, 24 Aug 2025 01:48:49 +0100", "Subject": "[PATCH v2 37/37] libcamera: software_isp: Reduce statistics image\n\tarea", "MIME-Version": "1.0", "Content-Type": "text/plain; charset=\"utf-8\"", "Content-Transfer-Encoding": "7bit", "Message-Id": "<20250824-b4-v0-5-2-gpuisp-v2-a-v2-37-96f4576c814e@linaro.org>", "References": "<20250824-b4-v0-5-2-gpuisp-v2-a-v2-0-96f4576c814e@linaro.org>", "In-Reply-To": "<20250824-b4-v0-5-2-gpuisp-v2-a-v2-0-96f4576c814e@linaro.org>", "To": "libcamera-devel@lists.libcamera.org", "Cc": "Bryan O'Donoghue <bryan.odonoghue@linaro.org>, \n\tMilan Zamazal <mzamazal@redhat.com>, \n\tKieran Bingham <kieran.bingham@ideasonboard.com>", "X-Mailer": "b4 0.14.2", "X-Developer-Signature": "v=1; a=openpgp-sha256; l=1809;\n\ti=bryan.odonoghue@linaro.org; h=from:subject:message-id;\n\tbh=bRnKLUJjXpxW5OOLk8SuBI4fSZ62DWkB8yvaqS8TeDk=;\n\tb=owEBbQKS/ZANAwAKASJxO7Ohjcg6AcsmYgBoqmFjiqIo2cIrllvz6JtiqpJNEwjIjEJEx39Pv\n\trHrBe7nekiJAjMEAAEKAB0WIQTmk/sqq6Nt4Rerb7QicTuzoY3IOgUCaKphYwAKCRAicTuzoY3I\n\tOuPlD/42q5/hcPeEsjKWvhxHAiHGIpYAf80gyme+F6iN6ie5Jj2aJBUdbXNcnJDgmdWTFaUWC71\n\tI0px3JYxyys/nclOoXNbdDhyauYSSvQx6fMveuBe0qpJTgIJM4pN022AP9lCn7j2tfvsfQVTqma\n\t8QJTpu97yda3R1ll+rLW3BUWcqkUQA/xoOzQoOxzbDnJtNGYhPBZAstKkjSFiAowQTX+pkV82xF\n\tjomi/VtRh7+JvwZtz45rPiPFTFn2/gZO9hMJu3wek+fs2nPFJQrbuyUf8ubuENAPmwvNNcerXoz\n\tAeezR4UaPcrbVkYdS/EtVaoPQGB8JH9a8bGOfoENT5E1DSMlb9HLzQSuFrrTZYk/5wFckQ9J0UU\n\tyRW0RlRz26ZXtGI1j7Kt9+pgfucMyUb3qDMnE3vWJ1SnYJ7EhPFd9L2TfJMPybKG9nsqIp77T3L\n\t0zpD1isFPAxdb4PTh8Nozcxi7PfpQWqi355oeAUj+VgLYTwdSOJ8JfR4lQa1vGa1ECY/UFqWaJu\n\tLqbAP21kP5Off0cWY1RUe6HRc2FhfvCY6w5gqVd9id8hgMqd93KS+BWa00Kwegn6rbmNL/VHU29\n\tGuizFeQmkkmg/NkSMNdHojFXWeUPCG84dhMZoMKmOjUtSK+yS1Kd/trM3BWi6JaL8K4WvnNdHAl\n\tU7kcODz+fW4J6MA==", "X-Developer-Key": "i=bryan.odonoghue@linaro.org; a=openpgp;\n\tfpr=E693FB2AABA36DE117AB6FB422713BB3A18DC83A", "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": "From: Milan Zamazal <mzamazal@redhat.com>\n\nThe statistics in software ISP is computed basically over the whole\nimage area, although only on part of the pixels. It is not necessary to\ncover the whole image area, it's sufficient to compute the statistics\nlet's say over the central area of 2/3 of the image width and height,\nwhich should be both sufficient and faster. The speedup is not that\nimportant with the CPU implementation but it may save CPU work\nmore noticeably with GPU debayering implementation.\n\nSigned-off-by: Milan Zamazal <mzamazal@redhat.com>\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\n src/libcamera/software_isp/debayer_cpu.cpp | 9 +++++++--\n 1 file changed, 7 insertions(+), 2 deletions(-)", "diff": "diff --git a/src/libcamera/software_isp/debayer_cpu.cpp b/src/libcamera/software_isp/debayer_cpu.cpp\nindex 7bd1fc39266f651845cc7a87ac991aa67c36c094..b19d89c1cae04104d6d8377555b306128e700f62 100644\n--- a/src/libcamera/software_isp/debayer_cpu.cpp\n+++ b/src/libcamera/software_isp/debayer_cpu.cpp\n@@ -526,8 +526,13 @@ int DebayerCpu::configure(const StreamConfiguration &inputCfg,\n \twindow_.width = outputCfg.size.width;\n \twindow_.height = outputCfg.size.height;\n \n-\t/* Don't pass x,y since process() already adjusts src before passing it */\n-\tstats_->setWindow(Rectangle(window_.size()));\n+\t/*\n+\t * Don't pass x,y from window_ since process() already adjusts for it.\n+\t * But crop the window to 2/3 of its width and height for speedup.\n+\t * The speedup is more important with GPU than with CPU ISP; we want the\n+\t * same implementation on both.\n+\t */\n+\tstats_->setWindow((window_.size() * 2 / 3).centeredTo(window_.center()));\n \n \t/* pad with patternSize.Width on both left and right side */\n \tlineBufferPadding_ = inputConfig_.patternSize.width * inputConfig_.bpp / 8;\n", "prefixes": [ "v2", "37/37" ] }