From patchwork Thu May 23 13:58:57 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kieran Bingham X-Patchwork-Id: 1269 Return-Path: Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 764A160DE9 for ; Thu, 23 May 2019 15:59:05 +0200 (CEST) Received: from localhost.localdomain (cpc89242-aztw30-2-0-cust488.18-1.cable.virginm.net [86.31.129.233]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id CE601583; Thu, 23 May 2019 15:59:04 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1558619945; bh=cL7Lj+zPewHA3DGtb2ie+gnTSg60XkliPnZf7qED8Ic=; h=From:To:Cc:Subject:Date:From; b=ER3O4ovRSjvYpwg7dzkLw5SH8VIEGCl7aTcvI1gS0oVQCgFKWGQujpI5J8H2InR8D geTAsAIz8s7gYWfWnBk/vj3ZQRHKRr/UByFSa8xTP956PW87n1AzjAC4fhe1YTIH0Y D5vvFpy3w2p1fgSv/vgnECLkal3AcpNIFKSlAh58= From: Kieran Bingham To: LibCamera Devel Date: Thu, 23 May 2019 14:58:57 +0100 Message-Id: <20190523135900.24029-1-kieran.bingham@ideasonboard.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v2 0/3] V4L2Device Try format support 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: Thu, 23 May 2019 13:59:05 -0000 Extend V4L2Device to provide a tryFormat function. This can be used to check a format against a V4L2 Device to determine a suitable configuration. Utilise this in the UVC pipeline handler so that we can validate configurations on any UVC web cam. Kieran Bingham (3): libcamera: v4l2_device: Add tryFormat support test: v4l2_device: Extend formats test with tryFromat() libcamera: pipeline: uvc: Use the device to validate formats src/libcamera/include/v4l2_device.h | 7 ++++-- src/libcamera/pipeline/uvcvideo.cpp | 36 +++++++++++++++++++++-------- src/libcamera/v4l2_device.cpp | 29 ++++++++++++++++++----- test/v4l2_device/formats.cpp | 16 +++++++++++++ 4 files changed, 70 insertions(+), 18 deletions(-)