diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2019-10-06 09:54:16 +0300 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2019-10-13 20:37:34 +0300 |
commit | a1c6b2b6419cdf82c623355725efd48ff169a675 (patch) | |
tree | 790fba07e2a66c2a0f9cc47e51c46f746c16f67e /src/ipa/rkisp1/rkisp1.cpp | |
parent | 576b8aa079388d2151f396bb947cf0a8e5ba255e (diff) |
libcamera: controls: Support accessing controls by numerical ID
The ControlList class has template get() and set() methods to get and
set control values. The methods require a reference to a Control
instance, which is only available when calling them with a hardcoded
control. In order to support usage of ControlList for V4L2 controls, as
well as serialisation and deserialisation of ControlList, we need a way
to get and set control values based on a control numerical ID. Add new
contains(), get() and set() overload methods to do so.
As this change prepares the ControlList to be used for other objects
than camera, update its documentation accordingly.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Tested-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
Diffstat (limited to 'src/ipa/rkisp1/rkisp1.cpp')
-rw-r--r-- | src/ipa/rkisp1/rkisp1.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ipa/rkisp1/rkisp1.cpp b/src/ipa/rkisp1/rkisp1.cpp index 80138f19..b0d23dd1 100644 --- a/src/ipa/rkisp1/rkisp1.cpp +++ b/src/ipa/rkisp1/rkisp1.cpp @@ -220,7 +220,7 @@ void IPARkISP1::setControls(unsigned int frame) void IPARkISP1::metadataReady(unsigned int frame, unsigned int aeState) { - ControlList ctrls; + ControlList ctrls(controls::controls); if (aeState) ctrls.set(controls::AeLocked, aeState == 2); |