Patch Detail
Show a patch.
GET /api/patches/15453/?format=api
{ "id": 15453, "url": "https://patchwork.libcamera.org/api/patches/15453/?format=api", "web_url": "https://patchwork.libcamera.org/patch/15453/", "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": "<20220315175345.479951-2-kieran.bingham@ideasonboard.com>", "date": "2022-03-15T17:53:43", "name": "[libcamera-devel,1/3] ipa: ipu3: af: Move constants to implementation", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "6f1e0ae6fa6df6274a714e719bddc1a913807813", "submitter": { "id": 4, "url": "https://patchwork.libcamera.org/api/people/4/?format=api", "name": "Kieran Bingham", "email": "kieran.bingham@ideasonboard.com" }, "delegate": { "id": 11, "url": "https://patchwork.libcamera.org/api/users/11/?format=api", "username": "kbingham", "first_name": "Kieran", "last_name": "Bingham", "email": "kieran.bingham@ideasonboard.com" }, "mbox": "https://patchwork.libcamera.org/patch/15453/mbox/", "series": [ { "id": 2964, "url": "https://patchwork.libcamera.org/api/series/2964/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=2964", "date": "2022-03-15T17:53:42", "name": "ipa: ipu3: af: Small improvements", "version": 1, "mbox": "https://patchwork.libcamera.org/series/2964/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/15453/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/15453/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\r\n\t[92.243.16.209])\r\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 6B228BDE17\r\n\tfor <parsemail@patchwork.libcamera.org>;\r\n\tTue, 15 Mar 2022 17:53:57 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\r\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5C5FB632E9;\r\n\tTue, 15 Mar 2022 18:53:55 +0100 (CET)", "from perceval.ideasonboard.com (perceval.ideasonboard.com\r\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\r\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id C79FC604DC\r\n\tfor <libcamera-devel@lists.libcamera.org>;\r\n\tTue, 15 Mar 2022 18:53:53 +0100 (CET)", "from Monstersaurus.ksquared.org.uk.beta.tailscale.net\r\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\r\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 6569F1C34;\r\n\tTue, 15 Mar 2022 18:53:53 +0100 (CET)" ], "DKIM-Signature": [ "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\r\n\ts=mail; t=1647366835;\r\n\tbh=7AS/3W+JcRjGwq7NqYyLfTa+SB8XRCp4BPvzwC6i2uc=;\r\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\r\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\r\n\tFrom;\r\n\tb=dMb06Hz/6ibompYHvXyzIl+lOC9hMEvD/GKBj2QrHEqL1rVQ6pdcb3lsG8IwfwFfB\r\n\tfTvoj3GNcwc/hCju91/e1pXH907/MS3fq48VH7UajKyrydTn6BcQv8zjDnwpOp8qab\r\n\tGa7gQUMD+71AOHSDI99+GSQGX/uGVmORkiv+HB1CdYpEWmeiBveyRMStFbO/jr4PTS\r\n\tJEevJPMAmlr1C56V0H3BPna8VUH8yTTq6H8Rt1l7EX2pV0SWoqU/IcIZ+IahDcCjBT\r\n\teCiwdchM8XMAKSlSC13DFtnG1WQoEmmXJQQPGu162FePndUu/BEK8gHvpI/xsGMd7r\r\n\tCJLFbibY1jbIw==", "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\r\n\ts=mail; t=1647366833;\r\n\tbh=7AS/3W+JcRjGwq7NqYyLfTa+SB8XRCp4BPvzwC6i2uc=;\r\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\r\n\tb=F7LIvDOqnjbz5mqjKvV5WUZIutx2IGjzP08Ajkz2nusHGf2QKKG2CXmMeGtxRI1Z8\r\n\tqrjeGQEg7RSZcNpSuWpxFD0skUo5tIQx+WNntuF0hMTWk8ZTnpVH9xKOm8M+7g7v8I\r\n\tBx1+mPGD/HXxKmmPmEhmy4CqQPNVx1Ij0SuVFZUc=" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \r\n\tunprotected) header.d=ideasonboard.com\r\n\theader.i=@ideasonboard.com\r\n\theader.b=\"F7LIvDOq\"; dkim-atps=neutral", "To": "libcamera devel <libcamera-devel@lists.libcamera.org>", "Date": "Tue, 15 Mar 2022 17:53:43 +0000", "Message-Id": "<20220315175345.479951-2-kieran.bingham@ideasonboard.com>", "X-Mailer": "git-send-email 2.32.0", "In-Reply-To": "<20220315175345.479951-1-kieran.bingham@ideasonboard.com>", "References": "<20220315175345.479951-1-kieran.bingham@ideasonboard.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[libcamera-devel] [PATCH 1/3] ipa: ipu3: af: Move constants to\r\n\timplementation", "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>,\r\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>,\r\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>", "From": "Kieran Bingham via libcamera-devel\r\n\t<libcamera-devel@lists.libcamera.org>", "Reply-To": "Kieran Bingham <kieran.bingham@ideasonboard.com>", "Errors-To": "libcamera-devel-bounces@lists.libcamera.org", "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>" }, "content": "A selection of constants are imported from ChromiumOS.\n\nMove these out of the header, and simplify their documentation. Further\nmore, add a direct reference to the location they were obtained from.\n\nSigned-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n---\n src/ipa/ipu3/algorithms/af.cpp | 73 ++++++++++------------------------\n src/ipa/ipu3/algorithms/af.h | 11 -----\n 2 files changed, 22 insertions(+), 62 deletions(-)", "diff": "diff --git a/src/ipa/ipu3/algorithms/af.cpp b/src/ipa/ipu3/algorithms/af.cpp\r\nindex 0170a3728892..3cedf8cbd687 100644\r\n--- a/src/ipa/ipu3/algorithms/af.cpp\r\n+++ b/src/ipa/ipu3/algorithms/af.cpp\r\n@@ -29,59 +29,30 @@\r\n * \\file af.h\r\n */\r\n \r\n-/**\r\n- * \\var kAfMinGridWidth\r\n- * \\brief the minimum width of AF grid.\r\n- * The minimum grid horizontal dimensions.\r\n- */\r\n-\r\n-/**\r\n- * \\var kAfMinGridHeight\r\n- * \\brief the minimum height of AF grid.\r\n- * The minimum grid vertical dimensions.\r\n- */\r\n-\r\n-/**\r\n- * \\var kAfMaxGridWidth\r\n- * \\brief the maximum width of AF grid.\r\n- * The maximum grid horizontal dimensions.\r\n- */\r\n-\r\n-/**\r\n- * \\var kAfMaxGridHeight\r\n- * \\brief The maximum height of AF grid.\r\n- * The maximum grid vertical dimensions.\r\n- */\r\n-\r\n-/**\r\n- * \\var kAfMinGridBlockWidth\r\n- * \\brief The minimum block size of the width.\r\n- * The minimum value of Log2 of the width of the grid cell.\r\n- */\r\n-\r\n-/**\r\n- * \\var kAfMinGridBlockHeight\r\n- * \\brief The minimum block size of the height.\r\n- * The minimum value of Log2 of the height of the grid cell.\r\n- */\r\n-\r\n-/**\r\n- * \\def kAfMaxGridBlockWidth\r\n- * \\brief The maximum block size of the width.\r\n- * The maximum value of Log2 of the width of the grid cell.\r\n- */\r\n-\r\n-/**\r\n- * \\var kAfMaxGridBlockHeight\r\n- * \\brief The maximum block size of the height.\r\n- * The maximum value of Log2 of the height of the grid cell.\r\n+/*\r\n+ * Static variables from ChromiumOS Intel Camera HAL and ia_imaging library:\r\n+ * - https://chromium.googlesource.com/chromiumos/platform/arc-camera/+/master/hal/intel/psl/ipu3/statsConverter/ipu3-stats.h\r\n+ * - https://chromium.googlesource.com/chromiumos/platform/camera/+/refs/heads/main/hal/intel/ipu3/include/ia_imaging/af_public.h\r\n */\r\n \r\n-/**\r\n- * \\var kAfDefaultHeightPerSlice\r\n- * \\brief The default number of blocks in vertical axis per slice.\r\n- * The number of blocks in vertical axis per slice.\r\n- */\r\n+/** The minimum horizontal grid dimensions. */\r\n+static constexpr uint8_t kAfMinGridWidth = 16;\r\n+/** The minimum vertical grid dimensions. */\r\n+static constexpr uint8_t kAfMinGridHeight = 16;\r\n+/** The maximum horizontal grid dimensions. */\r\n+static constexpr uint8_t kAfMaxGridWidth = 32;\r\n+/** The maximum vertical grid dimensions. */\r\n+static constexpr uint8_t kAfMaxGridHeight = 24;\r\n+/** The minimum value of Log2 of the width of the grid cell. */\r\n+static constexpr uint16_t kAfMinGridBlockWidth = 4;\r\n+/** The minimum value of Log2 of the height of the grid cell. */\r\n+static constexpr uint16_t kAfMinGridBlockHeight = 3;\r\n+/** The maximum value of Log2 of the width of the grid cell. */\r\n+static constexpr uint16_t kAfMaxGridBlockWidth = 6;\r\n+/** The maximum value of Log2 of the height of the grid cell. */\r\n+static constexpr uint16_t kAfMaxGridBlockHeight = 6;\r\n+/** The number of blocks in vertical axis per slice. */\r\n+static constexpr uint16_t kAfDefaultHeightPerSlice = 2;\r\n \r\n namespace libcamera {\r\n \r\ndiff --git a/src/ipa/ipu3/algorithms/af.h b/src/ipa/ipu3/algorithms/af.h\r\nindex 13c7e0e877fd..906f2843dd49 100644\r\n--- a/src/ipa/ipu3/algorithms/af.h\r\n+++ b/src/ipa/ipu3/algorithms/af.h\r\n@@ -15,17 +15,6 @@\r\n \r\n #include \"algorithm.h\"\r\n \r\n-/* Static variables from repo of chromium */\r\n-static constexpr uint8_t kAfMinGridWidth = 16;\r\n-static constexpr uint8_t kAfMinGridHeight = 16;\r\n-static constexpr uint8_t kAfMaxGridWidth = 32;\r\n-static constexpr uint8_t kAfMaxGridHeight = 24;\r\n-static constexpr uint16_t kAfMinGridBlockWidth = 4;\r\n-static constexpr uint16_t kAfMinGridBlockHeight = 3;\r\n-static constexpr uint16_t kAfMaxGridBlockWidth = 6;\r\n-static constexpr uint16_t kAfMaxGridBlockHeight = 6;\r\n-static constexpr uint16_t kAfDefaultHeightPerSlice = 2;\r\n-\r\n namespace libcamera {\r\n \r\n namespace ipa::ipu3::algorithms {", "prefixes": [ "libcamera-devel", "1/3" ] }