From patchwork Fri Jul 1 15:46:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacopo Mondi X-Patchwork-Id: 16513 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 A3CB2BD808 for ; Fri, 1 Jul 2022 15:47:12 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 5AE7065651; Fri, 1 Jul 2022 17:47:12 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1656690432; bh=1km8t/BvfrUvLPYwM9v37rUBS6Bl2/foVV9lOWkPbic=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=rkFkZKrt9dmg6o30g3L1BdKfmsZc5g7FZt5YqjyadF+JfL4NlQAqzeK8Cp5jYDrGR bCvEi3sZE7f7MEkICnvTKj2+4NQJVvDw6Y45H2ye+doYFjNsGDCz/zeb+aed841Wgu iMTcjNxylqKn4CA7XWG/eN5aOymQWeoX0FtvceJZzsQ1BRc18KsYHmPW0jdkpjfNGT 9DpaV4qdFcipLMJkYKItJDzhy8vePj3LM27RWcomlTKJ9lBkBq0xCP6Jo6Q534zclE dZRyDYVXqiUpjhePoLrADBVdeGfJNFixVDFPjMcfAC2/Erb42+jcHbF1xn+RB5JEYH M2ozlGn7HZ9UQ== Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 2D2396564F for ; Fri, 1 Jul 2022 17:47:09 +0200 (CEST) Received: (Authenticated sender: jacopo@jmondi.org) by mail.gandi.net (Postfix) with ESMTPSA id 6A055E0005; Fri, 1 Jul 2022 15:47:08 +0000 (UTC) To: libcamera-devel@lists.libcamera.org Date: Fri, 1 Jul 2022 17:46:55 +0200 Message-Id: <20220701154701.354052-3-jacopo@jmondi.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220701154701.354052-1-jacopo@jmondi.org> References: <20220518134728.777709-2-paul.elder@ideasonboard.com> <20220701154701.354052-1-jacopo@jmondi.org> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 3/9] fixup: s/Disabled/Manual for Exposure and Gain modes 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: , X-Patchwork-Original-From: Jacopo Mondi via libcamera-devel From: Jacopo Mondi Reply-To: Jacopo Mondi Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The ExposureTimeMode and AnalogueGainMode controls define the following statues: - Auto - Disabled The AE algorithm modes should either be - Active vs Disabled: to highlight that the algorithm is active or not - Auto vs Manual: to highlight where the exposure time and analogue gain values are computed from Use the latter form and change AnalogueGainModeDisabled and ExposureTimeModeDisabled in AnalogueGainModeManual and ExposureTimeModeManual respectively. Signed-off-by: Jacopo Mondi Acked-by: Paul Elder --- src/libcamera/control_ids.yaml | 54 +++++++++++++++++----------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/src/libcamera/control_ids.yaml b/src/libcamera/control_ids.yaml index 59770e63aead..bb5eeb1507a9 100644 --- a/src/libcamera/control_ids.yaml +++ b/src/libcamera/control_ids.yaml @@ -14,7 +14,7 @@ controls: result. The state is still reported even if ExposureTimeMode or - AnalogueGainMode is set to Disabled. + AnalogueGainMode is set to Manual. \sa AnalogueGain \sa AnalogueGainMode @@ -28,7 +28,7 @@ controls: The AE algorithm is inactive. This state should be returned if both AnalogueGainMode and - ExposureTimeMode are set to disabled (or one, if the camera only + ExposureTimeMode are set to manual (or one, if the camera only supports one of the two controls). - name: AeStateSearching value: 1 @@ -117,7 +117,7 @@ controls: and the sensor's analogue gain. The exposure modes are platform specific, and not all exposure modes may be supported. - When one of AnalogueGainMode or ExposureTimeMode is set to Disabled, + When one of AnalogueGainMode or ExposureTimeMode is set to Manual, the fixed values will override any choices made by AeExposureMode. \sa AnalogueGainMode @@ -157,7 +157,7 @@ controls: Exposure time (shutter speed) for the frame applied in the sensor device. This value is specified in micro-seconds. - This control will only take effect if ExposureTimeMode is Disabled. If + This control will only take effect if ExposureTimeMode is Manual. If this control is set when ExposureTimeMode is Auto, the value will be ignored and will not be retained. @@ -174,30 +174,30 @@ controls: description: | Controls the source of the exposure time that is applied to the image sensor. When set to Auto, the AE algorithm computes the exposure time - and configures the image sensor accordingly. When set to Disabled, + and configures the image sensor accordingly. When set to Manual, exposure time specified in ExposureTime is applied to the image sensor. If ExposureTime is not set, then the value last computed by the AE algorithm when the mode was Auto will be used. - If ExposureTime is not set and the mode is ExposureTimeModeDisabled and - AE was never Auto (either because the camera started in Disabled mode, + If ExposureTime is not set and the mode is ExposureTimeModeManual and + AE was never Auto (either because the camera started in Manual mode, or Auto is not supported by the camera), the camera should use a best-effort default value. When ExposureTimeMode is set Auto, the value set in ExposureTime is ignored and is not retained. This means that if ExposureTimeMode is set - to Disabled and ExposureTime is not also set, the exposure time that + to Manual and ExposureTime is not also set, the exposure time that was last computed by the AE algorithm while the mode was Auto will be applied to the sensor. - If ExposureTimeModeDisabled is supported, the ExposureTime control must + If ExposureTimeModeManual is supported, the ExposureTime control must also be supported. The set of ExposureTimeMode modes that are supported by the camera must have an intersection with the supported set of AnalogueGainMode modes. As it takes a few frames to apply the exposure time, there is a period of - time between submitting a request with ExposureTimeMode set to Disabled + time between submitting a request with ExposureTimeMode set to Manual and the exposure time component of the AE actually being disabled, during which the AE algorithm can still update the exposure time. If an application is switching from automatic and manual control and wishes @@ -206,10 +206,10 @@ controls: 1. Start with ExposureTimeMode set to Auto - 2. Set ExposureTimeMode to Disabled + 2. Set ExposureTimeMode to Manual 3. Wait for the first request to be output that has ExposureTimeMode - set to Disabled + set to Manual 4. Copy the value reported in ExposureTime into a new request, and submit it @@ -224,18 +224,18 @@ controls: The exposure time will be calculated automatically and set by the AE algorithm. If ExposureTime is set while this mode is active, it will be ignored, and it will also not be retained. - - name: ExposureTimeModeDisabled + - name: ExposureTimeModeManual value: 1 description: | The exposure time will not be updated by the AE algorithm. It will come from the last calculated value when the mode was Auto, or from the value specified in ExposureTime. - When transitioning from Auto to Disabled mode, the last computed + When transitioning from Auto to Manual mode, the last computed exposure value is used until a new value is specified through the ExposureTime control. If an ExposureTime value is specified in the same request where the ExposureTimeMode is changed from Auto to - Disabled, the provided ExposureTime is applied. + Manual, the provided ExposureTime is applied. - AnalogueGain: type: float @@ -244,7 +244,7 @@ controls: The value of the control specifies the gain multiplier applied to all colour channels. This value cannot be lower than 1.0. - This control will only take effect if AnalogueGainMode is Disabled. If + This control will only take effect if AnalogueGainMode is Manual. If this control is set when AnalogueGainMode is Auto, the value will be ignored and will not be retained. @@ -261,30 +261,30 @@ controls: description: | Controls the source of the analogue gain that is applied to the image sensor. When set to Auto, the AE algorithm computes the analogue gain - and configures the image sensor accordingly. When set to Disabled, + and configures the image sensor accordingly. When set to Manual, analogue gain specified in AnalogueGain is applied to the image sensor. If AnalogueGain is not set, then the value last computed by the AE algorithm when the mode was Auto will be used. - If AnalogueGain is not set and the mode is AnalogueGainModeDisabled and - AE was never Auto (either because the camera started in Disabled mode, + If AnalogueGain is not set and the mode is AnalogueGainModeManual and + AE was never Auto (either because the camera started in Manual mode, or Auto is not supported by the camera), the camera should use a best-effort default value. When AnalogueGainMode is set Auto, the value set in AnalogueGain is ignored and is not retained. This means that if AnalogueGainMode is set - to Disabled and AnalogueGain is not also set, the analogue gain that + to Manual and AnalogueGain is not also set, the analogue gain that was last computed by the AE algorithm while the mode was Auto will be applied to the sensor. - If AnalogueGainModeDisabled is supported, the AnalogueGain control must + If AnalogueGainModeManual is supported, the AnalogueGain control must also be supported. The set of AnalogueGainMode modes that are supported by the camera must have an intersection with the supported set of ExposureTimeMode modes. As it takes a few frames to apply the analogue gain, there is a period of - time between submitting a request with AnalogueGainMode set to Disabled + time between submitting a request with AnalogueGainMode set to Manual and the analogue gain component of the AE actually being disabled, during which the AE algorithm can still update the analogue gain. If an application is switching from automatic and manual control and wishes @@ -293,10 +293,10 @@ controls: 1. Start with AnalogueGainMode set to Auto - 2. Set AnalogueGainMode to Disabled + 2. Set AnalogueGainMode to Manual 3. Wait for the first request to be output that has AnalogueGainMode - set to Disabled + set to Manual 4. Copy the value reported in AnalogueGain into a new request, and submit it @@ -311,17 +311,17 @@ controls: The analogue gain will be calculated automatically and set by the AE algorithm. If AnalogueGain is set while this mode is active, it will be ignored, and it will also not be retained. - - name: AnalogueGainModeDisabled + - name: AnalogueGainModeManual value: 1 description: | The analogue gain will not be updated by the AE algorithm. It will come from the last calculated value when the mode was Auto, or from the value specified in AnalogueGain. - When transitioning from Auto to Disabled mode the last computed + When transitioning from Auto to Manual mode the last computed gain value is used until a new value is specified through the AnalogueGain control. If an AnalogueGain value is specified in the - same request where the AnalogueGainMode is set to Disabled, the + same request where the AnalogueGainMode is set to Manual, the provided AnalogueGain is applied. - Brightness: