From patchwork Thu Dec 18 23:22:18 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rui Wang X-Patchwork-Id: 25610 Return-Path: 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 421D4C3257 for ; Thu, 18 Dec 2025 23:22:55 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id DD24261F5C; Fri, 19 Dec 2025 00:22:54 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="DOiD8MLK"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 4236F61F5C for ; Fri, 19 Dec 2025 00:22:53 +0100 (CET) Received: from rui-Precision-7560.local (unknown [209.216.103.65]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 86A36596; Fri, 19 Dec 2025 00:22:45 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1766100165; bh=3CK6uMw2KOE4Likz+4ZQPxifnHxjNx2m8j+Tz7bjHOI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DOiD8MLKUO6BQSm8+Jma9lDqqI2QUBF2aHs9h4fVo9S1s/4nGmYC9nB3iP/dS/X+k MSKR6dqrdIeINVzXZD3suqOILkEV83NUFCrZnOMZICFQCxIAkCNGkxcYsHw2H76Grd l/fDWJeMAoYxD9tHHgejHyGL6OooZIFFRDWoXmXo= From: Rui Wang To: libcamera-devel@lists.libcamera.org Cc: Rui Wang Subject: [PATCH v6 4/6] ipa: rkisp1: algorithms: dpf: Simplify YAML key names Date: Thu, 18 Dec 2025 18:22:18 -0500 Message-ID: <20251218232220.761254-5-rui.wang@ideasonboard.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20251218232220.761254-1-rui.wang@ideasonboard.com> References: <20251218232220.761254-1-rui.wang@ideasonboard.com> MIME-Version: 1.0 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Rename DPF tuning file keys to shorter, more concise names: - DomainFilter -> filter - NoiseLevelFunction -> nll - FilterStrength -> strength This improves readability and reduces verbosity in tuning files while maintaining the same functionality. Error messages are updated accordingly to reflect the new key names. Signed-off-by: Rui Wang --- changelog since v5: Nothing changed Reviewed-by tags from v5 are carried over (no code changes). src/ipa/rkisp1/algorithms/dpf.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/ipa/rkisp1/algorithms/dpf.cpp b/src/ipa/rkisp1/algorithms/dpf.cpp index ee82dfd2..2c28e38f 100644 --- a/src/ipa/rkisp1/algorithms/dpf.cpp +++ b/src/ipa/rkisp1/algorithms/dpf.cpp @@ -126,7 +126,7 @@ int Dpf::parseSingleConfig(const YamlObject &tuningData, * The domain kernel is configured with a 9x9 kernel for the green * pixels, and a 13x9 or 9x9 kernel for red and blue pixels. */ - const YamlObject &dFObject = tuningData["DomainFilter"]; + const YamlObject &dFObject = tuningData["filter"]; /* * For the green component, we have the 9x9 kernel specified @@ -148,7 +148,7 @@ int Dpf::parseSingleConfig(const YamlObject &tuningData, values = dFObject["g"].getList().value_or(std::vector{}); if (values.size() != RKISP1_CIF_ISP_DPF_MAX_SPATIAL_COEFFS) { LOG(RkISP1Dpf, Error) - << "Invalid 'DomainFilter:g': expected " + << "Invalid 'filter:g': expected " << RKISP1_CIF_ISP_DPF_MAX_SPATIAL_COEFFS << " elements, got " << values.size(); return -EINVAL; @@ -185,7 +185,7 @@ int Dpf::parseSingleConfig(const YamlObject &tuningData, if (values.size() != RKISP1_CIF_ISP_DPF_MAX_SPATIAL_COEFFS && values.size() != RKISP1_CIF_ISP_DPF_MAX_SPATIAL_COEFFS - 1) { LOG(RkISP1Dpf, Error) - << "Invalid 'DomainFilter:rb': expected " + << "Invalid 'filter:rb': expected " << RKISP1_CIF_ISP_DPF_MAX_SPATIAL_COEFFS - 1 << " or " << RKISP1_CIF_ISP_DPF_MAX_SPATIAL_COEFFS << " elements, got " << values.size(); @@ -207,13 +207,13 @@ int Dpf::parseSingleConfig(const YamlObject &tuningData, * which stores a piecewise linear function that characterizes the * sensor noise profile as a noise level function curve (NLF). */ - const YamlObject &rFObject = tuningData["NoiseLevelFunction"]; + const YamlObject &rFObject = tuningData["nll"]; std::vector nllValues; nllValues = rFObject["coeff"].getList().value_or(std::vector{}); if (nllValues.size() != RKISP1_CIF_ISP_DPF_MAX_NLF_COEFFS) { LOG(RkISP1Dpf, Error) - << "Invalid 'RangeFilter:coeff': expected " + << "Invalid 'nll:coeff': expected " << RKISP1_CIF_ISP_DPF_MAX_NLF_COEFFS << " elements, got " << nllValues.size(); return -EINVAL; @@ -229,13 +229,13 @@ int Dpf::parseSingleConfig(const YamlObject &tuningData, config.nll.scale_mode = RKISP1_CIF_ISP_NLL_SCALE_LOGARITHMIC; } else { LOG(RkISP1Dpf, Error) - << "Invalid 'RangeFilter:scale-mode': expected " + << "Invalid 'nll:scale-mode': expected " << "'linear' or 'logarithmic' value, got " << scaleMode; return -EINVAL; } - const YamlObject &fSObject = tuningData["FilterStrength"]; + const YamlObject &fSObject = tuningData["strength"]; strengthConfig.r = fSObject["r"].get().value_or(64); strengthConfig.g = fSObject["g"].get().value_or(64);