ipa: rpi: awb: Add an initialValues method
This allows the IPA to get reasonable default colour gains before AWB has run. This is particularly important on the PiSP platform where these numbers are helpful in programming the Front End statistics block in advance. Signed-off-by: David Plowman <david.plowman@raspberrypi.com> Reviewed-by: Naushir Patuck <naush@raspberrypi.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
parent
8892d937c5
commit
cfb4bee74b
3 changed files with 8 additions and 0 deletions
|
@ -16,6 +16,7 @@ public:
|
|||
AwbAlgorithm(Controller *controller) : Algorithm(controller) {}
|
||||
/* An AWB algorithm must provide the following: */
|
||||
virtual unsigned int getConvergenceFrames() const = 0;
|
||||
virtual void initialValues(double &gainR, double &gainB) = 0;
|
||||
virtual void setMode(std::string const &modeName) = 0;
|
||||
virtual void setManualGains(double manualR, double manualB) = 0;
|
||||
virtual void enableAuto() = 0;
|
||||
|
|
|
@ -220,6 +220,12 @@ void Awb::initialise()
|
|||
asyncResults_ = syncResults_;
|
||||
}
|
||||
|
||||
void Awb::initialValues(double &gainR, double &gainB)
|
||||
{
|
||||
gainR = syncResults_.gainR;
|
||||
gainB = syncResults_.gainB;
|
||||
}
|
||||
|
||||
void Awb::disableAuto()
|
||||
{
|
||||
/* Freeze the most recent values, and treat them as manual gains */
|
||||
|
|
|
@ -95,6 +95,7 @@ public:
|
|||
void initialise() override;
|
||||
int read(const libcamera::YamlObject ¶ms) override;
|
||||
unsigned int getConvergenceFrames() const override;
|
||||
void initialValues(double &gainR, double &gainB) override;
|
||||
void setMode(std::string const &name) override;
|
||||
void setManualGains(double manualR, double manualB) override;
|
||||
void enableAuto() override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue