Commit graph

583 commits

Author SHA1 Message Date
François Laignel 3b3f0c1a29 net/aws/transcriber: fix transcript-lookahead prop nick
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1136>
2023-03-14 21:11:33 +01:00
François Laignel 299e25ab3c net/aws/transcriber: translate: optional experimental translation tokenization
This commit adds an optional experimental translation tokenization feature.
It can be activated using the `translation_src_%u` pads property
`tokenization-method`. For the moment, the feature is deactivated by default.

The Translate ws accepts '<span></span>' tags in the input and adds matching
tags in the output. When an 'id' is also provided as an attribute of the
'span', the matching output tag also uses this 'id'.

In the context of close captions, the 'id's are of little use. However, we can
take advantage of the spans in the output to identify translation chunks, which
more or less reflect the rythm of the input transcript.

This commit adds simples spans (no 'id') to the input Transcript Items and
parses the resulting spans in the translated output, assigning the timestamps
and durations sequentially from the input Transcript Items. Edge cases such as
absence of spans, nested spans were observed and are handled here. Similarly,
mismatches between the number of input and output items are taken care of by
some sort of reconcialiation.

Note that this is still experimental and requires further testings.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1109>
2023-03-14 13:48:32 +00:00
François Laignel 743e97738f net/aws/transcriber: add translation request src pads
This commit adds an optional transcript translation feature implemented as
request src Pads.

When requesting a src Pad, the user can specify the translation language code
using Pad properties 'language-code'.

The following properties are defined on the Element:

- 'transcribe-latency': formerly 'latency', defines the expected latency for
  the Transcribe webservice.
- 'translate-latency': defines the expected latency for the Translate
  webservice.
- 'transcript-lookahead': maximum transcript duration to send to translation
  when a transcript is hitting its deadline and no punctuation was found.

When the input and output languages are the same, only the 'transcribe-latency'
is used for the Pad. Otherwise, the resulting latency is the addition of
'transcribe-latency' and 'translate-latency'.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1109>
2023-03-14 13:48:32 +00:00
Sebastian Dröge 4eccd30ce2 Revert "aws: Temporarily enable the default features of the test-with crate"
This reverts commit 42116b5bce.
2023-03-14 13:28:28 +02:00
Sebastian Dröge 42116b5bce aws: Temporarily enable the default features of the test-with crate
Version 0.9.4 fails compiling without them enabled.

See https://github.com/yanganto/test-with/pull/57
2023-03-14 09:19:26 +02:00
Sebastian Dröge c1bac30694 webrtc: Update to aws 0.54/0.24
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1131>
2023-03-11 09:37:14 +02:00
Mathieu Duponchelle 584392049c net/webrtc: implement AWS KVS signaller
And expose a wrapper webrtcsink variant, aws-kvs-webrtcsink.

This adds support in webrtcsink for processing a consumer offer, instead
of producing one.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1114>
2023-03-09 15:39:09 +00:00
Sebastian Dröge fc5ed15af5 Update for gst::Element::link_many() and related API generalization
Specifically, get rid of now unneeded `&`.
2023-03-09 16:46:52 +02:00
François Laignel b9cd71d8eb net/aws/transcriber: fix eos not being sent
For eos to be sent from the srcpad task loop, we need to go through `dequeue`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1122>
2023-03-09 13:07:03 +01:00
François Laignel 2ea9f147ab net/aws/transcriber: fix deadlock when the pipeline is interrupted
... also makes sure to abort the taks_iter Future.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1122>
2023-03-09 13:07:03 +01:00
Sebastian Dröge 3ef8a48ded Fix a few new clippy warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1120>
2023-03-07 08:47:01 +00:00
Vivia Nikolaidou cd74d01324 ndisinkcombiner: Properly handle caps changes
We are caching one video buffer, so previously we were changing the src
caps one buffer too early.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1110>
2023-03-01 12:30:54 +00:00
François Laignel 4a988aaeb8 net/aws/transcriber: use a TranscriberLoop struct
This helps gather together the details related to the `TranscriberLoop`.
One difference with previous implementation is that the ws `Client` is
build each time the loop is started instead of being reused. With the new
approach, we don't keep the connection open after EOS and we should be
more resistant in case of a connection failure.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1104>
2023-03-01 08:47:58 +00:00
François Laignel f1a080c94e net/aws/transcriber: own transcription items
So that we can avoid copying the content.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1104>
2023-03-01 08:47:58 +00:00
François Laignel 36ae29d746 net/aws: enqueue transcribed buffers within the ws loop
Instead of sending transcription events to the src pad loop, this commit
enqueues the transcribed buffers immediately in the ws loop, then notifies
the src pad loop. The src pad loop is only in charge of dequeuing the buffers.

This should help with upcoming evolutions.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1104>
2023-03-01 08:47:58 +00:00
François Laignel 00153754bb net/aws: use aws-sdk-transcribestreaming
Switch from manual webservice client impl to `aws-sdk-transcribestreaming`.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1104>
2023-03-01 08:47:58 +00:00
François Laignel 57f365979c net/aws: remove aws_ from the aws_transcribe* folder names
Those folders reside under `aws`, so there's shouldn't be any confusion.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1104>
2023-03-01 08:47:58 +00:00
Thibault Saunier ce3bb2f1d4 Add a webrtcsrc element
Updating the docker image to include:
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3236

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/932>
2023-02-28 20:50:15 -03:00
Thibault Saunier 0ae637f531 webrtcsink: Move RUNTIME to the crate so it can be reused
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/932>
2023-02-28 17:57:14 -03:00
Thibault Saunier 4ec441560b webrtc: Enhance debug messages when using unknown peer ID
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/932>
2023-02-28 19:28:51 +00:00
Matthew Waters 542c7e12b8 webrtcsink: also support nvvidconv in lieu of nvvideoconvert
nvvideoconvert may not exist and nvvidconv might on some Jetson
platforms.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1107>
2023-02-28 10:12:36 +11:00
Sebastian Dröge 9fc1404415 Update minimum supported Rust version to 1.66
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1096>
2023-02-20 11:09:01 +02:00
Arun Raghavan 487d7fb26b hlssink3: Allow GIOStream signal handlers to return None
If creating a playlist or fragment stream fails (disk is full, the
directory is removed, ...), we will currently crash because the signal
handler expects a non-None GIOStream. The actual callback is allowed to
return None values and we handle this in the caller, so let's not have
this restriction on the signal handler.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1093>
2023-02-14 11:25:44 -05:00
Sebastian Dröge 04e101c605 Optimize various error message / debug message formatting
Directly make use of format strings instead of formatting a string
beforehand and then passing it to the macros.
2023-02-13 11:50:57 +02:00
Arun Raghavan 39e0acb55a hlssink3: Fix case on unspecified playlist type nick for consistency
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1089>
2023-02-10 23:07:12 +00:00
Seungha Yang 6420fe43da rtpav1pay: Fix Leb128Bytes size parsing
There are multiple ways of encoding the value, and don't assume
that bitstream used the way used in this plugin. Instead, count
the number of used bytes.

