| Message ID | 20261117-sklug-digital-gain-support-v1-v1-0-f0aa342ca877@ideasonboard.com |
|---|---|
| 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 3968EBDE17 for <parsemail@patchwork.libcamera.org>; Tue, 17 Nov 2026 08:47:18 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 6225D6A814; Tue, 17 Nov 2026 09:47:17 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="t7EsXs1j"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id E993C6A814 for <libcamera-devel@lists.libcamera.org>; Tue, 17 Nov 2026 09:47:15 +0100 (CET) Received: from ideasonboard.com (unknown [IPv6:2a00:6020:448c:6c00:27fa:cb4b:1d83:9b64]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 5800E593; Tue, 17 Nov 2026 09:44:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1794905088; bh=wX713o0P2gHMDc6OcAxJdP5eFihi1Tel2+aOazsAvG0=; h=From:Subject:Date:To:Cc:From; b=t7EsXs1jfc3yFCpjUp/59gEe227h8CiTascvt9BCPuTdBI6Zpuoih5CUorQ7yu+yg jv6tZXeL/vQRKerE5ILZje5wUOaAHWtyNDTXjSM/be2naWg68839iFy//y5PSFEa4B YuMT6bUuL7Db9coxwC6KOUiZ6lplZuiYQcV/VtTo= From: Stefan Klug <stefan.klug@ideasonboard.com> Subject: [PATCH 00/10] libipa: agc: Add digital gain support Date: Tue, 17 Nov 2026 09:47:10 +0100 Message-Id: <20261117-sklug-digital-gain-support-v1-v1-0-f0aa342ca877@ideasonboard.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-B4-Tracking: v=1; b=H4sIAAAAAAAC/x3MQQqEMAwAwK9IzgYaRdH9yuKhaFqDUkujIoh/t 3icy9ygnIQVfsUNiU9R2UIGlQWMsw2eUaZsqEzVElGNuqyHx0m87HZFbyWgHjFuaceT0DjTNY3 rOzu2kI+Y2Mn1/f/heV4gmm6VbwAAAA== X-Change-ID: 20261113-sklug-digital-gain-support-v1-0f0855f98ac6 To: libcamera-devel@lists.libcamera.org Cc: Stefan Klug <stefan.klug@ideasonboard.com> X-Mailer: b4 0.14.3 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
|
Hi everyone, Currently Agc (or specifically AgcMeanLuminance) doesn't support digital gain. In cases where either the sensor has no analogue gain or the available gain is not sufficient, digital gain is very useful. This series implements digital gain support for AgcMeanLuminance. Patches 1-6 implement digital gain and unconditionally enable it on RkIsp1. Unconditionally enabling it is not entirely correct as we can only apply digital gain if the Compress algorithm is provided in the tuning file. To properly solve that, we need some kind of inter-algorithm dependencies. Patches 7-9 implement a prototype for a simple dependency management. These patch are marked as RFC and should be treated as discussion basis. As we don't have tuning files in mainline that use digital gain, I think we could still continue with patches 1-6 even if we need more time for the rest as there is no negative effect for the user. Best regards, Stefan Signed-off-by: Stefan Klug <stefan.klug@ideasonboard.com> --- Stefan Klug (10): libipa: exposure_mode_helper: Add digital gain support libcamera: control_ids_core: Add DigitalGainMode enum libipa: agc_mean_luminance: Add support for digital gain libipa: agc: Rename agEnable to agMode libipa: agc: Pass agc::Session to prepare() libipa: agc: Implement DigitalGainMode support ipa: rkisp1: agc: Add digital gain support RFC ipa: libipa: Inject the registered name into an algorithm RFC ipa: libipa: Implement algorithm dependencies RFC rkisp1: Model dependencies between Compress and Agc src/ipa/ipu3/algorithms/agc.cpp | 2 +- src/ipa/libipa/agc.cpp | 102 ++++++++++++++++-- src/ipa/libipa/agc.h | 10 +- src/ipa/libipa/agc_mean_luminance.cpp | 30 +++++- src/ipa/libipa/agc_mean_luminance.h | 3 +- src/ipa/libipa/algorithm.cpp | 22 ++++ src/ipa/libipa/algorithm.h | 69 ++++++++++++- src/ipa/libipa/exposure_mode_helper.cpp | 90 +++++++++++----- src/ipa/libipa/exposure_mode_helper.h | 8 +- src/ipa/libipa/module.h | 178 ++++++++++++++++++++++++++------ src/ipa/mali-c55/algorithms/agc.cpp | 2 +- src/ipa/rkisp1/algorithms/agc.cpp | 46 +++++++-- src/ipa/rkisp1/algorithms/agc.h | 2 + src/ipa/rkisp1/algorithms/compress.cpp | 17 +++ src/ipa/rkisp1/algorithms/compress.h | 2 + src/ipa/rkisp1/rkisp1.cpp | 16 +-- src/ipa/softisp/algorithms/agc.cpp | 2 +- src/libcamera/control_ids_core.yaml | 44 ++++++++ 18 files changed, 554 insertions(+), 91 deletions(-) --- base-commit: da6a6ed33ed0ab305f10b6f8b44736150d39cef4 change-id: 20261113-sklug-digital-gain-support-v1-0f0855f98ac6 Best regards,