diff options
Diffstat (limited to 'src/libcamera/include')
-rw-r--r-- | src/libcamera/include/v4l2_controls.h | 42 | ||||
-rw-r--r-- | src/libcamera/include/v4l2_device.h | 1 |
2 files changed, 26 insertions, 17 deletions
diff --git a/src/libcamera/include/v4l2_controls.h b/src/libcamera/include/v4l2_controls.h index 4d7ac1a1..ca721750 100644 --- a/src/libcamera/include/v4l2_controls.h +++ b/src/libcamera/include/v4l2_controls.h @@ -28,31 +28,41 @@ public: class V4L2ControlInfo { public: - V4L2ControlInfo(const V4L2ControlId &id, - const struct v4l2_query_ext_ctrl &ctrl); + V4L2ControlInfo(const struct v4l2_query_ext_ctrl &ctrl); - const ControlId &id() const { return *id_; } const ControlRange &range() const { return range_; } private: - const V4L2ControlId *id_; ControlRange range_; }; -class V4L2ControlInfoMap : private std::map<unsigned int, V4L2ControlInfo> +class V4L2ControlInfoMap : private std::map<const ControlId *, V4L2ControlInfo> { public: - V4L2ControlInfoMap &operator=(std::map<unsigned int, V4L2ControlInfo> &&info); - - using std::map<unsigned int, V4L2ControlInfo>::begin; - using std::map<unsigned int, V4L2ControlInfo>::cbegin; - using std::map<unsigned int, V4L2ControlInfo>::end; - using std::map<unsigned int, V4L2ControlInfo>::cend; - using std::map<unsigned int, V4L2ControlInfo>::at; - using std::map<unsigned int, V4L2ControlInfo>::empty; - using std::map<unsigned int, V4L2ControlInfo>::size; - using std::map<unsigned int, V4L2ControlInfo>::count; - using std::map<unsigned int, V4L2ControlInfo>::find; + V4L2ControlInfoMap &operator=(std::map<const ControlId *, V4L2ControlInfo> &&info); + + using std::map<const ControlId *, V4L2ControlInfo>::key_type; + using std::map<const ControlId *, V4L2ControlInfo>::mapped_type; + using std::map<const ControlId *, V4L2ControlInfo>::value_type; + using std::map<const ControlId *, V4L2ControlInfo>::size_type; + using std::map<const ControlId *, V4L2ControlInfo>::iterator; + using std::map<const ControlId *, V4L2ControlInfo>::const_iterator; + + using std::map<const ControlId *, V4L2ControlInfo>::begin; + using std::map<const ControlId *, V4L2ControlInfo>::cbegin; + using std::map<const ControlId *, V4L2ControlInfo>::end; + using std::map<const ControlId *, V4L2ControlInfo>::cend; + using std::map<const ControlId *, V4L2ControlInfo>::at; + using std::map<const ControlId *, V4L2ControlInfo>::empty; + using std::map<const ControlId *, V4L2ControlInfo>::size; + using std::map<const ControlId *, V4L2ControlInfo>::count; + using std::map<const ControlId *, V4L2ControlInfo>::find; + + mapped_type &at(unsigned int key); + const mapped_type &at(unsigned int key) const; + size_type count(unsigned int key) const; + iterator find(unsigned int key); + const_iterator find(unsigned int key) const; const ControlIdMap &idmap() const { return idmap_; } diff --git a/src/libcamera/include/v4l2_device.h b/src/libcamera/include/v4l2_device.h index 5a5b8582..f30b1c2c 100644 --- a/src/libcamera/include/v4l2_device.h +++ b/src/libcamera/include/v4l2_device.h @@ -45,7 +45,6 @@ protected: private: void listControls(); void updateControls(ControlList *ctrls, - const V4L2ControlInfo **controlInfo, const struct v4l2_ext_control *v4l2Ctrls, unsigned int count); |