Fixes: https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/312
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1090>
2023-02-10 18:47:52 +00:00
Sebastian Dröge ac8afc4ac0 Update to async-tungstenite 0.20
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1087>
2023-02-10 13:03:07 +02:00
Sebastian Dröge 1e13dbb99c Update versions to 0.11.0-alpha.1 2023-02-10 00:23:56 +02:00
rajneeshksoni 994c79569e awss3sink: Add properties to set content-Type and content-disposition.
for uploaded object default content-type is set to binary/octet-stream,
which is correct.
metadata cannot be used to set content-type and content-disposition as
setting metadata add a prefix x-amz-meta to key
e.g. setting metadate "content-type=video/mp4" actually set value as
x-amz-meta-content-type. So these has to be seaprate property.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1085>
2023-02-09 19:04:07 +00:00
rajneeshksoni 0f383a6545 hlssink3: Allow setting i-frame-only playlist.
HLS allows manifest where all segments are single ifames.
This manifest requires `EXT-X-I-FRAMES-ONLY` tag in the
manifest.
I-FRAMES-ONLY playlist segments are video only segments.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1070>
2023-02-08 14:04:46 +00:00
Sebastian Dröge 0ed74d0aa4 rtpgccbwe: Don't use clamp() if there's no clear min/max value
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/305

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1078>
2023-02-06 21:56:46 +02:00
Sanchayan Maity 6006a0ba36 aws/s3hlssink: Fix deadlock on EOS
In state change to NULL, we take state lock and call stop. When stop
is called, we will try to upload queued segments in S3 request thread.
That tries to take the state lock again and deadlocks.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1076>
2023-02-03 19:09:18 +05:30
Sanchayan Maity 41aa1e51da aws/s3hlssink: Use factory name when checking name of child element
Commit ad3f1cf fixed the name of hlssink child element to be the same
for hlssink2 and hlssink3. However, we rely on element name to return
boolean in case of hlssink3 or None in case of hlssink2 as the return
value of the delete-fragment closure.

Fix this by using the factory name instead of the element name.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1076>
2023-02-03 19:08:40 +05:30
Sebastian Dröge 5506f8001e rtpav1pay: Add support for tu/frame aligned input
In this case every buffer can be sent out immediately and makes up a
whole frame.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1072>
2023-02-02 20:24:27 +02:00
Sebastian Dröge 194c4e9e9f rtpav1pay: Consider the marker flag to output packets immediately at the end of a frame
Otherwise it is necessary to wait for the beginning of the following
frame, which unnecessarily increases the latency.

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/255

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1072>
2023-02-02 20:24:27 +02:00
Sebastian Dröge 49350f738f rtpav1depay: Fix depayloading of packets starting with a leading OBU fragment followed by more OBUs
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/288

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1072>
2023-02-02 20:24:27 +02:00
Sebastian Dröge 1756d7a516 rtpav1depay: Fix error handling
Don't error out immediately on errors anymore but try again with the
next packet.

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/289

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1072>
2023-02-02 20:24:27 +02:00
Sebastian Dröge ed4e9a50d5 rtpav1depay: Set DISCONT flag on buffers following a corrupted packet
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1072>
2023-02-02 20:24:27 +02:00
Sebastian Dröge d6cb9d72d8 rtpav1depay: Don't output full TUs but just OBUs as they come
Simplifies state tracking and potentially reduces latency as it's not
necessary to wait until all fragments of an OBU are received.

The last OBU of a TU is marked with the marker flag to allow parsers to
detect this without first seeing the beginning of the next TU.

Also use a simple `Vec` for collecting complete OBUs instead of a
`gst_base::Adapter` as this reduces the number of allocations.

And also handle invalid packets a little bit more gracefully.

Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/244

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1072>
2023-02-02 20:24:27 +02:00
Sebastian Dröge 560bdc4cb7 Update for glib API changes 2023-01-31 12:24:07 +02:00
Sebastian Dröge a1cce9b796 aws: Update to AWS SDK 0.54/0.24
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1066>
2023-01-27 22:10:23 +02:00
Sebastian Dröge 3b4c48d9f5 Fix various new clippy warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1062>
2023-01-25 10:31:19 +02:00
Arun Raghavan ad3f1cf534 aws: s3hlssink: Fix the name of the hlssink child element
It's easier to set child element properties if the name doesn't depend
on the factory.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1061>
2023-01-24 18:56:46 +00:00
Sebastian Dröge 2c386fb792 Update for various deprecated APIs 2023-01-22 20:07:26 +02:00
Sebastian Dröge 4582ae91ab Move remaining plugins to ParamSpec builders
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1054>
2023-01-21 18:34:55 +02:00
Sebastian Dröge 458b2386ed Update for glib API changes 2023-01-21 18:13:48 +02:00
Sebastian Dröge 7cfd570c15 onvif: Update for allocation query caps API changes 2023-01-19 16:38:06 +02:00
Sebastian Dröge 812df78b75 webrtcbin: Update for StreamProducer API changes 2023-01-16 16:36:41 +02:00
Sebastian Dröge 6132788b02 Update for caps/structure-related string API changes
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1048>
2023-01-15 22:58:44 +02:00
Sebastian Dröge 0c954135a3 aws: Update to AWS SDK 0.53/0.23
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1047>
2023-01-14 18:58:30 +02:00
Mathieu Duponchelle 1a8abde884 webrtcsink: fix panic on pre-bwe request error
We dispose of consumer pipelines asynchronously, potentially after the
session objects have been disposed of.

As session objects are the owner of the cc element, it is entirely
possible for the bwe-request signal to get emitted after cc has been
disposed of, as the closure only takes a weak reference to it.

