From dd45866ea40f23738e461031eb971761c2c29576 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20S=C3=B6derlund?= Date: Mon, 4 Feb 2019 18:50:26 +0100 Subject: libcamera: pipeline: uvcvideo: set a default format MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pick a default format for the UVC one stream in a UVC camera. This is just a starting point to define a good default format for the UVC camera it's expected to evolve over time as the capabilities of the library grows. Signed-off-by: Niklas Söderlund Reviewed-by: Kieran Bingham --- src/libcamera/pipeline/uvcvideo.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/libcamera/pipeline/uvcvideo.cpp b/src/libcamera/pipeline/uvcvideo.cpp index 821e4c21..ad4d45d0 100644 --- a/src/libcamera/pipeline/uvcvideo.cpp +++ b/src/libcamera/pipeline/uvcvideo.cpp @@ -60,7 +60,11 @@ PipelineHandlerUVC::streamConfiguration(Camera *camera, StreamConfiguration config{}; - LOG(UVC, Info) << "TODO: Return a good default format"; + LOG(UVC, Debug) << "Retrieving default format"; + config.width = 640; + config.height = 480; + config.pixelFormat = V4L2_PIX_FMT_YUYV; + config.bufferCount = 4; configs[&stream_] = config; -- cgit v1.2.1