Message ID | 20240522203924.1111388-3-nicolas@ndufresne.ca |
---|---|
State | Superseded |
Headers | show |
Series |
|
Related | show |
Quoting Nicolas Dufresne (2024-05-22 21:39:24) > From: Nicolas Dufresne <nicolas.dufresne@collabora.com> > > This adds documentation and an example using gst-launch-1.0. > > Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com> > --- > README.rst | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) > > diff --git a/README.rst b/README.rst > index 1da7a3d6..d605182b 100644 > --- a/README.rst > +++ b/README.rst > @@ -178,6 +178,22 @@ Which can be received on another device over the network with: > gst-launch-1.0 tcpclientsrc host=$DEVICE_IP port=5000 ! \ > multipartdemux ! jpegdec ! autovideosink > > +The GStreamer element also supports multiple streams. This is achieved by > +requesting additionnal source pads. Downstream caps filteris can be used s/additionnal/additional/ s/filteris/filters/ > +to choose specific parameters like resolution and pixel format. The pad > +property ``stream-role`` can be used to select a role. > + > +The following example displayis a 640x480 view finder while streamiing JPEG s/displayis/displays/ > +encoded 800x600 video. You can use the receiver pipleine above to view the > +remote stream from another device. > + > +.. code:: > + > + gst-launch-1.0 libcamerasrc name=cs src::stream-role=view-finder src_0::stream-role=video-recording \ > + cs.src ! queue ! video/x-raw,width=640,height=480 ! videoconvert ! autovideosink \ > + cs.src_0 ! queue ! video/x-raw,width=800,height=600 ! videoconvert ! \ > + jpegenc ! multipartmux ! tcpserversink host=0.0.0.0 port=5000 > + Awesome - thank you - that demonstrates one of the purposes of multiple stream support - and how to use it with gstreamer! Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> > .. section-end-getting-started > > Troubleshooting > -- > 2.45.0 >
Hi Nicolas, Nice! I was wondering how to accomplish exactly this, thanks for the documentation. In addition to what Kieran said: On 5/22/24 22:39, Nicolas Dufresne wrote: > From: Nicolas Dufresne <nicolas.dufresne@collabora.com> > > This adds documentation and an example using gst-launch-1.0. > > Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com> > --- > README.rst | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) > > diff --git a/README.rst b/README.rst > index 1da7a3d6..d605182b 100644 > --- a/README.rst > +++ b/README.rst > @@ -178,6 +178,22 @@ Which can be received on another device over the network with: > gst-launch-1.0 tcpclientsrc host=$DEVICE_IP port=5000 ! \ > multipartdemux ! jpegdec ! autovideosink > > +The GStreamer element also supports multiple streams. This is achieved by > +requesting additionnal source pads. Downstream caps filteris can be used > +to choose specific parameters like resolution and pixel format. The pad > +property ``stream-role`` can be used to select a role. > + > +The following example displayis a 640x480 view finder while streamiing JPEG s/streamiing/streaming Stuck I key on your keyboard? :-) > +encoded 800x600 video. You can use the receiver pipleine above to view the s/pipleine/pipeline Best regards, Michael > +remote stream from another device. > + > +.. code:: > + > + gst-launch-1.0 libcamerasrc name=cs src::stream-role=view-finder src_0::stream-role=video-recording \ > + cs.src ! queue ! video/x-raw,width=640,height=480 ! videoconvert ! autovideosink \ > + cs.src_0 ! queue ! video/x-raw,width=800,height=600 ! videoconvert ! \ > + jpegenc ! multipartmux ! tcpserversink host=0.0.0.0 port=5000 > + > .. section-end-getting-started > > Troubleshooting
diff --git a/README.rst b/README.rst index 1da7a3d6..d605182b 100644 --- a/README.rst +++ b/README.rst @@ -178,6 +178,22 @@ Which can be received on another device over the network with: gst-launch-1.0 tcpclientsrc host=$DEVICE_IP port=5000 ! \ multipartdemux ! jpegdec ! autovideosink +The GStreamer element also supports multiple streams. This is achieved by +requesting additionnal source pads. Downstream caps filteris can be used +to choose specific parameters like resolution and pixel format. The pad +property ``stream-role`` can be used to select a role. + +The following example displayis a 640x480 view finder while streamiing JPEG +encoded 800x600 video. You can use the receiver pipleine above to view the +remote stream from another device. + +.. code:: + + gst-launch-1.0 libcamerasrc name=cs src::stream-role=view-finder src_0::stream-role=video-recording \ + cs.src ! queue ! video/x-raw,width=640,height=480 ! videoconvert ! autovideosink \ + cs.src_0 ! queue ! video/x-raw,width=800,height=600 ! videoconvert ! \ + jpegenc ! multipartmux ! tcpserversink host=0.0.0.0 port=5000 + .. section-end-getting-started Troubleshooting