Fix by simply checking if cc is None

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1044>
2023-01-11 15:09:45 +00:00
Sebastian Dröge be72fefb18 reqwest: Update for API changes 2023-01-06 12:52:30 +02:00
Sebastian Dröge 781fd1df9a aws: Update to test-with 0.9
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1035>
2023-01-05 12:35:42 +02:00
Sebastian Dröge 27435ad82e Update for API changes 2023-01-05 12:33:54 +02:00
rajneeshksoni d846f527af awss3hlssink: Add stats property.
application can monitor the progress of hls segment generation
and upload progress.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1022>
2023-01-04 12:36:13 +00:00
Philippe Normand 0fd63ece7d rtpav1depay: Implement srcpad set_caps
Without this auto-pluggers such as decodebin or parsebin will be unable to
process AV1 RTP payloads.

Tested with: `videotestsrc num-buffers=50 ! videoconvert ! av1enc ! av1parse ! rtpav1pay ! queue ! decodebin3 ! videoconvert ! queue ! autovideosink`

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1034>
2023-01-03 19:35:45 +02:00
Zhao, Gang 9fa838e366 webrtc: Fix rustfmt errors
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1019>
2022-12-27 11:12:54 +02:00
Zhao, Gang 877a9bd7f3 webrtc: Share runtime between webrtcsink and signaller crates
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1019>
2022-12-26 23:10:40 +00:00
Zhao, Gang 1ffeb4d44d webrtc: Move from async-std to tokio
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1019>
2022-12-26 23:10:40 +00:00
Zhao, Gang 2bc29c1fd3 webrtc: examples: Update package-lock.json
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1019>
2022-12-26 23:10:40 +00:00
Sebastian Dröge 4e444a066c aws: Update to AWS SDK 0.52/0.22
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1020>
2022-12-18 07:54:30 +00:00
Mathieu Duponchelle e5360ff431 webrtc/README: update command to run the signalling server
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/277

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1012>
2022-12-13 12:47:26 +01:00
Sebastian Dröge 3f904553ea Fix various new clippy warnings
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1011>
2022-12-13 11:43:16 +02:00
Sebastian Dröge 289e8a08c3 webrtchttp: Remove unnecessary clippy warning override
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1009>
2022-12-12 14:32:12 +02:00
Sebastian Dröge fb42cd8a0f net: Update to async-tungstenite 0.19
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1005>
2022-12-11 12:54:24 +02:00
Sebastian Dröge 9b964db4c9 whipsink: Handle offer creation errors more gracefully
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 12:15:55 +02:00
Sebastian Dröge 8452cd9efa webrtchttp: Fix missing import for docs build
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 12:10:53 +02:00
Sebastian Dröge 9c31344bbc webrtchttp: Don't use let-else for now
We still support Rust 1.63.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 12:08:57 +02:00
Sebastian Dröge 5dc52975ff webrtchttp: Fix formatting
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 12:07:09 +02:00
Sanchayan Maity 40680a47ab webrtchttp: Use tokio runtime for spawning thread used for candidate offer
While at it, we had a bug in whepsrc where for redirect we were
incorrectly calling initial_post_request instead of do_post. Fix
that.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 12:27:07 +05:30
Sanchayan Maity d18761892e webrtchttp: Use a proper Rust type name for ICE transport policy
We don't need to namespace here but can just use the Rust namespaces.
Only the GType name has to stay like it is.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity 2eba3b321e webrtchttp: Do not import element_imp_error
element_imp_error and such macros should not be imported but rather
only be accessed via gst namespace.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity 0b1b8b91b9 webrtchttp: Do not block webrtcbin signal handlers for sending candidates
While at it, drop the OPTIONS request in WHIP sink. This was not really
required. See section 4.4 of the spec
https://www.ietf.org/archive/id/draft-ietf-wish-whip-01.html#name-stun-turn-server-configurat

Also introduce a new error type and distinguish between a future being
aborted or returning an error.

We call abort only during shutdown and hence except for the DELETE
resource request being aborted, other waits on future should not
be fatal.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Alba Mendez db39370701 webrtchttp: whipsink: construct TURN URL correctly
Right now the code manually pieces together the components
in a String for efficiency. When credentials contain special
characters this can result in invalid URLs, so do it the proper
way (with Url::parse + format) to make sure components are escaped
as needed.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity 9fb058d5bc webrtchttp: Drop unused dependencies
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity b5daa92c9d webrtchttp: Implement timeout for waiting on futures
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity cc7419308b webrtchttp: whipsink: Add candidates when sending the offer
WHIP endpoint providers like Cloudflare do not support Trickle ICE
and need candidates to be send along with the initial offer. Instead
of sending the offer in create-offer promise, send it once the ICE
candidates have been gathered.

While at it add properties to set STUN and TURN server along with the
ICE transport policy as at least when testing the Cloudflare WHIP
endpoint seems unreachable without it. This has also been observed
with Cloudflare provided demos.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity b992596236 webrtchttp: whipsink: Miscellaneous clean up
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity b427cb6a3d webrtchttp: Factor out the common bits for WHIP and WHEP
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Sanchayan Maity 6be5796888 Add a WebRTC WHEP source element
This implements WHEP specification based on
https://datatracker.ietf.org/doc/html/draft-murillo-whep-00

and has been tested with Cloudflare.

Server offers are likely to be removed from the WHEP specification
in upcoming revisions, to avoid compatibility issues. None of the
commercial services implementing WHEP support server initiated offers.
So we only support client side initiated offers.

Follows session setup and tear down as covered in Figure 1, Section 3
of the specification.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/949>
2022-12-05 11:04:45 +05:30
Raphael Dürscheid aa2abc50bf webrtcsink: Support nvv4l2vp9enc
Naive support for nvv4l2vp9enc by assuming configuration is equivalent
to existing nvv4l2vp8enc. Validated to have relevant properties.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/983>
2022-12-02 10:18:27 +00:00
Jordan Petridis 821c23e202 net/ndi: fix build with --no-default-features
doc_show_default() is only available with gst/v1_18

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/588>
2022-11-29 21:06:12 +02:00
Vivia Nikolaidou 5bbe0eab25 ndisrc: Use actual number of channels in positions_from_mask
Otherwise it fails for mono and stereo

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/991>
2022-11-29 12:19:45 +02:00
Vivia Nikolaidou 73ce616bd9 ndisrc: Use default channel mask for audio output
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/988>
2022-11-28 17:06:07 +02:00
Sebastian Dröge fceacf7081 Update for gst::Array / gst::List API improvements
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/985>
2022-11-27 01:12:46 +02:00
Sebastian Dröge 0e2a00cbc8 aws: Update to env_logger 0.10 for the tests
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/984>
2022-11-25 11:08:19 +02:00
Sebastian Dröge 456fb276d6 Revert "Update for pango API changes"
This reverts commit 6e54d3cea9.

