src: ipa: raspberrypi: agc: Make AGC handle Pause/Resume for itself

AGC, when paused, sets the last exposure/gain it wrote to be its
"fixed" values and will therefore continue to return them. When
resumed, we clear them so that both will float again.

This approach is better because AGC can be paused and we can
subsequently change (for example) the exposure and the gain won't
float again.

Signed-off-by: David Plowman <david.plowman@raspberrypi.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Naushir Patuck <naush@raspberrypi.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
David Plowman 2020-12-01 17:55:33 +00:00 committed by Laurent Pinchart
parent 1b5001e92f
commit 4db11b5725
2 changed files with 28 additions and 0 deletions

View file

@ -70,6 +70,10 @@ public:
Agc(Controller *controller);
char const *Name() const override;
void Read(boost::property_tree::ptree const &params) override;
// AGC handles "pausing" for itself.
bool IsPaused() const override;
void Pause() override;
void Resume() override;
void SetEv(double ev) override;
void SetFlickerPeriod(double flicker_period) override;
void SetFixedShutter(double fixed_shutter) override; // microseconds