| Message ID | 20261029-disable_sensor_agc-v1-1-b3706d4e88b4@foss.st.com |
|---|---|
| State | New |
| Headers | show
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 [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id A7AFFC324C for <parsemail@patchwork.libcamera.org>; Thu, 29 Oct 2026 12:37:48 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id D7EE669094; Thu, 29 Oct 2026 13:37:47 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=foss.st.com header.i=@foss.st.com header.b="hnOotVV9"; dkim-atps=neutral Received: from DU2PR03CU002.outbound.protection.outlook.com (mail-northeuropeazlp170110003.outbound.protection.outlook.com [IPv6:2a01:111:f403:c200::3]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 9EC7868E07 for <libcamera-devel@lists.libcamera.org>; Thu, 29 Oct 2026 13:37:45 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=wLyFg/zMkNHHPvmDmkqWusuqU7J/WcU+5XuusR+rS2Gsvfw1/Y0QIwvpZXerxjSOFXqlVfn2q6sgNj0+f01eSlE9obrtDHBUFY4LrcANh7zXl+KP2TnToTkpeO+AJZItWAn9TyGNkHL2D+WFrBsatnEwOAiMhgOSyai/YcjHWMRNevHH8ACeTb41skMC6bNGPcAibFizmb2XxosKJZ5KVgyyvAuHLZXZOBPXxxrnBmWLL1jDIv7tSuCLlwYd/nRE8hiAANgxFMPZ33AOYd8U4J614LHWtm+TYrkknQnVYj3PQz1XKNw5FrCRsPnleupyAr67KYt8AKBhAbiQciOspg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=olq+KuVVu5lwVm01WE+ByP4DXMi2o/aweFO7NTxYNto=; b=RM7g+CIvyKRWsY1Au7q92xWtpGyso1q9DlyJLQFwEacRZibnxcmRVZon5s0OergNJA3wNB2xtr+KG/V4OWZJ7aUOraXPrftDBXp4sPDHh2u4+YsuJO6kvbCDHDt0VGgj0qrhkrG8qcVYd0/fJ63RiA7q8iP9kb/uOl4B7s25b9PMQKZApXNW2Epg32bVoqcKLLs4WXTiKVU4Wfpqz/qyp0FTem5oOrsddkBn//pkE10+Smx7WloYfynV+GfFXKS99lXrDmxnlbR1k3Nqq0ndzr4xxvazpU7HFaStkggtUR0w3IguLzCSrfwB/tCzLj09zy4Ih939xprFYElCGOmIyw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=fail (sender ip is 164.130.1.60) smtp.rcpttodomain=ideasonboard.com smtp.mailfrom=foss.st.com; dmarc=fail (p=none sp=none pct=100) action=none header.from=foss.st.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foss.st.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=olq+KuVVu5lwVm01WE+ByP4DXMi2o/aweFO7NTxYNto=; b=hnOotVV9cKaQCW9EhfQ0Y9js9KM6eDpIBKnhb/DMANPOJUy46bNU6O5EXVxVpHTPVcVCn2HYCEUa3mOZyl+LQNLLDP/3UxMeQIsrl4f1ETzxsGmueINH95S0ZWUzlkorD8a/3brexwL+6rUFUXnCdYv7r2+po2tcA0grOFnoD8Vn/CkW4GHgPBQ5AqRY7nK9v63fRRCt2j6cnwcQA+b+5umo/1UeydcQyUSN6MsFyL1KHIcrQLuoL5hAgXhYaXMpALIiAgYiwbyMQd2QnH9ktin5EzrVfmfb3rsaRoCdlBo/UtFxm2nyX5qYVKw79I34yHlbr9wds0Ryb6Ohghkgeg== Received: from MR1P264CA0097.FRAP264.PROD.OUTLOOK.COM (2603:10a6:501:50::18) by GV1PR10MB6145.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:150:9a::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.569.8; Thu, 29 Oct 2026 12:37:41 +0000 Received: from MAD0EPF000008B3.eurprd04.prod.outlook.com (2603:10a6:501:50:cafe::b) by MR1P264CA0097.outlook.office365.com (2603:10a6:501:50::18) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.569.7 via Frontend Transport; Thu, 29 Oct 2026 12:37:40 +0000 X-MS-Exchange-Authentication-Results: mx.microsoft.com 1; spf=fail (sender IP is 164.130.1.60) smtp.mailfrom=foss.st.com; dkim=none (message not signed) header.d=none;dmarc=fail action=none header.from=foss.st.com; Received-SPF: Fail (protection.outlook.com: domain of foss.st.com does not designate 164.130.1.60 as permitted sender) receiver=protection.outlook.com; client-ip=164.130.1.60; helo=smtpO365.st.com; Received: from smtpO365.st.com (164.130.1.60) by MAD0EPF000008B3.mail.protection.outlook.com (10.167.241.135) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.569.4 via Frontend Transport; Thu, 29 Oct 2026 12:37:40 +0000 Received: from STKDAG1NODE2.st.com (10.75.128.133) by smtpO365.st.com (10.250.44.72) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.46; Thu, 29 Oct 2026 13:38:21 +0100 Received: from localhost (10.130.78.67) by STKDAG1NODE2.st.com (10.75.128.133) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.46; Thu, 29 Oct 2026 13:37:39 +0100 From: Benjamin Mugnier <benjamin.mugnier@foss.st.com> Date: Thu, 29 Oct 2026 13:37:19 +0100 Subject: [PATCH] ipa: rpi: Disable on-sensor auto-exposure where available MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Message-ID: <20261029-disable_sensor_agc-v1-1-b3706d4e88b4@foss.st.com> X-B4-Tracking: v=1; b=H4sIAP4942oC/yXMTQqDMBBA4avIrA0kof5eRYrEZKIjEiXTiiDev akuv8V7JzBGQoY2OyHiTkxrSFB5BnYyYURBLhm01KWSuhGO2AwL9oyB19ib0YpXZXxVKFn42kE Kt4iejnvavR/zd5jRfv4nuK4fSGWcXXYAAAA= X-Change-ID: 20261029-disable_sensor_agc-47af75105f8d To: <libcamera-devel@lists.libcamera.org> CC: Naushir Patuck <naush@raspberrypi.com>, Dave Stevenson <dave.stevenson@raspberrypi.com>, Kieran Bingham <kieran.bingham@ideasonboard.com>, =?utf-8?q?Barnab?= =?utf-8?b?w6FzIFDFkWN6ZQ==?= <barnabas.pocze@ideasonboard.com>, Benjamin Mugnier <benjamin.mugnier@foss.st.com> X-Mailer: b4 0.15.2 X-Originating-IP: [10.130.78.67] X-ClientProxiedBy: ENXCAS1NODE2.st.com (10.75.128.138) To STKDAG1NODE2.st.com (10.75.128.133) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MAD0EPF000008B3:EE_|GV1PR10MB6145:EE_ X-MS-Office365-Filtering-Correlation-Id: 3823b809-14a4-4c15-9da6-08df35b96bb7 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|23010399003|376014|36860700016|82310400026|11063799006|56012099006|261009223027099003|261026140227099003|261026121527099003|261028144727099003|261021121427099003|261022105027099003|10067099003|18002099003|3023799007; X-Microsoft-Antispam-Message-Info: spd2x7/0FDMLIpoSu3Fh5FjqV/HWP7Wl2iylg/gHlTDy0EvtbC6n4p5am4LVgTHzsPjV1LhxN4wO1uNenUISl0U6SjMrkvPe+HIybqsCjQ3IAMhBcUQqSUETR+lJHt7OGpZOE6nGGsqIPnAxiUsjUSXNhg7ABf1HLp8JkVrWsAmr1ka9WEL6Fi8k6OueKRf7fWyImF5pykvYmgoDTIy0aaKlGhdC+c2GWFySwnIzVak7NUHbext74vU87Rxv/IdpTYPvjk+Was1zj59Ylmz1nurB1It6VAEq3kuapddmD+FTthdXYs+jVysEq05LK/GC24jD+BWfIy8Eh6mNG1Ylho5xcUziWSgLXtfGXoQrje1KfiLgKNZiuSqbWRNbbLgf7O3eJU272NZ5cO/+7NzBpCez2IYrn7RDDHtGpF8ZjL6XSNWAvMPYp4EAjsBU7sRD61IDv5OOphTOG7aFf3id0EnR9J5KkjVkUkRYpCiGa6L506u4TApjg7mdy5CqrpJ3JTSY5DQtM9wV3VueDylS/kpSq1DZhH0cHX69b3/B8AkjQKpcWaG1XWcUz6Qh2NjBa84RHUd89HoV/kH875O7RiAK6a+y9Z6rM22DATL9W9XTciQOop2TARcbE/3VByFT++VbpyLIdT9Rdbim9HKxLcsG44jEObGFLlNsYCVy3OCMLjDrcIWxiwvk+8uGtU12 X-Forefront-Antispam-Report: CIP:164.130.1.60; CTRY:IT; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:smtpO365.st.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(1800799024)(23010399003)(376014)(36860700016)(82310400026)(11063799006)(56012099006)(261009223027099003)(261026140227099003)(261026121527099003)(261028144727099003)(261021121427099003)(261022105027099003)(10067099003)(18002099003)(3023799007); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: bcyT0DsysRTrEMRUOdZMtq+hrayzHiMz/wjy2qmNZMGJ86lCEnVirnptKpxtdAXt5h2n9+j7mXkoP3vx47zyvks1vZrR1yuEwyY4aEZsnJVZP6YlXaNFhJhAtIsfSiSHwr7CWlmz7eMnuiKnxU3A+UfEemA6fVIxnPFe+IRdE8V244I3Lb/6h07UDwZ0ybfWpnTMJBf8691KtE4lJ9VQWiFIjAZTja/HG9gDvRBxaIulokAtSud4ynZu/m7bQHX+2Z6Y9z0JPzysgwilJKjtUJ6Xk9Q+GZpmBwfT1sktK603o3SVv44x5aPmjas7tVvxn5EkfT7hD9apnCeEakOweISyhgOKNo8zIhoHy2cjPGWAxeF8RsSkJjcSg5Y0me50gegIb/ftGHfVqRZcQ3N+sex1i7vLA2Mq1rCngOJ0wZESaliNT3n+rjBle0ec+XAY X-OriginatorOrg: foss.st.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Oct 2026 12:37:40.1217 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3823b809-14a4-4c15-9da6-08df35b96bb7 X-MS-Exchange-CrossTenant-Id: 75e027c9-20d5-47d5-b82f-77d7cd041e8f X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=75e027c9-20d5-47d5-b82f-77d7cd041e8f; Ip=[164.130.1.60]; Helo=[smtpO365.st.com] X-MS-Exchange-CrossTenant-AuthSource: MAD0EPF000008B3.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: GV1PR10MB6145 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>, <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>, <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> |
| Series |
|
| Related |
show
|
diff --git a/src/ipa/rpi/common/ipa_base.cpp b/src/ipa/rpi/common/ipa_base.cpp index c284834440c8..cd4e684d8423 100644 --- a/src/ipa/rpi/common/ipa_base.cpp +++ b/src/ipa/rpi/common/ipa_base.cpp @@ -208,6 +208,12 @@ int32_t IpaBase::configure(const IPACameraSensorInfo &sensorInfo, const ConfigPa } } + /* Disable sensor agc not to interfere with agc algorithm */ + RPiController::AgcAlgorithm *agc = dynamic_cast<RPiController::AgcAlgorithm *>( + controller_.getAlgorithm("agc")); + if (agc) + ctrl.set(V4L2_CID_EXPOSURE_AUTO, V4L2_EXPOSURE_MANUAL); + /* Setup a metadata ControlList to output metadata. */ libcameraMetadata_ = ControlList(controls::controls);
Some sensor device drivers (e.g, VD66GY and VD56G3) have sensor auto- exposure enabled by default. This interferes with the AGC algorithm running in the IPA. By default, disable the sensor auto-exposure on startup so that the IPA can control the sensor shutter time and gain. This is an alternative take on Naushir Patuck proposition. It was brought by Kieran Bingham and Barnabás Pőcze that some pipeline handlers (i.e the simple pipeline) lacks agc, and therefore should keep the sensor agc when available. This patch moves the decision from the core to the ipa, starting with rpi. It only disables sensor agc for rpi ipa if ipa agc is running, and keeps it if it doesn't. Signed-off-by: Benjamin Mugnier <benjamin.mugnier@foss.st.com> --- src/ipa/rpi/common/ipa_base.cpp | 6 ++++++ 1 file changed, 6 insertions(+) --- base-commit: 6e19ca0fa7aa75aa965511072f43b5e50dec1904 change-id: 20261029-disable_sensor_agc-47af75105f8d Best regards, -- Benjamin Mugnier <benjamin.mugnier@foss.st.com>