From 40bef01de0ed1159d99d8e6ec8edfcc025eb74a7 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Tue, 3 Nov 2020 15:30:41 +0200 Subject: libcamera: pipeline: vivid: Set camera properties Initialize the CameraData properties with Location and Model. Signed-off-by: Laurent Pinchart Reviewed-by: Kieran Bingham Signed-off-by: Kieran Bingham --- src/libcamera/pipeline/vivid/vivid.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/libcamera/pipeline/vivid/vivid.cpp b/src/libcamera/pipeline/vivid/vivid.cpp index a07f3012..19cac475 100644 --- a/src/libcamera/pipeline/vivid/vivid.cpp +++ b/src/libcamera/pipeline/vivid/vivid.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #include "libcamera/internal/camera.h" #include "libcamera/internal/device_enumerator.h" @@ -350,7 +351,7 @@ int VividCameraData::init() video_->bufferReady.connect(this, &VividCameraData::bufferReady); - /* Initialise the supported controls. */ + /* Initialise the supported controls and properties. */ const ControlInfoMap &controls = video_->controls(); ControlInfoMap::Map ctrls; @@ -380,6 +381,9 @@ int VividCameraData::init() controlInfo_ = ControlInfoMap(std::move(ctrls), controls::controls); + properties_.set(properties::Location, properties::CameraLocationExternal); + properties_.set(properties::Model, "Virtual Video Device"); + return 0; } -- cgit v1.2.1