ipa: ipu3: Extend ipu3 ipa interface for sensor controls
IPU3Event and IPU3Action use single ControlList for both libcamera and V4L2 controls, and it's content could be either one based on the context. Extend IPU3Event and IPU3Action for sensor V4L2 controls, and preserve the original one for only libcamera Controls to make the content of an event more specific. Signed-off-by: Han-Lin Chen <hanlinchen@chromium.org> [Jean-Michel: remove lensControls from the original patch] Signed-off-by: Jean-Michel Hautbois <jeanmichel.hautbois@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
This commit is contained in:
parent
6b288f8f4f
commit
f12efa6730
3 changed files with 4 additions and 2 deletions
|
@ -23,11 +23,13 @@ struct IPU3Event {
|
||||||
int64 frameTimestamp;
|
int64 frameTimestamp;
|
||||||
uint32 bufferId;
|
uint32 bufferId;
|
||||||
libcamera.ControlList controls;
|
libcamera.ControlList controls;
|
||||||
|
libcamera.ControlList sensorControls;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct IPU3Action {
|
struct IPU3Action {
|
||||||
IPU3Operations op;
|
IPU3Operations op;
|
||||||
libcamera.ControlList controls;
|
libcamera.ControlList controls;
|
||||||
|
libcamera.ControlList sensorControls;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct IPAConfigInfo {
|
struct IPAConfigInfo {
|
||||||
|
|
|
@ -653,7 +653,7 @@ void IPAIPU3::setControls(unsigned int frame)
|
||||||
ControlList ctrls(ctrls_);
|
ControlList ctrls(ctrls_);
|
||||||
ctrls.set(V4L2_CID_EXPOSURE, static_cast<int32_t>(exposure_));
|
ctrls.set(V4L2_CID_EXPOSURE, static_cast<int32_t>(exposure_));
|
||||||
ctrls.set(V4L2_CID_ANALOGUE_GAIN, static_cast<int32_t>(gain_));
|
ctrls.set(V4L2_CID_ANALOGUE_GAIN, static_cast<int32_t>(gain_));
|
||||||
op.controls = ctrls;
|
op.sensorControls = ctrls;
|
||||||
|
|
||||||
queueFrameAction.emit(frame, op);
|
queueFrameAction.emit(frame, op);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1248,7 +1248,7 @@ void IPU3CameraData::queueFrameAction(unsigned int id,
|
||||||
{
|
{
|
||||||
switch (action.op) {
|
switch (action.op) {
|
||||||
case ipa::ipu3::ActionSetSensorControls: {
|
case ipa::ipu3::ActionSetSensorControls: {
|
||||||
const ControlList &controls = action.controls;
|
const ControlList &controls = action.sensorControls;
|
||||||
delayedCtrls_->push(controls);
|
delayedCtrls_->push(controls);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue