From patchwork Sun Feb 3 11:00:51 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Kieran Bingham X-Patchwork-Id: 487 Return-Path: Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 03E6B60B1B for ; Sun, 3 Feb 2019 12:01:06 +0100 (CET) Received: from localhost.localdomain (218.182-78-194.adsl-static.isp.belgacom.be [194.78.182.218]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 72A3C41; Sun, 3 Feb 2019 12:01:06 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1549191666; bh=pdR6aotjHURAE3nzNJ3s3f2u/ss+o95vqDp5CyLGci8=; h=From:To:Cc:Subject:Date:From; b=oVyEMLTYQ1oRQOJxbz2tMOGLdpj56/mZP0VOQ7x2fYxWo/AHlI6m9CkxZnXRkWaXD L2BKBlTsEMB11eyqM3FuZMlL4BKxcCg2gyilI1uL+eFy27hBpKR75CI9TjSC8Jzi84 7WVu0O7GW9f8RP6MdDv6tQ12EaVmTDBu+q/Bhy80= From: Kieran Bingham To: LibCamera Devel Date: Sun, 3 Feb 2019 12:00:51 +0100 Message-Id: <20190203110102.5663-1-kieran.bingham@ideasonboard.com> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH RFC 00/11] libcamera: V4L2 Streams X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Feb 2019 11:01:07 -0000 This extensive set of patches is still in development and so is marked RFC. The recent removal of the ability to mmap buffers with an externally provided FD (from the V4L2 device) has now broken my tests so these tests all fail at mmap(). Please don't be 'too' alarmed at that if you run the tests. This series implements first fixes up the V4L2 test base class to use the device enumerator to identify a UVCVideo device for testing with. Then support for creating a buffer pool and requesting, and queueing buffers is sketched out. Asynchronous support for the buffer notification is finally added with a signal to allow Pipeline objects (or the owner of the V4L2Device) to be able to receive completed buffers. Kieran Bingham (10): test: v4l2_device: Use DeviceEnumerator to find a UVCVideo libcamera: buffer: Support v4l2_buffer construction libcamera: v4l2_device: Request buffers from the device libcamera: v4l2_device: Support exporting buffers test: v4l2_device: Add request_buffers test libcamera: v4l2_device: Implement stream{On,Off} test: v4l2_device: Add StreamOn/StreamOff test test: v4l2_device: Add a functional capture test libcamera: v4l2_device: Add event driven buffer passing test: v4l2_device: Provide asynchronous capture test Niklas Söderlund (1): libcamera: v4l2device: update Buffer with information from v4l2_buffer when dequeueing include/libcamera/buffer.h | 18 +- src/libcamera/buffer.cpp | 27 ++ src/libcamera/include/v4l2_device.h | 35 +++ src/libcamera/v4l2_device.cpp | 381 +++++++++++++++++++++++++- test/v4l2_device/capture_async.cpp | 69 +++++ test/v4l2_device/capture_frames.cpp | 51 ++++ test/v4l2_device/meson.build | 4 + test/v4l2_device/request_buffers.cpp | 28 ++ test/v4l2_device/stream_on_off.cpp | 29 ++ test/v4l2_device/v4l2_device_test.cpp | 28 +- test/v4l2_device/v4l2_device_test.h | 7 + 11 files changed, 667 insertions(+), 10 deletions(-) create mode 100644 test/v4l2_device/capture_async.cpp create mode 100644 test/v4l2_device/capture_frames.cpp create mode 100644 test/v4l2_device/request_buffers.cpp create mode 100644 test/v4l2_device/stream_on_off.cpp