mirror of
https://git.libcamera.org/libcamera/libcamera.git
synced 2025-07-21 23:55:07 +03:00
libcamera: controls: Use ControlValidator to validate ControlList
Replace the manual validation of controls against a Camera with usage of the new ControlValidator interface. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
This commit is contained in:
parent
f671d84ceb
commit
ecf1c2e57b
5 changed files with 43 additions and 26 deletions
|
@ -13,7 +13,7 @@
|
|||
|
||||
namespace libcamera {
|
||||
|
||||
class Camera;
|
||||
class ControlValidator;
|
||||
|
||||
enum ControlType {
|
||||
ControlTypeNone,
|
||||
|
@ -119,7 +119,7 @@ private:
|
|||
using ControlListMap = std::unordered_map<const ControlId *, ControlValue>;
|
||||
|
||||
public:
|
||||
ControlList(Camera *camera);
|
||||
ControlList(ControlValidator *validator);
|
||||
|
||||
using iterator = ControlListMap::iterator;
|
||||
using const_iterator = ControlListMap::const_iterator;
|
||||
|
@ -160,7 +160,7 @@ private:
|
|||
const ControlValue *find(const ControlId &id) const;
|
||||
ControlValue *find(const ControlId &id);
|
||||
|
||||
Camera *camera_;
|
||||
ControlValidator *validator_;
|
||||
ControlListMap controls_;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue