From patchwork Tue Mar 24 15:51:40 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Niklas_S=C3=B6derlund?= X-Patchwork-Id: 3301 Return-Path: Received: from bin-mail-out-05.binero.net (bin-mail-out-05.binero.net [195.74.38.228]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 1BCFB62BEB for ; Tue, 24 Mar 2020 16:51:54 +0100 (CET) X-Halon-ID: 5f8f617a-6de7-11ea-b7d8-005056917a89 Authorized-sender: niklas@soderlund.pp.se Received: from bismarck.berto.se (p4fca2392.dip0.t-ipconnect.de [79.202.35.146]) by bin-vsp-out-01.atm.binero.net (Halon) with ESMTPA id 5f8f617a-6de7-11ea-b7d8-005056917a89; Tue, 24 Mar 2020 16:51:49 +0100 (CET) From: =?utf-8?q?Niklas_S=C3=B6derlund?= To: libcamera-devel@lists.libcamera.org Date: Tue, 24 Mar 2020 16:51:40 +0100 Message-Id: <20200324155145.3896183-3-niklas.soderlund@ragnatech.se> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200324155145.3896183-1-niklas.soderlund@ragnatech.se> References: <20200324155145.3896183-1-niklas.soderlund@ragnatech.se> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 2/7] cam: Add option to capture StillCaptureRaw stream X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Mar 2020 15:51:54 -0000 Add a role name 'stillraw' to request a StillCaptureRaw stream. Signed-off-by: Niklas Söderlund Reviewed-by: Laurent Pinchart --- src/cam/main.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/cam/main.cpp b/src/cam/main.cpp index 7cdd215ba5398aec..4ef9cce2c97caddd 100644 --- a/src/cam/main.cpp +++ b/src/cam/main.cpp @@ -155,7 +155,7 @@ int CamApp::parseOptions(int argc, char *argv[]) { KeyValueParser streamKeyValue; streamKeyValue.addOption("role", OptionString, - "Role for the stream (viewfinder, video, still)", + "Role for the stream (viewfinder, video, still, stillraw)", ArgumentRequired); streamKeyValue.addOption("width", OptionInteger, "Width in pixels", ArgumentRequired); @@ -219,6 +219,8 @@ int CamApp::prepareConfig() roles.push_back(StreamRole::VideoRecording); } else if (role == "still") { roles.push_back(StreamRole::StillCapture); + } else if (opt["role"].toString() == "stillraw") { + roles.push_back(StreamRole::StillCaptureRaw); } else { std::cerr << "Unknown stream role " << role << std::endl;