From patchwork Wed Aug 25 19:53:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kieran Bingham X-Patchwork-Id: 13492 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 91641BD87D for ; Wed, 25 Aug 2021 19:53:43 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 4DD8368893; Wed, 25 Aug 2021 21:53:43 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="LmB4rtzX"; dkim-atps=neutral Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 9F65660288 for ; Wed, 25 Aug 2021 21:53:42 +0200 (CEST) Received: from Monstersaurus.local (cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 4FAB924F; Wed, 25 Aug 2021 21:53:42 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1629921222; bh=uhrqhsGN10DIREyd3XXchpplrtTlBR8HIRElxBrv9uk=; h=From:To:Cc:Subject:Date:From; b=LmB4rtzXrb5AJZ/tNxRM2nMPXNaeFIhuRDt0SHMJ4s8BUuzhOauzQfa0UR+KCLAZG VXVkVWqhBfjJWrbtE9ue6Qb/d7xIDP+r4LqKL/S3lfUpvleaa0VPvei+RJt1yH1H29 mb1cvw0yMQD3aI969Yu3G7DLasBGBI1Tg3HB3VhE= From: Kieran Bingham To: libcamera devel Date: Wed, 25 Aug 2021 20:53:38 +0100 Message-Id: <20210825195338.185663-1-kieran.bingham@ideasonboard.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v2] README.rst: Update gstreamer element guidance X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" The Gstreamer gstlibcamerasrc element operates better with the glimagesink, as it can perform direct renders or hardware accellerated image format conversion. Further extend the sample commands to demonstrate how to specify a fixed width and height parameter to the pipeline. Signed-off-by: Kieran Bingham Reviewed-by: Laurent Pinchart Reviewed-by: Paul Elder --- README.rst | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/README.rst b/README.rst index fcf0f47f14c5..d5b36e21dec6 100644 --- a/README.rst +++ b/README.rst @@ -94,17 +94,32 @@ Using GStreamer plugin ~~~~~~~~~~~~~~~~~~~~~~ To use GStreamer plugin from source tree, set the following environment so that -GStreamer can find it. +GStreamer can find it. This isn't necessary when libcamera is installed. export GST_PLUGIN_PATH=$(pwd)/build/src/gstreamer The debugging tool ``gst-launch-1.0`` can be used to construct a pipeline and test it. The following pipeline will stream from the camera named "Camera 1" -onto the default video display element on your system. +onto the OpenGL accelerated display element on your system. .. code:: - gst-launch-1.0 libcamerasrc camera-name="Camera 1" ! videoconvert ! autovideosink + gst-launch-1.0 libcamerasrc camera-name="Camera 1" ! glimagesink + +To show the first camera found you can omit the camera-name property, or you +can identify the camera and capabilities using: + +.. code:: + + gst-device-monitor-1.0 Video + +This will also show the supported stream sizes which can be manually selected +if desired with a pipeline such as: + +.. code:: + + gst-launch-1.0 libcamerasrc ! 'video/x-raw,width=1280,height=720' ! \ + glimagesink .. section-end-getting-started