The change was wrong and the pango bindings work the same as before
again.
2022-11-18 10:58:41 +02:00
Sebastian Dröge 6e54d3cea9 Update for pango API changes
pango::Language::from_string() can fail and also can accept None as
argument.
2022-11-18 09:46:50 +02:00
Thibault Saunier 6b11284e8a webrtcsink: Make the turn-server prop a turn-servers list
So that we can simply specify several turn servers at once

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/973>
2022-11-16 14:48:16 +00:00
Arun Raghavan 3abd13e57b aws: s3sink: Treat stopping without EOS as an error for multipart upload
This allows us to try to clean up based on configuration (abort /
complete / do nothing) if the pipeline is shut down without an EOS.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/970>
2022-11-15 02:28:35 +00:00
Guillaume Desmottes 37cb636140 webrtc: README: fix couple of links
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/975>
2022-11-11 14:51:46 +01:00
Mathieu Duponchelle 66e7b314f7 webrtcsink: improve debug
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/972>
2022-11-10 15:00:19 +00:00
Sebastian Dröge a5f3197651 Add missing doc features to WebRTC plugins 2022-11-07 18:06:29 +00:00
Jan Beich 9aeaac5a96 ndi: provide Unix fallback after 3fe9e4a207
error[E0425]: cannot find value `LIBRARY_NAME` in this scope
   --> net/ndi/src/ndisys.rs:336:23
    |
336 |             path.push(LIBRARY_NAME);
    |                       ^^^^^^^^^^^^ not found in this scope

error[E0425]: cannot find value `LIBRARY_NAME` in this scope
   --> net/ndi/src/ndisys.rs:339:33
    |
339 |             path::PathBuf::from(LIBRARY_NAME)
    |                                 ^^^^^^^^^^^^ not found in this scope
2022-11-05 02:51:28 +00:00
Arun Raghavan 54c84a7211 aws: Skip s3 test on Windows until we figure out why it times out 2022-11-02 13:14:08 -04:00
Sebastian Dröge a8250abbf1 Fix various new clippy warnings 2022-11-01 10:27:48 +02:00
Sebastian Dröge 976ae5707e webrtc: Update to human_bytes 0.4 2022-10-31 14:11:29 +02:00
Sebastian Dröge 6ceeadc0f0 aws: Update to aws 0.21/0.51 2022-10-31 14:11:29 +02:00
Sebastian Dröge ce166b4d8f whipsink: Add object to debug logs 2022-10-26 16:20:26 +03:00
Guillaume Desmottes d46857d3b1 aws: fix title in README
The title was not matching the actual plugin name which was confusing.
2022-10-26 11:13:47 +02:00
Sebastian Dröge bf6bdab80c webrtc: Remove version requirement from internal crate dependencies 2022-10-24 19:50:24 +03:00
Sebastian Dröge f2223cf2cb Update versions to 0.10.0-alpha.1 2022-10-24 19:31:19 +03:00
Sebastian Dröge b64f951160 Update to async-tungstenite 0.18 2022-10-24 18:03:33 +03:00
Sebastian Dröge 9a68f6e221 Move from imp.instance() to imp.obj()
It's doing the same thing and is shorter.
2022-10-23 23:08:46 +03:00
François Laignel 86776be58c Remove & for obj in log macros
This is no longer necessary.

See https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1137
2022-10-23 21:22:31 +02:00
Sebastian Dröge f045099fc1 Fix GObject type names, GStreamer debug category names and element factory names
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/198
2022-10-23 20:46:08 +03:00
Sebastian Dröge 5d44e0eb3c rtp: Move GCC bandwidth estimation element from webrtc to rtp plugin 2022-10-23 20:25:08 +03:00
Sebastian Dröge 20ad9175d8 Make GStreamer plugin/crate/library/directory names and descriptions consistent
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/238
2022-10-23 20:25:08 +03:00
Sebastian Dröge 45168639e9 Rename rtpav1 plugin to just rtp
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/issues/243
2022-10-23 20:04:43 +03:00
Sebastian Dröge f058a5e229 Various minor cleanups 2022-10-22 19:50:24 +03:00
François Laignel 6319d104a8 Take advantage of Into<Option<_>> args
Commit 24b7cfc8 applied changes related to nullability as declared
by gir. One consequence was that some functions signature ended up
requiring users to pass `Some(val)` when they could use `val`
before.

This commit applies changes on `gstreamer-rs` which, will honoring
the nullability stil allow users to pass `val` for the few affected
functions.

This commit also fixes the signature for `Element::request_new_pad`
which was updated upstream.
2022-10-21 11:54:24 +02:00
Sebastian Dröge 7b5d887c5b onvifmetadatacombiner: On timeout don't wait for metadata to arrive anymore but output the current video frame
Otherwise it will be too late downstream.
2022-10-21 07:08:46 +00:00
Sebastian Dröge 09ffeaf04e onvifmetadatacombiner: Add a lot of trace debug output 2022-10-21 07:08:46 +00:00
Thibault Saunier 5c89c3db69 webrtc: Rename and add to meson build the signalling server
The binary was only called `server` it has been renamed to
`gst-webrtc-signalling-server` and is installed in meson.
2022-10-20 18:20:15 +00:00
Thibault Saunier cbdd3a7f26 webrtc: Enhance documentation 2022-10-20 12:04:43 +00:00
Sebastian Dröge c0bf05d4bb webrtc: Minor cleanup 2022-10-20 13:20:32 +03:00
Thibault Saunier 71ed04d89b webrtc: Rename signaller and protocol crates 2022-10-20 13:32:31 +02:00
Thibault Saunier 25bda89ac8 webrtc: Update an unify rust-version and edition
So it all matches the rest of the plugins
2022-10-20 13:32:31 +02:00
Thibault Saunier 4942a916a8 webrtc: Uniformise GType names 2022-10-20 13:32:31 +02:00
Thibault Saunier 37c0239aff webrtc: Port to new ElementBuilder API 2022-10-20 13:32:31 +02:00
Thibault Saunier ad78936365 webrtc: Enable more documentation 2022-10-20 13:32:31 +02:00
Thibault Saunier 0f0dec7fa9 webrtc: Fix fmt issues 2022-10-20 11:51:59 +02:00
Thibault Saunier 5ab7be6124 webrtc: Add SDPX license header on every file 2022-10-20 11:51:58 +02:00
Thibault Saunier 39c0dcb0d4 Plug webrtc in 2022-10-20 11:51:58 +02:00
Thibault Saunier b164daf510 webrtc: Fix clippy issues 2022-10-20 11:51:58 +02:00
Thibault Saunier 87fd49a9bf webrtc:signalling: Remove short option for 'host' in the cli
It clashes with `--help`
2022-10-20 11:51:58 +02:00
Thibault Saunier eb9d0bb824 Merge 'webrtcsink' from 020c7e2900 2022-10-20 11:51:58 +02:00
Sebastian Dröge 12400b6b87 Update everything for element factory builder API changes
And set properties as part of object construction wherever it makes
sense.
2022-10-19 19:43:29 +03:00
Sebastian Dröge 9ce8e93c63 rtpav1pay: Track last known upstream PTS/DTS in case not all OBUs are properly timestamped 2022-10-19 15:42:48 +03:00
Sebastian Dröge 36861edf9a rtpav1pay: Use a VecDeque instead of a Vec for the queued OBUs
And use a `Vec` plus offset for consuming partial byte buffers.
Removing the first element from a `Vec` repeatedly is not very cheap.

