ipa: rkisp1: dpf: Enable strength after enable Dpf
diff mbox series

Message ID 20251110192511.762532-1-rui.wang@ideasonboard.com
State New
Headers show
Series
  • ipa: rkisp1: dpf: Enable strength after enable Dpf
Related show

Commit Message

rui wang Nov. 10, 2025, 7:25 p.m. UTC
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 <rui.wang@ideasonboard.com>
---
 src/ipa/rkisp1/algorithms/dpf.cpp | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

Patch
diff mbox series

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<BlockType::Dpf>();
 	config.setEnabled(frameContext.dpf.denoise);
 
+	auto strengthConfig = params->block<BlockType::DpfStrength>();
+	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<BlockType::DpfStrength>();
-		strengthConfig.setEnabled(true);
-		*strengthConfig = strengthConfig_;
-	}
 }
 
 REGISTER_IPA_ALGORITHM(Dpf, "Dpf")