Commit graph

2535 commits

Author SHA1 Message Date
Guillaume Desmottes
4576bea10c add textahead plugin
Plugin displaying upcoming text buffers ahead.
2022-01-12 08:47:23 +01:00
Praveen Perera
f0d64a9fe8 Update README.md with correct repo and branch
Closes #15
2022-01-11 17:55:30 +01:00
François Laignel
64dd588734 ts/runtime/scheduler: check must_awake before sleeping 2022-01-05 19:00:00 +01:00
François Laignel
1573522520 ts/runtime: rewrite runnable loop
Previous version relied on a plain loop / match / break because
I experimented different strategies. The while variant is better
for the final solution.
2022-01-05 18:59:43 +01:00
Thibault Saunier
689bd93055 Implement the GstNavigation interface using a dedicated DataChannel protocol
This allows interacting with the source element from within the browser
very easily
2022-01-03 22:30:44 +01:00
Thibault Saunier
7b66b21f47 www: Check in input.js
input.js: f8ee83f12d/images/gst-web/src/input.js
2022-01-03 22:30:44 +01:00
Thibault Saunier
e57c2eb101 signalling: Add a flag to hide local Ice candidates 2022-01-03 22:30:44 +01:00
Thibault Saunier
cf176bdd93 Update plugins/src/webrtcsink/imp.rs
Co-authored-by: Sebastian Dröge <slomo@coaxion.net>
2022-01-03 18:29:45 +01:00
Thibault Saunier
300adda41b Dot 'caps inspection' pipelines 2022-01-03 18:29:45 +01:00
Thibault Saunier
85fd7175de Add support for cuda and GL memory
This way we don't need to download/upload when unnecessary
2022-01-03 18:29:45 +01:00
Guillaume Desmottes
8bab034bc8 uriplaylistbin: fix license when registering plugin 2022-01-03 00:08:53 +01:00
Guillaume Desmottes
0615a94cae spotify: fix license when registering plugin 2022-01-03 00:08:36 +01:00
Guillaume Desmottes
53cef60f2c spotifyaudiosrc: log error if setup() failed 2022-01-03 00:02:39 +01:00
Guillaume Desmottes
faee72bf5b spotify: link the proper LICENSE file 2022-01-03 00:02:20 +01:00
Sebastian Dröge
e2ecd77654 sodium: Port examples to clap 3 2022-01-02 09:13:55 +00:00
Guillaume Desmottes
9858eeeb00 spotify: relicense to MPL-2.0 2021-12-30 14:40:31 +01:00
Sanchayan Maity
a43e21a414 videofx: roundedcorners: Fix missing copyright attribution 2021-12-29 16:15:43 +00:00
Guillaume Desmottes
61cdf47462 add spotify plugin
Plugin adding an element to play audio from Spotify.
2021-12-29 16:48:20 +01:00
Sebastian Dröge
d6ba009742 Fix various clippy warnings 2021-12-28 18:28:09 +01:00
Thibault Saunier
d15c32e3e6 stat-frontend: Allow passing a URL to the stat producer 2021-12-28 17:09:52 +01:00
Sebastian Dröge
c5cba3fec5 deny: Remove unnecessary duplicated dependencies
These were all pulled in via the old tokio dependency of the threadshare
plugin.
2021-12-26 14:56:39 +02:00
François Laignel
5e4fc8b138 ts/executor: relax the static bound on enter
The function `enter` is executed in a blocking way from the caller's
point of view. This means that we can guaranty that the provided
function and its output will outlive the underlying Scheduler Task
execution. This requires an unsafe call to
`async_task::spawn_unchecked`. See:

https://docs.rs/async-task/latest/async_task/fn.spawn_unchecked.html
2021-12-25 11:25:56 +00:00
François Laignel
21d41ca244 deny.toml: don't ignore RUSTSEC-2021-0124
This advisory was ignored because we couldn't use a version for
the tokio fork that reflected that it was not vulnerable.

Also remove the tokio fork as an allowed git since we now use
our own executor for threadshare.
2021-12-25 11:25:56 +00:00
François Laignel
6163589ac7 ts/executor: replace tokio with smol-like implementation
The threadshare executor was based on a modified version of tokio
which implemented the throttling strategy in the BasicScheduler.
Upstream tokio codebase has significantly diverged from what it
was when the throttling strategy was implemented making it hard
to follow. This means that we can hardly get updates from the
upstream project and when we cherry pick fixes, we can't reflect
the state of the project on our fork's version. As a consequence,
tools such as cargo-deny can't check for RUSTSEC fixes in our fork.

The smol ecosystem makes it quite easy to implement and maintain
a custom async executor. This MR imports the smol parts that
need modifications to comply with the threadshare model and implements
a throttling executor in place of the tokio fork.

Networking tokio specific types are replaced with Async wrappers
in the spirit of [smol-rs/async-io]. Note however that the Async
wrappers needed modifications in order to use the per thread
Reactor model. This means that higher level upstream networking
crates such as [async-net] can not be used with our Async
implementation.

Based on the example benchmark with ts-udpsrc, performances seem on par
with what we achieved using the tokio fork.

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

