summaryrefslogtreecommitdiff
path: root/src/gstreamer/gstlibcameraallocator.h
diff options
context:
space:
mode:
authorJacopo Mondi <jacopo@jmondi.org>2022-07-15 10:50:41 +0200
committerJacopo Mondi <jacopo@jmondi.org>2022-07-23 11:41:20 +0200
commit0f1d5cc15b88bb9cbc759a77186c891c6481d7b2 (patch)
tree3e342f51a7d9b95b1eb68f1ddc24e2b1483c9397 /src/gstreamer/gstlibcameraallocator.h
parent953879a15d83704d86a0b054a06d8e2d4730a2cb (diff)
libcamera: v4l2_videodevice: Reintroduce toV4L2PixelFormat()
This is a partial revert of commit 395d43d6d75b ("libcamera: v4l2_videodevice: Drop toV4L2PixelFormat()") The function was removed because it incorrectly maps non-contigous V4L2 format variants (ie V4L2_PIX_FMT_YUV420M) to the API version supported by the video device (singleplanar API and multiplanar API). It was decided at the time to remove the function and let its users call directly V4L2PixelFormat::fromPixelFormat() which accepts a 'multiplanar' flags. As we now aim to associate multiple V4L2PixelFormat to a single libcamera format, it is necessary to verify which of them is actually supported by the video device. Hence re-introduce V4L2VideoDevice::toV4L2PixelFormat() and convert all the V4L2PixelFormat::fromPixelFormat() users to use it. The V4L2 compatibility layer is the only outliner as it doesn't have a video device to poke, hence it still uses V4L2PixelFormat::fromPixelFormat() and defaults to the first format. Next patches will implement the device format matching logic and handle the non-contiguous plane issue in V4L2VideoDevice::toV4L2PixelFormat(). Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>
Diffstat (limited to 'src/gstreamer/gstlibcameraallocator.h')
0 files changed, 0 insertions, 0 deletions