Also simplify calculation of the current packet by removing a mostly
unused type and keeping track of the calculations always locally instead
of sometimes storing it in the element state.
2022-10-19 15:23:10 +03:00
Sebastian Dröge 24b7cfc841 Update for GStreamer API changes 2022-10-18 19:26:52 +03:00
Arun Raghavan 03b03fe2dd whipsink: Log error body along with status code when POST fails 2022-10-18 17:01:36 +02:00
Thibault Saunier 5e7537953c webrtc: Move to net/webrtc 2022-10-18 15:18:53 +02:00
Sanchayan Maity c63307e6d7 net/webrtc-http: whipsink: Return a proper error message & not panic
On a server error, we currently crash and panic. Return a proper error
message instead.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/914>
2022-10-18 10:38:57 +00:00
François Laignel 8011eadfd2 Use new format constructors
See https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1128
2022-10-18 10:36:59 +00:00
Arun Raghavan e66378d254 aws: Add a test for s3src/s3sink
This does rely on AWS credentials being provided in the environment, but
the test will be ignored if those are missing.
2022-10-18 09:51:34 +00:00
Sebastian Dröge e17688a2da Update for pango API changes 2022-10-17 20:02:02 +03:00
Vivia Nikolaidou 0ab965335f onvifmetadataoverlay, cea608overlay: Fix pangocairo::FontMap::new()
It doesn't return an Option anymore.
2022-10-14 18:12:33 +03:00
Vivia Nikolaidou f11b0fa5eb plugins, examples, tutorials: Use AudioCapsBuilder and VideoCapsBuilder
Simplify caps creation code
2022-10-13 19:24:57 +00:00
Sebastian Dröge 862c2af1d9 ndi: Remove unnecessary explicit Send+Sync impls
These are automatically available now.
2022-10-13 17:54:08 +00:00
Vivia Nikolaidou dbd5a44b90 hlssink3: Use #[cfg(feature = "doc")] on gst::prelude import
It otherwise gives a warning about the unused import
2022-10-13 14:22:36 +03:00
Sebastian Dröge 5f19639d0f ndi: Various code cleanup 2022-10-13 08:52:52 +00:00
Sebastian Dröge b2ddb34258 onvif: Switch from minidom to xmltree for parsing ONVIF timed metadata
minidom doesn't handle various valid but suboptimal XML documents.
2022-10-12 21:00:13 +00:00
Sebastian Dröge 97e0852156 ndi: Add NDI plugin to the docs 2022-10-12 22:25:13 +03:00
Sebastian Dröge 53b02a82ae ndi: Re-organize code a bit and don't make internal modules public 2022-10-12 22:09:56 +03:00
Sebastian Dröge 0a2e6e47c9 ndi: Silence some more clippy warnings 2022-10-12 22:09:55 +03:00
Sebastian Dröge db8037d16c ndi: Update for pad default functions API changes 2022-10-12 22:09:55 +03:00
Sebastian Dröge 3fe9e4a207 ndi: Implement dynamic loading of the NDI SDK
And build the plugin on the CI and via meson.
2022-10-12 22:09:53 +03:00
Sebastian Dröge 16c036e2cc ndi: Make element factory details and debug categories more consistent 2022-10-12 21:29:07 +03:00
Sebastian Dröge 907910329f ndi: Prefix GType names with Gst 2022-10-12 21:29:07 +03:00
Sebastian Dröge 047f990c78 ndi: Integrate into the build system 2022-10-12 21:29:07 +03:00
Sebastian Dröge a000432b13 ndi: Relicense plugin from LGPL-2.1 to MPL-2
This was agreed to by all previous contributors in writing.
2022-10-12 21:29:07 +03:00
Sebastian Dröge fb8192f40b ndi: Remove unnecessary reference-timestamps feature 2022-10-12 21:29:07 +03:00
Vivia Nikolaidou fedd67dcaa ndi: Use AudioCapsBuilder and VideoCapsBuilder
Simplify caps creation codes
2022-10-12 21:29:07 +03:00
Vivia Nikolaidou 95e8deded9 ndi: Simplify code using ParamSpecBuilder 2022-10-12 21:29:07 +03:00
Vivia Nikolaidou 77a5e35081 ndi: Update to git version of the bindings 2022-10-12 21:29:07 +03:00
Vivia Nikolaidou 18cbb587ba ndisrcdemux: Add no-more-pads signal
Emit no-more-pads if we are adding the second pad of the element.
2022-10-12 21:29:07 +03:00
Sebastian Dröge 1c43a51520 ndisrcdemux: Use ANY caps in the pad templates of ndisrcdemux
When using the Advanced SDK it is possible to output compressed formats
too.
2022-10-12 21:29:07 +03:00
Sebastian Dröge 26f843a89f ndisrc: Fix latency reporting in auto timestamp mode 2022-10-12 21:29:07 +03:00
Sebastian Dröge 9c10ba87df ndisrc: Improve handling of broken sources with regards to timestamping
- NDI HX Camera Android in the past used 1ns instead of 100ns as unit
   for timecodes/timestamps.
 - NDI HX Camera iOS uses 0 for all timecodes and the same non-zero
   value for all audio timestamps

Detect such situations and try to compensate for them. Also add a new
"auto" timestamping mode that prefers to use timecodes and otherwise
falls back to timestamps or receive times.

