From patchwork Mon Dec 16 15:40:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Klug X-Patchwork-Id: 22363 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id AFAF2C32F6 for ; Mon, 16 Dec 2024 15:42:37 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 1E78967F9C; Mon, 16 Dec 2024 16:42:37 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="ag2O+Voo"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 3BB3167F72 for ; Mon, 16 Dec 2024 16:42:33 +0100 (CET) Received: from ideasonboard.com (unknown [IPv6:2a00:6020:448c:6c00:bfdf:3a3c:e45:66e3]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 96362A30; Mon, 16 Dec 2024 16:41:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1734363716; bh=L81KN7R/BOj6ABWZJ0ZS63M/EB8ev+WtAxJ7qGap3rU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ag2O+Vooi5599fT6P32k00vFM0ARMpijRElYPq+qoq0ojwMDod5ZhPsa3frS8YC2q rcUAQWQ7hEtGD+GnmbkEGLyJWO1CH3uoWqO/DkXTQECh7z94AP6UtvamcvvNaYJ09f xhSIAmWvM5Ohm4335L6arh+A32x0lDrOcZ6LqB7k= From: Stefan Klug To: libcamera-devel@lists.libcamera.org Cc: Stefan Klug , Jacopo Mondi , Paul Elder Subject: [PATCH v4 17/20] pipeline: rkisp1: make RkISP1CameraConfiguration a friend of the pipeline handler Date: Mon, 16 Dec 2024 16:40:57 +0100 Message-ID: <20241216154124.203650-18-stefan.klug@ideasonboard.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20241216154124.203650-1-stefan.klug@ideasonboard.com> References: <20241216154124.203650-1-stefan.klug@ideasonboard.com> MIME-Version: 1.0 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: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" For the validate() implementation, the RkISP1CameraConfiguration needs access to dewarper related members of the PipelineHandlerRkISP1 object. Allow this access by adding const versions of the pipe accessors and making RkISP1CameraConfiguration a friend of PipelineHandlerRkISP1. Signed-off-by: Stefan Klug Reviewed-by: Jacopo Mondi Reviewed-by: Paul Elder --- Changes in v4: - Changed commit title prefix to pipeline: - Collected tags Changes in v3: - Added this patch --- src/libcamera/pipeline/rkisp1/rkisp1.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp index 14d4bb9a929b..55b839e76d06 100644 --- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp +++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp @@ -98,6 +98,7 @@ public: } PipelineHandlerRkISP1 *pipe(); + const PipelineHandlerRkISP1 *pipe() const; int loadIPA(unsigned int hwRevision); Stream mainPathStream_; @@ -176,6 +177,7 @@ private: } friend RkISP1CameraData; + friend RkISP1CameraConfiguration; friend RkISP1Frames; int initLinks(Camera *camera, const CameraSensor *sensor, @@ -363,6 +365,11 @@ PipelineHandlerRkISP1 *RkISP1CameraData::pipe() return static_cast(Camera::Private::pipe()); } +const PipelineHandlerRkISP1 *RkISP1CameraData::pipe() const +{ + return static_cast(Camera::Private::pipe()); +} + int RkISP1CameraData::loadIPA(unsigned int hwRevision) { ipa_ = IPAManager::createIPA(pipe(), 1, 1);