diff options
author | Naushir Patuck <naush@raspberrypi.com> | 2021-07-12 11:02:03 +0100 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2021-07-12 15:57:02 +0300 |
commit | df8cafaf8788eb27c25576ce94ca605f8a50527d (patch) | |
tree | bec65455099fd9e6d4bd899f040ebae43764c817 /src/ipa/raspberrypi/controller/device_status.h | |
parent | ace5e21feba28cf43461375312f09c29230df370 (diff) |
ipa: raspberrypi: Add a constructor struct DeviceStatus
The constructor sets all fields to 0. This replaces the memset(0) and default
value initialisation usage in the agc and lux controllers respectively.
Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
Reviewed-by: David Plowman <david.plowman@raspberrypi.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.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/controller/device_status.h')
-rw-r--r-- | src/ipa/raspberrypi/controller/device_status.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/ipa/raspberrypi/controller/device_status.h b/src/ipa/raspberrypi/controller/device_status.h index 733378db..73df7ce2 100644 --- a/src/ipa/raspberrypi/controller/device_status.h +++ b/src/ipa/raspberrypi/controller/device_status.h @@ -14,6 +14,12 @@ */ struct DeviceStatus { + DeviceStatus() + : shutter_speed(std::chrono::seconds(0)), analogue_gain(0.0), + lens_position(0.0), aperture(0.0), flash_intensity(0.0) + { + } + /* time shutter is open */ libcamera::utils::Duration shutter_speed; double analogue_gain; |