Fixes https://github.com/teltek/gst-plugin-ndi/issues/79
2022-10-12 21:29:07 +03:00
Sebastian Dröge a3c752830b ndisrc: Keep track of audio/video and timestamp/timecode observations separately
Audio/video are in practice not always from the same clock and can have
different behaviours with regards to clock rate and jitter. Handling
them separately generally gives better results for the timestamps output
by the source element.
2022-10-12 21:29:07 +03:00
Sebastian Dröge b82acb9ca9 ndisrc: Remove unnecessary Arc around the timestamp observations and use AtomicRefCell instead of Mutex 2022-10-12 21:29:07 +03:00
Sebastian Dröge 718734ab18 ndi: Fix/silence various clippy warnings 2022-10-12 21:29:07 +03:00
Sebastian Dröge 7a90500fe7 Merge branch 'master' of https://github.com/teltek/gst-plugin-ndi 2022-10-12 21:27:56 +03:00
Sebastian Dröge e49138516c Update for pad default functions API changes 2022-10-12 19:50:15 +03:00
Sebastian Dröge 9c540d8abb Move everything to net/ndi for preparing to merge into gst-plugins-rs 2022-10-12 19:25:32 +03:00
François Laignel bc5b51687d fix formatted values constructors
In restrospect, building formatted values using operations on the
`ONE` constant doesn't seem idiomatic. This commit uses new panicking
constructors instead.

See https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1122
2022-10-11 15:06:53 +02:00
François Laignel bd14e476f1 Fix direct access to the inner specific formatted values
This is no longer available as this could lead to building a defined
value in Rust which could be interpreted as undefined in C due to
the sentinel `u64::MAX` for `None`.

Use the constants (e.g. `ONE`, `K`, `M`, ...) and operations to build
a value and deref (`*`) to get the quantity as an integer.
2022-10-10 19:28:13 +02:00
Sebastian Dröge 7ee4afacf4 Change *Impl trait methods to only take &self and not Self::Type in addition 2022-10-10 15:03:25 +03:00
Sebastian Dröge 4c57a97d4d Update for glib::Object::new() API changes 2022-10-07 23:54:53 +03:00
Nirbheek Chauhan 1d4d3e4cb0 build: Update versions to be 0.9.0-alpha.1
0.9.0 is the next release, so we can't name things that already.

Also the version in meson.build was 0.13.0, which is completely wrong.
2022-10-04 21:27:23 +05:30
Sebastian Dröge 8601562efe onvif: Fix for gst::meta::CustomMeta::register() API change 2022-09-29 17:48:27 +03:00
Sebastian Dröge 0b81ed2e34 rtpav1: Use GStreamer types by namespace instead of importing dozens of types directly into the scope
For consistency with other plugins and to reduce confusion of where
types actually come from.
2022-09-28 08:14:07 +00:00
Sebastian Dröge 5774d9c9ee rtpav1: Reset state on FlushStop/Eos in all conditions and reset all of the state 2022-09-28 08:14:07 +00:00
Sebastian Dröge d6ab55c263 onvifmetadataparse: Schedule EOS events after the last currently queued up frame
Otherwise EOS might be sent before the last frame's data, or even at a
much earlier frame due to reordering.
2022-09-27 11:43:54 +00:00
Sebastian Dröge f0b2df49dc onvifmetadataparse: Handle negative running times in debug output 2022-09-27 11:43:54 +00:00
Sebastian Dröge 692a063528 onvifmetadataparse: Refactor clock/condvar waiting
Always first try draining queued data in the loop and only start waiting
if there's nothing to drain right now. Otherwise data might have to be
drained right now but we still wait and nothing is ever waking up the
source pad task again.

Also make sure to not wait multiple times on the same gst::ClockId but
instead unset it after waiting on it and no new one was scheduled in the
meantime. Future waits on the same ClockId will immediately return and
instead we should wait on the condvar if no new ClockId is available.
2022-09-23 13:26:15 +03:00
Sebastian Dröge c4d2f4a60a onvifmetadataparse: Start source pad task on StreamStart if needed
Otherwise receiving StreamStart after Eos might keep the source pad task
paused and no new data is ever pushed downstream.
2022-09-23 13:26:15 +03:00
François Laignel 0b7259afac Fixes for removal of SpecificFormattedValues ops on ref
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/874>
2022-09-22 12:18:49 +02:00
François Laignel caefa6d33e net/onvif: update with new gst::Signed features 2022-09-21 17:45:22 +00:00
Sebastian Dröge c32f0ca12e rtpav1: Specify version helper dependency by path
It's in the same repository after all.
2022-09-21 11:17:44 +03:00
Sebastian Dröge 6a10728d94 aws: Update to aws 0.48/0.18 2022-09-21 11:17:44 +03:00
Sebastian Dröge 1fa39d0ab4 onvifmetadatacombiner: Drop gap metadata buffers
They won't have a reference timestamp metadata set and are not useful
for further processing.
2022-09-16 14:54:33 +03:00
Sebastian Dröge f2893aae0b onvifmetadataparse: Simplify some code 2022-09-16 14:54:33 +03:00
Sebastian Dröge 49602e1e01 onvifmetadataparse: Drop initial buffers until an UTC/running time mapping can be established 2022-09-16 14:54:33 +03:00
Sebastian Dröge c6d8fec18f onvifmetadataparse: Drop initial buffers if their UTC time would be negative 2022-09-16 14:54:33 +03:00
Sebastian Dröge 28151f2011 onvifmetadataparse: Push buffers from a separate source pad task to guarantee latency and generally improve correctness 2022-09-16 14:54:33 +03:00
Sebastian Dröge 18f3edd3ee Add missing Since markers to new plugins 2022-09-15 09:40:53 +03:00
rajneeshksoni 45962eca1c s3sink, s3src: Max 1 (re)try when retry-duration < request_timeout.
When retry-duration is less than request_timeout, only 1 try
is attempted.
2022-09-13 08:02:54 +00:00
rajneeshksoni 62f76e1e8b s3sink: Dont set call_timeout,call_attempt_timeout is enough with retry.
When call_timeout is triggered, request will fail
irrespective of the retry setting. call_timeout define
max time request can take along with retry.
It can be solved by either setting call_timeout to
retry * call_attempt_timeout or not setting the call_timeout.

