[{"id":30489,"web_url":"https://patchwork.libcamera.org/comment/30489/","msgid":"<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>","date":"2024-07-26T10:56:10","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Hi Harvey,\n\nQuoting Harvey Yang (2024-07-26 10:54:21)\n> Hi folks,\n> \n> Sorry for the super late update. It's been a while since the last series\n> of patches, as we were busy with mtkisp7's bringup & migration.\n> \n> Thanks to Hans de Goede's work on DmaBufAllocator, the prerequisites of\n> VirtualPipelineHandler are almost landed. Only a helper function added\n> in the first patch.\n\nExcellent, Yes - I had this virtual pipeline work in mind as well when\nthe buffer allocator landed!\n\nI've just tried to run this and built locally then tried to run but I\nget:\n\nkbingham@Monstersaurus:~/iob/libcamera/libcamera$ ./build/gcc/src/apps/cam/cam --list\n[686:32:50.927990678] [2690143]  INFO IPAManager ipa_manager.cpp:143 libcamera is not installed. Adding '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA search path\n[686:32:50.933827146] [2690143]  INFO Camera camera_manager.cpp:313 libcamera v0.3.1+7-e4713a22\n[686:32:51.016903716] [2690146]  WARN CameraSensorProperties camera_sensor_properties.cpp:283 No static properties available for 'Sensor B'\n[686:32:51.016924335] [2690146]  WARN CameraSensorProperties camera_sensor_properties.cpp:285 Please consider updating the camera sensor properties database\n[686:32:51.016941437] [2690146]  WARN CameraSensor camera_sensor.cpp:479 'Sensor B': Failed to retrieve the camera location\n[686:32:51.016953209] [2690146]  WARN CameraSensor camera_sensor.cpp:501 'Sensor B': Rotation control not available, default to 0 degrees\n[686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130 libcamera is not installed. Loading IPA configuration from '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n[686:32:51.019729155] [2690146] ERROR DmaBufAllocator dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n[686:32:51.020135800] [2690146]  INFO Pipeline pipeline_handler.cpp:575 libcamera is not installed. Loading platform configuration file from '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\nterminate called after throwing an instance of 'std::filesystem::__cxx11::filesystem_error'\n  what():  filesystem error: directory iterator cannot open directory: No such file or directory [files/libcamera_short_anime/]\nAborted (core dumped)\n\n\nDoes it have to be installed to run? Is there anything else missing?\n\n--\nKieran\n\n\n> \n> Konami, our intern in 2023, helped to add test patterns and real image\n> loading into VirtualPipelineHandler.\n> \n> I tried to address the previous comments, while it's very likely that I\n> left some behind. Please leave the comments again if I do. Many thanks!\n> \n> \n> BR,\n> Harvey\n> \n> Harvey Yang (3):\n>   Add a helper function exportFrameBuffers in DmaBufAllocator to make it\n>     easier to use.\n>   The Fatal check of having at least one MediaDevice was to prevent\n>     pipeline handler implementations searching and owning media devices\n>     with custom conventions, instead of using the base function\n>     |acquireMediaDevice|. It also has the assumption that there's at\n>     least one media device to make a camera work.\n>   libcamera: pipeline: Add VirtualPipelineHandler\n> \n> Konami Shu (4):\n>   libcamera: pipeline: Add test pattern for VirtualPipelineHandler\n>   libcamera: pipeline: Read config and register cameras based on the\n>     config\n>   libcamera: pipeline: Shift test pattern by 1 pixel left every frame\n>   libcamera: pipeline: Load images\n> \n>  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n>  meson.build                                   |   1 +\n>  meson_options.txt                             |   3 +-\n>  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n>  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n>  .../pipeline/virtual/common_functions.cpp     |  27 ++\n>  .../pipeline/virtual/common_functions.h       |  18 ++\n>  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n>  .../pipeline/virtual/frame_generator.h        |  33 +++\n>  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n>  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n>  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n>  src/libcamera/pipeline/virtual/parser.cpp     | 243 +++++++++++++++\n>  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n>  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n>  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n>  src/libcamera/pipeline/virtual/virtual.cpp    | 279 ++++++++++++++++++\n>  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n>  src/libcamera/pipeline_handler.cpp            |  11 +-\n>  19 files changed, 1404 insertions(+), 6 deletions(-)\n>  create mode 100644 src/libcamera/pipeline/virtual/README.md\n>  create mode 100644 src/libcamera/pipeline/virtual/common_functions.cpp\n>  create mode 100644 src/libcamera/pipeline/virtual/common_functions.h\n>  create mode 100644 src/libcamera/pipeline/virtual/data/virtual.yaml\n>  create mode 100644 src/libcamera/pipeline/virtual/frame_generator.h\n>  create mode 100644 src/libcamera/pipeline/virtual/image_frame_generator.cpp\n>  create mode 100644 src/libcamera/pipeline/virtual/image_frame_generator.h\n>  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n>  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n>  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n>  create mode 100644 src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n>  create mode 100644 src/libcamera/pipeline/virtual/test_pattern_generator.h\n>  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n>  create mode 100644 src/libcamera/pipeline/virtual/virtual.h\n> \n> -- \n> 2.46.0.rc1.232.g9752f9e123-goog\n>","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 F0C0ABDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 26 Jul 2024 10:56:16 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 213A86336F;\n\tFri, 26 Jul 2024 12:56:16 +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 405506199C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 26 Jul 2024 12:56:14 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust6594.18-1.cable.virginm.net [86.31.185.195])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id AB2CF83F;\n\tFri, 26 Jul 2024 12:55:29 +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=\"ptZFDa9I\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1721991329;\n\tbh=/OarjGzCDSE5sn7rW8SQp4tATBFJb6WSk1KQHCbvGd8=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=ptZFDa9IJfQ4ZL8fwUZ0u7r+UfqsfSrytDGvQFY6UkbV6UvtYeE9Id6HuyL3+CIv2\n\tt+Nd8s5C2LLDWfPCjupjINGQiIXMDRy146QuXkfWKc68H4P6PRoxOaLDYWX46+ZNgs\n\tLiMOZW62qoTHTIFQ4CaQb+tDtgQYr6A4EuDrq9Rc=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20240726095626.3632402-1-chenghaoyang@chromium.org>","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Harvey Yang <chenghaoyang@chromium.org>","To":"Harvey Yang <chenghaoyang@chromium.org>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Fri, 26 Jul 2024 11:56:10 +0100","Message-ID":"<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>","User-Agent":"alot/0.10","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":30490,"web_url":"https://patchwork.libcamera.org/comment/30490/","msgid":"<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>","date":"2024-07-26T11:41:40","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":117,"url":"https://patchwork.libcamera.org/api/people/117/","name":"Cheng-Hao Yang","email":"chenghaoyang@chromium.org"},"content":"Hi Kieran,\n\nThanks for looking into this!\n\nOn Fri, Jul 26, 2024 at 6:56 PM Kieran Bingham <\nkieran.bingham@ideasonboard.com> wrote:\n\n> Hi Harvey,\n>\n> Quoting Harvey Yang (2024-07-26 10:54:21)\n> > Hi folks,\n> >\n> > Sorry for the super late update. It's been a while since the last series\n> > of patches, as we were busy with mtkisp7's bringup & migration.\n> >\n> > Thanks to Hans de Goede's work on DmaBufAllocator, the prerequisites of\n> > VirtualPipelineHandler are almost landed. Only a helper function added\n> > in the first patch.\n>\n> Excellent, Yes - I had this virtual pipeline work in mind as well when\n> the buffer allocator landed!\n>\n> I've just tried to run this and built locally then tried to run but I\n> get:\n>\n> kbingham@Monstersaurus:~/iob/libcamera/libcamera$\n> ./build/gcc/src/apps/cam/cam --list\n> [686:32:50.927990678] [2690143]  INFO IPAManager ipa_manager.cpp:143\n> libcamera is not installed. Adding\n> '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA\n> search path\n> [686:32:50.933827146] [2690143]  INFO Camera camera_manager.cpp:313\n> libcamera v0.3.1+7-e4713a22\n> [686:32:51.016903716] [2690146]  WARN CameraSensorProperties\n> camera_sensor_properties.cpp:283 No static properties available for 'Sensor\n> B'\n> [686:32:51.016924335] [2690146]  WARN CameraSensorProperties\n> camera_sensor_properties.cpp:285 Please consider updating the camera sensor\n> properties database\n> [686:32:51.016941437] [2690146]  WARN CameraSensor camera_sensor.cpp:479\n> 'Sensor B': Failed to retrieve the camera location\n> [686:32:51.016953209] [2690146]  WARN CameraSensor camera_sensor.cpp:501\n> 'Sensor B': Rotation control not available, default to 0 degrees\n> [686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130 libcamera\n> is not installed. Loading IPA configuration from\n> '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n> [686:32:51.019729155] [2690146] ERROR DmaBufAllocator\n> dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n>\n\nJFYI, currently virtual pipeline handler uses the default type\n`DmaBufAllocatorFlag::CmaHeap`. If none of the dma heaps or udmabuf are\navailable, we can use memfd_create [1] to allocate local memory.\n\n[1]:\nhttps://chromium-review.googlesource.com/c/chromiumos/third_party/libcamera/+/4739525/2\n\n\n> [686:32:51.020135800] [2690146]  INFO Pipeline pipeline_handler.cpp:575\n> libcamera is not installed. Loading platform configuration file from\n> '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\n> terminate called after throwing an instance of\n> 'std::filesystem::__cxx11::filesystem_error'\n>   what():  filesystem error: directory iterator cannot open directory: No\n> such file or directory [files/libcamera_short_anime/]\n> Aborted (core dumped)\n\n\nThe virtual pipeline handler has a config file\n`src/libcamera/pipeline/virtual/data/virtual.yaml` to load and config the\ncameras listed. In the current default yaml (We can discuss what should be\nthe default config file though) expects `files/libcamera_short_anime/` (I\nbelieve it's the relative path from which you run libcamera) to contain at\nleast one `0.jpg` (and `1.jpg`, `2.jpg`, ...) to support camera `Virtual0`;\n`files/bike-min.jpg` to support camera `Virtual1`;\n`files/chrome_anniversary.jpg` to support camera `Virtual5`. For the\nformats and details, please check\n`src/libcamera/pipeline/virtual/README.md`.\n\nI also need your opinions: maybe we should upload some images used in the\nsample yaml config file in the patch?\n\nBR,\nHarvey\n\nDoes it have to be installed to run? Is there anything else missing?\n>\n> --\n> Kieran\n>\n>\n> >\n> > Konami, our intern in 2023, helped to add test patterns and real image\n> > loading into VirtualPipelineHandler.\n> >\n> > I tried to address the previous comments, while it's very likely that I\n> > left some behind. Please leave the comments again if I do. Many thanks!\n> >\n> >\n> > BR,\n> > Harvey\n> >\n> > Harvey Yang (3):\n> >   Add a helper function exportFrameBuffers in DmaBufAllocator to make it\n> >     easier to use.\n> >   The Fatal check of having at least one MediaDevice was to prevent\n> >     pipeline handler implementations searching and owning media devices\n> >     with custom conventions, instead of using the base function\n> >     |acquireMediaDevice|. It also has the assumption that there's at\n> >     least one media device to make a camera work.\n> >   libcamera: pipeline: Add VirtualPipelineHandler\n> >\n> > Konami Shu (4):\n> >   libcamera: pipeline: Add test pattern for VirtualPipelineHandler\n> >   libcamera: pipeline: Read config and register cameras based on the\n> >     config\n> >   libcamera: pipeline: Shift test pattern by 1 pixel left every frame\n> >   libcamera: pipeline: Load images\n> >\n> >  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n> >  meson.build                                   |   1 +\n> >  meson_options.txt                             |   3 +-\n> >  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n> >  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n> >  .../pipeline/virtual/common_functions.cpp     |  27 ++\n> >  .../pipeline/virtual/common_functions.h       |  18 ++\n> >  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n> >  .../pipeline/virtual/frame_generator.h        |  33 +++\n> >  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n> >  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n> >  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n> >  src/libcamera/pipeline/virtual/parser.cpp     | 243 +++++++++++++++\n> >  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n> >  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n> >  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n> >  src/libcamera/pipeline/virtual/virtual.cpp    | 279 ++++++++++++++++++\n> >  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n> >  src/libcamera/pipeline_handler.cpp            |  11 +-\n> >  19 files changed, 1404 insertions(+), 6 deletions(-)\n> >  create mode 100644 src/libcamera/pipeline/virtual/README.md\n> >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.cpp\n> >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.h\n> >  create mode 100644 src/libcamera/pipeline/virtual/data/virtual.yaml\n> >  create mode 100644 src/libcamera/pipeline/virtual/frame_generator.h\n> >  create mode 100644\n> src/libcamera/pipeline/virtual/image_frame_generator.cpp\n> >  create mode 100644\n> src/libcamera/pipeline/virtual/image_frame_generator.h\n> >  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n> >  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n> >  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n> >  create mode 100644\n> src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n> >  create mode 100644\n> src/libcamera/pipeline/virtual/test_pattern_generator.h\n> >  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n> >  create mode 100644 src/libcamera/pipeline/virtual/virtual.h\n> >\n> > --\n> > 2.46.0.rc1.232.g9752f9e123-goog\n> >\n>","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 E0626C323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 26 Jul 2024 11:41:55 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 01E656336F;\n\tFri, 26 Jul 2024 13:41:55 +0200 (CEST)","from mail-lj1-x22f.google.com (mail-lj1-x22f.google.com\n\t[IPv6:2a00:1450:4864:20::22f])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 86A3B6199C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 26 Jul 2024 13:41:53 +0200 (CEST)","by mail-lj1-x22f.google.com with SMTP id\n\t38308e7fff4ca-2f01e9f53e3so15597251fa.1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 26 Jul 2024 04:41:53 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=chromium.org header.i=@chromium.org\n\theader.b=\"CY1bBe6L\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=chromium.org; s=google; t=1721994112; x=1722598912;\n\tdarn=lists.libcamera.org; \n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:from:to:cc:subject:date:message-id:reply-to;\n\tbh=ldDCGqktQiXfsHfq2vZH9q+OPL8a2Zw/ANQhvXQZoqA=;\n\tb=CY1bBe6LwD05PWrrxPNb/ZeJjuF72jcoJuJWuunoiRHqP8YAEi3+TCKW78TnvO3uUQ\n\tjttzHhMcEKjt1v1FIeVmtUSDFvS3VkOSa7k4WUhHpQ/zZMplRRMzZGdhsoZcWK6Zpytp\n\tmTz31WhLBZV4S0wdPQYcYb2RejZV3Dv7xj5s4=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1721994112; x=1722598912;\n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=ldDCGqktQiXfsHfq2vZH9q+OPL8a2Zw/ANQhvXQZoqA=;\n\tb=niIysIEIDsSrv/Fqoe2zUawk/uZT+sMUW1NRqsle5I8MTWPJMOXaSjy6IaAeykTyAR\n\ttzdG+OvLNZoTP/YJPqnw36J0QQestLh3m4HqpM7DYk5KIHEvlPYmwtTD3UamLsuOP/4k\n\t1tWlAqiGrljGtrzPBl1XbBuwfdZ91dlRzHh/sXQVYi+paRNDrpkH9f6dD4Hix5VhOQhg\n\tjTHp8/MKSuIOU54VM4iFji0VJr0QToRRVXBSJhrhTp2V0deOfp6fcMUWY/0Rv59G5BI6\n\tIfHy5lI/qaa+7vNsAtc6W0n9GH07uhsiXzCVpF5+w0IH7x1vvFPiUTlqmQiNKBPzUtkr\n\tUYTw==","X-Gm-Message-State":"AOJu0YwNeO/YPloyGI0tp8pGnc9LjVt1oJIMbqVSLOiu3pvr5tnNwQqX\n\tEdkcf8MGNjIJOai56dsAAhFhxKYNzoshlcOZ6eCZqklDNGa2eDtNy/p9I34uONAX2BW5HabUb+a\n\ti+1fAoHfEfXzvqtQKgTsaWqF26f62T74N37AfzrQgX7fPp5g/gQ==","X-Google-Smtp-Source":"AGHT+IFithbXOE3elnHyYbp9XQcjHVsxIFxAZkZBXc2QUSYzebnSxIE4aXDgXBjGSbCNjpTR/K3xXqdkg/WxJ47IyaE=","X-Received":"by 2002:a2e:88cd:0:b0:2ef:2012:eecf with SMTP id\n\t38308e7fff4ca-2f03db74367mr39932331fa.26.1721994112454;\n\tFri, 26 Jul 2024 04:41:52 -0700 (PDT)","MIME-Version":"1.0","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>\n\t<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>","In-Reply-To":"<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>","From":"Cheng-Hao Yang <chenghaoyang@chromium.org>","Date":"Fri, 26 Jul 2024 19:41:40 +0800","Message-ID":"<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Content-Type":"multipart/alternative; boundary=\"00000000000060f0e0061e24ff5d\"","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":30493,"web_url":"https://patchwork.libcamera.org/comment/30493/","msgid":"<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>","date":"2024-07-29T15:03:05","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Cheng-Hao Yang (2024-07-26 12:41:40)\n> Hi Kieran,\n> \n> Thanks for looking into this!\n> \n> On Fri, Jul 26, 2024 at 6:56 PM Kieran Bingham <\n> kieran.bingham@ideasonboard.com> wrote:\n> \n> > Hi Harvey,\n> >\n> > Quoting Harvey Yang (2024-07-26 10:54:21)\n> > > Hi folks,\n> > >\n> > > Sorry for the super late update. It's been a while since the last series\n> > > of patches, as we were busy with mtkisp7's bringup & migration.\n> > >\n> > > Thanks to Hans de Goede's work on DmaBufAllocator, the prerequisites of\n> > > VirtualPipelineHandler are almost landed. Only a helper function added\n> > > in the first patch.\n> >\n> > Excellent, Yes - I had this virtual pipeline work in mind as well when\n> > the buffer allocator landed!\n> >\n> > I've just tried to run this and built locally then tried to run but I\n> > get:\n> >\n> > kbingham@Monstersaurus:~/iob/libcamera/libcamera$\n> > ./build/gcc/src/apps/cam/cam --list\n> > [686:32:50.927990678] [2690143]  INFO IPAManager ipa_manager.cpp:143\n> > libcamera is not installed. Adding\n> > '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA\n> > search path\n> > [686:32:50.933827146] [2690143]  INFO Camera camera_manager.cpp:313\n> > libcamera v0.3.1+7-e4713a22\n> > [686:32:51.016903716] [2690146]  WARN CameraSensorProperties\n> > camera_sensor_properties.cpp:283 No static properties available for 'Sensor\n> > B'\n> > [686:32:51.016924335] [2690146]  WARN CameraSensorProperties\n> > camera_sensor_properties.cpp:285 Please consider updating the camera sensor\n> > properties database\n> > [686:32:51.016941437] [2690146]  WARN CameraSensor camera_sensor.cpp:479\n> > 'Sensor B': Failed to retrieve the camera location\n> > [686:32:51.016953209] [2690146]  WARN CameraSensor camera_sensor.cpp:501\n> > 'Sensor B': Rotation control not available, default to 0 degrees\n> > [686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130 libcamera\n> > is not installed. Loading IPA configuration from\n> > '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n> > [686:32:51.019729155] [2690146] ERROR DmaBufAllocator\n> > dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n> >\n> \n> JFYI, currently virtual pipeline handler uses the default type\n> `DmaBufAllocatorFlag::CmaHeap`. If none of the dma heaps or udmabuf are\n> available, we can use memfd_create [1] to allocate local memory.\n> \n> [1]:\n> https://chromium-review.googlesource.com/c/chromiumos/third_party/libcamera/+/4739525/2\n> \n> \n> > [686:32:51.020135800] [2690146]  INFO Pipeline pipeline_handler.cpp:575\n> > libcamera is not installed. Loading platform configuration file from\n> > '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\n> > terminate called after throwing an instance of\n> > 'std::filesystem::__cxx11::filesystem_error'\n> >   what():  filesystem error: directory iterator cannot open directory: No\n> > such file or directory [files/libcamera_short_anime/]\n> > Aborted (core dumped)\n> \n> \n> The virtual pipeline handler has a config file\n> `src/libcamera/pipeline/virtual/data/virtual.yaml` to load and config the\n> cameras listed. In the current default yaml (We can discuss what should be\n> the default config file though) expects `files/libcamera_short_anime/` (I\n> believe it's the relative path from which you run libcamera) to contain at\n> least one `0.jpg` (and `1.jpg`, `2.jpg`, ...) to support camera `Virtual0`;\n> `files/bike-min.jpg` to support camera `Virtual1`;\n> `files/chrome_anniversary.jpg` to support camera `Virtual5`. For the\n> formats and details, please check\n> `src/libcamera/pipeline/virtual/README.md`.\n> \n> I also need your opinions: maybe we should upload some images used in the\n> sample yaml config file in the patch?\n\nI don't know if you should upload files, but if it requires files then\nthey need to be there!\n\nThe files perhaps should be an optional additional feature - with fall\nback to a (simple) test pattern generator perhaps?\n\n> \n> BR,\n> Harvey\n> \n> Does it have to be installed to run? Is there anything else missing?\n\nIt should be possible to run without being installed.\n\nI've pushed this branch to the CI and it fails in many of the instances:\n\n - https://gitlab.freedesktop.org/camera/libcamera/-/pipelines/1235732\n\n\nIt might be worth making a fork of\nhttps://gitlab.freedesktop.org/camera/libcamera for yourself on gitlab\nso that you can run the integration tests while developing. But I'm\nhappy to push any patches you send to the list and report the CI url for\nyou. (I do expect that to be automated 'soon'*)\n\n--\nKieran\n\n\n* Soon is such a hard term to define ;-)\n\n\n\n\n> >\n> > --\n> > Kieran\n> >\n> >\n> > >\n> > > Konami, our intern in 2023, helped to add test patterns and real image\n> > > loading into VirtualPipelineHandler.\n> > >\n> > > I tried to address the previous comments, while it's very likely that I\n> > > left some behind. Please leave the comments again if I do. Many thanks!\n> > >\n> > >\n> > > BR,\n> > > Harvey\n> > >\n> > > Harvey Yang (3):\n> > >   Add a helper function exportFrameBuffers in DmaBufAllocator to make it\n> > >     easier to use.\n> > >   The Fatal check of having at least one MediaDevice was to prevent\n> > >     pipeline handler implementations searching and owning media devices\n> > >     with custom conventions, instead of using the base function\n> > >     |acquireMediaDevice|. It also has the assumption that there's at\n> > >     least one media device to make a camera work.\n> > >   libcamera: pipeline: Add VirtualPipelineHandler\n> > >\n> > > Konami Shu (4):\n> > >   libcamera: pipeline: Add test pattern for VirtualPipelineHandler\n> > >   libcamera: pipeline: Read config and register cameras based on the\n> > >     config\n> > >   libcamera: pipeline: Shift test pattern by 1 pixel left every frame\n> > >   libcamera: pipeline: Load images\n> > >\n> > >  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n> > >  meson.build                                   |   1 +\n> > >  meson_options.txt                             |   3 +-\n> > >  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n> > >  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n> > >  .../pipeline/virtual/common_functions.cpp     |  27 ++\n> > >  .../pipeline/virtual/common_functions.h       |  18 ++\n> > >  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n> > >  .../pipeline/virtual/frame_generator.h        |  33 +++\n> > >  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n> > >  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n> > >  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n> > >  src/libcamera/pipeline/virtual/parser.cpp     | 243 +++++++++++++++\n> > >  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n> > >  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n> > >  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n> > >  src/libcamera/pipeline/virtual/virtual.cpp    | 279 ++++++++++++++++++\n> > >  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n> > >  src/libcamera/pipeline_handler.cpp            |  11 +-\n> > >  19 files changed, 1404 insertions(+), 6 deletions(-)\n> > >  create mode 100644 src/libcamera/pipeline/virtual/README.md\n> > >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.cpp\n> > >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.h\n> > >  create mode 100644 src/libcamera/pipeline/virtual/data/virtual.yaml\n> > >  create mode 100644 src/libcamera/pipeline/virtual/frame_generator.h\n> > >  create mode 100644\n> > src/libcamera/pipeline/virtual/image_frame_generator.cpp\n> > >  create mode 100644\n> > src/libcamera/pipeline/virtual/image_frame_generator.h\n> > >  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n> > >  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n> > >  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n> > >  create mode 100644\n> > src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n> > >  create mode 100644\n> > src/libcamera/pipeline/virtual/test_pattern_generator.h\n> > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n> > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.h\n> > >\n> > > --\n> > > 2.46.0.rc1.232.g9752f9e123-goog\n> > >\n> >","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 AA07DBDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 29 Jul 2024 15:03:11 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5DCC363370;\n\tMon, 29 Jul 2024 17:03:10 +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 A93C261984\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 29 Jul 2024 17:03:08 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust6594.18-1.cable.virginm.net [86.31.185.195])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id ED780229;\n\tMon, 29 Jul 2024 17:02:21 +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=\"QsgtjRZb\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1722265342;\n\tbh=DDaN74sG0FGVvzf33EL4GM1/rsseTJoeX5FBpxBO8HQ=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=QsgtjRZbZSYNi1LW1gOTFTwFwMpnoH7FSjQqC7jy6kAb9xTH0ElGbaMMUl6fXuzoN\n\tk1y/qfZD5yEHoZy4t0gjZiyJjRrkc5Uyrc3/Iko7RmcgwLzpSxlpgpu/3YwXTh4hri\n\tiY676APKQHvJ/tVQme6PwDLfG0o1/FroHeRracm4=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>\n\t<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>\n\t<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","To":"Cheng-Hao Yang <chenghaoyang@chromium.org>","Date":"Mon, 29 Jul 2024 16:03:05 +0100","Message-ID":"<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>","User-Agent":"alot/0.10","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":30525,"web_url":"https://patchwork.libcamera.org/comment/30525/","msgid":"<20240731134143.GA29266@pendragon.ideasonboard.com>","date":"2024-07-31T13:41:43","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Mon, Jul 29, 2024 at 04:03:05PM +0100, Kieran Bingham wrote:\n> Quoting Cheng-Hao Yang (2024-07-26 12:41:40)\n> > On Fri, Jul 26, 2024 at 6:56 PM Kieran Bingham wrote:\n> > > Quoting Harvey Yang (2024-07-26 10:54:21)\n> > > > Hi folks,\n> > > >\n> > > > Sorry for the super late update. It's been a while since the last series\n> > > > of patches, as we were busy with mtkisp7's bringup & migration.\n> > > >\n> > > > Thanks to Hans de Goede's work on DmaBufAllocator, the prerequisites of\n> > > > VirtualPipelineHandler are almost landed. Only a helper function added\n> > > > in the first patch.\n> > >\n> > > Excellent, Yes - I had this virtual pipeline work in mind as well when\n> > > the buffer allocator landed!\n> > >\n> > > I've just tried to run this and built locally then tried to run but I\n> > > get:\n> > >\n> > > kbingham@Monstersaurus:~/iob/libcamera/libcamera$\n> > > ./build/gcc/src/apps/cam/cam --list\n> > > [686:32:50.927990678] [2690143]  INFO IPAManager ipa_manager.cpp:143 libcamera is not installed. Adding '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA search path\n> > > [686:32:50.933827146] [2690143]  INFO Camera camera_manager.cpp:313 libcamera v0.3.1+7-e4713a22\n> > > [686:32:51.016903716] [2690146]  WARN CameraSensorProperties camera_sensor_properties.cpp:283 No static properties available for 'Sensor B'\n> > > [686:32:51.016924335] [2690146]  WARN CameraSensorProperties camera_sensor_properties.cpp:285 Please consider updating the camera sensor properties database\n> > > [686:32:51.016941437] [2690146]  WARN CameraSensor camera_sensor.cpp:479 'Sensor B': Failed to retrieve the camera location\n> > > [686:32:51.016953209] [2690146]  WARN CameraSensor camera_sensor.cpp:501 'Sensor B': Rotation control not available, default to 0 degrees\n> > > [686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130 libcamera is not installed. Loading IPA configuration from '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n> > > [686:32:51.019729155] [2690146] ERROR DmaBufAllocator dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n> > \n> > JFYI, currently virtual pipeline handler uses the default type\n> > `DmaBufAllocatorFlag::CmaHeap`. If none of the dma heaps or udmabuf are\n> > available, we can use memfd_create [1] to allocate local memory.\n> > \n> > [1]: https://chromium-review.googlesource.com/c/chromiumos/third_party/libcamera/+/4739525/2\n> > \n> > > [686:32:51.020135800] [2690146]  INFO Pipeline pipeline_handler.cpp:575\n> > > libcamera is not installed. Loading platform configuration file from\n> > > '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\n> > > terminate called after throwing an instance of\n> > > 'std::filesystem::__cxx11::filesystem_error'\n> > >   what():  filesystem error: directory iterator cannot open directory: No\n> > > such file or directory [files/libcamera_short_anime/]\n> > > Aborted (core dumped)\n> > \n> > The virtual pipeline handler has a config file\n> > `src/libcamera/pipeline/virtual/data/virtual.yaml` to load and config the\n> > cameras listed. In the current default yaml (We can discuss what should be\n> > the default config file though) expects `files/libcamera_short_anime/` (I\n> > believe it's the relative path from which you run libcamera) to contain at\n> > least one `0.jpg` (and `1.jpg`, `2.jpg`, ...) to support camera `Virtual0`;\n> > `files/bike-min.jpg` to support camera `Virtual1`;\n> > `files/chrome_anniversary.jpg` to support camera `Virtual5`. For the\n> > formats and details, please check\n> > `src/libcamera/pipeline/virtual/README.md`.\n> > \n> > I also need your opinions: maybe we should upload some images used in the\n> > sample yaml config file in the patch?\n> \n> I don't know if you should upload files, but if it requires files then\n> they need to be there!\n> \n> The files perhaps should be an optional additional feature - with fall\n> back to a (simple) test pattern generator perhaps?\n\nThat's what I was about to propose, so I think it's a good idea.\n\n> > Does it have to be installed to run? Is there anything else missing?\n> \n> It should be possible to run without being installed.\n> \n> I've pushed this branch to the CI and it fails in many of the instances:\n> \n>  - https://gitlab.freedesktop.org/camera/libcamera/-/pipelines/1235732\n> \n> It might be worth making a fork of\n> https://gitlab.freedesktop.org/camera/libcamera for yourself on gitlab\n> so that you can run the integration tests while developing. But I'm\n> happy to push any patches you send to the list and report the CI url for\n> you. (I do expect that to be automated 'soon'*)\n> \n> * Soon is such a hard term to define ;-)\n> \n> > > > Konami, our intern in 2023, helped to add test patterns and real image\n> > > > loading into VirtualPipelineHandler.\n> > > >\n> > > > I tried to address the previous comments, while it's very likely that I\n> > > > left some behind. Please leave the comments again if I do. Many thanks!\n> > > >\n> > > >\n> > > > BR,\n> > > > Harvey\n> > > >\n> > > > Harvey Yang (3):\n> > > >   Add a helper function exportFrameBuffers in DmaBufAllocator to make it\n> > > >     easier to use.\n> > > >   The Fatal check of having at least one MediaDevice was to prevent\n> > > >     pipeline handler implementations searching and owning media devices\n> > > >     with custom conventions, instead of using the base function\n> > > >     |acquireMediaDevice|. It also has the assumption that there's at\n> > > >     least one media device to make a camera work.\n> > > >   libcamera: pipeline: Add VirtualPipelineHandler\n> > > >\n> > > > Konami Shu (4):\n> > > >   libcamera: pipeline: Add test pattern for VirtualPipelineHandler\n> > > >   libcamera: pipeline: Read config and register cameras based on the\n> > > >     config\n> > > >   libcamera: pipeline: Shift test pattern by 1 pixel left every frame\n> > > >   libcamera: pipeline: Load images\n> > > >\n> > > >  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n> > > >  meson.build                                   |   1 +\n> > > >  meson_options.txt                             |   3 +-\n> > > >  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n> > > >  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n> > > >  .../pipeline/virtual/common_functions.cpp     |  27 ++\n> > > >  .../pipeline/virtual/common_functions.h       |  18 ++\n> > > >  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n> > > >  .../pipeline/virtual/frame_generator.h        |  33 +++\n> > > >  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n> > > >  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n> > > >  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n> > > >  src/libcamera/pipeline/virtual/parser.cpp     | 243 +++++++++++++++\n> > > >  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n> > > >  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n> > > >  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n> > > >  src/libcamera/pipeline/virtual/virtual.cpp    | 279 ++++++++++++++++++\n> > > >  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n> > > >  src/libcamera/pipeline_handler.cpp            |  11 +-\n> > > >  19 files changed, 1404 insertions(+), 6 deletions(-)\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/README.md\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.cpp\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.h\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/data/virtual.yaml\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/frame_generator.h\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/image_frame_generator.cpp\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/image_frame_generator.h\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/test_pattern_generator.h\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n> > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.h","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 70E88BDC71\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 31 Jul 2024 13:42:07 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 6884663374;\n\tWed, 31 Jul 2024 15:42:06 +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 761D86198E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 31 Jul 2024 15:42:04 +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 ESMTPSA id 2FE56F85;\n\tWed, 31 Jul 2024 15:41:16 +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=\"MepFC7DE\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1722433276;\n\tbh=f86cu0SL147DPfHHPxRPtZ51Cms8QOsRUTln2XcvmJk=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=MepFC7DEmMgXWc0XFwuY1IqIvdqELt6CREZFIK3GPPVF5ojCHFmAE8LEXfXDlDMvB\n\t625eXK+dCAJmdgrI3VhNPGyCWWfpB1ISv8UYWTC56W65OIvVRL3LZ9I1WQ2xcAuAAi\n\tpGLE1bzaS9SqDVllFGO+kziJvaJUFNc0S9UBSwXY=","Date":"Wed, 31 Jul 2024 16:41:43 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Cheng-Hao Yang <chenghaoyang@chromium.org>,\n\tlibcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","Message-ID":"<20240731134143.GA29266@pendragon.ideasonboard.com>","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>\n\t<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>\n\t<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>\n\t<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>","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":30536,"web_url":"https://patchwork.libcamera.org/comment/30536/","msgid":"<CAEB1ahvXMBD1rDXAvQao0_=uO9MS2VZJv7jDxKuK+Ou09rbVBg@mail.gmail.com>","date":"2024-08-01T07:39:51","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":117,"url":"https://patchwork.libcamera.org/api/people/117/","name":"Cheng-Hao Yang","email":"chenghaoyang@chromium.org"},"content":"Hi Laurent,\n\nOn Wed, Jul 31, 2024 at 9:42 PM Laurent Pinchart <\nlaurent.pinchart@ideasonboard.com> wrote:\n\n> On Mon, Jul 29, 2024 at 04:03:05PM +0100, Kieran Bingham wrote:\n> > Quoting Cheng-Hao Yang (2024-07-26 12:41:40)\n> > > On Fri, Jul 26, 2024 at 6:56 PM Kieran Bingham wrote:\n> > > > Quoting Harvey Yang (2024-07-26 10:54:21)\n> > > > > Hi folks,\n> > > > >\n> > > > > Sorry for the super late update. It's been a while since the last\n> series\n> > > > > of patches, as we were busy with mtkisp7's bringup & migration.\n> > > > >\n> > > > > Thanks to Hans de Goede's work on DmaBufAllocator, the\n> prerequisites of\n> > > > > VirtualPipelineHandler are almost landed. Only a helper function\n> added\n> > > > > in the first patch.\n> > > >\n> > > > Excellent, Yes - I had this virtual pipeline work in mind as well\n> when\n> > > > the buffer allocator landed!\n> > > >\n> > > > I've just tried to run this and built locally then tried to run but I\n> > > > get:\n> > > >\n> > > > kbingham@Monstersaurus:~/iob/libcamera/libcamera$\n> > > > ./build/gcc/src/apps/cam/cam --list\n> > > > [686:32:50.927990678] [2690143]  INFO IPAManager ipa_manager.cpp:143\n> libcamera is not installed. Adding\n> '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA\n> search path\n> > > > [686:32:50.933827146] [2690143]  INFO Camera camera_manager.cpp:313\n> libcamera v0.3.1+7-e4713a22\n> > > > [686:32:51.016903716] [2690146]  WARN CameraSensorProperties\n> camera_sensor_properties.cpp:283 No static properties available for 'Sensor\n> B'\n> > > > [686:32:51.016924335] [2690146]  WARN CameraSensorProperties\n> camera_sensor_properties.cpp:285 Please consider updating the camera sensor\n> properties database\n> > > > [686:32:51.016941437] [2690146]  WARN CameraSensor\n> camera_sensor.cpp:479 'Sensor B': Failed to retrieve the camera location\n> > > > [686:32:51.016953209] [2690146]  WARN CameraSensor\n> camera_sensor.cpp:501 'Sensor B': Rotation control not available, default\n> to 0 degrees\n> > > > [686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130\n> libcamera is not installed. Loading IPA configuration from\n> '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n> > > > [686:32:51.019729155] [2690146] ERROR DmaBufAllocator\n> dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n> > >\n> > > JFYI, currently virtual pipeline handler uses the default type\n> > > `DmaBufAllocatorFlag::CmaHeap`. If none of the dma heaps or udmabuf are\n> > > available, we can use memfd_create [1] to allocate local memory.\n> > >\n> > > [1]:\n> https://chromium-review.googlesource.com/c/chromiumos/third_party/libcamera/+/4739525/2\n> > >\n> > > > [686:32:51.020135800] [2690146]  INFO Pipeline\n> pipeline_handler.cpp:575\n> > > > libcamera is not installed. Loading platform configuration file from\n> > > >\n> '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\n> > > > terminate called after throwing an instance of\n> > > > 'std::filesystem::__cxx11::filesystem_error'\n> > > >   what():  filesystem error: directory iterator cannot open\n> directory: No\n> > > > such file or directory [files/libcamera_short_anime/]\n> > > > Aborted (core dumped)\n> > >\n> > > The virtual pipeline handler has a config file\n> > > `src/libcamera/pipeline/virtual/data/virtual.yaml` to load and config\n> the\n> > > cameras listed. In the current default yaml (We can discuss what\n> should be\n> > > the default config file though) expects `files/libcamera_short_anime/`\n> (I\n> > > believe it's the relative path from which you run libcamera) to\n> contain at\n> > > least one `0.jpg` (and `1.jpg`, `2.jpg`, ...) to support camera\n> `Virtual0`;\n> > > `files/bike-min.jpg` to support camera `Virtual1`;\n> > > `files/chrome_anniversary.jpg` to support camera `Virtual5`. For the\n> > > formats and details, please check\n> > > `src/libcamera/pipeline/virtual/README.md`.\n> > >\n> > > I also need your opinions: maybe we should upload some images used in\n> the\n> > > sample yaml config file in the patch?\n> >\n> > I don't know if you should upload files, but if it requires files then\n> > they need to be there!\n> >\n> > The files perhaps should be an optional additional feature - with fall\n> > back to a (simple) test pattern generator perhaps?\n>\n> That's what I was about to propose, so I think it's a good idea.\n>\n>\nHmm, I still find it weird to have a fallback mechanism if an image file\nis not installed as the configuration file indicates.\n\nIf you still think that it's a proper mechanism, how about we add it in\nanother series of patches? We might also need to discuss the format\nand fields of the configuration file.\n\nBR,\nHarvey\n\n\n> > > Does it have to be installed to run? Is there anything else missing?\n> >\n> > It should be possible to run without being installed.\n> >\n> > I've pushed this branch to the CI and it fails in many of the instances:\n> >\n> >  - https://gitlab.freedesktop.org/camera/libcamera/-/pipelines/1235732\n> >\n> > It might be worth making a fork of\n> > https://gitlab.freedesktop.org/camera/libcamera for yourself on gitlab\n> > so that you can run the integration tests while developing. But I'm\n> > happy to push any patches you send to the list and report the CI url for\n> > you. (I do expect that to be automated 'soon'*)\n> >\n> > * Soon is such a hard term to define ;-)\n> >\n> > > > > Konami, our intern in 2023, helped to add test patterns and real\n> image\n> > > > > loading into VirtualPipelineHandler.\n> > > > >\n> > > > > I tried to address the previous comments, while it's very likely\n> that I\n> > > > > left some behind. Please leave the comments again if I do. Many\n> thanks!\n> > > > >\n> > > > >\n> > > > > BR,\n> > > > > Harvey\n> > > > >\n> > > > > Harvey Yang (3):\n> > > > >   Add a helper function exportFrameBuffers in DmaBufAllocator to\n> make it\n> > > > >     easier to use.\n> > > > >   The Fatal check of having at least one MediaDevice was to prevent\n> > > > >     pipeline handler implementations searching and owning media\n> devices\n> > > > >     with custom conventions, instead of using the base function\n> > > > >     |acquireMediaDevice|. It also has the assumption that there's\n> at\n> > > > >     least one media device to make a camera work.\n> > > > >   libcamera: pipeline: Add VirtualPipelineHandler\n> > > > >\n> > > > > Konami Shu (4):\n> > > > >   libcamera: pipeline: Add test pattern for VirtualPipelineHandler\n> > > > >   libcamera: pipeline: Read config and register cameras based on\n> the\n> > > > >     config\n> > > > >   libcamera: pipeline: Shift test pattern by 1 pixel left every\n> frame\n> > > > >   libcamera: pipeline: Load images\n> > > > >\n> > > > >  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n> > > > >  meson.build                                   |   1 +\n> > > > >  meson_options.txt                             |   3 +-\n> > > > >  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n> > > > >  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n> > > > >  .../pipeline/virtual/common_functions.cpp     |  27 ++\n> > > > >  .../pipeline/virtual/common_functions.h       |  18 ++\n> > > > >  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n> > > > >  .../pipeline/virtual/frame_generator.h        |  33 +++\n> > > > >  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n> > > > >  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n> > > > >  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n> > > > >  src/libcamera/pipeline/virtual/parser.cpp     | 243\n> +++++++++++++++\n> > > > >  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n> > > > >  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n> > > > >  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n> > > > >  src/libcamera/pipeline/virtual/virtual.cpp    | 279\n> ++++++++++++++++++\n> > > > >  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n> > > > >  src/libcamera/pipeline_handler.cpp            |  11 +-\n> > > > >  19 files changed, 1404 insertions(+), 6 deletions(-)\n> > > > >  create mode 100644 src/libcamera/pipeline/virtual/README.md\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/common_functions.cpp\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/common_functions.h\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/data/virtual.yaml\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/frame_generator.h\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/image_frame_generator.cpp\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/image_frame_generator.h\n> > > > >  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n> > > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n> > > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n> > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/test_pattern_generator.h\n> > > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n> > > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.h\n>\n> --\n> Regards,\n>\n> Laurent Pinchart\n>","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 EC1D4C323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu,  1 Aug 2024 07:40:06 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id BB3CF63381;\n\tThu,  1 Aug 2024 09:40:05 +0200 (CEST)","from mail-lj1-x230.google.com (mail-lj1-x230.google.com\n\t[IPv6:2a00:1450:4864:20::230])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 192136336E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu,  1 Aug 2024 09:40:04 +0200 (CEST)","by mail-lj1-x230.google.com with SMTP id\n\t38308e7fff4ca-2eeb1051360so73351591fa.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 01 Aug 2024 00:40:04 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=chromium.org header.i=@chromium.org\n\theader.b=\"NGrleRHe\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=chromium.org; s=google; t=1722498003; x=1723102803;\n\tdarn=lists.libcamera.org; \n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:from:to:cc:subject:date:message-id:reply-to;\n\tbh=SpzRsIbQKTzYTfb1cVyZWVPScC6C8fztgWrY5cDPMqE=;\n\tb=NGrleRHeYOyjv9xlLJRVv/sOIz7W3zD4zTtWpyx/iSkcNilvQLpYWPqYmoYTgL2CU3\n\tTb5o80IpSVvS515K4xoKULr6X1paXPGyye2BlsBIwl948YrydkzB2VhEvtK93txpfxy3\n\tWQjrJNjIsku+4YwlzIFGnDsZbCW1brXNPWMmo=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1722498003; x=1723102803;\n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=SpzRsIbQKTzYTfb1cVyZWVPScC6C8fztgWrY5cDPMqE=;\n\tb=f7QA2im655263mtpLAKzp72fBB2DO8/b1/kjRra+BPK47NamJdEfHbvIjfnQYD0kU0\n\t8YNg1gGhprKK6OnOp0uVupYhphmrV+RcT0PQNAJ72FSL37YRRDO6bA4BUgV33rVKI7GM\n\tPVRky1YtORYYyHZoPAufhKiUkCe6ChcQKCSldpiQgh5tVtDuouuzITyNx8yXjHQuP1EW\n\tKzRa6dM7V0Yl96jfnDwDmVM1ZLPTEHkKLn2tJ05A70m1XNfFXK9hNbaYmmYAaVrXJT6K\n\tFuFe4feyAGuki3HFRbbZCQ0We+oAMIMTiw29Fv8EcNTlO+J8JP94MoTau7AwlgvhIYe3\n\tBZtQ==","X-Forwarded-Encrypted":"i=1;\n\tAJvYcCUo+HoX75QHfsZyox6IX/zq2hx2I+lj6u+BCJSgxK9FQCYUHyDESqHucmd3hfUzFK95DSm7I37M8cTsnA4+GFk=@lists.libcamera.org","X-Gm-Message-State":"AOJu0Yzo4kCwNoHELa3xuErs6JocSYULV5SfYCHUusZ7vRltaVIKtBO+\n\taV5K50NwinllF/TAbkcvXNFjs3ygDMbx82aO+x+ScsRrZNE4uIdUOhKVBPG6CWqwoQFZCeAEbCW\n\tuXrcWri37NhmgVXiQT9qI0nTy3lHl1dwead59WmVwh7geQyE=","X-Google-Smtp-Source":"AGHT+IFQVe/OcOAfDRxeLd4/oCIFE6A7WjHeoaY89sZf/oO8CXoO0IbNul3S39xzhMsRtwbSLseKEwlx8M9P9QZIaXU=","X-Received":"by 2002:a2e:908a:0:b0:2ef:2d3a:e70a with SMTP id\n\t38308e7fff4ca-2f153100b36mr10093801fa.18.1722498002767;\n\tThu, 01 Aug 2024 00:40:02 -0700 (PDT)","MIME-Version":"1.0","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>\n\t<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>\n\t<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>\n\t<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>\n\t<20240731134143.GA29266@pendragon.ideasonboard.com>","In-Reply-To":"<20240731134143.GA29266@pendragon.ideasonboard.com>","From":"Cheng-Hao Yang <chenghaoyang@chromium.org>","Date":"Thu, 1 Aug 2024 15:39:51 +0800","Message-ID":"<CAEB1ahvXMBD1rDXAvQao0_=uO9MS2VZJv7jDxKuK+Ou09rbVBg@mail.gmail.com>","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"Kieran Bingham <kieran.bingham@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Content-Type":"multipart/alternative; boundary=\"00000000000094e25c061e9a5158\"","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":30537,"web_url":"https://patchwork.libcamera.org/comment/30537/","msgid":"<20240801084639.GB5738@pendragon.ideasonboard.com>","date":"2024-08-01T08:46:39","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":2,"url":"https://patchwork.libcamera.org/api/people/2/","name":"Laurent Pinchart","email":"laurent.pinchart@ideasonboard.com"},"content":"On Thu, Aug 01, 2024 at 03:39:51PM +0800, Cheng-Hao Yang wrote:\n> On Wed, Jul 31, 2024 at 9:42 PM Laurent Pinchart wrote:\n> > On Mon, Jul 29, 2024 at 04:03:05PM +0100, Kieran Bingham wrote:\n> > > Quoting Cheng-Hao Yang (2024-07-26 12:41:40)\n> > > > On Fri, Jul 26, 2024 at 6:56 PM Kieran Bingham wrote:\n> > > > > Quoting Harvey Yang (2024-07-26 10:54:21)\n> > > > > > Hi folks,\n> > > > > >\n> > > > > > Sorry for the super late update. It's been a while since the last series\n> > > > > > of patches, as we were busy with mtkisp7's bringup & migration.\n> > > > > >\n> > > > > > Thanks to Hans de Goede's work on DmaBufAllocator, the prerequisites of\n> > > > > > VirtualPipelineHandler are almost landed. Only a helper function added\n> > > > > > in the first patch.\n> > > > >\n> > > > > Excellent, Yes - I had this virtual pipeline work in mind as well when\n> > > > > the buffer allocator landed!\n> > > > >\n> > > > > I've just tried to run this and built locally then tried to run but I\n> > > > > get:\n> > > > >\n> > > > > kbingham@Monstersaurus:~/iob/libcamera/libcamera$\n> > > > > ./build/gcc/src/apps/cam/cam --list\n> > > > > [686:32:50.927990678] [2690143]  INFO IPAManager ipa_manager.cpp:143 libcamera is not installed. Adding '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA search path\n> > > > > [686:32:50.933827146] [2690143]  INFO Camera camera_manager.cpp:313 libcamera v0.3.1+7-e4713a22\n> > > > > [686:32:51.016903716] [2690146]  WARN CameraSensorProperties camera_sensor_properties.cpp:283 No static properties available for 'Sensor B'\n> > > > > [686:32:51.016924335] [2690146]  WARN CameraSensorProperties camera_sensor_properties.cpp:285 Please consider updating the camera sensor properties database\n> > > > > [686:32:51.016941437] [2690146]  WARN CameraSensor camera_sensor.cpp:479 'Sensor B': Failed to retrieve the camera location\n> > > > > [686:32:51.016953209] [2690146]  WARN CameraSensor camera_sensor.cpp:501 'Sensor B': Rotation control not available, default to 0 degrees\n> > > > > [686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130 libcamera is not installed. Loading IPA configuration from '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n> > > > > [686:32:51.019729155] [2690146] ERROR DmaBufAllocator dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n> > > >\n> > > > JFYI, currently virtual pipeline handler uses the default type\n> > > > `DmaBufAllocatorFlag::CmaHeap`. If none of the dma heaps or udmabuf are\n> > > > available, we can use memfd_create [1] to allocate local memory.\n> > > >\n> > > > [1]: https://chromium-review.googlesource.com/c/chromiumos/third_party/libcamera/+/4739525/2\n> > > >\n> > > > > [686:32:51.020135800] [2690146]  INFO Pipeline pipeline_handler.cpp:575\n> > > > > libcamera is not installed. Loading platform configuration file from\n> > > > > '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\n> > > > > terminate called after throwing an instance of\n> > > > > 'std::filesystem::__cxx11::filesystem_error'\n> > > > >   what():  filesystem error: directory iterator cannot open directory: No\n> > > > > such file or directory [files/libcamera_short_anime/]\n> > > > > Aborted (core dumped)\n> > > >\n> > > > The virtual pipeline handler has a config file\n> > > > `src/libcamera/pipeline/virtual/data/virtual.yaml` to load and config the\n> > > > cameras listed. In the current default yaml (We can discuss what should be\n> > > > the default config file though) expects `files/libcamera_short_anime/` (I\n> > > > believe it's the relative path from which you run libcamera) to contain at\n> > > > least one `0.jpg` (and `1.jpg`, `2.jpg`, ...) to support camera `Virtual0`;\n> > > > `files/bike-min.jpg` to support camera `Virtual1`;\n> > > > `files/chrome_anniversary.jpg` to support camera `Virtual5`. For the\n> > > > formats and details, please check\n> > > > `src/libcamera/pipeline/virtual/README.md`.\n> > > >\n> > > > I also need your opinions: maybe we should upload some images used in the\n> > > > sample yaml config file in the patch?\n> > >\n> > > I don't know if you should upload files, but if it requires files then\n> > > they need to be there!\n> > >\n> > > The files perhaps should be an optional additional feature - with fall\n> > > back to a (simple) test pattern generator perhaps?\n> >\n> > That's what I was about to propose, so I think it's a good idea.\n> >\n> >\n> Hmm, I still find it weird to have a fallback mechanism if an image file\n> is not installed as the configuration file indicates.\n> \n> If you still think that it's a proper mechanism, how about we add it in\n> another series of patches? We might also need to discuss the format\n> and fields of the configuration file.\n\nI don't see it as much as a fallback than a default behaviour. I don't\nthink we should have a set of images in the source tree for the virtual\npipeline handler. The default configuration file should enable a TPG,\nand users can optionally modify the configuration and add their own\nimages if they desire.\n\n> > > > Does it have to be installed to run? Is there anything else missing?\n> > >\n> > > It should be possible to run without being installed.\n> > >\n> > > I've pushed this branch to the CI and it fails in many of the instances:\n> > >\n> > >  - https://gitlab.freedesktop.org/camera/libcamera/-/pipelines/1235732\n> > >\n> > > It might be worth making a fork of\n> > > https://gitlab.freedesktop.org/camera/libcamera for yourself on gitlab\n> > > so that you can run the integration tests while developing. But I'm\n> > > happy to push any patches you send to the list and report the CI url for\n> > > you. (I do expect that to be automated 'soon'*)\n> > >\n> > > * Soon is such a hard term to define ;-)\n> > >\n> > > > > > Konami, our intern in 2023, helped to add test patterns and real image\n> > > > > > loading into VirtualPipelineHandler.\n> > > > > >\n> > > > > > I tried to address the previous comments, while it's very likely that I\n> > > > > > left some behind. Please leave the comments again if I do. Many thanks!\n> > > > > >\n> > > > > >\n> > > > > > BR,\n> > > > > > Harvey\n> > > > > >\n> > > > > > Harvey Yang (3):\n> > > > > >   Add a helper function exportFrameBuffers in DmaBufAllocator to make it\n> > > > > >     easier to use.\n> > > > > >   The Fatal check of having at least one MediaDevice was to prevent\n> > > > > >     pipeline handler implementations searching and owning media devices\n> > > > > >     with custom conventions, instead of using the base function\n> > > > > >     |acquireMediaDevice|. It also has the assumption that there's at\n> > > > > >     least one media device to make a camera work.\n> > > > > >   libcamera: pipeline: Add VirtualPipelineHandler\n> > > > > >\n> > > > > > Konami Shu (4):\n> > > > > >   libcamera: pipeline: Add test pattern for VirtualPipelineHandler\n> > > > > >   libcamera: pipeline: Read config and register cameras based on the\n> > > > > >     config\n> > > > > >   libcamera: pipeline: Shift test pattern by 1 pixel left every frame\n> > > > > >   libcamera: pipeline: Load images\n> > > > > >\n> > > > > >  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n> > > > > >  meson.build                                   |   1 +\n> > > > > >  meson_options.txt                             |   3 +-\n> > > > > >  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n> > > > > >  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n> > > > > >  .../pipeline/virtual/common_functions.cpp     |  27 ++\n> > > > > >  .../pipeline/virtual/common_functions.h       |  18 ++\n> > > > > >  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n> > > > > >  .../pipeline/virtual/frame_generator.h        |  33 +++\n> > > > > >  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n> > > > > >  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n> > > > > >  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n> > > > > >  src/libcamera/pipeline/virtual/parser.cpp     | 243 +++++++++++++++\n> > > > > >  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n> > > > > >  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n> > > > > >  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n> > > > > >  src/libcamera/pipeline/virtual/virtual.cpp    | 279 ++++++++++++++++++\n> > > > > >  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n> > > > > >  src/libcamera/pipeline_handler.cpp            |  11 +-\n> > > > > >  19 files changed, 1404 insertions(+), 6 deletions(-)\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/README.md\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.cpp\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/common_functions.h\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/data/virtual.yaml\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/frame_generator.h\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/image_frame_generator.cpp\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/image_frame_generator.h\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/test_pattern_generator.h\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n> > > > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.h","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 72E4BC323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu,  1 Aug 2024 08:47:04 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 3F94263381;\n\tThu,  1 Aug 2024 10:47:03 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 878F96336E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu,  1 Aug 2024 10:47:01 +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 ESMTPSA id 99E6C667;\n\tThu,  1 Aug 2024 10:46:12 +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=\"n9ol4+O0\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1722501972;\n\tbh=N5Zd00ONVIWVxw6cMwYAUrOrbuLPFpeZlBlxgdCoJjg=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=n9ol4+O0EYAntMT5jSYP1X/COcpHk7H7mEEjhfiPj861lPcH4hEmjP154FLnuSZ5w\n\tx8m8IwNjvmUgnjr2mveFB4X4ecb+PZlV954tebs8q99UPjrbYBbnWOXlbEA2WZFQ2y\n\tf/G/TwmL/L9IeUgH96+0eIVeul+ElfmZ/1DnalPE=","Date":"Thu, 1 Aug 2024 11:46:39 +0300","From":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","To":"Cheng-Hao Yang <chenghaoyang@chromium.org>","Cc":"Kieran Bingham <kieran.bingham@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","Message-ID":"<20240801084639.GB5738@pendragon.ideasonboard.com>","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>\n\t<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>\n\t<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>\n\t<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>\n\t<20240731134143.GA29266@pendragon.ideasonboard.com>\n\t<CAEB1ahvXMBD1rDXAvQao0_=uO9MS2VZJv7jDxKuK+Ou09rbVBg@mail.gmail.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","Content-Transfer-Encoding":"8bit","In-Reply-To":"<CAEB1ahvXMBD1rDXAvQao0_=uO9MS2VZJv7jDxKuK+Ou09rbVBg@mail.gmail.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":30611,"web_url":"https://patchwork.libcamera.org/comment/30611/","msgid":"<CAEB1ahvB+rB+V7Fpg1j-gCEWA8+KbTzRtnc2jSesOP2is-yAgw@mail.gmail.com>","date":"2024-08-06T07:09:10","subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","submitter":{"id":117,"url":"https://patchwork.libcamera.org/api/people/117/","name":"Cheng-Hao Yang","email":"chenghaoyang@chromium.org"},"content":"Hi Laurent and Kieran,\n\nOn Thu, Aug 1, 2024 at 10:47 AM Laurent Pinchart <\nlaurent.pinchart@ideasonboard.com> wrote:\n\n> On Thu, Aug 01, 2024 at 03:39:51PM +0800, Cheng-Hao Yang wrote:\n> > On Wed, Jul 31, 2024 at 9:42 PM Laurent Pinchart wrote:\n> > > On Mon, Jul 29, 2024 at 04:03:05PM +0100, Kieran Bingham wrote:\n> > > > Quoting Cheng-Hao Yang (2024-07-26 12:41:40)\n> > > > > On Fri, Jul 26, 2024 at 6:56 PM Kieran Bingham wrote:\n> > > > > > Quoting Harvey Yang (2024-07-26 10:54:21)\n> > > > > > > Hi folks,\n> > > > > > >\n> > > > > > > Sorry for the super late update. It's been a while since the\n> last series\n> > > > > > > of patches, as we were busy with mtkisp7's bringup & migration.\n> > > > > > >\n> > > > > > > Thanks to Hans de Goede's work on DmaBufAllocator, the\n> prerequisites of\n> > > > > > > VirtualPipelineHandler are almost landed. Only a helper\n> function added\n> > > > > > > in the first patch.\n> > > > > >\n> > > > > > Excellent, Yes - I had this virtual pipeline work in mind as\n> well when\n> > > > > > the buffer allocator landed!\n> > > > > >\n> > > > > > I've just tried to run this and built locally then tried to run\n> but I\n> > > > > > get:\n> > > > > >\n> > > > > > kbingham@Monstersaurus:~/iob/libcamera/libcamera$\n> > > > > > ./build/gcc/src/apps/cam/cam --list\n> > > > > > [686:32:50.927990678] [2690143]  INFO IPAManager\n> ipa_manager.cpp:143 libcamera is not installed. Adding\n> '/home/kbingham/iob/libcamera/libcamera/build/gcc/src/ipa' to the IPA\n> search path\n> > > > > > [686:32:50.933827146] [2690143]  INFO Camera\n> camera_manager.cpp:313 libcamera v0.3.1+7-e4713a22\n> > > > > > [686:32:51.016903716] [2690146]  WARN CameraSensorProperties\n> camera_sensor_properties.cpp:283 No static properties available for 'Sensor\n> B'\n> > > > > > [686:32:51.016924335] [2690146]  WARN CameraSensorProperties\n> camera_sensor_properties.cpp:285 Please consider updating the camera sensor\n> properties database\n> > > > > > [686:32:51.016941437] [2690146]  WARN CameraSensor\n> camera_sensor.cpp:479 'Sensor B': Failed to retrieve the camera location\n> > > > > > [686:32:51.016953209] [2690146]  WARN CameraSensor\n> camera_sensor.cpp:501 'Sensor B': Rotation control not available, default\n> to 0 degrees\n> > > > > > [686:32:51.019533566] [2690146]  INFO IPAProxy ipa_proxy.cpp:130\n> libcamera is not installed. Loading IPA configuration from\n> '/home/kbingham/iob/libcamera/libcamera/src/ipa/vimc/data'\n> > > > > > [686:32:51.019729155] [2690146] ERROR DmaBufAllocator\n> dma_buf_allocator.cpp:121 Could not open any dma-buf provider\n> > > > >\n> > > > > JFYI, currently virtual pipeline handler uses the default type\n> > > > > `DmaBufAllocatorFlag::CmaHeap`. If none of the dma heaps or\n> udmabuf are\n> > > > > available, we can use memfd_create [1] to allocate local memory.\n> > > > >\n> > > > > [1]:\n> https://chromium-review.googlesource.com/c/chromiumos/third_party/libcamera/+/4739525/2\n> > > > >\n> > > > > > [686:32:51.020135800] [2690146]  INFO Pipeline\n> pipeline_handler.cpp:575\n> > > > > > libcamera is not installed. Loading platform configuration file\n> from\n> > > > > >\n> '/home/kbingham/iob/libcamera/libcamera/src/libcamera/pipeline/virtual/data/virtual.yaml'\n> > > > > > terminate called after throwing an instance of\n> > > > > > 'std::filesystem::__cxx11::filesystem_error'\n> > > > > >   what():  filesystem error: directory iterator cannot open\n> directory: No\n> > > > > > such file or directory [files/libcamera_short_anime/]\n> > > > > > Aborted (core dumped)\n> > > > >\n> > > > > The virtual pipeline handler has a config file\n> > > > > `src/libcamera/pipeline/virtual/data/virtual.yaml` to load and\n> config the\n> > > > > cameras listed. In the current default yaml (We can discuss what\n> should be\n> > > > > the default config file though) expects\n> `files/libcamera_short_anime/` (I\n> > > > > believe it's the relative path from which you run libcamera) to\n> contain at\n> > > > > least one `0.jpg` (and `1.jpg`, `2.jpg`, ...) to support camera\n> `Virtual0`;\n> > > > > `files/bike-min.jpg` to support camera `Virtual1`;\n> > > > > `files/chrome_anniversary.jpg` to support camera `Virtual5`. For\n> the\n> > > > > formats and details, please check\n> > > > > `src/libcamera/pipeline/virtual/README.md`.\n> > > > >\n> > > > > I also need your opinions: maybe we should upload some images used\n> in the\n> > > > > sample yaml config file in the patch?\n> > > >\n> > > > I don't know if you should upload files, but if it requires files\n> then\n> > > > they need to be there!\n> > > >\n> > > > The files perhaps should be an optional additional feature - with\n> fall\n> > > > back to a (simple) test pattern generator perhaps?\n> > >\n> > > That's what I was about to propose, so I think it's a good idea.\n> > >\n> > >\n> > Hmm, I still find it weird to have a fallback mechanism if an image file\n> > is not installed as the configuration file indicates.\n> >\n> > If you still think that it's a proper mechanism, how about we add it in\n> > another series of patches? We might also need to discuss the format\n> > and fields of the configuration file.\n>\n> I don't see it as much as a fallback than a default behaviour. I don't\n> think we should have a set of images in the source tree for the virtual\n> pipeline handler. The default configuration file should enable a TPG,\n> and users can optionally modify the configuration and add their own\n> images if they desire.\n>\n>\nI agree that we might not want a set of images in the source tree.\n\nJust to clarify: in the latest patches, the default configuration file only\nuses TPGs, and yes, users can optionally modify the config file and\nadd images.\n\nI thought that Kieran and you want the config file to support a camera\nwith both TPG and an image generator, and use the latter if the images\nare in the data path. Maybe I misunderstood.\n\nBR,\nHarvey\n\n> > > > Does it have to be installed to run? Is there anything else missing?\n> > > >\n> > > > It should be possible to run without being installed.\n> > > >\n> > > > I've pushed this branch to the CI and it fails in many of the\n> instances:\n> > > >\n> > > >  -\n> https://gitlab.freedesktop.org/camera/libcamera/-/pipelines/1235732\n> > > >\n> > > > It might be worth making a fork of\n> > > > https://gitlab.freedesktop.org/camera/libcamera for yourself on\n> gitlab\n> > > > so that you can run the integration tests while developing. But I'm\n> > > > happy to push any patches you send to the list and report the CI url\n> for\n> > > > you. (I do expect that to be automated 'soon'*)\n> > > >\n> > > > * Soon is such a hard term to define ;-)\n> > > >\n> > > > > > > Konami, our intern in 2023, helped to add test patterns and\n> real image\n> > > > > > > loading into VirtualPipelineHandler.\n> > > > > > >\n> > > > > > > I tried to address the previous comments, while it's very\n> likely that I\n> > > > > > > left some behind. Please leave the comments again if I do.\n> Many thanks!\n> > > > > > >\n> > > > > > >\n> > > > > > > BR,\n> > > > > > > Harvey\n> > > > > > >\n> > > > > > > Harvey Yang (3):\n> > > > > > >   Add a helper function exportFrameBuffers in DmaBufAllocator\n> to make it\n> > > > > > >     easier to use.\n> > > > > > >   The Fatal check of having at least one MediaDevice was to\n> prevent\n> > > > > > >     pipeline handler implementations searching and owning\n> media devices\n> > > > > > >     with custom conventions, instead of using the base function\n> > > > > > >     |acquireMediaDevice|. It also has the assumption that\n> there's at\n> > > > > > >     least one media device to make a camera work.\n> > > > > > >   libcamera: pipeline: Add VirtualPipelineHandler\n> > > > > > >\n> > > > > > > Konami Shu (4):\n> > > > > > >   libcamera: pipeline: Add test pattern for\n> VirtualPipelineHandler\n> > > > > > >   libcamera: pipeline: Read config and register cameras based\n> on the\n> > > > > > >     config\n> > > > > > >   libcamera: pipeline: Shift test pattern by 1 pixel left\n> every frame\n> > > > > > >   libcamera: pipeline: Load images\n> > > > > > >\n> > > > > > >  .../libcamera/internal/dma_buf_allocator.h    |  10 +\n> > > > > > >  meson.build                                   |   1 +\n> > > > > > >  meson_options.txt                             |   3 +-\n> > > > > > >  src/libcamera/dma_buf_allocator.cpp           |  57 +++-\n> > > > > > >  src/libcamera/pipeline/virtual/README.md      |  76 +++++\n> > > > > > >  .../pipeline/virtual/common_functions.cpp     |  27 ++\n> > > > > > >  .../pipeline/virtual/common_functions.h       |  18 ++\n> > > > > > >  .../pipeline/virtual/data/virtual.yaml        |  51 ++++\n> > > > > > >  .../pipeline/virtual/frame_generator.h        |  33 +++\n> > > > > > >  .../virtual/image_frame_generator.cpp         | 154 ++++++++++\n> > > > > > >  .../pipeline/virtual/image_frame_generator.h  |  65 ++++\n> > > > > > >  src/libcamera/pipeline/virtual/meson.build    |  32 ++\n> > > > > > >  src/libcamera/pipeline/virtual/parser.cpp     | 243\n> +++++++++++++++\n> > > > > > >  src/libcamera/pipeline/virtual/parser.h       |  48 +++\n> > > > > > >  .../virtual/test_pattern_generator.cpp        | 148 ++++++++++\n> > > > > > >  .../pipeline/virtual/test_pattern_generator.h |  58 ++++\n> > > > > > >  src/libcamera/pipeline/virtual/virtual.cpp    | 279\n> ++++++++++++++++++\n> > > > > > >  src/libcamera/pipeline/virtual/virtual.h      |  96 ++++++\n> > > > > > >  src/libcamera/pipeline_handler.cpp            |  11 +-\n> > > > > > >  19 files changed, 1404 insertions(+), 6 deletions(-)\n> > > > > > >  create mode 100644 src/libcamera/pipeline/virtual/README.md\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/common_functions.cpp\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/common_functions.h\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/data/virtual.yaml\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/frame_generator.h\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/image_frame_generator.cpp\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/image_frame_generator.h\n> > > > > > >  create mode 100644 src/libcamera/pipeline/virtual/meson.build\n> > > > > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.cpp\n> > > > > > >  create mode 100644 src/libcamera/pipeline/virtual/parser.h\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/test_pattern_generator.cpp\n> > > > > > >  create mode 100644\n> src/libcamera/pipeline/virtual/test_pattern_generator.h\n> > > > > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.cpp\n> > > > > > >  create mode 100644 src/libcamera/pipeline/virtual/virtual.h\n>\n> --\n> Regards,\n>\n> Laurent Pinchart\n>","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 81BC7C323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue,  6 Aug 2024 07:09:25 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 3ED5A63398;\n\tTue,  6 Aug 2024 09:09:24 +0200 (CEST)","from mail-lj1-x231.google.com (mail-lj1-x231.google.com\n\t[IPv6:2a00:1450:4864:20::231])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id BF0DA6337E\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue,  6 Aug 2024 09:09:22 +0200 (CEST)","by mail-lj1-x231.google.com with SMTP id\n\t38308e7fff4ca-2ef2fbf1d14so61269001fa.1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tTue, 06 Aug 2024 00:09:22 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=chromium.org header.i=@chromium.org\n\theader.b=\"M/mXoq8O\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=chromium.org; s=google; t=1722928162; x=1723532962;\n\tdarn=lists.libcamera.org; \n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:from:to:cc:subject:date:message-id:reply-to;\n\tbh=sxbepMdn9xXXzTEUb2iuH/sbtvlYPved4UxXRHgFwYM=;\n\tb=M/mXoq8On0Aq91+oN+L42guRihzHK5x7/L0SNQ7h7KPnGuQ1+o15QXdX9zWbANpv0K\n\t0XII86kSc69InhP/wZzPaRnmlamsWe9CWb1KRFNsXqdSPsXWJ6dESTf8dzxhQ45fidW+\n\tBz/bMjhyrT58dF3rKBGUA9Sh7C6Ls8KQCUbzI=","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1722928162; x=1723532962;\n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=sxbepMdn9xXXzTEUb2iuH/sbtvlYPved4UxXRHgFwYM=;\n\tb=AYATQhQhtk5J8kfPn0EqsCBvCtMTgQGPfcAc1hBdvxkF3Q3jp6OqvgkyQvcawEIhAd\n\tkuQpMzjW0zdaZQh8UJIr79O9Rm8HhjXHNBC28LuXoI3o4oFCF4AWDxFLF9pi0nQHF8e8\n\t4okoTqxsdBbWefn0VZwQ1CuUlnzT7dbQKZRNggbUFblrQkqM7D7EW6jiLq9lIR8/Ymsw\n\tTQnAZz8arSo/48+V5IWjr/Ba6A2+4HUqfsD7v2YrJXtk2np7Cn1mg5DztRbfn+BlOCk5\n\tM5nf5Ip4eKb65WFc/7/IDApsb7DY93+AmKsbC81zSERIBypX6Maf1VVwtvKlP/FTO5yZ\n\te3/A==","X-Forwarded-Encrypted":"i=1;\n\tAJvYcCX+b8MiQ63RTKR6W5UryeBUN+BiRweHhrrzNIh0y61GOOdg+a2OtOFv8WitIcqQnPQC2/dZ46iHApjuHE5YsDJv0Rd3z44lzAZTP+mgf5CbXTFZlg==","X-Gm-Message-State":"AOJu0YzWJJLFk66oxVDdGj6z8RXjZwqPzT4fqutOinHhO+GhAQUz4wWC\n\tx4y/y82ZMMrlmEygfq6Vyfm0QUI71ehnqsv5LlbWcNCwqORXMLe0S2NAabKBRqJ/03UNi7v5GxO\n\ti4RS5qOIxTLvQNvmY2FZdhzzcapW+QMx31Ey0TxJN2ltaopRZr7Q3","X-Google-Smtp-Source":"AGHT+IE/HeGTaZtvtAwGDv8bOEqCEyP5R/mowlqNkesZsNBuzAEPMRScdNSHu5QS2PJEMzUAnhpF1+KN717XZPpphSU=","X-Received":"by 2002:a2e:95d9:0:b0:2ef:2b67:58bc with SMTP id\n\t38308e7fff4ca-2f15b186889mr41059621fa.22.1722928161431;\n\tTue, 06 Aug 2024 00:09:21 -0700 (PDT)","MIME-Version":"1.0","References":"<20240726095626.3632402-1-chenghaoyang@chromium.org>\n\t<172199137091.392292.9161523521470848904@ping.linuxembedded.co.uk>\n\t<CAEB1ahtr3YQS4KnHz7U_2e1T38C0ZWt2zFjrGy6QVv5ogaACJQ@mail.gmail.com>\n\t<172226538565.392292.10964154777651018960@ping.linuxembedded.co.uk>\n\t<20240731134143.GA29266@pendragon.ideasonboard.com>\n\t<CAEB1ahvXMBD1rDXAvQao0_=uO9MS2VZJv7jDxKuK+Ou09rbVBg@mail.gmail.com>\n\t<20240801084639.GB5738@pendragon.ideasonboard.com>","In-Reply-To":"<20240801084639.GB5738@pendragon.ideasonboard.com>","From":"Cheng-Hao Yang <chenghaoyang@chromium.org>","Date":"Tue, 6 Aug 2024 09:09:10 +0200","Message-ID":"<CAEB1ahvB+rB+V7Fpg1j-gCEWA8+KbTzRtnc2jSesOP2is-yAgw@mail.gmail.com>","Subject":"Re: [PATCH v6 0/7] Add VirtualPipelineHandler","To":"Laurent Pinchart <laurent.pinchart@ideasonboard.com>","Cc":"Kieran Bingham <kieran.bingham@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Content-Type":"multipart/alternative; boundary=\"0000000000000939b9061efe7919\"","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>"}}]