[{"id":29446,"web_url":"https://patchwork.libcamera.org/comment/29446/","msgid":"<171517288587.1857112.13988878080108843847@ping.linuxembedded.co.uk>","date":"2024-05-08T12:54:45","subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Daniel Scally (2024-04-18 13:46:30)\n> Within the IPU3 IPA module there are multiple references to min and\n> max shutter speeds. In calculation and usage however those variables\n> reflect integration time rather than shutter speed - this difference\n> in terminology is particularly problematic because the minimum\n> shutter speed is equivalent to the maximum integration time.\n> \n> Replace references to shutter speed with integration time.\n\nI think this makes sense.\n\n\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n> \n> Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com>\n> ---\n>  src/ipa/ipu3/algorithms/agc.cpp | 12 ++++++------\n>  src/ipa/ipu3/algorithms/agc.h   |  4 ++--\n>  src/ipa/ipu3/ipa_context.cpp    |  8 ++++----\n>  src/ipa/ipu3/ipa_context.h      |  4 ++--\n>  src/ipa/ipu3/ipu3.cpp           |  8 ++++----\n>  5 files changed, 18 insertions(+), 18 deletions(-)\n> \n> diff --git a/src/ipa/ipu3/algorithms/agc.cpp b/src/ipa/ipu3/algorithms/agc.cpp\n> index 46fc3b33..a59b73fb 100644\n> --- a/src/ipa/ipu3/algorithms/agc.cpp\n> +++ b/src/ipa/ipu3/algorithms/agc.cpp\n> @@ -51,7 +51,7 @@ LOG_DEFINE_CATEGORY(IPU3Agc)\n>  static constexpr double kMinAnalogueGain = 1.0;\n>  \n>  /* \\todo Honour the FrameDurationLimits control instead of hardcoding a limit */\n> -static constexpr utils::Duration kMaxShutterSpeed = 60ms;\n> +static constexpr utils::Duration kMaxIntegrationTime = 60ms;\n>  \n>  /* Histogram constants */\n>  static constexpr uint32_t knumHistogramBins = 256;\n> @@ -71,7 +71,7 @@ static constexpr uint32_t kNumStartupFrames = 10;\n>  static constexpr double kRelativeLuminanceTarget = 0.16;\n>  \n>  Agc::Agc()\n> -       : minShutterSpeed_(0s), maxShutterSpeed_(0s)\n> +       : minIntegrationTime_(0s), maxIntegrationTime_(0s)\n>  {\n>  }\n>  \n> @@ -114,9 +114,9 @@ int Agc::configure(IPAContext &context,\n>         stride_ = configuration.grid.stride;\n>         bdsGrid_ = configuration.grid.bdsGrid;\n>  \n> -       minShutterSpeed_ = configuration.agc.minShutterSpeed;\n> -       maxShutterSpeed_ = std::min(configuration.agc.maxShutterSpeed,\n> -                                   kMaxShutterSpeed);\n> +       minIntegrationTime_ = configuration.agc.minIntegrationTime;\n> +       maxIntegrationTime_ = std::min(configuration.agc.maxIntegrationTime,\n> +                                      kMaxIntegrationTime);\n>  \n>         minAnalogueGain_ = std::max(configuration.agc.minAnalogueGain, kMinAnalogueGain);\n>         maxAnalogueGain_ = configuration.agc.maxAnalogueGain;\n> @@ -129,7 +129,7 @@ int Agc::configure(IPAContext &context,\n>         context.activeState.agc.exposureMode = exposureModeHelpers().begin()->first;\n>  \n>         /* \\todo Run this again when FrameDurationLimits is passed in */\n> -       configureExposureModeHelpers(minShutterSpeed_, maxShutterSpeed_,\n> +       configureExposureModeHelpers(minIntegrationTime_, maxIntegrationTime_,\n>                                      minAnalogueGain_, maxAnalogueGain_);\n>  \n>         resetFrameCount();\n> diff --git a/src/ipa/ipu3/algorithms/agc.h b/src/ipa/ipu3/algorithms/agc.h\n> index 945d1846..631dea52 100644\n> --- a/src/ipa/ipu3/algorithms/agc.h\n> +++ b/src/ipa/ipu3/algorithms/agc.h\n> @@ -42,8 +42,8 @@ private:\n>         Histogram parseStatistics(const ipu3_uapi_stats_3a *stats,\n>                                   const ipu3_uapi_grid_config &grid);\n>  \n> -       utils::Duration minShutterSpeed_;\n> -       utils::Duration maxShutterSpeed_;\n> +       utils::Duration minIntegrationTime_;\n> +       utils::Duration maxIntegrationTime_;\n>  \n>         double minAnalogueGain_;\n>         double maxAnalogueGain_;\n> diff --git a/src/ipa/ipu3/ipa_context.cpp b/src/ipa/ipu3/ipa_context.cpp\n> index c4fb5642..72f7cec9 100644\n> --- a/src/ipa/ipu3/ipa_context.cpp\n> +++ b/src/ipa/ipu3/ipa_context.cpp\n> @@ -92,11 +92,11 @@ namespace libcamera::ipa::ipu3 {\n>   * \\var IPASessionConfiguration::agc\n>   * \\brief AGC parameters configuration of the IPA\n>   *\n> - * \\var IPASessionConfiguration::agc.minShutterSpeed\n> - * \\brief Minimum shutter speed supported with the configured sensor\n> + * \\var IPASessionConfiguration::agc.minIntegrationTime\n> + * \\brief Minimum integration time supported with the configured sensor\n>   *\n> - * \\var IPASessionConfiguration::agc.maxShutterSpeed\n> - * \\brief Maximum shutter speed supported with the configured sensor\n> + * \\var IPASessionConfiguration::agc.maxIntegrationTime\n> + * \\brief Maximum integration time supported with the configured sensor\n>   *\n>   * \\var IPASessionConfiguration::agc.minAnalogueGain\n>   * \\brief Minimum analogue gain supported with the configured sensor\n> diff --git a/src/ipa/ipu3/ipa_context.h b/src/ipa/ipu3/ipa_context.h\n> index a92cb6ce..6b1ffdd1 100644\n> --- a/src/ipa/ipu3/ipa_context.h\n> +++ b/src/ipa/ipu3/ipa_context.h\n> @@ -33,8 +33,8 @@ struct IPASessionConfiguration {\n>         } af;\n>  \n>         struct {\n> -               utils::Duration minShutterSpeed;\n> -               utils::Duration maxShutterSpeed;\n> +               utils::Duration minIntegrationTime;\n> +               utils::Duration maxIntegrationTime;\n>                 double minAnalogueGain;\n>                 double maxAnalogueGain;\n>         } agc;\n> diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp\n> index 4809eb60..f13cc394 100644\n> --- a/src/ipa/ipu3/ipu3.cpp\n> +++ b/src/ipa/ipu3/ipu3.cpp\n> @@ -217,13 +217,13 @@ void IPAIPU3::updateSessionConfiguration(const ControlInfoMap &sensorControls)\n>  \n>         /*\n>          * When the AGC computes the new exposure values for a frame, it needs\n> -        * to know the limits for shutter speed and analogue gain.\n> +        * to know the limits for integration time and analogue gain.\n>          * As it depends on the sensor, update it with the controls.\n>          *\n> -        * \\todo take VBLANK into account for maximum shutter speed\n> +        * \\todo take VBLANK into account for maximum integration time\n>          */\n> -       context_.configuration.agc.minShutterSpeed = minExposure * context_.configuration.sensor.lineDuration;\n> -       context_.configuration.agc.maxShutterSpeed = maxExposure * context_.configuration.sensor.lineDuration;\n> +       context_.configuration.agc.minIntegrationTime = minExposure * context_.configuration.sensor.lineDuration;\n> +       context_.configuration.agc.maxIntegrationTime = maxExposure * context_.configuration.sensor.lineDuration;\n>         context_.configuration.agc.minAnalogueGain = camHelper_->gain(minGain);\n>         context_.configuration.agc.maxAnalogueGain = camHelper_->gain(maxGain);\n>  }\n> -- \n> 2.34.1\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 5B56CC3226\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed,  8 May 2024 12:54:51 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5063A62C9F;\n\tWed,  8 May 2024 14:54:50 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 2C0BA61A73\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  8 May 2024 14:54:49 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust6594.18-1.cable.virginm.net [86.31.185.195])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 1D10419FA;\n\tWed,  8 May 2024 14:54:46 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"ivT1oIfV\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1715172886;\n\tbh=BQOFUVPfZ8M2nDU/vOVKl6ABg56oAA3+dEfIb36rXcU=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=ivT1oIfVeqVAe75+sfly/uhrJ/hk0lX6f/pdyoRrX1FnQiCs0ss8qroPB7ULh2ef+\n\tkFGZEOhYNV8gC7TY47tKMmAwxajWRVqSYLbiYmRg0Wdo7HJNOiJJWtPMQzRi/pyL1q\n\tTetK2TgHxscnEWP4rHAOzU9VM8trF1/TbZNJ8QUk=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20240418124632.652163-2-dan.scally@ideasonboard.com>","References":"<20240418124632.652163-1-dan.scally@ideasonboard.com>\n\t<20240418124632.652163-2-dan.scally@ideasonboard.com>","Subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Daniel Scally <dan.scally@ideasonboard.com>","To":"Daniel Scally <dan.scally@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Wed, 08 May 2024 13:54:45 +0100","Message-ID":"<171517288587.1857112.13988878080108843847@ping.linuxembedded.co.uk>","User-Agent":"alot/0.10","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":29448,"web_url":"https://patchwork.libcamera.org/comment/29448/","msgid":"<20240508133309.GK2012@pendragon.ideasonboard.com>","date":"2024-05-08T13:33:09","subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Dan,\n\nThank you for the patch.\n\nOn Thu, Apr 18, 2024 at 01:46:30PM +0100, Daniel Scally wrote:\n> Within the IPU3 IPA module there are multiple references to min and\n> max shutter speeds. In calculation and usage however those variables\n> reflect integration time rather than shutter speed - this difference\n> in terminology is particularly problematic because the minimum\n> shutter speed is equivalent to the maximum integration time.\n> \n> Replace references to shutter speed with integration time.\n\nI like this (I may be tempted to reply with U+2661), and I'd like the\nchange to be applied globally through libcamera. \"Integration time\" even\ndeserves a place in a glossary in my opinion.\n\n> Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com>\n\nReviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n\n> ---\n>  src/ipa/ipu3/algorithms/agc.cpp | 12 ++++++------\n>  src/ipa/ipu3/algorithms/agc.h   |  4 ++--\n>  src/ipa/ipu3/ipa_context.cpp    |  8 ++++----\n>  src/ipa/ipu3/ipa_context.h      |  4 ++--\n>  src/ipa/ipu3/ipu3.cpp           |  8 ++++----\n>  5 files changed, 18 insertions(+), 18 deletions(-)\n> \n> diff --git a/src/ipa/ipu3/algorithms/agc.cpp b/src/ipa/ipu3/algorithms/agc.cpp\n> index 46fc3b33..a59b73fb 100644\n> --- a/src/ipa/ipu3/algorithms/agc.cpp\n> +++ b/src/ipa/ipu3/algorithms/agc.cpp\n> @@ -51,7 +51,7 @@ LOG_DEFINE_CATEGORY(IPU3Agc)\n>  static constexpr double kMinAnalogueGain = 1.0;\n>  \n>  /* \\todo Honour the FrameDurationLimits control instead of hardcoding a limit */\n> -static constexpr utils::Duration kMaxShutterSpeed = 60ms;\n> +static constexpr utils::Duration kMaxIntegrationTime = 60ms;\n>  \n>  /* Histogram constants */\n>  static constexpr uint32_t knumHistogramBins = 256;\n> @@ -71,7 +71,7 @@ static constexpr uint32_t kNumStartupFrames = 10;\n>  static constexpr double kRelativeLuminanceTarget = 0.16;\n>  \n>  Agc::Agc()\n> -\t: minShutterSpeed_(0s), maxShutterSpeed_(0s)\n> +\t: minIntegrationTime_(0s), maxIntegrationTime_(0s)\n>  {\n>  }\n>  \n> @@ -114,9 +114,9 @@ int Agc::configure(IPAContext &context,\n>  \tstride_ = configuration.grid.stride;\n>  \tbdsGrid_ = configuration.grid.bdsGrid;\n>  \n> -\tminShutterSpeed_ = configuration.agc.minShutterSpeed;\n> -\tmaxShutterSpeed_ = std::min(configuration.agc.maxShutterSpeed,\n> -\t\t\t\t    kMaxShutterSpeed);\n> +\tminIntegrationTime_ = configuration.agc.minIntegrationTime;\n> +\tmaxIntegrationTime_ = std::min(configuration.agc.maxIntegrationTime,\n> +\t\t\t\t       kMaxIntegrationTime);\n>  \n>  \tminAnalogueGain_ = std::max(configuration.agc.minAnalogueGain, kMinAnalogueGain);\n>  \tmaxAnalogueGain_ = configuration.agc.maxAnalogueGain;\n> @@ -129,7 +129,7 @@ int Agc::configure(IPAContext &context,\n>  \tcontext.activeState.agc.exposureMode = exposureModeHelpers().begin()->first;\n>  \n>  \t/* \\todo Run this again when FrameDurationLimits is passed in */\n> -\tconfigureExposureModeHelpers(minShutterSpeed_, maxShutterSpeed_,\n> +\tconfigureExposureModeHelpers(minIntegrationTime_, maxIntegrationTime_,\n>  \t\t\t\t     minAnalogueGain_, maxAnalogueGain_);\n>  \n>  \tresetFrameCount();\n> diff --git a/src/ipa/ipu3/algorithms/agc.h b/src/ipa/ipu3/algorithms/agc.h\n> index 945d1846..631dea52 100644\n> --- a/src/ipa/ipu3/algorithms/agc.h\n> +++ b/src/ipa/ipu3/algorithms/agc.h\n> @@ -42,8 +42,8 @@ private:\n>  \tHistogram parseStatistics(const ipu3_uapi_stats_3a *stats,\n>  \t\t\t\t  const ipu3_uapi_grid_config &grid);\n>  \n> -\tutils::Duration minShutterSpeed_;\n> -\tutils::Duration maxShutterSpeed_;\n> +\tutils::Duration minIntegrationTime_;\n> +\tutils::Duration maxIntegrationTime_;\n>  \n>  \tdouble minAnalogueGain_;\n>  \tdouble maxAnalogueGain_;\n> diff --git a/src/ipa/ipu3/ipa_context.cpp b/src/ipa/ipu3/ipa_context.cpp\n> index c4fb5642..72f7cec9 100644\n> --- a/src/ipa/ipu3/ipa_context.cpp\n> +++ b/src/ipa/ipu3/ipa_context.cpp\n> @@ -92,11 +92,11 @@ namespace libcamera::ipa::ipu3 {\n>   * \\var IPASessionConfiguration::agc\n>   * \\brief AGC parameters configuration of the IPA\n>   *\n> - * \\var IPASessionConfiguration::agc.minShutterSpeed\n> - * \\brief Minimum shutter speed supported with the configured sensor\n> + * \\var IPASessionConfiguration::agc.minIntegrationTime\n> + * \\brief Minimum integration time supported with the configured sensor\n>   *\n> - * \\var IPASessionConfiguration::agc.maxShutterSpeed\n> - * \\brief Maximum shutter speed supported with the configured sensor\n> + * \\var IPASessionConfiguration::agc.maxIntegrationTime\n> + * \\brief Maximum integration time supported with the configured sensor\n>   *\n>   * \\var IPASessionConfiguration::agc.minAnalogueGain\n>   * \\brief Minimum analogue gain supported with the configured sensor\n> diff --git a/src/ipa/ipu3/ipa_context.h b/src/ipa/ipu3/ipa_context.h\n> index a92cb6ce..6b1ffdd1 100644\n> --- a/src/ipa/ipu3/ipa_context.h\n> +++ b/src/ipa/ipu3/ipa_context.h\n> @@ -33,8 +33,8 @@ struct IPASessionConfiguration {\n>  \t} af;\n>  \n>  \tstruct {\n> -\t\tutils::Duration minShutterSpeed;\n> -\t\tutils::Duration maxShutterSpeed;\n> +\t\tutils::Duration minIntegrationTime;\n> +\t\tutils::Duration maxIntegrationTime;\n>  \t\tdouble minAnalogueGain;\n>  \t\tdouble maxAnalogueGain;\n>  \t} agc;\n> diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp\n> index 4809eb60..f13cc394 100644\n> --- a/src/ipa/ipu3/ipu3.cpp\n> +++ b/src/ipa/ipu3/ipu3.cpp\n> @@ -217,13 +217,13 @@ void IPAIPU3::updateSessionConfiguration(const ControlInfoMap &sensorControls)\n>  \n>  \t/*\n>  \t * When the AGC computes the new exposure values for a frame, it needs\n> -\t * to know the limits for shutter speed and analogue gain.\n> +\t * to know the limits for integration time and analogue gain.\n>  \t * As it depends on the sensor, update it with the controls.\n>  \t *\n> -\t * \\todo take VBLANK into account for maximum shutter speed\n> +\t * \\todo take VBLANK into account for maximum integration time\n>  \t */\n> -\tcontext_.configuration.agc.minShutterSpeed = minExposure * context_.configuration.sensor.lineDuration;\n> -\tcontext_.configuration.agc.maxShutterSpeed = maxExposure * context_.configuration.sensor.lineDuration;\n> +\tcontext_.configuration.agc.minIntegrationTime = minExposure * context_.configuration.sensor.lineDuration;\n> +\tcontext_.configuration.agc.maxIntegrationTime = maxExposure * context_.configuration.sensor.lineDuration;\n>  \tcontext_.configuration.agc.minAnalogueGain = camHelper_->gain(minGain);\n>  \tcontext_.configuration.agc.maxAnalogueGain = camHelper_->gain(maxGain);\n>  }","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 4EC9FC3226\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed,  8 May 2024 13:33:21 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 261E763437;\n\tWed,  8 May 2024 15:33:20 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4EDD961A73\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  8 May 2024 15:33:18 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 212E23D5;\n\tWed,  8 May 2024 15:33:15 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"mrSVWKyb\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1715175195;\n\tbh=J8M955zGZGmHJCmlqG7idGfowXH5AuBmZXQkUqXUKM4=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=mrSVWKyb4fEX50ba3UtUxX+QEjgEY8riznrOiy7pX5oH3F5eALV/fHIzkiTyK9RJ7\n\tRdl5JmHU/JlFfKiqrzEGdzgaZQ/zVngRIuVUOfeKpxIrIE1HITzPDIPIGBv0hh3rAy\n\tozHE6Ez5QaDzFg2jud3Rsv5FZ85oR46L1Jv26d4Q=","Date":"Wed, 8 May 2024 16:33:09 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Daniel Scally <dan.scally@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","Message-ID":"<20240508133309.GK2012@pendragon.ideasonboard.com>","References":"<20240418124632.652163-1-dan.scally@ideasonboard.com>\n\t<20240418124632.652163-2-dan.scally@ideasonboard.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20240418124632.652163-2-dan.scally@ideasonboard.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":29450,"web_url":"https://patchwork.libcamera.org/comment/29450/","msgid":"<CAEmqJPqZMk0afLHVepy_SfZ-yMGebVensXitHb=ZaWaWf7BckQ@mail.gmail.com>","date":"2024-05-08T14:02:34","subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/people/34/","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"content":"On Wed, 8 May 2024 at 14:33, Laurent Pinchart <\nlaurent.pinchart@ideasonboard.com> wrote:\n\n> Hi Dan,\n>\n> Thank you for the patch.\n>\n> On Thu, Apr 18, 2024 at 01:46:30PM +0100, Daniel Scally wrote:\n> > Within the IPU3 IPA module there are multiple references to min and\n> > max shutter speeds. In calculation and usage however those variables\n> > reflect integration time rather than shutter speed - this difference\n> > in terminology is particularly problematic because the minimum\n> > shutter speed is equivalent to the maximum integration time.\n> >\n> > Replace references to shutter speed with integration time.\n>\n> I like this (I may be tempted to reply with U+2661), and I'd like the\n> change to be applied globally through libcamera. \"Integration time\" even\n> deserves a place in a glossary in my opinion.\n>\n\nI might regret asking this... :)\n\nWhat's the difference between the two?  I always treat them as equivalent\nin value.\n\n\n>\n> > Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com>\n>\n> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n>\n> > ---\n> >  src/ipa/ipu3/algorithms/agc.cpp | 12 ++++++------\n> >  src/ipa/ipu3/algorithms/agc.h   |  4 ++--\n> >  src/ipa/ipu3/ipa_context.cpp    |  8 ++++----\n> >  src/ipa/ipu3/ipa_context.h      |  4 ++--\n> >  src/ipa/ipu3/ipu3.cpp           |  8 ++++----\n> >  5 files changed, 18 insertions(+), 18 deletions(-)\n> >\n> > diff --git a/src/ipa/ipu3/algorithms/agc.cpp\n> b/src/ipa/ipu3/algorithms/agc.cpp\n> > index 46fc3b33..a59b73fb 100644\n> > --- a/src/ipa/ipu3/algorithms/agc.cpp\n> > +++ b/src/ipa/ipu3/algorithms/agc.cpp\n> > @@ -51,7 +51,7 @@ LOG_DEFINE_CATEGORY(IPU3Agc)\n> >  static constexpr double kMinAnalogueGain = 1.0;\n> >\n> >  /* \\todo Honour the FrameDurationLimits control instead of hardcoding a\n> limit */\n> > -static constexpr utils::Duration kMaxShutterSpeed = 60ms;\n> > +static constexpr utils::Duration kMaxIntegrationTime = 60ms;\n> >\n> >  /* Histogram constants */\n> >  static constexpr uint32_t knumHistogramBins = 256;\n> > @@ -71,7 +71,7 @@ static constexpr uint32_t kNumStartupFrames = 10;\n> >  static constexpr double kRelativeLuminanceTarget = 0.16;\n> >\n> >  Agc::Agc()\n> > -     : minShutterSpeed_(0s), maxShutterSpeed_(0s)\n> > +     : minIntegrationTime_(0s), maxIntegrationTime_(0s)\n> >  {\n> >  }\n> >\n> > @@ -114,9 +114,9 @@ int Agc::configure(IPAContext &context,\n> >       stride_ = configuration.grid.stride;\n> >       bdsGrid_ = configuration.grid.bdsGrid;\n> >\n> > -     minShutterSpeed_ = configuration.agc.minShutterSpeed;\n> > -     maxShutterSpeed_ = std::min(configuration.agc.maxShutterSpeed,\n> > -                                 kMaxShutterSpeed);\n> > +     minIntegrationTime_ = configuration.agc.minIntegrationTime;\n> > +     maxIntegrationTime_ =\n> std::min(configuration.agc.maxIntegrationTime,\n> > +                                    kMaxIntegrationTime);\n> >\n> >       minAnalogueGain_ = std::max(configuration.agc.minAnalogueGain,\n> kMinAnalogueGain);\n> >       maxAnalogueGain_ = configuration.agc.maxAnalogueGain;\n> > @@ -129,7 +129,7 @@ int Agc::configure(IPAContext &context,\n> >       context.activeState.agc.exposureMode =\n> exposureModeHelpers().begin()->first;\n> >\n> >       /* \\todo Run this again when FrameDurationLimits is passed in */\n> > -     configureExposureModeHelpers(minShutterSpeed_, maxShutterSpeed_,\n> > +     configureExposureModeHelpers(minIntegrationTime_,\n> maxIntegrationTime_,\n> >                                    minAnalogueGain_, maxAnalogueGain_);\n> >\n> >       resetFrameCount();\n> > diff --git a/src/ipa/ipu3/algorithms/agc.h\n> b/src/ipa/ipu3/algorithms/agc.h\n> > index 945d1846..631dea52 100644\n> > --- a/src/ipa/ipu3/algorithms/agc.h\n> > +++ b/src/ipa/ipu3/algorithms/agc.h\n> > @@ -42,8 +42,8 @@ private:\n> >       Histogram parseStatistics(const ipu3_uapi_stats_3a *stats,\n> >                                 const ipu3_uapi_grid_config &grid);\n> >\n> > -     utils::Duration minShutterSpeed_;\n> > -     utils::Duration maxShutterSpeed_;\n> > +     utils::Duration minIntegrationTime_;\n> > +     utils::Duration maxIntegrationTime_;\n> >\n> >       double minAnalogueGain_;\n> >       double maxAnalogueGain_;\n> > diff --git a/src/ipa/ipu3/ipa_context.cpp b/src/ipa/ipu3/ipa_context.cpp\n> > index c4fb5642..72f7cec9 100644\n> > --- a/src/ipa/ipu3/ipa_context.cpp\n> > +++ b/src/ipa/ipu3/ipa_context.cpp\n> > @@ -92,11 +92,11 @@ namespace libcamera::ipa::ipu3 {\n> >   * \\var IPASessionConfiguration::agc\n> >   * \\brief AGC parameters configuration of the IPA\n> >   *\n> > - * \\var IPASessionConfiguration::agc.minShutterSpeed\n> > - * \\brief Minimum shutter speed supported with the configured sensor\n> > + * \\var IPASessionConfiguration::agc.minIntegrationTime\n> > + * \\brief Minimum integration time supported with the configured sensor\n> >   *\n> > - * \\var IPASessionConfiguration::agc.maxShutterSpeed\n> > - * \\brief Maximum shutter speed supported with the configured sensor\n> > + * \\var IPASessionConfiguration::agc.maxIntegrationTime\n> > + * \\brief Maximum integration time supported with the configured sensor\n> >   *\n> >   * \\var IPASessionConfiguration::agc.minAnalogueGain\n> >   * \\brief Minimum analogue gain supported with the configured sensor\n> > diff --git a/src/ipa/ipu3/ipa_context.h b/src/ipa/ipu3/ipa_context.h\n> > index a92cb6ce..6b1ffdd1 100644\n> > --- a/src/ipa/ipu3/ipa_context.h\n> > +++ b/src/ipa/ipu3/ipa_context.h\n> > @@ -33,8 +33,8 @@ struct IPASessionConfiguration {\n> >       } af;\n> >\n> >       struct {\n> > -             utils::Duration minShutterSpeed;\n> > -             utils::Duration maxShutterSpeed;\n> > +             utils::Duration minIntegrationTime;\n> > +             utils::Duration maxIntegrationTime;\n> >               double minAnalogueGain;\n> >               double maxAnalogueGain;\n> >       } agc;\n> > diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp\n> > index 4809eb60..f13cc394 100644\n> > --- a/src/ipa/ipu3/ipu3.cpp\n> > +++ b/src/ipa/ipu3/ipu3.cpp\n> > @@ -217,13 +217,13 @@ void IPAIPU3::updateSessionConfiguration(const\n> ControlInfoMap &sensorControls)\n> >\n> >       /*\n> >        * When the AGC computes the new exposure values for a frame, it\n> needs\n> > -      * to know the limits for shutter speed and analogue gain.\n> > +      * to know the limits for integration time and analogue gain.\n> >        * As it depends on the sensor, update it with the controls.\n> >        *\n> > -      * \\todo take VBLANK into account for maximum shutter speed\n> > +      * \\todo take VBLANK into account for maximum integration time\n> >        */\n> > -     context_.configuration.agc.minShutterSpeed = minExposure *\n> context_.configuration.sensor.lineDuration;\n> > -     context_.configuration.agc.maxShutterSpeed = maxExposure *\n> context_.configuration.sensor.lineDuration;\n> > +     context_.configuration.agc.minIntegrationTime = minExposure *\n> context_.configuration.sensor.lineDuration;\n> > +     context_.configuration.agc.maxIntegrationTime = maxExposure *\n> context_.configuration.sensor.lineDuration;\n> >       context_.configuration.agc.minAnalogueGain =\n> camHelper_->gain(minGain);\n> >       context_.configuration.agc.maxAnalogueGain =\n> camHelper_->gain(maxGain);\n> >  }\n>\n> --\n> Regards,\n>\n> Laurent Pinchart\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 4AABEC3226\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed,  8 May 2024 14:03:16 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 17A1662C9F;\n\tWed,  8 May 2024 16:03:15 +0200 (CEST)","from mail-yw1-x112b.google.com (mail-yw1-x112b.google.com\n\t[IPv6:2607:f8b0:4864:20::112b])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id E18EE61A73\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  8 May 2024 16:03:12 +0200 (CEST)","by mail-yw1-x112b.google.com with SMTP id\n\t00721157ae682-620390308e5so40153867b3.3\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 08 May 2024 07:03:12 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"aMNBwUys\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google; t=1715176991; x=1715781791;\n\tdarn=lists.libcamera.org; \n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:from:to:cc:subject:date:message-id:reply-to;\n\tbh=oh80COVx6LG6aPjhG+zWPrWNzVzlvHBK8UWDTIWH6c4=;\n\tb=aMNBwUysgj76O1PViFuz+Bj4rK1ah8SOa6G0J1vS9+qzhsPya2kEmMY0CQc5HUjYCc\n\trLqQPiAaCPyB/YJ//PFf20d6P1tpb8Dl8iWn4HtdYKxWaEgKohz7jTVK+Lk1RGIpBRs+\n\tpAWitA4qeyhmJgxiMknv7CGEnpbdaDQPIRcaYQCVBs5/nLf9rRzBeQdWbLcDLuMseOaW\n\t5XHDAYXDqQZJydl/sz6OyIgWJuS4SCLCyBLizOC+VFYn6STHGtxBTr9Y5Poe/tClyl0Y\n\tFeIzTKQBD0OkGMQE5u3KG2hzBsAjJ7xxFQQ6G9VBpWzY+O+N+SVYWDaBpgpbWqULS/lt\n\tsP7Q==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1715176991; x=1715781791;\n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=oh80COVx6LG6aPjhG+zWPrWNzVzlvHBK8UWDTIWH6c4=;\n\tb=P4Wj0agHI0ceKdqZdInpYbSvzVuPqNOQF5Q6C8m8jzdr66Wq2bI2VpYJ6LsB23t370\n\to1WvkcDsdzUT4HemVQ0D8AcLS+4ajGf3FwkCSMzY9Vao+avicC7N6i5UDC5U4P6cYvam\n\tSdqdW6G6efpF3iWYRbKRO0wLJmajfnmdZQFt7AWLty7KBhNz/Ly6Jy+PehDZW34V2T1K\n\tf9/3kvWJ2PN52H+1UT+LLF30OE0Aez1vwC6ywjFfaZ5rSx6R/xdDhKnkPkzVz1OkTdGU\n\t1Q9t12tKTXdCNQm0yUy6ZKZdl8s4r9sHuEDUWLjR3JDmeO7jdbx1Brq9AlHLpMvCwjKx\n\tU4Og==","X-Forwarded-Encrypted":"i=1;\n\tAJvYcCXM7Wa9cpzGjpnR9uTjLGT2YYln8Z+9mM1Q+N8s7RIjCpxb1V8rskSNnE1w3l/X0WHs8gaLF2DOoSR+L3fWfeuFtYILCE8t9zkHcDglVEp8rj0c+A==","X-Gm-Message-State":"AOJu0YxoCMhkkUyM0bnsRdIAawBxAZmgXFkRPd3ca1FH6mZyg9QnTgpq\n\tw2ZaSpBoFQNV1FCJyzohmb8i02kOaUDo8DCC3mlHKGzqDHFFaa8HzxWRPh4h3a93EynmSlHYcC/\n\tkAWB2l2MdfAUVhzWLSaPZGwSV5U8Dnf8Uv4Ishw==","X-Google-Smtp-Source":"AGHT+IFCKj7Yz475jAg7P1/3II8mXHv69SzB0YC71jaWvgvri0XFj6nmtENCwIS1jwq52lbo2R/hJFWK1hXBKhfTUIk=","X-Received":"by 2002:a0d:dd88:0:b0:615:1a0:78ea with SMTP id\n\t00721157ae682-62085af24aamr27321177b3.34.1715176990011;\n\tWed, 08 May 2024 07:03:10 -0700 (PDT)","MIME-Version":"1.0","References":"<20240418124632.652163-1-dan.scally@ideasonboard.com>\n\t<20240418124632.652163-2-dan.scally@ideasonboard.com>\n\t<20240508133309.GK2012@pendragon.ideasonboard.com>","In-Reply-To":"<20240508133309.GK2012@pendragon.ideasonboard.com>","From":"Naushir Patuck <naush@raspberrypi.com>","Date":"Wed, 8 May 2024 15:02:34 +0100","Message-ID":"<CAEmqJPqZMk0afLHVepy_SfZ-yMGebVensXitHb=ZaWaWf7BckQ@mail.gmail.com>","Subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"Daniel Scally <dan.scally@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Content-Type":"multipart/alternative; boundary=\"0000000000003794970617f1c361\"","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":29452,"web_url":"https://patchwork.libcamera.org/comment/29452/","msgid":"<20240508143200.GO2012@pendragon.ideasonboard.com>","date":"2024-05-08T14:32:00","subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Naush,\n\nOn Wed, May 08, 2024 at 03:02:34PM +0100, Naushir Patuck wrote:\n> On Wed, 8 May 2024 at 14:33, Laurent Pinchart wrote:\n> > On Thu, Apr 18, 2024 at 01:46:30PM +0100, Daniel Scally wrote:\n> > > Within the IPU3 IPA module there are multiple references to min and\n> > > max shutter speeds. In calculation and usage however those variables\n> > > reflect integration time rather than shutter speed - this difference\n> > > in terminology is particularly problematic because the minimum\n> > > shutter speed is equivalent to the maximum integration time.\n> > >\n> > > Replace references to shutter speed with integration time.\n> >\n> > I like this (I may be tempted to reply with U+2661), and I'd like the\n> > change to be applied globally through libcamera. \"Integration time\" even\n> > deserves a place in a glossary in my opinion.\n> \n> I might regret asking this... :)\n> \n> What's the difference between the two?  I always treat them as equivalent\n> in value.\n\nUnless you have a mechanical shutter, in which case the shutter speed\ncould have a different meaning, it's mostly a matter of vocabulary.\nExpressing a shutter \"speed\" in seconds would make most physics teachers\ncry. The current code base uses \"maximum speed\" to indicate the maximum\nintegration time, which should be the minimum speed. Using \"speed\" is\njust confusing.\n\nGoing for time units, we could use \"exposure time\", which is a common\nterm. I dislike it as it's often shortened to \"exposure\", which also has\nother meanings. \"Integration time\" is less subject to confusion.\n\n> > > Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com>\n> >\n> > Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\n> >\n> > > ---\n> > >  src/ipa/ipu3/algorithms/agc.cpp | 12 ++++++------\n> > >  src/ipa/ipu3/algorithms/agc.h   |  4 ++--\n> > >  src/ipa/ipu3/ipa_context.cpp    |  8 ++++----\n> > >  src/ipa/ipu3/ipa_context.h      |  4 ++--\n> > >  src/ipa/ipu3/ipu3.cpp           |  8 ++++----\n> > >  5 files changed, 18 insertions(+), 18 deletions(-)\n> > >\n> > > diff --git a/src/ipa/ipu3/algorithms/agc.cpp b/src/ipa/ipu3/algorithms/agc.cpp\n> > > index 46fc3b33..a59b73fb 100644\n> > > --- a/src/ipa/ipu3/algorithms/agc.cpp\n> > > +++ b/src/ipa/ipu3/algorithms/agc.cpp\n> > > @@ -51,7 +51,7 @@ LOG_DEFINE_CATEGORY(IPU3Agc)\n> > >  static constexpr double kMinAnalogueGain = 1.0;\n> > >\n> > >  /* \\todo Honour the FrameDurationLimits control instead of hardcoding a limit */\n> > > -static constexpr utils::Duration kMaxShutterSpeed = 60ms;\n> > > +static constexpr utils::Duration kMaxIntegrationTime = 60ms;\n> > >\n> > >  /* Histogram constants */\n> > >  static constexpr uint32_t knumHistogramBins = 256;\n> > > @@ -71,7 +71,7 @@ static constexpr uint32_t kNumStartupFrames = 10;\n> > >  static constexpr double kRelativeLuminanceTarget = 0.16;\n> > >\n> > >  Agc::Agc()\n> > > -     : minShutterSpeed_(0s), maxShutterSpeed_(0s)\n> > > +     : minIntegrationTime_(0s), maxIntegrationTime_(0s)\n> > >  {\n> > >  }\n> > >\n> > > @@ -114,9 +114,9 @@ int Agc::configure(IPAContext &context,\n> > >       stride_ = configuration.grid.stride;\n> > >       bdsGrid_ = configuration.grid.bdsGrid;\n> > >\n> > > -     minShutterSpeed_ = configuration.agc.minShutterSpeed;\n> > > -     maxShutterSpeed_ = std::min(configuration.agc.maxShutterSpeed,\n> > > -                                 kMaxShutterSpeed);\n> > > +     minIntegrationTime_ = configuration.agc.minIntegrationTime;\n> > > +     maxIntegrationTime_ = std::min(configuration.agc.maxIntegrationTime,\n> > > +                                    kMaxIntegrationTime);\n> > >\n> > >       minAnalogueGain_ = std::max(configuration.agc.minAnalogueGain, kMinAnalogueGain);\n> > >       maxAnalogueGain_ = configuration.agc.maxAnalogueGain;\n> > > @@ -129,7 +129,7 @@ int Agc::configure(IPAContext &context,\n> > >       context.activeState.agc.exposureMode = exposureModeHelpers().begin()->first;\n> > >\n> > >       /* \\todo Run this again when FrameDurationLimits is passed in */\n> > > -     configureExposureModeHelpers(minShutterSpeed_, maxShutterSpeed_,\n> > > +     configureExposureModeHelpers(minIntegrationTime_, maxIntegrationTime_,\n> > >                                    minAnalogueGain_, maxAnalogueGain_);\n> > >\n> > >       resetFrameCount();\n> > > diff --git a/src/ipa/ipu3/algorithms/agc.h b/src/ipa/ipu3/algorithms/agc.h\n> > > index 945d1846..631dea52 100644\n> > > --- a/src/ipa/ipu3/algorithms/agc.h\n> > > +++ b/src/ipa/ipu3/algorithms/agc.h\n> > > @@ -42,8 +42,8 @@ private:\n> > >       Histogram parseStatistics(const ipu3_uapi_stats_3a *stats,\n> > >                                 const ipu3_uapi_grid_config &grid);\n> > >\n> > > -     utils::Duration minShutterSpeed_;\n> > > -     utils::Duration maxShutterSpeed_;\n> > > +     utils::Duration minIntegrationTime_;\n> > > +     utils::Duration maxIntegrationTime_;\n> > >\n> > >       double minAnalogueGain_;\n> > >       double maxAnalogueGain_;\n> > > diff --git a/src/ipa/ipu3/ipa_context.cpp b/src/ipa/ipu3/ipa_context.cpp\n> > > index c4fb5642..72f7cec9 100644\n> > > --- a/src/ipa/ipu3/ipa_context.cpp\n> > > +++ b/src/ipa/ipu3/ipa_context.cpp\n> > > @@ -92,11 +92,11 @@ namespace libcamera::ipa::ipu3 {\n> > >   * \\var IPASessionConfiguration::agc\n> > >   * \\brief AGC parameters configuration of the IPA\n> > >   *\n> > > - * \\var IPASessionConfiguration::agc.minShutterSpeed\n> > > - * \\brief Minimum shutter speed supported with the configured sensor\n> > > + * \\var IPASessionConfiguration::agc.minIntegrationTime\n> > > + * \\brief Minimum integration time supported with the configured sensor\n> > >   *\n> > > - * \\var IPASessionConfiguration::agc.maxShutterSpeed\n> > > - * \\brief Maximum shutter speed supported with the configured sensor\n> > > + * \\var IPASessionConfiguration::agc.maxIntegrationTime\n> > > + * \\brief Maximum integration time supported with the configured sensor\n> > >   *\n> > >   * \\var IPASessionConfiguration::agc.minAnalogueGain\n> > >   * \\brief Minimum analogue gain supported with the configured sensor\n> > > diff --git a/src/ipa/ipu3/ipa_context.h b/src/ipa/ipu3/ipa_context.h\n> > > index a92cb6ce..6b1ffdd1 100644\n> > > --- a/src/ipa/ipu3/ipa_context.h\n> > > +++ b/src/ipa/ipu3/ipa_context.h\n> > > @@ -33,8 +33,8 @@ struct IPASessionConfiguration {\n> > >       } af;\n> > >\n> > >       struct {\n> > > -             utils::Duration minShutterSpeed;\n> > > -             utils::Duration maxShutterSpeed;\n> > > +             utils::Duration minIntegrationTime;\n> > > +             utils::Duration maxIntegrationTime;\n> > >               double minAnalogueGain;\n> > >               double maxAnalogueGain;\n> > >       } agc;\n> > > diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp\n> > > index 4809eb60..f13cc394 100644\n> > > --- a/src/ipa/ipu3/ipu3.cpp\n> > > +++ b/src/ipa/ipu3/ipu3.cpp\n> > > @@ -217,13 +217,13 @@ void IPAIPU3::updateSessionConfiguration(const ControlInfoMap &sensorControls)\n> > >\n> > >       /*\n> > >        * When the AGC computes the new exposure values for a frame, it needs\n> > > -      * to know the limits for shutter speed and analogue gain.\n> > > +      * to know the limits for integration time and analogue gain.\n> > >        * As it depends on the sensor, update it with the controls.\n> > >        *\n> > > -      * \\todo take VBLANK into account for maximum shutter speed\n> > > +      * \\todo take VBLANK into account for maximum integration time\n> > >        */\n> > > -     context_.configuration.agc.minShutterSpeed = minExposure * context_.configuration.sensor.lineDuration;\n> > > -     context_.configuration.agc.maxShutterSpeed = maxExposure * context_.configuration.sensor.lineDuration;\n> > > +     context_.configuration.agc.minIntegrationTime = minExposure * context_.configuration.sensor.lineDuration;\n> > > +     context_.configuration.agc.maxIntegrationTime = maxExposure * context_.configuration.sensor.lineDuration;\n> > >       context_.configuration.agc.minAnalogueGain = camHelper_->gain(minGain);\n> > >       context_.configuration.agc.maxAnalogueGain = camHelper_->gain(maxGain);\n> > >  }","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id E1ADDC3226\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed,  8 May 2024 14:32:11 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 0C0D562C9F;\n\tWed,  8 May 2024 16:32:11 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id DEFFC61A73\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed,  8 May 2024 16:32:08 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 973F316D4;\n\tWed,  8 May 2024 16:32:05 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"q5T4/dwq\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1715178725;\n\tbh=LHtmgJR5saLaCsSLAgqyP6Nw1QO8P/JxxZW9YnMWOK4=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=q5T4/dwqqF47UaYe/5GUmplyHpeBtIyjBQiFQq51RY5KQcJmmgOttU+7zjkhuiK7g\n\t+SddDM5weP0+Zv94vhuFZUxnn6WklUrt25vQCqOpxJyy/df8IyMM1ForGuL8hd9zLS\n\tOS+/gfQqlHwZQK2XSuR0pf8OadmwfhXBUGzdBjGI=","Date":"Wed, 8 May 2024 17:32:00 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Naushir Patuck <naush@raspberrypi.com>","Cc":"Daniel Scally <dan.scally@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH 1/3] ipa: ipu3: Refer to integration time instead of\n\tshutter speed","Message-ID":"<20240508143200.GO2012@pendragon.ideasonboard.com>","References":"<20240418124632.652163-1-dan.scally@ideasonboard.com>\n\t<20240418124632.652163-2-dan.scally@ideasonboard.com>\n\t<20240508133309.GK2012@pendragon.ideasonboard.com>\n\t<CAEmqJPqZMk0afLHVepy_SfZ-yMGebVensXitHb=ZaWaWf7BckQ@mail.gmail.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<CAEmqJPqZMk0afLHVepy_SfZ-yMGebVensXitHb=ZaWaWf7BckQ@mail.gmail.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]