{"id":22395,"url":"https://patchwork.libcamera.org/api/patches/22395/?format=json","web_url":"https://patchwork.libcamera.org/patch/22395/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20241218083610.2397879-5-naush@raspberrypi.com>","date":"2024-12-18T08:34:21","name":"[v2,4/4] ipa: rpi: Provide the camera helper with the hardware configuration","commit_ref":null,"pull_url":null,"state":"superseded","archived":false,"hash":"351999f87eb88b1c92fef3bc68c77b226e4301b4","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/people/34/?format=json","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/22395/mbox/","series":[{"id":4910,"url":"https://patchwork.libcamera.org/api/series/4910/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=4910","date":"2024-12-18T08:34:17","name":"Raspberry Pi: Various changes","version":2,"mbox":"https://patchwork.libcamera.org/series/4910/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/22395/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/22395/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 33A0AC3301\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 18 Dec 2024 08:36:29 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id C8C6B6809B;\n\tWed, 18 Dec 2024 09:36:27 +0100 (CET)","from mail-wr1-x429.google.com (mail-wr1-x429.google.com\n\t[IPv6:2a00:1450:4864:20::429])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id E5BBD68095\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 18 Dec 2024 09:36:19 +0100 (CET)","by mail-wr1-x429.google.com with SMTP id\n\tffacd0b85a97d-38625aa01b3so592522f8f.3\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 18 Dec 2024 00:36:19 -0800 (PST)","from NAUSH-P-DELL.pitowers.org ([93.93.133.154])\n\tby smtp.gmail.com with ESMTPSA id\n\tffacd0b85a97d-388c804a2f9sm13585781f8f.77.2024.12.18.00.36.18\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tWed, 18 Dec 2024 00:36:18 -0800 (PST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"SV2/Zh6V\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google; t=1734510979; x=1735115779;\n\tdarn=lists.libcamera.org; \n\th=content-transfer-encoding:mime-version:references:in-reply-to\n\t:message-id:date:subject:cc:to:from:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=PIP26LxRuK+JHZPjKFeLlcD5pLgXl3eiU614VFDvcKc=;\n\tb=SV2/Zh6V+qWsOx8Rh2weiC9AMi8c6ATVGo49trKJmfxZNSpqXr5OmlZwpTFqlsPZm/\n\tEoe8I3/TBIg3b6Zi1GY7Z+cjbmIwAIfNK89A8OlHy7jobpnIRhnd+zfw4r1AZeR7gXZz\n\tUGXpcX69jIllW8dIeh+UA6sEH8AQ1B6yBtlABWNGEknjo4yW1TBOASJWUhs5p6aNbX+l\n\tJXSXzGO6KYcWxp8HjxZoli82wec6JfrbjHuIuxtW849dQMM8Cpitv1W4NPk/en9g5Moh\n\tIGyWw61ASdrk8reyhbQJj3e6MKUzE4d5Ta5GuFPfEyNPoGZKX9ugF3UFpECgKdCZaUxP\n\tBFXg==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1734510979; x=1735115779;\n\th=content-transfer-encoding:mime-version:references:in-reply-to\n\t:message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc\n\t:subject:date:message-id:reply-to;\n\tbh=PIP26LxRuK+JHZPjKFeLlcD5pLgXl3eiU614VFDvcKc=;\n\tb=SHYMSapAiPBQ4hdYiVqrvUvZXPy24BzHPQfZM4h29fzMaBN7vD9di1hybJZfa2QcLK\n\tAL+ilbUVO0nzz3mKBKvyNMkw3Dvy5WpIovN6X9vviaZDGaccPNHNqSxlx5lO63RrIS2j\n\tNSm5z1wveDyGolGKTDr64MiIJFONpHWdCOu59S4qC9dz7jfsMVCSdZJYk57fRnBq+lcm\n\tZDJXi8NLI2belHgmPePDs9yi+CQ2rOij94KeEjwlJ7gB8UaC1vryvVjIE8qALY885OcR\n\tAY2iD19mnAgrRI4b0i5UrtGYWAgl4z9M3m8dSY8TAXWTZYsP1nco6OZLGYPlV4Z+5XO7\n\tM5AQ==","X-Gm-Message-State":"AOJu0YxTFYbnUOD0EWNyblI7/JJNIBSug7THVUyPyET6tImU+Ya2tXFp\n\tjpfQcmbb13bxmf5Yu82bl4tF3YVjZdou5OuAXnboTpzbKdU4NixRW1QJqfalSANcp0xubeavVgP\n\ty","X-Gm-Gg":"ASbGncsosfMURjklCUUECSubJxZ1oN4DOwQLo3lVYdR0Gx+8o/FDaX7plU7JiR1Z/Og\n\t8Y/ddE47v1nYx23pDThFso8ATQVWJu37juE4Ut9VAeoKrp8nL3han9cSIuRkvoLsIzSQPKo70l4\n\tOoF4vQSL1R1t6e6kDfJbJTmjeq/b775qauUmlgYhIfr11FYtpSJLQjk5nfAs/zGsPBlTYEdhNz+\n\t+zIt1BPoN3Z6M7jt87rm4ZF4+zsg59Ltc6sdeZearqVxBN73R8CLwm9dF2ydPCoG295fTVOYN4O","X-Google-Smtp-Source":"AGHT+IGOjcfgNOPbuuXMXJkrlfZcidrF7TrotoJz/YOz1RT6WGzq1h7irRMPST7o4N3NxeSAaormrQ==","X-Received":"by 2002:a5d:6c6e:0:b0:385:fa20:6583 with SMTP id\n\tffacd0b85a97d-388e4d313f2mr561776f8f.2.1734510979046; \n\tWed, 18 Dec 2024 00:36:19 -0800 (PST)","From":"Naushir Patuck <naush@raspberrypi.com>","To":"libcamera-devel@lists.libcamera.org","Cc":"Naushir Patuck <naush@raspberrypi.com>,\n\tDavid Plowman <david.plowman@raspberrypi.com>","Subject":"[PATCH v2 4/4] ipa: rpi: Provide the camera helper with the hardware\n\tconfiguration","Date":"Wed, 18 Dec 2024 08:34:21 +0000","Message-ID":"<20241218083610.2397879-5-naush@raspberrypi.com>","X-Mailer":"git-send-email 2.43.0","In-Reply-To":"<20241218083610.2397879-1-naush@raspberrypi.com>","References":"<20241218083610.2397879-1-naush@raspberrypi.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":"Add a CamHelper::setHwConfig() helper used by the IPA to set the\nhardware configuration in use by the pipeline. This will be needed by\nthe IMX500 camera helper in a future commit to determine if the\nmetadata buffer is strided.\n\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\nReviewed-by: David Plowman <david.plowman@raspberrypi.com>\n---\n src/ipa/rpi/cam_helper/cam_helper.cpp | 5 +++++\n src/ipa/rpi/cam_helper/cam_helper.h   | 2 ++\n src/ipa/rpi/common/ipa_base.cpp       | 1 +\n 3 files changed, 8 insertions(+)","diff":"diff --git a/src/ipa/rpi/cam_helper/cam_helper.cpp b/src/ipa/rpi/cam_helper/cam_helper.cpp\nindex 6493e88232a4..1422a02e9953 100644\n--- a/src/ipa/rpi/cam_helper/cam_helper.cpp\n+++ b/src/ipa/rpi/cam_helper/cam_helper.cpp\n@@ -156,6 +156,11 @@ void CamHelper::setCameraMode(const CameraMode &mode)\n \t}\n }\n \n+void CamHelper::setHwConfig(const Controller::HardwareConfig &hwConfig)\n+{\n+\thwConfig_ = hwConfig;\n+}\n+\n void CamHelper::getDelays(int &exposureDelay, int &gainDelay,\n \t\t\t  int &vblankDelay, int &hblankDelay) const\n {\ndiff --git a/src/ipa/rpi/cam_helper/cam_helper.h b/src/ipa/rpi/cam_helper/cam_helper.h\nindex 4a4ab5e68cba..fb7eb3202e79 100644\n--- a/src/ipa/rpi/cam_helper/cam_helper.h\n+++ b/src/ipa/rpi/cam_helper/cam_helper.h\n@@ -76,6 +76,7 @@ public:\n \tCamHelper(std::unique_ptr<MdParser> parser, unsigned int frameIntegrationDiff);\n \tvirtual ~CamHelper();\n \tvoid setCameraMode(const CameraMode &mode);\n+\tvoid setHwConfig(const Controller::HardwareConfig &hwConfig);\n \tvirtual void prepare(libcamera::Span<const uint8_t> buffer,\n \t\t\t     Metadata &metadata);\n \tvirtual void process(StatisticsPtr &stats, Metadata &metadata);\n@@ -108,6 +109,7 @@ protected:\n \n \tstd::unique_ptr<MdParser> parser_;\n \tCameraMode mode_;\n+\tController::HardwareConfig hwConfig_;\n \n private:\n \t/*\ndiff --git a/src/ipa/rpi/common/ipa_base.cpp b/src/ipa/rpi/common/ipa_base.cpp\nindex 5fce17e67bd6..165c23c88d49 100644\n--- a/src/ipa/rpi/common/ipa_base.cpp\n+++ b/src/ipa/rpi/common/ipa_base.cpp\n@@ -160,6 +160,7 @@ int32_t IpaBase::init(const IPASettings &settings, const InitParams &params, Ini\n \tlensPresent_ = params.lensPresent;\n \n \tcontroller_.initialise();\n+\thelper_->setHwConfig(controller_.getHardwareConfig());\n \n \t/* Return the controls handled by the IPA */\n \tControlInfoMap::Map ctrlMap = ipaControls;\n","prefixes":["v2","4/4"]}