From patchwork Tue Dec 2 13:31:49 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 25304 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 C0717C32F4 for ; Tue, 2 Dec 2025 13:32:35 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 2BC7160E27; Tue, 2 Dec 2025 14:32:35 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="Tt4s7D+8"; dkim-atps=neutral Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 6FEE660D1D for ; Tue, 2 Dec 2025 14:32:22 +0100 (CET) Received: by mail-wm1-x32d.google.com with SMTP id 5b1f17b1804b1-477563e28a3so36799615e9.1 for ; Tue, 02 Dec 2025 05:32:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1764682342; x=1765287142; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=XKx6dnLcAAKiMuvnL7lnAZrPjjjZBylNVwjMOuMrIMM=; b=Tt4s7D+8Qf5arUKGbRXDdFioKIn77Tv5NwP8EIdjPP17Oy3aOy7N/eNzZA5FTsCM7r KP9AKx//9zGOQr04ocVihTvG0z5UthiHdT8PC8+DUNanjmloxwCDIP3S0ky1UiBdfjh1 jheOOb3oj4b7MG7UUFaZwKsuVKEN6NjW3m4FcCvluIWMdfqWBCuus17kVuuQmJp9H3Kq Mb+pO6HVk0A03FVIGXBrJNVrapgi+DKlgQLPW6J3D2bzakNRG/z2tNkt3ovNWGGJ3nGK 0IYeKcjGXUHUUF9hxW7PIVVd+cuSl81IdvAdwJUx6YKILQAo+DEwmHFuaYI45PBidh5d pjgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1764682342; x=1765287142; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=XKx6dnLcAAKiMuvnL7lnAZrPjjjZBylNVwjMOuMrIMM=; b=grlO43Kw94NlUoFVP4kbzi6agl6rVKfkbzksqnLA/xllN1x3NEgyl5qRnibf9Q6eip uD9ULUCMW2aPti5bEAimKqYdpKtJz02gkqqbluglDqapgohgxMKU3LDcHqHOj/0IJAEy nkBK14q3QEpYWzz6dPd2XKJ3nH1A9epS7pFwamfq9e/T1uUowLM9RdEBFRrAWuR9OoVG Dml05k90+6b6gCDa6X0CJkNLmy/1Ee2NA/MmQ4UntbnoYLpWpo60jj2Bj1UQmScoXoSN vKdGupsQNuy4yx9RRe7nYmI3u/gx74nSvc01ecTgbU819pRVkET6o+2Rnnp+7FhnI8wE Albw== X-Gm-Message-State: AOJu0Yw6Diro/A3xbVQsPmfpFmh6RuxSL0g0AC7zJtL/G8WfoHfpWiHg Y+9NeofHkUVbBnRFyOrMCtiEiC9nMbdgXt7+/bzi3RXqJz+KwogsZRFEQAKij7/NCDQuVz7H1/x CL6kr X-Gm-Gg: ASbGncujlABJ2BCMLyF+MIeYnXeV8ADQfE6Tb/HuyOsBKtmRtvjoDZgmMM6pN/DrclA yShgu/UJ6ktREWx3AW/2t+oa+U2SyF25rBVlNmIJR5y5dhM+3URU9dh2D7BTMwKF9OHUQBEZpYb DrxGLgyBb1mK5GF42UkgznJ78AE62cwhLJPjyvZbi1XUPpSmBf8YqasU2hRW3BHOveDZY0DNY0W npW90WH/xJO2O0ksdvx9Vf8KCvezQAMDifnkQXB2y9cOQYrecFVnifOyRQWckCvof3tDES8724J QFrV2U0LwJQtIruiUDFY0YWyIBINlXeekuJJNAP6D9ZW8k07EFC3IHEGf7hp3GkjbCHXP2uciig F641YrbcTlQN5FoG/nSR91PHjkcVPOMCbuxBe/0/esAyD0t/hG47BJAlj3rjRpGT8YsA8oAPpJt TGlzA2xXHE5RtiyMmbN8GU5AupfV+LDnZOKTRkdySuuTXNZkNyeu1u41KyRxU/OYo3aA8= X-Google-Smtp-Source: AGHT+IHD67lytfHakPZ/BKvvXyCtSJbqrYmOdB+xxY+nOlJmNtRyrWvNWY9OMFe6PcNDhFnb1xgnZg== X-Received: by 2002:a05:600c:314f:b0:477:a1bb:c58e with SMTP id 5b1f17b1804b1-47926f93e8bmr26236355e9.7.1764682341737; Tue, 02 Dec 2025 05:32:21 -0800 (PST) Received: from inspiron14p-linux.ht.home (188-141-3-146.dynamic.upc.ie. [188.141.3.146]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-42e1c5c30c4sm33363322f8f.9.2025.12.02.05.32.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Dec 2025 05:32:21 -0800 (PST) From: Bryan O'Donoghue To: libcamera-devel@lists.libcamera.org Cc: pavel@ucw.cz, Bryan O'Donoghue , Kieran Bingham , Milan Zamazal Subject: [PATCH v3 18/22] libcamera: software_isp: debayer: Make the debayer_ object of type class Debayer not DebayerCpu Date: Tue, 2 Dec 2025 13:31:49 +0000 Message-ID: <20251202133157.661407-19-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20251202133157.661407-1-bryan.odonoghue@linaro.org> References: <20251202133157.661407-1-bryan.odonoghue@linaro.org> 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" Make the type of object Debayer not DebayerCpu thus allowing us to assign the object to either DebayerCpu or DebayerEGL. Reviewed-by: Kieran Bingham Reviewed-by: Milan Zamazal Signed-off-by: Bryan O'Donoghue --- include/libcamera/internal/software_isp/software_isp.h | 5 ++--- src/libcamera/software_isp/software_isp.cpp | 6 +++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/include/libcamera/internal/software_isp/software_isp.h b/include/libcamera/internal/software_isp/software_isp.h index 786246592..ad89c9b3c 100644 --- a/include/libcamera/internal/software_isp/software_isp.h +++ b/include/libcamera/internal/software_isp/software_isp.h @@ -37,7 +37,7 @@ namespace libcamera { -class DebayerCpu; +class Debayer; class FrameBuffer; class PixelFormat; class Stream; @@ -94,8 +94,7 @@ private: void statsReady(uint32_t frame, uint32_t bufferId); void inputReady(FrameBuffer *input); void outputReady(FrameBuffer *output); - - std::unique_ptr debayer_; + std::unique_ptr debayer_; Thread ispWorkerThread_; SharedMemObject sharedParams_; DebayerParams debayerParams_; diff --git a/src/libcamera/software_isp/software_isp.cpp b/src/libcamera/software_isp/software_isp.cpp index c0ff91cc4..638d9a6e6 100644 --- a/src/libcamera/software_isp/software_isp.cpp +++ b/src/libcamera/software_isp/software_isp.cpp @@ -267,7 +267,7 @@ int SoftwareIsp::configure(const StreamConfiguration &inputCfg, ispWorkerThread_.start(); - ret = debayer_->invokeMethod(&DebayerCpu::configure, + ret = debayer_->invokeMethod(&Debayer::configure, ConnectionTypeBlocking, inputCfg, outputCfgs, ccmEnabled_); if (ret) { @@ -367,7 +367,7 @@ int SoftwareIsp::start() */ void SoftwareIsp::stop() { - debayer_->invokeMethod(&DebayerCpu::stop, + debayer_->invokeMethod(&Debayer::stop, ConnectionTypeBlocking); ispWorkerThread_.exit(); @@ -401,7 +401,7 @@ void SoftwareIsp::stop() void SoftwareIsp::process(uint32_t frame, FrameBuffer *input, FrameBuffer *output) { ipa_->computeParams(frame); - debayer_->invokeMethod(&DebayerCpu::process, + debayer_->invokeMethod(&Debayer::process, ConnectionTypeQueued, frame, input, output, debayerParams_); }