[{"id":35175,"web_url":"https://patchwork.libcamera.org/comment/35175/","msgid":"<20250727230110.GD787@pendragon.ideasonboard.com>","date":"2025-07-27T23:01:10","subject":"Re: [PATCH v11 2/8] libcamera: simple: Set the number of software\n\tISP streams to 2","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"Hi Milan,\n\nThank you for the patch.\n\nOn Wed, Jul 23, 2025 at 08:08:07PM +0200, Milan Zamazal wrote:\n> When software ISP is enabled, we want to be able to provide a raw stream\n> in addition to the processed stream.  For this purpose, we need two\n> streams.  If only the processed stream is requested, it doesn't harm to\n> allocate two.\n> \n> This is a hack for the lack of a better easy option.  The number of\n> streams is determined as a camera property in the pipeline matching.\n> The actual number of streams needed (one or two) is determined only when\n> examining roles in SimplePipelineHandler::generateConfiguration.\n\nI don't think that's a hack. numStreams in the match() function\nindicates how many streams the camera can produce. By allowing capture\nof raw frames and processed frames, the simple pipeline handler can\nproduce two streams. How many streams are selected when configuring the\ncamera is a different matter.\n\n> In theory, software ISP could produce multiple processed streams but\n> this is out of scope of this patch series.  Hence two streams are\n> sufficient at the moment.\n> \n> When software ISP is not enabled, the camera won't be able to produce\n> multiple streams (assuming there's no hardware converter) and only\n> single stream should be allocated as before.  The simple pipeline\n> handler assumes there's a linear pipeline from the camera sensor to a\n> video capture device, and only supports a single stream.  Branches in\n> the hardware pipeline that would allow capturing multiple streams from\n> the same camera sensor are not supported.  We have no plan to change\n> that, as a device that can produce multiple streams will likely be\n> better supported by a dedicated pipeline handler.\n> \n> Signed-off-by: Milan Zamazal <mzamazal@redhat.com>\n> ---\n>  src/libcamera/pipeline/simple/simple.cpp | 13 ++++++++++++-\n>  1 file changed, 12 insertions(+), 1 deletion(-)\n> \n> diff --git a/src/libcamera/pipeline/simple/simple.cpp b/src/libcamera/pipeline/simple/simple.cpp\n> index d45480fe7..06532ed26 100644\n> --- a/src/libcamera/pipeline/simple/simple.cpp\n> +++ b/src/libcamera/pipeline/simple/simple.cpp\n> @@ -1723,7 +1723,18 @@ bool SimplePipelineHandler::match(DeviceEnumerator *enumerator)\n>  \t\t}\n>  \t}\n>  \n> -\tswIspEnabled_ = info->swIspEnabled;\n> +\tif (info->swIspEnabled) {\n> +\t\t/*\n> +\t\t * When the software ISP is enabled, the simple pipeline handler\n> +\t\t * exposes the raw stream, giving a total of two streams. This\n> +\t\t * is mutally exclusive with the presence of a converter.\n> +\t\t */\n> +\t\tASSERT(!converter_);\n> +\t\tnumStreams = 2;\n> +\t\tswIspEnabled_ = true;\n> +\t} else {\n> +\t\tswIspEnabled_ = false;\n> +\t}\n\nI'd write it as\n\n\tif (info->swIspEnabled) {\n\t\t/*\n\t\t * When the software ISP is enabled, the simple pipeline handler\n\t\t * exposes the raw stream, giving a total of two streams. This\n\t\t * is mutally exclusive with the presence of a converter.\n\t\t */\n\t\tASSERT(!converter_);\n\t\tnumStreams = 2;\n\t}\n\n\tswIspEnabled_ = info->swIspEnabled;\n\nAlso, shouldn't this patch be moved later in the series ? This will\ncreate a second stream that applications can request, but\ngenerateConfiguration() and validate() are not ready.\n\n>  \n>  \t/* Locate the sensors. */\n>  \tstd::vector<MediaEntity *> sensors = locateSensors(media);","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 36F32C3237\n\tfor <parsemail@patchwork.libcamera.org>;\n\tSun, 27 Jul 2025 23:04:57 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 95A2C69134;\n\tMon, 28 Jul 2025 01:03:29 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 63B00690A5\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 28 Jul 2025 01:01:48 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with UTF8SMTPSA id 8022C842;\n\tMon, 28 Jul 2025 01:00:35 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"peS2vVPl\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1753657235;\n\tbh=Pujdn5jSymA+7p0HcR3I9j4LiJZ+5QSR+wL+GiJeq2s=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=peS2vVPl8xJaGU6dlcUOLADx26oB/1MFK3+XMlFAAOM/GqsF0IS98f3eIpbCf7YpW\n\tOQzLgxGd8sjkWv/VTtwQRbGDfEYWbk2vihi3J0VKfHMlWQvEkqNqI5uWC3KMuxQrVU\n\t3MasFID2pKePS3zWD3yo8TJP8e7NQ/fztGadUjCE=","Date":"Mon, 28 Jul 2025 02:01:10 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Milan Zamazal <mzamazal@redhat.com>","Cc":"libcamera-devel@lists.libcamera.org, Kieran Bingham\n\t<kieran.bingham@ideasonboard.com>, =?utf-8?q?Barnab=C3=A1s_P=C5=91cze?=\n\t<barnabas.pocze@ideasonboard.com>, Paul Elder\n\t<paul.elder@ideasonboard.com>, Umang Jain <uajain@igalia.com>","Subject":"Re: [PATCH v11 2/8] libcamera: simple: Set the number of software\n\tISP streams to 2","Message-ID":"<20250727230110.GD787@pendragon.ideasonboard.com>","References":"<20250723180815.82450-1-mzamazal@redhat.com>\n\t<20250723180815.82450-3-mzamazal@redhat.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20250723180815.82450-3-mzamazal@redhat.com>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":35186,"web_url":"https://patchwork.libcamera.org/comment/35186/","msgid":"<85cy9kd4ky.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","date":"2025-07-28T09:53:17","subject":"Re: [PATCH v11 2/8] libcamera: simple: Set the number of software\n\tISP streams to 2","submitter":{"id":177,"url":"https://patchwork.libcamera.org/api/people/177/","name":"Milan Zamazal","email":"mzamazal@redhat.com"},"content":"Hi Laurent,\n\nthank you for review.\n\nLaurent Pinchart <laurent.pinchart@ideasonboard.com> writes:\n\n> Hi Milan,\n>\n> Thank you for the patch.\n>\n> On Wed, Jul 23, 2025 at 08:08:07PM +0200, Milan Zamazal wrote:\n>> When software ISP is enabled, we want to be able to provide a raw stream\n>> in addition to the processed stream.  For this purpose, we need two\n>> streams.  If only the processed stream is requested, it doesn't harm to\n>> allocate two.\n>> \n>> This is a hack for the lack of a better easy option.  The number of\n>> streams is determined as a camera property in the pipeline matching.\n>> The actual number of streams needed (one or two) is determined only when\n>> examining roles in SimplePipelineHandler::generateConfiguration.\n>\n> I don't think that's a hack. numStreams in the match() function\n> indicates how many streams the camera can produce. By allowing capture\n> of raw frames and processed frames, the simple pipeline handler can\n> produce two streams. How many streams are selected when configuring the\n> camera is a different matter.\n>\n>> In theory, software ISP could produce multiple processed streams but\n>> this is out of scope of this patch series.  Hence two streams are\n>> sufficient at the moment.\n>> \n>> When software ISP is not enabled, the camera won't be able to produce\n>> multiple streams (assuming there's no hardware converter) and only\n>> single stream should be allocated as before.  The simple pipeline\n>> handler assumes there's a linear pipeline from the camera sensor to a\n>> video capture device, and only supports a single stream.  Branches in\n>> the hardware pipeline that would allow capturing multiple streams from\n>> the same camera sensor are not supported.  We have no plan to change\n>> that, as a device that can produce multiple streams will likely be\n>> better supported by a dedicated pipeline handler.\n>> \n>> Signed-off-by: Milan Zamazal <mzamazal@redhat.com>\n>> ---\n>>  src/libcamera/pipeline/simple/simple.cpp | 13 ++++++++++++-\n>>  1 file changed, 12 insertions(+), 1 deletion(-)\n>> \n>> diff --git a/src/libcamera/pipeline/simple/simple.cpp b/src/libcamera/pipeline/simple/simple.cpp\n>> index d45480fe7..06532ed26 100644\n>> --- a/src/libcamera/pipeline/simple/simple.cpp\n>> +++ b/src/libcamera/pipeline/simple/simple.cpp\n>> @@ -1723,7 +1723,18 @@ bool SimplePipelineHandler::match(DeviceEnumerator *enumerator)\n>>  \t\t}\n>>  \t}\n>>  \n>> -\tswIspEnabled_ = info->swIspEnabled;\n>> +\tif (info->swIspEnabled) {\n>> +\t\t/*\n>> +\t\t * When the software ISP is enabled, the simple pipeline handler\n>> +\t\t * exposes the raw stream, giving a total of two streams. This\n>> +\t\t * is mutally exclusive with the presence of a converter.\n>> +\t\t */\n>> +\t\tASSERT(!converter_);\n>> +\t\tnumStreams = 2;\n>> +\t\tswIspEnabled_ = true;\n>> +\t} else {\n>> +\t\tswIspEnabled_ = false;\n>> +\t}\n>\n> I'd write it as\n>\n> \tif (info->swIspEnabled) {\n> \t\t/*\n> \t\t * When the software ISP is enabled, the simple pipeline handler\n> \t\t * exposes the raw stream, giving a total of two streams. This\n> \t\t * is mutally exclusive with the presence of a converter.\n> \t\t */\n> \t\tASSERT(!converter_);\n> \t\tnumStreams = 2;\n> \t}\n>\n> \tswIspEnabled_ = info->swIspEnabled;\n\nOK.\n\n> Also, shouldn't this patch be moved later in the series ? This will\n> create a second stream that applications can request, but\n> generateConfiguration() and validate() are not ready.\n\nI can move it but all the patches are needed to make raw (=> multiple)\nstreams working and are of no real value without the other patches so\nthe order is not that important.  With the exception of the first patch\nto assign colour spaces, which fixes a `cam' crash and can be merged\nseparately.\n\n>>  \n>>  \t/* Locate the sensors. */\n>>  \tstd::vector<MediaEntity *> sensors = locateSensors(media);","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 3D452BDCC1\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 28 Jul 2025 09:53:26 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 6DE5869149;\n\tMon, 28 Jul 2025 11:53:25 +0200 (CEST)","from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.133.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id CCB416146B\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 28 Jul 2025 11:53:23 +0200 (CEST)","from mail-ed1-f69.google.com (mail-ed1-f69.google.com\n\t[209.85.208.69]) by relay.mimecast.com with ESMTP with STARTTLS\n\t(version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n\tus-mta-654-iaNq13aVMiuZSuFzIUZq3g-1; Mon, 28 Jul 2025 05:53:21 -0400","by mail-ed1-f69.google.com with SMTP id\n\t4fb4d7f45d1cf-60c9d8a169cso4760302a12.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 28 Jul 2025 02:53:20 -0700 (PDT)","from mzamazal-thinkpadp1gen7.tpbc.csb\n\t(ip-77-48-47-2.net.vodafone.cz. [77.48.47.2])\n\tby smtp.gmail.com with ESMTPSA id\n\t4fb4d7f45d1cf-6153a041a4esm1245313a12.28.2025.07.28.02.53.18\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tMon, 28 Jul 2025 02:53:18 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=redhat.com header.i=@redhat.com\n\theader.b=\"cgkgC/qC\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1753696402;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=t57h5eXIJQzuq2wK4opwe8zj/NPcfDrEkcOz+ZeOjMw=;\n\tb=cgkgC/qCUk2cewP2zJJG+7vHwyEotLJuxD84ymyt8tkTLNSzJwTQShw2/iQ71boRs9MG+h\n\tEA8cKKHqjYqOVmDPqxEHnOa5yTR2YsV50ffzGFbbg/tmOJpKHzlt4mptEEkNRX8i0xrNQh\n\tn132I1DzsP9m9F+P1lmMepqXDsS/qvI=","X-MC-Unique":"iaNq13aVMiuZSuFzIUZq3g-1","X-Mimecast-MFC-AGG-ID":"iaNq13aVMiuZSuFzIUZq3g_1753696400","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1753696400; x=1754301200;\n\th=mime-version:user-agent:message-id:date:references:in-reply-to\n\t:subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=t57h5eXIJQzuq2wK4opwe8zj/NPcfDrEkcOz+ZeOjMw=;\n\tb=sDU58hzX0tmpfpkn9v7xPKL3uYwdVzZd7BoNwNQ3zv3VLyWugjBgQc/4p4rYu5xBio\n\tp0LvDYYA3MEWuDyuDFRlblykcpVpH1wvefGkJlDnc7kFzdut7gmRsGBGJKfiI30v/5t8\n\totUYeTtO6HxDIRCmUj5JoPxzYKX1AH3NdNOCUdaymFg84YfJEjZtiWsqN4qLuqZkBA3L\n\thgI1yMZXRlfYW7AVEaTrm8lS1v74ncNfwMZBARGSMCRSHmrugdAtERK1Ex3b0hAhf4Ot\n\tezPmlDSy5uE0raw9DGyZSwJHgM0q0QCf0BGqxaFO5nw+O/XwSBZOYfChgcrf3QG5S5Y/\n\tF8ZA==","X-Gm-Message-State":"AOJu0YzC1cZn1d5PJVLXFyHMpMX6FG1Sd+ledmBgAO2PhzqXuaEHJ7+B\n\tx/QeA1fmgw9B1XClVNSVD0P3/Pf8IBvd//BPuto9RRWfsNyJUJks9eOQk/hBa9oSQdse65DlzLa\n\tqFgP2FLbzx+S5QD0h+1pS83pFtiAlgM7/x7kyA7LF2GCk++1DDqgmN932s17Y1DJ6WdZleK04/b\n\tQ=","X-Gm-Gg":"ASbGncugLHtRvCXOnChcDZyQs9hiwbA30LMORYhbQyjMZOmYTWDNQLTZWwJ9qc3I0eM\n\tUQB8oiatG3c80UsHshMYP+QCH7UMSOYdN6vMPmErqqY2zYErsnD+COaeHconGivYMogfNoZrFLu\n\tRm4zymz5rxZz0Eh6zVfFGsx7PznsdueAceJKBtDuub9MDer5un/2ayb4xJCiMCYcHu4dd7o/thV\n\tnnMTXdnuDJdjWTGcNCW/b7F2xHXFqcdmQZ2rxNV94swPli93DFMoc556oHECY1GY/w4HEELtj9m\n\tRCc+lzsox8KyVXHT+mEaCNvj0IGT03Ei+DYg37dO2ZUZu4BOv2nD4hQXpDhkfw0NraMugHBDli9\n\trtVA8tykuxzjysaQx","X-Received":["by 2002:a05:6402:d0b:b0:607:ea0c:6590 with SMTP id\n\t4fb4d7f45d1cf-614f1ddf532mr10226761a12.24.1753696399712; \n\tMon, 28 Jul 2025 02:53:19 -0700 (PDT)","by 2002:a05:6402:d0b:b0:607:ea0c:6590 with SMTP id\n\t4fb4d7f45d1cf-614f1ddf532mr10226732a12.24.1753696399161; \n\tMon, 28 Jul 2025 02:53:19 -0700 (PDT)"],"X-Google-Smtp-Source":"AGHT+IHUgA7gJKn9CPjp7j1cg8KPVYyRkLqH1eB0N9bTEoVgbCywqBfUEfMgbi7Y07TFJJbZ3hfQcg==","From":"Milan Zamazal <mzamazal@redhat.com>","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org,\n\tKieran Bingham <kieran.bingham@ideasonboard.com>, =?utf-8?q?Barnab?=\n\t=?utf-8?b?w6FzIFDFkWN6ZQ==?=\n\t<barnabas.pocze@ideasonboard.com>, Paul Elder\n\t<paul.elder@ideasonboard.com>, Umang Jain <uajain@igalia.com>","Subject":"Re: [PATCH v11 2/8] libcamera: simple: Set the number of software\n\tISP streams to 2","In-Reply-To":"<20250727230110.GD787@pendragon.ideasonboard.com> (Laurent\n\tPinchart's message of \"Mon, 28 Jul 2025 02:01:10 +0300\")","References":"<20250723180815.82450-1-mzamazal@redhat.com>\n\t<20250723180815.82450-3-mzamazal@redhat.com>\n\t<20250727230110.GD787@pendragon.ideasonboard.com>","Date":"Mon, 28 Jul 2025 11:53:17 +0200","Message-ID":"<85cy9kd4ky.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","User-Agent":"Gnus/5.13 (Gnus v5.13)","MIME-Version":"1.0","X-Mimecast-Spam-Score":"0","X-Mimecast-MFC-PROC-ID":"l0MkjdDln9d1cRwUYep2CY8uqzmgwpkQBK4ImNA_BV4_1753696400","X-Mimecast-Originator":"redhat.com","Content-Type":"text/plain","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":35193,"web_url":"https://patchwork.libcamera.org/comment/35193/","msgid":"<20250728112930.GG787@pendragon.ideasonboard.com>","date":"2025-07-28T11:29:30","subject":"Re: [PATCH v11 2/8] libcamera: simple: Set the number of software\n\tISP streams to 2","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Mon, Jul 28, 2025 at 11:53:17AM +0200, Milan Zamazal wrote:\n> Laurent Pinchart writes:\n> > On Wed, Jul 23, 2025 at 08:08:07PM +0200, Milan Zamazal wrote:\n> >> When software ISP is enabled, we want to be able to provide a raw stream\n> >> in addition to the processed stream.  For this purpose, we need two\n> >> streams.  If only the processed stream is requested, it doesn't harm to\n> >> allocate two.\n> >> \n> >> This is a hack for the lack of a better easy option.  The number of\n> >> streams is determined as a camera property in the pipeline matching.\n> >> The actual number of streams needed (one or two) is determined only when\n> >> examining roles in SimplePipelineHandler::generateConfiguration.\n> >\n> > I don't think that's a hack. numStreams in the match() function\n> > indicates how many streams the camera can produce. By allowing capture\n> > of raw frames and processed frames, the simple pipeline handler can\n> > produce two streams. How many streams are selected when configuring the\n> > camera is a different matter.\n> >\n> >> In theory, software ISP could produce multiple processed streams but\n> >> this is out of scope of this patch series.  Hence two streams are\n> >> sufficient at the moment.\n> >> \n> >> When software ISP is not enabled, the camera won't be able to produce\n> >> multiple streams (assuming there's no hardware converter) and only\n> >> single stream should be allocated as before.  The simple pipeline\n> >> handler assumes there's a linear pipeline from the camera sensor to a\n> >> video capture device, and only supports a single stream.  Branches in\n> >> the hardware pipeline that would allow capturing multiple streams from\n> >> the same camera sensor are not supported.  We have no plan to change\n> >> that, as a device that can produce multiple streams will likely be\n> >> better supported by a dedicated pipeline handler.\n> >> \n> >> Signed-off-by: Milan Zamazal <mzamazal@redhat.com>\n> >> ---\n> >>  src/libcamera/pipeline/simple/simple.cpp | 13 ++++++++++++-\n> >>  1 file changed, 12 insertions(+), 1 deletion(-)\n> >> \n> >> diff --git a/src/libcamera/pipeline/simple/simple.cpp b/src/libcamera/pipeline/simple/simple.cpp\n> >> index d45480fe7..06532ed26 100644\n> >> --- a/src/libcamera/pipeline/simple/simple.cpp\n> >> +++ b/src/libcamera/pipeline/simple/simple.cpp\n> >> @@ -1723,7 +1723,18 @@ bool SimplePipelineHandler::match(DeviceEnumerator *enumerator)\n> >>  \t\t}\n> >>  \t}\n> >>  \n> >> -\tswIspEnabled_ = info->swIspEnabled;\n> >> +\tif (info->swIspEnabled) {\n> >> +\t\t/*\n> >> +\t\t * When the software ISP is enabled, the simple pipeline handler\n> >> +\t\t * exposes the raw stream, giving a total of two streams. This\n> >> +\t\t * is mutally exclusive with the presence of a converter.\n> >> +\t\t */\n> >> +\t\tASSERT(!converter_);\n> >> +\t\tnumStreams = 2;\n> >> +\t\tswIspEnabled_ = true;\n> >> +\t} else {\n> >> +\t\tswIspEnabled_ = false;\n> >> +\t}\n> >\n> > I'd write it as\n> >\n> > \tif (info->swIspEnabled) {\n> > \t\t/*\n> > \t\t * When the software ISP is enabled, the simple pipeline handler\n> > \t\t * exposes the raw stream, giving a total of two streams. This\n> > \t\t * is mutally exclusive with the presence of a converter.\n> > \t\t */\n> > \t\tASSERT(!converter_);\n> > \t\tnumStreams = 2;\n> > \t}\n> >\n> > \tswIspEnabled_ = info->swIspEnabled;\n> \n> OK.\n> \n> > Also, shouldn't this patch be moved later in the series ? This will\n> > create a second stream that applications can request, but\n> > generateConfiguration() and validate() are not ready.\n> \n> I can move it but all the patches are needed to make raw (=> multiple)\n> streams working and are of no real value without the other patches so\n> the order is not that important.  With the exception of the first patch\n> to assign colour spaces, which fixes a `cam' crash and can be merged\n> separately.\n\nSure, I understand. My concern is that applying this patch early will\nlikely break bisection. If patches can be easily reordered to avoid\nthat, it would be nice.\n\n> >>  \n> >>  \t/* Locate the sensors. */\n> >>  \tstd::vector<MediaEntity *> sensors = locateSensors(media);","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id 3F1F9BDCC1\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 28 Jul 2025 11:29:41 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 659FD6904C;\n\tMon, 28 Jul 2025 13:29:40 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 3B8226904C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 28 Jul 2025 13:29:38 +0200 (CEST)","from pendragon.ideasonboard.com (81-175-209-231.bb.dnainternet.fi\n\t[81.175.209.231])\n\tby perceval.ideasonboard.com (Postfix) with UTF8SMTPSA id 12097465;\n\tMon, 28 Jul 2025 13:28:55 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"oHYjnpnh\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1753702136;\n\tbh=79+imarub2LiKI/jhQ3f7DNOr5YntTcsTeonAkLjWow=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=oHYjnpnhF8negzQIzrip3niHjFMBo2MCs7J9TKQZqy8vph0Uht4BoYRuKNQ6QRIvu\n\tFtHfA1DmeJxyXgQhgh26h6jRG1769f+3MgPH3poEGCGXf4hvMCVJ2fgCoOBvmC4u/k\n\tOD9imPCEVj9uHt73wviFtOblB5w5Rh2bXc9MLByE=","Date":"Mon, 28 Jul 2025 14:29:30 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Milan Zamazal <mzamazal@redhat.com>","Cc":"libcamera-devel@lists.libcamera.org, Kieran Bingham\n\t<kieran.bingham@ideasonboard.com>, =?utf-8?q?Barnab=C3=A1s_P=C5=91cze?=\n\t<barnabas.pocze@ideasonboard.com>, Paul Elder\n\t<paul.elder@ideasonboard.com>, Umang Jain <uajain@igalia.com>","Subject":"Re: [PATCH v11 2/8] libcamera: simple: Set the number of software\n\tISP streams to 2","Message-ID":"<20250728112930.GG787@pendragon.ideasonboard.com>","References":"<20250723180815.82450-1-mzamazal@redhat.com>\n\t<20250723180815.82450-3-mzamazal@redhat.com>\n\t<20250727230110.GD787@pendragon.ideasonboard.com>\n\t<85cy9kd4ky.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<85cy9kd4ky.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]