From patchwork Tue Nov 30 05:22:53 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 14878 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 77D68BDB13 for ; Tue, 30 Nov 2021 05:23:02 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 1D94D605A3; Tue, 30 Nov 2021 06:23:02 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="dFNubCEc"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id F0DEE604FC for ; Tue, 30 Nov 2021 06:23:00 +0100 (CET) Received: from perceval.ideasonboard.com (unknown [103.251.226.170]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id D8C568F0; Tue, 30 Nov 2021 06:22:59 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1638249780; bh=zqfASILgCGLSIZ6wDq699bEMHTGp5VhfgsI3kUWC/dw=; h=From:To:Cc:Subject:Date:From; b=dFNubCEcCasFUeZJkMOW5cDhd7i4C3FndyVnRPO/1Es/BKkohhIzNLLxeNvcpjH3O oOQQttzvGQFscR/3ypXiwmzFwC9+ih9RdXxNfxzj3RVfaDTZQVRiLlu/qX9jnJPy5I 6aQMU1P8OKxibVie3lSoG84EGfA94oohdThInXkc= From: Umang Jain To: libcamera-devel@lists.libcamera.org Date: Tue, 30 Nov 2021 10:52:53 +0530 Message-Id: <20211130052253.513278-1-umang.jain@ideasonboard.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH] ipa: ipu3: Rectify gain value reporting in request metadata 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" Report value of sensor's gain pertaining to the current request completion, as that is the gain value the request completed with. The Agc algorithm processes the gain value for incoming next request hence it should not be reported in request's metadata. Signed-off-by: Umang Jain Reviewed-by: Jean-Michel Hautbois Reviewed-by: Kieran Bingham --- src/ipa/ipu3/ipu3.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp index b0c75541..76182587 100644 --- a/src/ipa/ipu3/ipu3.cpp +++ b/src/ipa/ipu3/ipu3.cpp @@ -628,7 +628,7 @@ void IPAIPU3::parseStatistics(unsigned int frame, int64_t frameDuration = (defVBlank_ + sensorInfo_.outputSize.height) * lineDuration_.get(); ctrls.set(controls::FrameDuration, frameDuration); - ctrls.set(controls::AnalogueGain, context_.frameContext.agc.gain); + ctrls.set(controls::AnalogueGain, context_.frameContext.sensor.gain); ctrls.set(controls::ColourTemperature, context_.frameContext.awb.temperatureK);