From patchwork Sat Jan 26 16:28:58 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacopo Mondi X-Patchwork-Id: 407 Return-Path: Received: from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net [217.70.183.200]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id B07F760B2D for ; Sat, 26 Jan 2019 17:28:53 +0100 (CET) X-Originating-IP: 79.18.49.20 Received: from uno.homenet.telecomitalia.it (host20-49-dynamic.18-79-r.retail.telecomitalia.it [79.18.49.20]) (Authenticated sender: jacopo@jmondi.org) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 2CEA220004; Sat, 26 Jan 2019 16:28:52 +0000 (UTC) From: Jacopo Mondi To: libcamera-devel@lists.libcamera.org Date: Sat, 26 Jan 2019 17:28:58 +0100 Message-Id: <20190126162859.32031-2-jacopo@jmondi.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190126162859.32031-1-jacopo@jmondi.org> References: <20190126162859.32031-1-jacopo@jmondi.org> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH 1/2] libcamera: ipu3: Add method to retrieve camera data 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: Sat, 26 Jan 2019 16:28:53 -0000 Provide a method for the IPU3 pipeline handler that hides the downcast required to return an "IPU3CameraData *" reference from the PipelineHandler::cameraData() method. Signed-off-by: Jacopo Mondi --- src/libcamera/pipeline/ipu3/ipu3.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/libcamera/pipeline/ipu3/ipu3.cpp b/src/libcamera/pipeline/ipu3/ipu3.cpp index d74655d..64f639f 100644 --- a/src/libcamera/pipeline/ipu3/ipu3.cpp +++ b/src/libcamera/pipeline/ipu3/ipu3.cpp @@ -42,6 +42,12 @@ private: std::shared_ptr cio2_; std::shared_ptr imgu_; + IPU3CameraData *cameraData(const Camera *camera) + { + return static_cast( + PipelineHandler::cameraData(camera)); + } + V4L2Device *createVideoDevice(unsigned int id); void registerCameras(); };