Related to https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/604
2021-12-25 11:25:56 +00:00
François Laignel
db9c38aa93 ts/runtime: shuffle some structs to dedicated modules 2021-12-25 11:25:56 +00:00
François Laignel
c5ef83d5b0 ts/runtime: use a directory for executor module
This will ease the introduction of other concepts which are required
for our own executor implementation.
2021-12-25 11:25:56 +00:00
François Laignel
cd0773662f ts: migrate most tests so that they don't use tokio 2021-12-25 11:25:56 +00:00
Thibault Saunier
da0a934307 nvh264enc: Do not wrongly set vbv-buffer-size and use the cbr-ld-hq rc-mode
vbv-buffer-size which is in kbits can't be set while playing so we
can't really use it for our use case.
2021-12-23 17:02:50 +01:00
Guillaume Desmottes
bba26a9cf5 threadshare: remove unused import 2021-12-22 15:43:32 +01:00
Guillaume Desmottes
b7c08933aa uriplaylistbin: add properties reporting the current state of the playlist 2021-12-22 15:26:17 +01:00
Guillaume Desmottes
9783d01a35 uriplaylistbin: prevent overflow panic with infinite playlist
enumerate() will panic if the index overflows.
2021-12-22 12:53:11 +01:00
Guillaume Desmottes
4a5815cc97 uriplaylistbin: factor out create_items() 2021-12-22 12:53:11 +01:00
Mathieu Duponchelle
8128c14fa9 API: refactor error signalling
* Expect Box<dyn Error> from custom signaller

* Use thiserror to define the error codes returned to custom
  signallers
2021-12-21 23:37:29 +01:00
Mathieu Duponchelle
114fd3c5f6 README: mention https://github.com/centricular/webrtcsink-custom-signaller 2021-12-21 00:32:51 +01:00
François Laignel
7c909e59a9 utils/togglerecord: fix race condition in sink_chain when segment is pending
In `sink_chain` when the Segment is pending, attempting to lock
rec state could lead to a dead lock because the stream state is
already locked while the main stream state was not locked.
2021-12-20 09:01:09 +00:00
François Laignel
a1c89dd17b utils/togglerecord: fix race condition checking other streams EOS state
Function `check_and_update_stream_start` checks whether other streams
reached EOS. The stream being checked might already have locked its
state. If it's about to check other streams too, this results in a
deadlock.

The problem was due to the `main_state` guard being dropped handling
event `StreamStart` checking whether the main stream is EOS:

```rust
    let main_is_eos = if let Some(main_state) = main_state {
        main_state.eos
    } else {
        false
    };
```

In the above code, `main_state` main state is comsumed and dropped
after evaluating `main_state.eos`.

This is also the case before handling event `Eos`.

This revealed another deadlock handling event `Eos` which is under
investigation.
2021-12-20 09:01:09 +00:00
Sebastian Dröge
82d969190f ci: Remove the gstreamer directory if it exists already for the gst-build job
Otherwise it will regularly fail because the runner already has the
directory available for some reason.
2021-12-20 10:51:41 +02:00
Sebastian Dröge
d7677a6337 deny: Update 2021-12-18 10:08:48 +02:00
Sebastian Dröge
7b908e0165 deny: Update 2021-12-15 12:47:08 +02:00
Vivia Nikolaidou
2acb83da8f togglerecord: Handle stream-start event after EOS
It should restart any pending streams instead of keeping everything
EOS'd

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/622>
2021-12-14 14:34:50 +02:00
Mathieu Duponchelle
a4df10b112 webrtcsink: reset default values when disabling congestion control 2021-12-10 03:33:02 +01:00
Mathieu Duponchelle
d230345d90 webrtcsink: make sure we always scale to multiple of 2 dimensions
Some encoders do not like odd widths or heights
2021-12-10 01:16:10 +01:00
Mathieu Duponchelle
1826111278 Implement support for FEC / retransmission 2021-12-10 01:12:19 +01:00
9ae8f0d330 hlssink3: fix segment paths in playlist file 2021-12-09 12:38:35 +00:00
Sebastian Dröge
86021d637b fallbacksrc: Actually calculate running times of segment start/stop if the PTS is outside the segment
Previously it was just using the segment start/stop without converting
it to the corresponding running time.
2021-12-09 12:30:42 +02:00
Sebastian Dröge
6db599e5ae deny: Clarify license of encoding_rs
See https://github.com/hsivonen/encoding_rs/issues/75
2021-12-09 12:04:11 +02:00
Mathieu Duponchelle
7bd7c4e960 webrtcsink: tune homegrown CC algorithm
Make control decisions based on packet loss closer in intent to
the algorithm described in gcc section 6., and raise the threshold
for decreasing the bitrate based on delay_factor
2021-12-08 22:31:03 +01:00
Thibault Saunier
b12d91775d Respect user provided max-bitrate when congestion controler is disabled 2021-12-08 22:30:37 +01:00
Thibault Saunier
5904e1ccb4 Allow changeing Congestion control algorithm at runtime 2021-12-08 22:30:37 +01:00
Sanchayan Maity
099a3f2114 rusoto: s3sink: Support aborting or completing multipart upload on error
A multipart upload should either be completed or aborted on error. In
the current state of things, a multipart upload would neither be
completed nor aborted, putting the onus on an external entity to take
care of finishing incomplete uploads or relying on a sane bucket
life cycle policy configured to abort incomplete multipart uploads.

An incomplete multipart upload still contributes to the storage costs as
long as it exists.

We introduce a property here to allow the user to select either aborting
or completing multipart uploads on error. Aborting the upload causes
whole of data to be discarded and the same upload ID is not usable for
uploading more parts to the same.

Completing an incomplete multipart upload can be useful in situations
like having a streamable MP4 where one might want to complete the upload
and have part of the data which was uploaded be preserved.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/618>
2021-12-07 18:29:52 +05:30