diff options
Diffstat (limited to 'include/libcamera/control_ids.h')
-rw-r--r-- | include/libcamera/control_ids.h | 42 |
1 files changed, 20 insertions, 22 deletions
diff --git a/include/libcamera/control_ids.h b/include/libcamera/control_ids.h index 75b6a2d5..54235f1a 100644 --- a/include/libcamera/control_ids.h +++ b/include/libcamera/control_ids.h @@ -8,34 +8,32 @@ #ifndef __LIBCAMERA_CONTROL_IDS_H__ #define __LIBCAMERA_CONTROL_IDS_H__ -#include <functional> +#include <stdint.h> -namespace libcamera { +#include <libcamera/controls.h> -enum ControlId { - AwbEnable, - Brightness, - Contrast, - Saturation, - ManualExposure, - ManualGain, -}; +namespace libcamera { -} /* namespace libcamera */ +namespace controls { -namespace std { +enum { + AWB_ENABLE = 1, + BRIGHTNESS = 2, + CONTRAST = 3, + SATURATION = 4, + MANUAL_EXPOSURE = 5, + MANUAL_GAIN = 6, +}; -template<> -struct hash<libcamera::ControlId> { - using argument_type = libcamera::ControlId; - using result_type = std::size_t; +extern const Control<bool> AwbEnable; +extern const Control<int32_t> Brightness; +extern const Control<int32_t> Contrast; +extern const Control<int32_t> Saturation; +extern const Control<int32_t> ManualExposure; +extern const Control<int32_t> ManualGain; - result_type operator()(const argument_type &key) const noexcept - { - return std::hash<std::underlying_type<argument_type>::type>()(key); - } -}; +} /* namespace controls */ -} /* namespace std */ +} /* namespace libcamera */ #endif // __LIBCAMERA_CONTROL_IDS_H__ |