mirror of
https://git.libcamera.org/libcamera/libcamera.git
synced 2025-07-21 15:53:54 +03:00
libcamera: v4l2_subdevice: Add colorSpace field to V4L2SubdeviceFormat
This adds a ColorSpace field to the V4L2SubdeviceFormat so that we can set and request particular color spaces from V4L2. This commit simply adds the field and fixes some occurrences of brace initializers that would otherwise be broken. A subsequent commit will pass and retrieve the value correctly to/from V4l2 itself. Signed-off-by: David Plowman <david.plowman@raspberrypi.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
This commit is contained in:
parent
3e520cadf1
commit
c8a4b52e3a
5 changed files with 28 additions and 6 deletions
|
@ -8,12 +8,14 @@
|
|||
#pragma once
|
||||
|
||||
#include <memory>
|
||||
#include <optional>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
#include <libcamera/base/class.h>
|
||||
#include <libcamera/base/log.h>
|
||||
|
||||
#include <libcamera/color_space.h>
|
||||
#include <libcamera/geometry.h>
|
||||
|
||||
#include "libcamera/internal/formats.h"
|
||||
|
@ -27,6 +29,7 @@ class MediaDevice;
|
|||
struct V4L2SubdeviceFormat {
|
||||
uint32_t mbus_code;
|
||||
Size size;
|
||||
std::optional<ColorSpace> colorSpace;
|
||||
|
||||
const std::string toString() const;
|
||||
uint8_t bitsPerPixel() const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue