From 34d986d1ec342e84db0302d28b7d8bc98c2cd054 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Mon, 5 Jul 2021 18:48:38 +0300 Subject: cam: Store camera session pointer in CamApp class Move the local CameraSession variable from the CamApp::run() function to a member variable of the CamApp class, created in CamApp::init(). This is a first step towards moving code to the CameraSession class. Signed-off-by: Laurent Pinchart Reviewed-by: Kieran Bingham --- src/cam/camera_session.cpp | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src/cam/camera_session.cpp') diff --git a/src/cam/camera_session.cpp b/src/cam/camera_session.cpp index 1fb7c1b6..7bb75e86 100644 --- a/src/cam/camera_session.cpp +++ b/src/cam/camera_session.cpp @@ -34,11 +34,6 @@ int CameraSession::start(const OptionsParser::Options &options) captureLimit_ = options[OptCapture].toInteger(); printMetadata_ = options.isSet(OptMetadata); - if (!camera_) { - std::cout << "Can't capture without a camera" << std::endl; - return -ENODEV; - } - ret = camera_->configure(config_); if (ret < 0) { std::cout << "Failed to configure camera" << std::endl; -- cgit v1.2.1