From patchwork Wed Aug 28 01:17:05 2019 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: 1873 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 BF94C6192E for ; Wed, 28 Aug 2019 03:17:46 +0200 (CEST) X-Halon-ID: 9b744c35-c931-11e9-bdc3-005056917a89 Authorized-sender: niklas@soderlund.pp.se Received: from bismarck.berto.se (unknown [95.195.154.80]) by bin-vsp-out-01.atm.binero.net (Halon) with ESMTPA id 9b744c35-c931-11e9-bdc3-005056917a89; Wed, 28 Aug 2019 03:17:31 +0200 (CEST) From: =?utf-8?q?Niklas_S=C3=B6derlund?= To: libcamera-devel@lists.libcamera.org Date: Wed, 28 Aug 2019 03:17:05 +0200 Message-Id: <20190828011710.32128-9-niklas.soderlund@ragnatech.se> X-Mailer: git-send-email 2.22.1 In-Reply-To: <20190828011710.32128-1-niklas.soderlund@ragnatech.se> References: <20190828011710.32128-1-niklas.soderlund@ragnatech.se> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 08/13] libcamera: request: Allow read only access to controls X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 28 Aug 2019 01:17:47 -0000 Allow the controls in a Request to be examined from a const environment. Signed-off-by: Niklas Söderlund --- include/libcamera/request.h | 1 + src/libcamera/request.cpp | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/include/libcamera/request.h b/include/libcamera/request.h index 570924c5ef5e2425..f5de5257bba3f2bb 100644 --- a/include/libcamera/request.h +++ b/include/libcamera/request.h @@ -40,6 +40,7 @@ public: ~Request(); ControlList &controls() { return controls_; } + const ControlList &controls() const { return controls_; } const std::map &buffers() const { return bufferMap_; } int addBuffer(std::unique_ptr buffer); Buffer *findBuffer(Stream *stream) const; diff --git a/src/libcamera/request.cpp b/src/libcamera/request.cpp index 4d7bf177534267ac..79e456db1b7dd282 100644 --- a/src/libcamera/request.cpp +++ b/src/libcamera/request.cpp @@ -84,6 +84,11 @@ Request::~Request() * \return A reference to the ControlList in this request */ +/** + * \fn Request::controls() const + * \sa Request::controls() + */ + /** * \fn Request::buffers() * \brief Retrieve the request's streams to buffers map