As per thread call_attempt and rety setting is enough.
https://github.com/awslabs/aws-sdk-rust/issues/558
2022-09-13 08:02:54 +00:00
Sebastian Dröge cc0ef5290f rtpav1depay: Don't unnecessary map RTP payload a second time
`RTPBuffer` already has it mapped internally and can give direct access
to it as byte slice.
2022-09-12 18:14:39 +03:00
Sebastian Dröge 7edc9e656f rtpav1pay: Don't push buffers downstream while holding mutexes
And also push all packets that can be generated as a time as a single
buffer list instead of one by one.
2022-09-12 18:14:39 +03:00
Sebastian Dröge f9a8e121e1 rtpav1: Remove some unneeded lifetime annotations 2022-09-12 18:14:39 +03:00
Vivienne Watermeier 8d73b5008a Add RTP de/payloader elements for AV1
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/881
2022-09-12 18:14:39 +03:00
Thibault Saunier 528bbcf67e onvifmetadatacombiner: Do not classify as Muxer
It confuses `encodebin` and technically it is not really a muxer so
as agreed on IRC, I am proposing to remove that classification.
2022-09-09 10:01:12 +03:00
Mathieu Duponchelle 419cc03133 awstranscriber: only set vocabulary filter when vocabulary is set
AWS otherwise refuses to start the transcription.
2022-09-09 06:53:54 +00:00
Mathieu Duponchelle 72b659b3ea awstranscriber: fix set_property for language-code 2022-09-09 06:53:54 +00:00
Sebastian Dröge 1a40186485 Update for GLib ParamSpec builder API changes 2022-09-05 11:45:47 +03:00
Sebastian Dröge 46dddaf31c Update minimum supported Rust version to 1.63 2022-09-04 21:31:55 +03:00
Xavier Claessens 16f9c37c71 Fix missing pkgconfig requires 2022-09-02 22:00:57 +00:00
Taruntej Kanakamalla 67e9ba8286 whipsink: A GstBin implementation for WHIP
Fixes https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/issues/1410

Created a new plugin 'webrtchttp' to implement all the
WebRTC HTTP protocols under /net/webrtc-http directory.

WhipSink wraps around 'webrtcbin' with HTTP capabilites
to exchange SDP offer/answer so an ICE/DTLS session can
be established between the encoder/media producer (WHIP client)
and the broadcasting ingestion endpoint (Media Server).

Once the ICE/DTLS session is set up, the media will
flow unidirectionally from the WHIP client to the
broadcasting ingestion endpoint (Media Server).
Spec:
https://www.ietf.org/archive/id/draft-ietf-wish-whip-04.html
2022-09-03 00:18:59 +03:00
Sebastian Dröge 827099d22d aws: Update to aws 0.18/0.48 2022-09-02 10:46:02 +03:00
Sebastian Dröge cb339c1bf8 onvifmetadataparse: Pass through other XML as is with the UTC times based on the buffer PTSs 2022-08-31 10:33:16 +00:00
Sebastian Dröge 420f36251a onvif: Rename onvif(de)pay to rtponvifmetadata(de)pay and include the metadata specifier in the other element names too
This is more descriptive and avoids any future conflicts with other
kinds of ONVIF specific RTP (de)payloaders.
2022-08-31 13:00:53 +03:00
Thibault Saunier 16d804e761 doc: Mark request::user-agent as doc show default 2022-08-29 18:33:22 -04:00
Thibault Saunier 67e651f57c Allow "unused_doc_comments" as we use hotdoc and not rustdoc 2022-08-29 18:33:22 -04:00
Thibault Saunier 31a53bba8a Generate plugins documentation using hotdoc
Which will automatically be integrated in gstreamer documentation
2022-08-29 18:33:22 -04:00
Mathieu Duponchelle 052092cd2e onvifmetadata: removing encoding field
The encoding of ONVIF metadata is always UTF-8. ONVIF metadata may
or may not be encoded with gzip, but we don't see a use case for
transporting compressed ONVIF metadata between elements for now.
2022-08-24 08:57:12 +00:00
Arun Raghavan 56e7a2f6ab aws: Document the s3hlssink element in README 2022-08-23 06:19:39 -04:00
Vivia Nikolaidou 5606111345 plugins: Simplify code using ParamSpecBuilder 2022-08-22 17:58:43 +03:00
Sebastian Dröge 374bb8323f Fix build after glib SignalBuilder::param_types() API change 2022-08-17 23:37:39 +03:00
Sebastian Dröge 9827406113 onvifmetadataparse: Use NTP reference timestamp meta
The times are in the NTP epoch.
2022-08-16 15:51:32 +03:00
Sebastian Dröge be56991b73 onvifmetadataparse: use NTP epoch everywhere instead of mixing UNIX/NTP epochs 2022-08-16 14:14:24 +03:00
Mathieu Duponchelle 3011764da1 onvifaggregator: refactor, expect parsed metadata
The aggregator was consuming meta buffers too greedily, causing
potential interleaving starvation upstream. Refactor to consume
media and meta buffers synchronously

Also expect parsed=true metadata caps (requiring an upstream
onvifmetadataparse element).
2022-08-16 12:28:52 +03:00
Sebastian Dröge 837126be76 onvifmetadataparse: Only define the namespace prefix once for the top-level element 2022-08-12 22:35:40 +03:00
Sebastian Dröge 2b61d51e91 Remove unnecessary unsafe blocks for Buffer::as_ptr() 2022-08-12 18:12:22 +03:00
Sebastian Dröge 35b42b88d9 onvif: Add onvifmetadataparse element
This splits XML metadata into separate frames and ensures properly
timestamped metadata.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/781>
2022-08-12 14:00:27 +00:00
Sebastian Dröge 05207cafea raptorq: Derive Eq for some more structs
warning: you are deriving `PartialEq` and can implement `Eq`
  --> net/raptorq/src/fecscheme.rs:13:24
   |
13 | #[derive(Clone, Debug, PartialEq)]
   |                        ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
   |
   = note: `#[warn(clippy::derive_partial_eq_without_eq)]` on by default
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq

warning: you are deriving `PartialEq` and can implement `Eq`
  --> net/raptorq/src/fecscheme.rs:38:24
   |
38 | #[derive(Clone, Debug, PartialEq)]
   |                        ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq
2022-08-09 13:40:39 +00:00
Sebastian Dröge cbb55c2322 hlssink3: Update to m3u8-rs 5 2022-08-09 13:40:39 +00:00
Sebastian Dröge 8b11aee04d aws: Update to aws 0.17/0.47 2022-08-09 13:40:39 +00:00
Mathieu Duponchelle f646cabb3d aws_transcriber: expose filtering related properties
- vocabulary-filter-name allows picking a vocabulary to filter words
- vocabulary-filter-method allows controlling how words are filtered
2022-08-09 12:14:31 +00:00
Sanchayan Maity d240bbc4e2 aws_transcriber: Fix regression with credentials mechanism
A regression was introduced during the migration to AWS SDK. One used
to be able to provide credentials in multiple ways with the earlier
Rusoto ChainProvider (config file / environment variables). Now one
has to explicitly set the properties.

