diff options
author | Naushir Patuck <naush@raspberrypi.com> | 2021-06-08 12:03:34 +0100 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2021-06-08 23:56:18 +0300 |
commit | 2db8a767ca2c1a06658716e762b2fa8b4c005983 (patch) | |
tree | 2cf1c8d4278c2a738ff72747a26e89a43c8e4fcb /src/ipa/raspberrypi/raspberrypi.cpp | |
parent | caa753179c039a0ecbfef595c3179aac4bf044d5 (diff) |
ipa: raspberrypi: Switch AgcAlgorithm API to use utils::Duration
Switch the AgcAlgorithm API functions to use utils::Duration for all
time based variables.
Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
Reviewed-by: David Plowman <david.plowman@raspberrypi.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src/ipa/raspberrypi/raspberrypi.cpp')
-rw-r--r-- | src/ipa/raspberrypi/raspberrypi.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ipa/raspberrypi/raspberrypi.cpp b/src/ipa/raspberrypi/raspberrypi.cpp index 33b316b9..4aa8ccaa 100644 --- a/src/ipa/raspberrypi/raspberrypi.cpp +++ b/src/ipa/raspberrypi/raspberrypi.cpp @@ -638,8 +638,8 @@ void IPARPi::queueRequest(const ControlList &controls) break; } - /* This expects units of micro-seconds. */ - agc->SetFixedShutter(ctrl.second.get<int32_t>()); + /* The control provides units of microseconds. */ + agc->SetFixedShutter(ctrl.second.get<int32_t>() * 1.0us); libcameraMetadata_.set(controls::ExposureTime, ctrl.second.get<int32_t>()); break; @@ -1091,7 +1091,7 @@ void IPARPi::applyFrameDurations(Duration minFrameDuration, Duration maxFrameDur RPiController::AgcAlgorithm *agc = dynamic_cast<RPiController::AgcAlgorithm *>( controller_.GetAlgorithm("agc")); - agc->SetMaxShutter(maxShutter.get<std::micro>()); + agc->SetMaxShutter(maxShutter); } void IPARPi::applyAGC(const struct AgcStatus *agcStatus, ControlList &ctrls) |