libcamera: software_isp: Make stats frame and buffer aware
This patch adds frame and bufferId arguments to stats related calls. Although the parameters are currently unused, because frame ids are not tracked and used and the stats buffer is passed around directly rather than being referred by its id, they bring the internal APIs closer to their counterparts in hardware pipelines. It serves as a preparation for followup patches that will introduce: - Frame number tracking in order to switch to DelayedControls (software ISP TODO #11 + #12). - A ring buffer for stats in order to improve passing the stats (software ISP TODO #2). Frame and buffer ids are unrelated for the given purposes but since they are passed together at the same places, the change is implemented as a single patch rather than two, basically the same, patches. Signed-off-by: Milan Zamazal <mzamazal@redhat.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Daniel Scally <dan.scally@ideasonboard.com> Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
This commit is contained in:
committed by
Kieran Bingham
parent
0cc74c492a
commit
c64f2f197a
@@ -155,15 +155,18 @@ SoftwareIsp::~SoftwareIsp()
|
||||
|
||||
/**
|
||||
* \brief Process the statistics gathered
|
||||
* \param[in] frame The frame number
|
||||
* \param[in] bufferId ID of the statistics buffer
|
||||
* \param[in] sensorControls The sensor controls
|
||||
*
|
||||
* Requests the IPA to calculate new parameters for ISP and new control
|
||||
* values for the sensor.
|
||||
*/
|
||||
void SoftwareIsp::processStats(const ControlList &sensorControls)
|
||||
void SoftwareIsp::processStats(const uint32_t frame, const uint32_t bufferId,
|
||||
const ControlList &sensorControls)
|
||||
{
|
||||
ASSERT(ipa_);
|
||||
ipa_->processStats(sensorControls);
|
||||
ipa_->processStats(frame, bufferId, sensorControls);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -349,9 +352,9 @@ void SoftwareIsp::setSensorCtrls(const ControlList &sensorControls)
|
||||
setSensorControls.emit(sensorControls);
|
||||
}
|
||||
|
||||
void SoftwareIsp::statsReady()
|
||||
void SoftwareIsp::statsReady(uint32_t frame, uint32_t bufferId)
|
||||
{
|
||||
ispStatsReady.emit();
|
||||
ispStatsReady.emit(frame, bufferId);
|
||||
}
|
||||
|
||||
void SoftwareIsp::inputReady(FrameBuffer *input)
|
||||
|
||||
Reference in New Issue
Block a user