summaryrefslogtreecommitdiff
path: root/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
diff options
context:
space:
mode:
authorNaushir Patuck <naush@raspberrypi.com>2022-11-15 09:07:51 +0000
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2022-11-29 17:16:45 +0200
commit33abc2b31e9fa53eb903fe5408c81255dfdd3953 (patch)
tree0aa42e642f6969dc1c592a42e30b6bc9fc3c8420 /src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
parentc7524b10e0a07623b8fbb2c4becfd01ca9cb936a (diff)
pipeline: raspberrypi: delayed_controls: Add user cookie to DelayedControls
Allow the caller to provide a cookie value to DelayedControls::reset and DelayedControls::push. This cookie value is returned from DelayedControls::get for the frame that has the control values applied to it. The cookie value is useful in tracking when a set of controls has been applied to a frame. In a subsequent commit, it will be used by the Raspberry Pi IPA to track the IPA context used when setting the control values. Signed-off-by: Naushir Patuck <naush@raspberrypi.com> Reviewed-by: David Plowman <david.plowman@raspberrypi.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'src/libcamera/pipeline/raspberrypi/raspberrypi.cpp')
-rw-r--r--src/libcamera/pipeline/raspberrypi/raspberrypi.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
index 4c2f4993..164a65b7 100644
--- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
+++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp
@@ -1066,7 +1066,7 @@ int PipelineHandlerRPi::start(Camera *camera, const ControlList *controls)
* Reset the delayed controls with the gain and exposure values set by
* the IPA.
*/
- data->delayedCtrls_->reset();
+ data->delayedCtrls_->reset(0);
data->state_ = RPiCameraData::State::Idle;
@@ -1802,7 +1802,7 @@ void RPiCameraData::setIspControls(const ControlList &controls)
void RPiCameraData::setDelayedControls(const ControlList &controls)
{
- if (!delayedCtrls_->push(controls))
+ if (!delayedCtrls_->push(controls, 0))
LOG(RPI, Error) << "V4L2 DelayedControl set failed";
handleState();
}
@@ -1875,7 +1875,7 @@ void RPiCameraData::unicamBufferDequeue(FrameBuffer *buffer)
* Lookup the sensor controls used for this frame sequence from
* DelayedControl and queue them along with the frame buffer.
*/
- ControlList ctrl = delayedCtrls_->get(buffer->metadata().sequence);
+ auto [ctrl, cookie] = delayedCtrls_->get(buffer->metadata().sequence);
/*
* Add the frame timestamp to the ControlList for the IPA to use
* as it does not receive the FrameBuffer object.