ipa: ipu3: agc: Reset frame count when configuring AGC

The frame count is used to skip the gain and exposure filtering when
starting. It thus needs to be reset when configuring the algorithm, to
avoid slower convergence when stopping and restarting.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jean-Michel Hautbois <jeanmichel.hautbois@ideasonboard.com>
Reviewed-by: Umang Jain <umang.jain@ideasonboard.com>
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
Laurent Pinchart 2022-03-15 15:34:06 +02:00 committed by Kieran Bingham
parent f0bfb2f19e
commit 4b2515899c

View file

@ -102,6 +102,7 @@ int Agc::configure(IPAContext &context,
frameContext.agc.gain = std::max(minAnalogueGain_, kMinAnalogueGain);
frameContext.agc.exposure = 10ms / configuration.sensor.lineDuration;
frameCount_ = 0;
return 0;
}