From patchwork Tue Nov 11 15:59:04 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rui Wang X-Patchwork-Id: 24997 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 5F304C3241 for ; Tue, 11 Nov 2025 15:59:21 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 96812606A0; Tue, 11 Nov 2025 16:59:20 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="dFCy3/mq"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id E03B6606A0 for ; Tue, 11 Nov 2025 16:59:18 +0100 (CET) Received: from rui-Precision-7560.local (unknown [209.216.122.90]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id D67311D29; Tue, 11 Nov 2025 16:57:19 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1762876640; bh=5NMOfndQO6ZgKUSt8tQv2JrPlmhllWLcHUguoD6JsZU=; h=From:Date:Subject:To:Cc:From; b=dFCy3/mqU0o69SneidL9c/RI7mcOqI6dj5e1TXdU3bCJjWcI9HYl7SzFRH0KOCkjz vJnpdeSXqwQikYigzqBjIxsUr1bneP5eN7j77Pu1GxXEmkks9nv0u9FXLbKviyXrHq QzBp3aOuxF8w1kSy3vm/nrUsVP7MMQ05BnYjL+aE= From: Rui Wang Date: Tue, 11 Nov 2025 10:59:04 -0500 Subject: [PATCH] ipa: rkisp1: dpf: Enable strength after enable Dpf MIME-Version: 1.0 Message-Id: <20251111-denoise_mainline_issue-v1-1-6d5db30d958f@ideasonboard.com> X-B4-Tracking: v=1; b=H4sIAEddE2kC/x2MQQqDMBQFryJ/3UAiEalXERExT/ug/Uo+FUG8e 0NnN4uZSwyZMOmqSzIOGjctEh6VzK9JVzim4lL7ugkFl6AbDeNnor6pGGn2hVvm1qfm6X0MUUq 8Zyw8/+N+uO8f+bd6h2gAAAA= X-Change-ID: 20251111-denoise_mainline_issue-fc70d5900414 To: libcamera-devel@lists.libcamera.org Cc: Rui Wang X-Mailer: b4 0.14.3 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" The filter strength configuration block was previously only enabled on the first frame (frame == 0). Apply the strength values when denoise is active. This prevents the strength config from being disabled on subsequent frames. Signed-off-by: Rui Wang --- src/ipa/rkisp1/algorithms/dpf.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) --- base-commit: 06aee9135f9fd135a8c0bc0b55971b29f7617d02 change-id: 20251111-denoise_mainline_issue-fc70d5900414 Best regards, diff --git a/src/ipa/rkisp1/algorithms/dpf.cpp b/src/ipa/rkisp1/algorithms/dpf.cpp index cb6095da..39f3e461 100644 --- a/src/ipa/rkisp1/algorithms/dpf.cpp +++ b/src/ipa/rkisp1/algorithms/dpf.cpp @@ -225,8 +225,12 @@ void Dpf::prepare(IPAContext &context, const uint32_t frame, auto config = params->block(); config.setEnabled(frameContext.dpf.denoise); + auto strengthConfig = params->block(); + strengthConfig.setEnabled(frameContext.dpf.denoise); + if (frameContext.dpf.denoise) { *config = config_; + *strengthConfig = strengthConfig_; const auto &awb = context.configuration.awb; const auto &lsc = context.configuration.lsc; @@ -250,12 +254,6 @@ void Dpf::prepare(IPAContext &context, const uint32_t frame, else mode = RKISP1_CIF_ISP_DPF_GAIN_USAGE_DISABLED; } - - if (frame == 0) { - auto strengthConfig = params->block(); - strengthConfig.setEnabled(true); - *strengthConfig = strengthConfig_; - } } REGISTER_IPA_ALGORITHM(Dpf, "Dpf")