From patchwork Thu Aug 29 23:26:39 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: 1888 Return-Path: Received: from bin-mail-out-06.binero.net (bin-mail-out-06.binero.net [195.74.38.229]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 9BAC760C18 for ; Fri, 30 Aug 2019 01:27:30 +0200 (CEST) X-Halon-ID: 857654df-cab4-11e9-837a-0050569116f7 Authorized-sender: niklas@soderlund.pp.se Received: from bismarck.berto.se (unknown [79.202.45.17]) by bin-vsp-out-03.atm.binero.net (Halon) with ESMTPA id 857654df-cab4-11e9-837a-0050569116f7; Fri, 30 Aug 2019 01:27:23 +0200 (CEST) From: =?utf-8?q?Niklas_S=C3=B6derlund?= To: libcamera-devel@lists.libcamera.org Date: Fri, 30 Aug 2019 01:26:39 +0200 Message-Id: <20190829232653.13214-1-niklas.soderlund@ragnatech.se> X-Mailer: git-send-email 2.22.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v2 00/14] libcamera: ipa: Add basic IPA support 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: Thu, 29 Aug 2019 23:27:31 -0000 Hi, This series adds basic support for Image Processing Algorithms (IPA). It extends the pipeline handler framework to optionally allow an IPA plugin to prepare a parameters buffer and examine a statistics buffer as well as applying V4L2 controls on a sensor. It's not mandatory for a pipeline to have an IPA component, but if a pipeline handler supports an IPA it becomes mandatory, if an IPA component can't be found that pipeline will not register any cameras. This series adds an Auto Exposure control and extends the rkisp1 pipeline with and IPA that implements a very basic control loop for exposure time and gain. The series lack support for exposing the status of control loops running inside an IPA to the pipeline handler and users of libcamera. This is something that is planed to be added on top of this series. Other bits missing which are also planed for the near future is serialization of data being transferred between pipeline handler and IPA to allow process isolation. Niklas Söderlund (14): libcamera: ipa: Remove IPAInterface::init() libcamera: pipeline: vimc: Increase version of dummy IPA libcamera: pipeline: Move IPA from pipeline to camera data libcamera: pipeline: Add method to prepare internal buffers libcamera: pipeline: Add callback to initialize IPA libcamera: controls: Add AeEnable libcamera: controls: Allow read only access to control values libcamera: request: Add RequestData libcamera: request: Allow read only access to controls libcamera: ipa: meson: Allow access to internal libcamera headers libcamera: ipa: Extend to support IPA interactions include: linux: Add rkisp1-config.h kernel header libcamera: ipa: rkisp1: Add basic control of auto exposure libcamera: pipeline: rkisp1: Attach to an IPA include/libcamera/control_ids.h | 1 + include/libcamera/controls.h | 1 + include/libcamera/ipa/ipa_interface.h | 17 +- include/libcamera/request.h | 6 + include/linux/rkisp1-config.h | 798 +++++++++++++++++++++++ include/linux/videodev2.h | 4 + src/ipa/ipa_dummy.cpp | 13 +- src/ipa/ipa_dummy_isolate.cpp | 11 +- src/ipa/ipa_rkisp1.cpp | 165 +++++ src/ipa/meson.build | 7 +- src/libcamera/controls.cpp | 49 +- src/libcamera/include/pipeline_handler.h | 16 +- src/libcamera/ipa_interface.cpp | 72 +- src/libcamera/pipeline/rkisp1/rkisp1.cpp | 263 +++++++- src/libcamera/pipeline/vimc.cpp | 10 +- src/libcamera/pipeline_handler.cpp | 78 ++- src/libcamera/proxy/ipa_proxy_linux.cpp | 12 +- src/libcamera/request.cpp | 15 +- 18 files changed, 1483 insertions(+), 55 deletions(-) create mode 100644 include/linux/rkisp1-config.h create mode 100644 src/ipa/ipa_rkisp1.cpp