From patchwork Thu Dec 18 12:31:23 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Naushir Patuck X-Patchwork-Id: 25602 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 5395BC326C for ; Thu, 18 Dec 2025 12:35:37 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id CDE0B61AA8; Thu, 18 Dec 2025 13:35:36 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=raspberrypi.com header.i=@raspberrypi.com header.b="Vk0sgr8f"; dkim-atps=neutral Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 14BF561A61 for ; Thu, 18 Dec 2025 13:35:34 +0100 (CET) Received: by mail-wr1-x429.google.com with SMTP id ffacd0b85a97d-430f38c7d4eso27945f8f.3 for ; Thu, 18 Dec 2025 04:35:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=raspberrypi.com; s=google; t=1766061333; x=1766666133; 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=YJ+F3mOgAHj9/6mDr8cNT7N9zqrSNuf3WOT2ofJXRf8=; b=Vk0sgr8f8rERtgl9bsJLlbGxxFvt0FmzKWBYJW3pflE1ZpsRW1gfuu8aQn0JvLTI+7 04nRLz5CyrVU0nHgfPdRq3w+99xgTQQXzHwjDKGwxP4wP10fJyFtZPMEIIsWpLdAo0nm gmD0zrfcpPXhrRkKFOOCyK6IPkrqMkCfatAsM0lvuo14AmGpVeLe63NuYKng88SluV8f HTuaFwMVBm77D322gZSpMwCB+u09sOYZwwpvgwXcSpQdKekqSq64DNfvv890US/Z8b5i NiHmjSTOGdaX2xRILoADVtrjBDSwkCxqyQd4BrbZMsaX5/q5TXOb+09zu6CdIBF+OkR2 DJcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1766061333; x=1766666133; 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=YJ+F3mOgAHj9/6mDr8cNT7N9zqrSNuf3WOT2ofJXRf8=; b=aQV4Tx96KNmoVv4r9LxxQbJQ/iT4tmvXRjOJ7SDzvzlpAy+KWDqCHjcN4ylVqrz5P8 g2XlAzGs/PoqUvTk4kl8L7vJGNeCvLgJ6XjDTKuyT5Lf93fhIvhA07BnlgKLVWQGGabG tQE8TldgAWV3CD5bwQyLRP6TdSamfP86gt76L0+tmoYgLXzw8738B0yeYHQ2HfRLlh4W X/z01Zbxo8039u/j7q5jPvNsv4gXRvfOwjL5HCjVBrGV+NIHiRtYbTJf3gFvbeEgCOYP rNg1NwYBXidGyELfcgQmrvwqMuT+2calTmf5z0wWvt0fOfro4geuXIyYcCHxD0BgZ/oz lNKQ== X-Gm-Message-State: AOJu0YwRqfLEN0772AH3uPc4y7cvPjeqwhGGu6b8gRv7uGsKQm/g3l26 A5Uw0qKaSB+sudO7cwEcmO9uFOlfkAnefX37IpznwPUdScPCioIqDRgSYmXY1k+BSR8RXQsMBYu ruCK3 X-Gm-Gg: AY/fxX5ctQbepcGUHokIpMs5BrDL2wlrhnXBXisxq9dJVC4KGrfKe7vGY4SRbMEAfwl vHVHWfEduR1pfLm6PNBEslNUMUsRZatRFRAnxGYeNDKGDeyIZmdAxIGObCmGoqh4I2HOpOwBmdR zymOeN3rs2ufjBkbg9dZLfo/7wFPs6Zs9GWisrr3o5USNika2t4t4ljxvz9lZ9o6rxqPU1o5kLn kk0NLz8VcREKYN06YTb0pTZZVxNj4BXZQQg1Ibt8I4Gx8tNSqb8Nyr78q4ynl58fyMM21L8umgN jAyvynQtwQ6LTIFqhyHI8h6yLeRDeA4ry93QBLqLBSHL41CW4/cQpkXRuK+GjrNK7pufWnjGjXS dnrdsJL+aW9RqapsKoTcWnCScQIrUpgx7OF69PxCoHVWDbCLyj8Bgsas1jGk4HepbwnMdV99BUz aaYRyl1zhiJ7CSF0vvRFBhjdKNboj7DVM= X-Google-Smtp-Source: AGHT+IH8fchTrazZlCNx6QkSiQEuKydxAofFcvnzWLstMGs2FUtNtqSUu9pa1X779LQ4WoLTU1kT+A== X-Received: by 2002:a5d:5f51:0:b0:431:6ba:38c4 with SMTP id ffacd0b85a97d-4324686f55fmr1530032f8f.8.1766061333262; Thu, 18 Dec 2025 04:35:33 -0800 (PST) Received: from naush-dell.pitowers.org ([2a00:1098:3142:1f:1670:643a:b830:51f7]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4324493fd73sm4769434f8f.13.2025.12.18.04.35.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Dec 2025 04:35:33 -0800 (PST) From: Naushir Patuck To: libcamera-devel@lists.libcamera.org Cc: Jacopo Mondi , Naushir Patuck , =?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= Subject: [PATCH v2 1/2] pipeline: rpi: Rename Stream::prepareBuffers to Stream::allocateBuffers Date: Thu, 18 Dec 2025 12:31:23 +0000 Message-ID: <20251218123524.130886-2-naush@raspberrypi.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20251218123524.130886-1-naush@raspberrypi.com> References: <20251218123524.130886-1-naush@raspberrypi.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" This rename is in preparation for a subsequent change where only buffer allocations happen in this function. Signed-off-by: Naushir Patuck Reviewed-by: Barnabás Pőcze --- src/libcamera/pipeline/rpi/common/pipeline_base.cpp | 2 +- src/libcamera/pipeline/rpi/common/pipeline_base.h | 2 +- src/libcamera/pipeline/rpi/common/rpi_stream.cpp | 2 +- src/libcamera/pipeline/rpi/common/rpi_stream.h | 2 +- src/libcamera/pipeline/rpi/pisp/pisp.cpp | 6 +++--- src/libcamera/pipeline/rpi/vc4/vc4.cpp | 6 +++--- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp index 9d65dc83573b..2b61b5d241c5 100644 --- a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp +++ b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp @@ -668,7 +668,7 @@ int PipelineHandlerBase::start(Camera *camera, const ControlList *controls) if (!data->buffersAllocated_) { /* Allocate buffers for internal pipeline usage. */ - ret = prepareBuffers(camera); + ret = allocateBuffers(camera); if (ret) { LOG(RPI, Error) << "Failed to allocate buffers"; data->freeBuffers(); diff --git a/src/libcamera/pipeline/rpi/common/pipeline_base.h b/src/libcamera/pipeline/rpi/common/pipeline_base.h index 15628259afc6..0c6354493548 100644 --- a/src/libcamera/pipeline/rpi/common/pipeline_base.h +++ b/src/libcamera/pipeline/rpi/common/pipeline_base.h @@ -242,7 +242,7 @@ private: } int queueAllBuffers(Camera *camera); - virtual int prepareBuffers(Camera *camera) = 0; + virtual int allocateBuffers(Camera *camera) = 0; }; class RPiCameraConfiguration final : public CameraConfiguration diff --git a/src/libcamera/pipeline/rpi/common/rpi_stream.cpp b/src/libcamera/pipeline/rpi/common/rpi_stream.cpp index accf59eb424e..e73f4b7d31af 100644 --- a/src/libcamera/pipeline/rpi/common/rpi_stream.cpp +++ b/src/libcamera/pipeline/rpi/common/rpi_stream.cpp @@ -106,7 +106,7 @@ void Stream::setExportedBuffer(FrameBuffer *buffer) bufferEmplace(++id_, buffer); } -int Stream::prepareBuffers(unsigned int count) +int Stream::allocateBuffers(unsigned int count) { int ret; diff --git a/src/libcamera/pipeline/rpi/common/rpi_stream.h b/src/libcamera/pipeline/rpi/common/rpi_stream.h index 0dba12961743..c267447e5ab5 100644 --- a/src/libcamera/pipeline/rpi/common/rpi_stream.h +++ b/src/libcamera/pipeline/rpi/common/rpi_stream.h @@ -125,7 +125,7 @@ public: void setExportedBuffer(FrameBuffer *buffer); - int prepareBuffers(unsigned int count); + int allocateBuffers(unsigned int count); int queueBuffer(FrameBuffer *buffer); void returnBuffer(FrameBuffer *buffer); diff --git a/src/libcamera/pipeline/rpi/pisp/pisp.cpp b/src/libcamera/pipeline/rpi/pisp/pisp.cpp index 77acd2f64092..7bcba32b9b58 100644 --- a/src/libcamera/pipeline/rpi/pisp/pisp.cpp +++ b/src/libcamera/pipeline/rpi/pisp/pisp.cpp @@ -864,7 +864,7 @@ private: return static_cast(camera->_d()); } - int prepareBuffers(Camera *camera) override; + int allocateBuffers(Camera *camera) override; int platformRegister(std::unique_ptr &cameraData, std::shared_ptr cfe, std::shared_ptr isp) override; @@ -958,7 +958,7 @@ bool PipelineHandlerPiSP::match(DeviceEnumerator *enumerator) return false; } -int PipelineHandlerPiSP::prepareBuffers(Camera *camera) +int PipelineHandlerPiSP::allocateBuffers(Camera *camera) { PiSPCameraData *data = cameraData(camera); unsigned int numRawBuffers = 0; @@ -1021,7 +1021,7 @@ int PipelineHandlerPiSP::prepareBuffers(Camera *camera) LOG(RPI, Debug) << "Preparing " << numBuffers << " buffers for stream " << stream->name(); - ret = stream->prepareBuffers(numBuffers); + ret = stream->allocateBuffers(numBuffers); if (ret < 0) return ret; } diff --git a/src/libcamera/pipeline/rpi/vc4/vc4.cpp b/src/libcamera/pipeline/rpi/vc4/vc4.cpp index f0cb99d59e74..8a80439e9082 100644 --- a/src/libcamera/pipeline/rpi/vc4/vc4.cpp +++ b/src/libcamera/pipeline/rpi/vc4/vc4.cpp @@ -158,7 +158,7 @@ private: return static_cast(camera->_d()); } - int prepareBuffers(Camera *camera) override; + int allocateBuffers(Camera *camera) override; int platformRegister(std::unique_ptr &cameraData, std::shared_ptr unicam, std::shared_ptr isp) override; @@ -219,7 +219,7 @@ bool PipelineHandlerVc4::match(DeviceEnumerator *enumerator) return false; } -int PipelineHandlerVc4::prepareBuffers(Camera *camera) +int PipelineHandlerVc4::allocateBuffers(Camera *camera) { Vc4CameraData *data = cameraData(camera); unsigned int numRawBuffers = 0; @@ -289,7 +289,7 @@ int PipelineHandlerVc4::prepareBuffers(Camera *camera) LOG(RPI, Debug) << "Preparing " << numBuffers << " buffers for stream " << stream->name(); - ret = stream->prepareBuffers(numBuffers); + ret = stream->allocateBuffers(numBuffers); if (ret < 0) return ret; } From patchwork Thu Dec 18 12:31:24 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Naushir Patuck X-Patchwork-Id: 25603 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 07738C3272 for ; Thu, 18 Dec 2025 12:35:38 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 95C7161B10; Thu, 18 Dec 2025 13:35:37 +0100 (CET) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=raspberrypi.com header.i=@raspberrypi.com header.b="eA0iv59j"; dkim-atps=neutral Received: from mail-wm1-x330.google.com (mail-wm1-x330.google.com [IPv6:2a00:1450:4864:20::330]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id A9CF261603 for ; Thu, 18 Dec 2025 13:35:34 +0100 (CET) Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-47798f4059fso681695e9.2 for ; Thu, 18 Dec 2025 04:35:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=raspberrypi.com; s=google; t=1766061334; x=1766666134; 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=BOdXiYWfo8kvoAXoNdJXmnlFHzLYsyEj3I+WNR70pss=; b=eA0iv59j3tu+TP+52CbOVj/iobWP4hDwECe0gFmTbl3e8tfBvJ0OiARCRGri1UX8W/ 354YTaWK4AUQKB5wegPdbXDMb2FEciQlPaZRF65khEmX+o4Y0iWEzR2gdY7UYhY9Mjqk oqZFaUP58lF16EIC7tSMAlpLpeS1oXQRdq7DsW5N9c6MsnRlFxXtF7iikYgqD0kOEj8q ryorjPV38re1e6IffSf5/ZBYGmwP1OX2CXE1fh7EXP9N6u/OziZBqW5ql4rVGkQDTkEp 9adsBxLtld9s07PaHQC2olkyhw3mVDpO29I12UIu9ebXZzSEqd0zuPt4mopTWLpZ5oft PH5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1766061334; x=1766666134; 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=BOdXiYWfo8kvoAXoNdJXmnlFHzLYsyEj3I+WNR70pss=; b=G8u137YABROkBvB72zlCzTfZQQcyAesMvNs0xQliTc5YQol2KFPmH1ziRyhj7C0Egc 3eiQLUnkyCztOh56f3KAnOl0QyWE60B09eR91JwgMyOfMySF1hvAvjN5H2dbj5pIz3uN zhxa1gH+0HqNSOAK2huTTLKtxLYrY6pXnEDXEHJRelv7/sIAbKunX2NJigiBHsj5fuaP fFk2KR8/Vx0/Q9dK9/k2L63VlavUanjnAiaKntbZH781KgeWHLdZ3s/JjJevGOIOhk1L PmtLj1SR6TdrQcA3R7Yf3ABbqX+stzSrnZCEhG0j9OVcqvCTgSxmsUWtNCMa5AuOD/sa 7dRg== X-Gm-Message-State: AOJu0YyyInywWDYZF5C1zYQRQK0HSCOHBO2yDYmfN5+ZiTsGIOaAd5P7 RtScUSd79SHK/maf/KZjwZONfzk1QfU7888OMK7ZQTNUTo8l5b+LX/OogRcy9HyL3OrxMJlrEwl zQKpQ X-Gm-Gg: AY/fxX4c7Abxk4H3q0nw9O1f0rIuLJqAcRuJJFd0Dgh5mhWjxS4V4wF7PoTeA99wS4F CMbopeBaaylsn68raCFp6T3lT1CGqqjRD1bDzBxNSTaDWUH/xfonh6DtLcLvixh5eD6h2/qvStf rWOV51wyLNReeq496O+y2h0nVG0tlUa0IsvBhdIkk7KCcB4Dkg4WoUcMTN23TFloAy4o1fYI0sR CCjDPnA9wiSUrVyx1GXhLchrz2OCErgd9fdgtgr6RlBIEKB64mKZN11uk3xMoj5u66EnJ7QL8ep lVgoN14WgaXO2ro9CBRbz0acPJkJcM1Ct/JwOkEcxfWK5ns73cxW1yPmCUtAw0tFFNam8EzazEK 9/8WbQXsbznFAinkmHikf6kc3ZBY9VFgytMEh6kb4CJ1+a92OU48dqeB6HpKKb8glD/Bi7ItF8V 59brBEUMQkg/38TB1LrA77aFODVMuS5VU= X-Google-Smtp-Source: AGHT+IEkx/8wiQuTTdzZj3v8IZijtccJkzl4mwFEhXaxvr1EY13Z15aMRgtPfHmBScNckCH87oRElA== X-Received: by 2002:a05:600c:8707:b0:477:5b01:7d42 with SMTP id 5b1f17b1804b1-47be3ced2bdmr11744905e9.5.1766061333879; Thu, 18 Dec 2025 04:35:33 -0800 (PST) Received: from naush-dell.pitowers.org ([2a00:1098:3142:1f:1670:643a:b830:51f7]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4324493fd73sm4769434f8f.13.2025.12.18.04.35.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Dec 2025 04:35:33 -0800 (PST) From: Naushir Patuck To: libcamera-devel@lists.libcamera.org Cc: Jacopo Mondi , Naushir Patuck , =?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= Subject: [PATCH v2 2/2] pipeline: rpi: Rework internal buffer allocations Date: Thu, 18 Dec 2025 12:31:24 +0000 Message-ID: <20251218123524.130886-3-naush@raspberrypi.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20251218123524.130886-1-naush@raspberrypi.com> References: <20251218123524.130886-1-naush@raspberrypi.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" In order to clear the V4L2VideoDevice cache, we must call V4L2VideoDevice::releaseBuffers() when stopping the camera. To do this without releasing the allocated buffers, we have to rework the internal buffer allocation logic. Remove calls to V4L2VideoDevice::importBuffers() and releaseBuffers() from within the RPi::Stream class. Instead, move these calls to the PipelineHandlerBase class, where we can call releaseBuffers(), i.e. clear the V4L2VideoDevice cache unconditionally on stop without de-allocating the internal buffers. The loigc Stream::clearBuffers() can be then moved into releaseBuffers() which will actually de-allocate the internal buffers when required. Closes: https://gitlab.freedesktop.org/camera/libcamera/-/issues/265 Signed-off-by: Naushir Patuck Tested-by: Barnabás Pőcze # rpi4 Reviewed-by: Jacopo Mondi --- .../pipeline/rpi/common/pipeline_base.cpp | 8 ++++++- .../pipeline/rpi/common/rpi_stream.cpp | 23 ++++++------------- .../pipeline/rpi/common/rpi_stream.h | 1 - 3 files changed, 14 insertions(+), 18 deletions(-) diff --git a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp index 2b61b5d241c5..aa0af367d301 100644 --- a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp +++ b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp @@ -719,8 +719,10 @@ void PipelineHandlerBase::stopDevice(Camera *camera) data->state_ = CameraData::State::Stopped; data->platformStop(); - for (auto const stream : data->streams_) + for (auto const stream : data->streams_) { stream->dev()->streamOff(); + stream->dev()->releaseBuffers(); + } /* Disable SOF event generation. */ data->frontendDevice()->setFrameStartEnabled(false); @@ -901,6 +903,10 @@ int PipelineHandlerBase::queueAllBuffers(Camera *camera) int ret; for (auto const stream : data->streams_) { + ret = stream->dev()->importBuffers(VIDEO_MAX_FRAME); + if (ret < 0) + return ret; + if (stream->getFlags() & StreamFlag::External) continue; diff --git a/src/libcamera/pipeline/rpi/common/rpi_stream.cpp b/src/libcamera/pipeline/rpi/common/rpi_stream.cpp index e73f4b7d31af..f420400dfe18 100644 --- a/src/libcamera/pipeline/rpi/common/rpi_stream.cpp +++ b/src/libcamera/pipeline/rpi/common/rpi_stream.cpp @@ -12,9 +12,6 @@ #include -/* Maximum number of buffer slots to allocate in the V4L2 device driver. */ -static constexpr unsigned int maxV4L2BufferCount = 32; - namespace libcamera { LOG_DEFINE_CATEGORY(RPISTREAM) @@ -108,7 +105,7 @@ void Stream::setExportedBuffer(FrameBuffer *buffer) int Stream::allocateBuffers(unsigned int count) { - int ret; + int ret = 0; if (!(flags_ & StreamFlag::ImportOnly)) { /* Export some frame buffers for internal use. */ @@ -121,7 +118,7 @@ int Stream::allocateBuffers(unsigned int count) resetBuffers(); } - return dev_->importBuffers(maxV4L2BufferCount); + return ret; } int Stream::queueBuffer(FrameBuffer *buffer) @@ -243,8 +240,11 @@ int Stream::queueAllBuffers() void Stream::releaseBuffers() { - dev_->releaseBuffers(); - clearBuffers(); + availableBuffers_ = std::queue{}; + requestBuffers_ = std::queue{}; + internalBuffers_.clear(); + bufferMap_.clear(); + id_ = 0; } void Stream::bufferEmplace(unsigned int id, FrameBuffer *buffer) @@ -257,15 +257,6 @@ void Stream::bufferEmplace(unsigned int id, FrameBuffer *buffer) std::forward_as_tuple(buffer, false)); } -void Stream::clearBuffers() -{ - availableBuffers_ = std::queue{}; - requestBuffers_ = std::queue{}; - internalBuffers_.clear(); - bufferMap_.clear(); - id_ = 0; -} - int Stream::queueToDevice(FrameBuffer *buffer) { LOG(RPISTREAM, Debug) << "Queuing buffer " << getBufferId(buffer) diff --git a/src/libcamera/pipeline/rpi/common/rpi_stream.h b/src/libcamera/pipeline/rpi/common/rpi_stream.h index c267447e5ab5..300a352a7d39 100644 --- a/src/libcamera/pipeline/rpi/common/rpi_stream.h +++ b/src/libcamera/pipeline/rpi/common/rpi_stream.h @@ -140,7 +140,6 @@ public: private: void bufferEmplace(unsigned int id, FrameBuffer *buffer); - void clearBuffers(); int queueToDevice(FrameBuffer *buffer); StreamFlags flags_;