From d4680c8ca2b5cac4f723ec869b297099000b1100 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Sat, 29 Feb 2020 03:39:46 +0200 Subject: libcamera: controls: Add rectangle and size control types MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add two control types to store rectangles and sizes. These will be useful for the properties related to the pixel array. Signed-off-by: Laurent Pinchart Reviewed-by: Niklas Söderlund Reviewed-by: Jacopo Mondi --- include/libcamera/controls.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'include') diff --git a/include/libcamera/controls.h b/include/libcamera/controls.h index 4b2e7e9c..80944efc 100644 --- a/include/libcamera/controls.h +++ b/include/libcamera/controls.h @@ -13,6 +13,7 @@ #include #include +#include #include namespace libcamera { @@ -27,6 +28,8 @@ enum ControlType { ControlTypeInteger64, ControlTypeFloat, ControlTypeString, + ControlTypeRectangle, + ControlTypeSize, }; namespace details { @@ -70,6 +73,16 @@ struct control_type { static constexpr ControlType value = ControlTypeString; }; +template<> +struct control_type { + static constexpr ControlType value = ControlTypeRectangle; +}; + +template<> +struct control_type { + static constexpr ControlType value = ControlTypeSize; +}; + template struct control_type> : public control_type> { }; -- cgit v1.2.1