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:
parent
0cc74c492a
commit
c64f2f197a
8 changed files with 38 additions and 18 deletions
|
@ -11,6 +11,7 @@
|
|||
#include <initializer_list>
|
||||
#include <map>
|
||||
#include <memory>
|
||||
#include <stdint.h>
|
||||
#include <string>
|
||||
#include <tuple>
|
||||
#include <vector>
|
||||
|
@ -66,7 +67,8 @@ public:
|
|||
int exportBuffers(const Stream *stream, unsigned int count,
|
||||
std::vector<std::unique_ptr<FrameBuffer>> *buffers);
|
||||
|
||||
void processStats(const ControlList &sensorControls);
|
||||
void processStats(const uint32_t frame, const uint32_t bufferId,
|
||||
const ControlList &sensorControls);
|
||||
|
||||
int start();
|
||||
void stop();
|
||||
|
@ -78,13 +80,13 @@ public:
|
|||
|
||||
Signal<FrameBuffer *> inputBufferReady;
|
||||
Signal<FrameBuffer *> outputBufferReady;
|
||||
Signal<> ispStatsReady;
|
||||
Signal<uint32_t, uint32_t> ispStatsReady;
|
||||
Signal<const ControlList &> setSensorControls;
|
||||
|
||||
private:
|
||||
void saveIspParams();
|
||||
void setSensorCtrls(const ControlList &sensorControls);
|
||||
void statsReady();
|
||||
void statsReady(uint32_t frame, uint32_t bufferId);
|
||||
void inputReady(FrameBuffer *input);
|
||||
void outputReady(FrameBuffer *output);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue