diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2022-04-29 04:31:48 +0300 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2022-05-04 14:11:31 +0300 |
commit | d5d6dbe85cf270aee7c956429a5a692feca3900f (patch) | |
tree | 05a91c081e0c5685f76984ca45f3ff833e64eff9 /include/libcamera/internal/v4l2_subdevice.h | |
parent | 08d613311371ef26da7b6c226d1e35d12be0ca32 (diff) |
libcamera: Add operator<<() for V4L2 format classes
Implement the stream output operator<<() for the V4L2DeviceFormat and
V4L2SubdeviceFormat classes to simplify printing them.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Diffstat (limited to 'include/libcamera/internal/v4l2_subdevice.h')
-rw-r--r-- | include/libcamera/internal/v4l2_subdevice.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/libcamera/internal/v4l2_subdevice.h b/include/libcamera/internal/v4l2_subdevice.h index 58d1e511..6fda52ad 100644 --- a/include/libcamera/internal/v4l2_subdevice.h +++ b/include/libcamera/internal/v4l2_subdevice.h @@ -9,6 +9,7 @@ #include <memory> #include <optional> +#include <ostream> #include <string> #include <vector> @@ -35,6 +36,8 @@ struct V4L2SubdeviceFormat { uint8_t bitsPerPixel() const; }; +std::ostream &operator<<(std::ostream &out, const V4L2SubdeviceFormat &f); + class V4L2Subdevice : public V4L2Device { public: |