libcamera: pipeline: vimc: Name camera based on sensor model

Use the sensor model to create the camera name. The resulting name
should still be "VIMC Sensor B", but prepares for support of Sensor A.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
This commit is contained in:
Laurent Pinchart
2020-04-28 21:09:21 +03:00
parent 5c8570cf37
commit 6ed463911d
+2 -2
View File
@@ -394,9 +394,9 @@ bool PipelineHandlerVimc::match(DeviceEnumerator *enumerator)
return false;
/* Create and register the camera. */
std::string name{ "VIMC " + data->sensor_->model() };
std::set<Stream *> streams{ &data->stream_ };
std::shared_ptr<Camera> camera = Camera::create(this, "VIMC Sensor B",
streams);
std::shared_ptr<Camera> camera = Camera::create(this, name, streams);
registerCamera(std::move(camera), std::move(data));
return true;