Use the DefaultCredentialsChain from AWS SDK to restore the previous
functionality.

See
https://docs.rs/aws-config/0.46.0/aws_config/default_provider/credentials/struct.DefaultCredentialsChain.html.
2022-08-04 12:15:32 +00:00
Sanchayan Maity a4893f30c8 net/aws: Add support for specifying endpoint
Allow specifying an endpoint to be used for S3 requests. This makes
it possible to use integrations providing object storage based on S3
API like MinIO.

When the endpoint-uri property is specified, the endpoint resolver to
use will be overridden when making S3 requests.
2022-08-04 10:37:37 +05:30
Bilal Elmoussaoui 52973d975e Update per glib::SignalBuilder changes 2022-07-21 20:03:13 +02:00
Tomasz Andrzejak 14160d1d31 Add RaptorQ RTP FEC plugins 2022-07-20 13:34:58 +00:00
Sebastian Dröge 42b6c32f34 onvif: Update to minidom 0.15 2022-07-18 11:21:04 +03:00
Rafael Caricio adde6fc4e3
hlssink3: convert playlist type to an enum
Change the property `playlist-type` to an enum. We also expose the
new enum externally from the crate so users of Rust can directly use it.
2022-07-08 11:24:32 +02:00
Rajneesh Soni 08c6ab29e1 hlssink3: Put EXT-X-ENDLIST for vod playlist-type.
Ideally, when player encounter PLAYLIST-TYPE is VOD, player should
not reload the playlist. For playlist-type=vod, initially we put
PLAYLIST-TYPE=EVENT, and later change it to VOD, which confuse some
players so we shold put ENDLIST here.
In any case putting ENDLIST is right thing to do to indicate no new
segment will be added to playlist.
2022-07-04 15:15:20 +00:00
Rajneesh Soni 4ff2c8f1bc hlssink3: Dont reset end_list after stop is called.
in current implementation EXT-X-ENDLIST is never set for any playlist-type.
After calling playlist.stop(), during write_final_playlist() is called.
in final playlist write, segment is not added but update_playlist is called.
and update_playlist reset end_list again, so plugin never put ENDLIST.
2022-07-04 15:15:20 +00:00
Sebastian Dröge 88bb91a5cb aws: Update to aws 0.15/0.45 2022-07-04 10:20:43 +03:00
Sebastian Dröge 51c7d0652e Fix/silence a couple new clippy warnings 2022-06-30 16:07:32 +03:00
Sanchayan Maity a85a647794 net/aws: Add support for S3 HLS sink
This is a helper bin allowing the output of HLS sink to be uploaded
to S3.
2022-06-29 17:35:37 +00:00
Sanchayan Maity e0594ef349 net/aws/aws_transcriber: Fix clippy warning 2022-06-29 17:35:37 +00:00
Sanchayan Maity 7bc785fba3 net/aws: Clean up pending rusoto references 2022-06-29 17:35:37 +00:00
Sebastian Dröge cb84206457 Fix a couple of new 1.62 clippy warnings 2022-06-28 14:52:20 +03:00
Sebastian Dröge 5c00db62b7 aws: Update to aws 0.14/0.44 2022-06-27 10:11:16 +03:00
Rajneesh Soni b3e558bec0 aws: s3sink,s3src,transcriber: Add property to set temporary credentials.
STS provide temporary credentials to access AWS resource. Temporary
credentials include, AccessKeyId, SecretAccessKey and SessionToken.
With session-token property, element will be able to use temporary
credentials. When session-token is not set, element can use long
term credentials.
2022-06-22 18:45:41 +00:00
Sebastian Dröge d902ecca4f aws: Update to aws 0.13/0.43 2022-06-21 06:45:24 +00:00
Mathieu Duponchelle 20d2a7d05b onvifoverlay: render polygons when present 2022-06-15 14:32:48 +00:00
Sebastian Dröge dfa5b9d8bb onvifaggregator: Add support for UNIX reference timestamp metadata
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/780>
2022-06-14 23:44:00 +02:00
Sebastian Dröge 939f37dec5 onvif: Disable default features for the chrono dependency
We don't need all those.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/780>
2022-06-14 23:43:47 +02:00
Sanchayan Maity 19f69614a2 aws: s3sink: Add a deprecation warning for retry duration properties
Keeping the upload-part-retry-duration & complete-upload-retry-duration
properties changes the semantics in comparison to their usage in
rusotos3sink. Deprecate these two properties and add a warning while
making them noop.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/759>
2022-06-14 08:03:49 +00:00
Sanchayan Maity 511ee766df Rename rusoto to aws
Now that migration to AWS SDK is complete, rename directory and
references to aws/AWS SDK.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/759>
2022-06-14 08:03:49 +00:00
Sanchayan Maity 81437bb1c9 net/rusoto: Rename to aws
Rename all the elements to use aws prefix now but still register a
backwards compat element factory.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/759>
2022-06-14 08:03:49 +00:00
Sanchayan Maity 2b0bf218b1 net/rusoto: Drop rusoto crates
Now that all elements are migrated to AWS SDK drop the rusoto
dependencies.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/759>
2022-06-14 08:03:49 +00:00
Sanchayan Maity 753425507a Migrate transcriber to aws sdk
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/759>
2022-06-14 08:03:49 +00:00
Sanchayan Maity 768fad2445 Migrate s3src and s3sink to use AWS SDK
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/759>
2022-06-14 08:03:49 +00:00
Mathieu Duponchelle ab01fc6143 onvifaggregator: refactor to support duration-less media buffers
For instance when dealing with a variable framerate media stream,
input media buffers may not hold a duration, in which case we try
to calculate one by waiting for the following buffer.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/765>
2022-05-25 17:35:04 +00:00
Mathieu Duponchelle 77260a8442 onvifaggregator: implement proper EOS support
We could otherwise busy loop in aggregate forever when the meta
sink pad received EOS.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/765>
2022-05-25 17:35:04 +00:00
Sebastian Dröge dcad6ffe34 rtponvifdepay: Set caps on the source pad
The RTP depayloader base class does not take care of this in any way and
it has to be done manually.
2022-05-13 13:34:30 +03:00