libcamera: v4l2_pixelformat: Add V4L2 description strings

Add V4L2 description strings to the map of V4L2 formats. To achieve
this, create an Info struct to wrap them. Update the one current user of
the old map.

This will be used later in the V4L2 compatibility layer to report the
V4L2 format description.

Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jean-Michel Hautbois <jeanmichel.hautbois@ideasonboard.com>
This commit is contained in:
Paul Elder
2021-09-08 16:46:32 +09:00
parent a20d52a35b
commit 67f0def9ba
2 changed files with 130 additions and 57 deletions

View File

@@ -20,6 +20,11 @@ namespace libcamera {
class V4L2PixelFormat
{
public:
struct Info {
PixelFormat format;
const char *description;
};
V4L2PixelFormat()
: fourcc_(0)
{