ipa: simple: Report exposure in metadata

Report exposure and gain in metadata.

This is more complicated than it could be expected because the exposure
value should be in microseconds but it's handled using V4L2_CID_EXPOSURE
control, which doesn't specify the unit, see
https://www.kernel.org/doc/html/latest/userspace-api/media/v4l/control.html.
So the unit conversion is done in the way rkisp1 IPA uses.

This requires getting and passing IPACameraSensorInfo around.  To avoid
naming confusion and to improve consistency with rkisp1 IPA,
sensorCtrlInfoMap parameter is renamed to sensorControls.

Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Milan Zamazal <mzamazal@redhat.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
Milan Zamazal 2025-03-27 19:59:44 +01:00 committed by Laurent Pinchart
parent 1375b07ede
commit 485a807dcb
5 changed files with 43 additions and 14 deletions

View file

@ -16,7 +16,8 @@ interface IPASoftInterface {
init(libcamera.IPASettings settings,
libcamera.SharedFD fdStats,
libcamera.SharedFD fdParams,
libcamera.ControlInfoMap sensorCtrlInfoMap)
libcamera.IPACameraSensorInfo sensorInfo,
libcamera.ControlInfoMap sensorControls)
=> (int32 ret, libcamera.ControlInfoMap ipaControls, bool ccmEnabled);
start() => (int32 ret);
stop();