From 364ae3b78d3f0fc18c9bf1c2c3ee9fee1d80e68a Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Mon, 1 Nov 2021 09:15:03 +0000 Subject: libcamera: bayer_format: Turn BayerFormat::Packing into scoped enum The unscoped enum BayerFormat::Packing leads to usage of the ambiguous BayerFormat::None enumerator. Turn the enumeration into a scoped enum to force usage of BayerFormat::Packing::None, and drop the now redundant "Packed" suffix for the CSI2 and IPU3 packing. Signed-off-by: Laurent Pinchart Signed-off-by: Naushir Patuck Reviewed-by: Naushir Patuck Reviewed-by: Kieran Bingham Signed-off-by: Kieran Bingham --- include/libcamera/internal/bayer_format.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/libcamera/internal/bayer_format.h b/include/libcamera/internal/bayer_format.h index 723382d4..d9a56d74 100644 --- a/include/libcamera/internal/bayer_format.h +++ b/include/libcamera/internal/bayer_format.h @@ -27,10 +27,10 @@ public: MONO = 4 }; - enum Packing : uint16_t { + enum class Packing : uint16_t { None = 0, - CSI2Packed = 1, - IPU3Packed = 2, + CSI2 = 1, + IPU3 = 2, }; constexpr BayerFormat() -- cgit v1.2.1