Commit Graph

13 Commits

Author SHA1 Message Date
prlanzarin
be6a23a003 feat: add option to force/extend gathering window in SFU components
There's an edge case in finnicky networks where ALG-like firewalls
tamper with USE-CANDIDATE STUN packets and, consequently, bork ICE-lite
connectivity establishment. The odd part is that client-side gathering
seems to complete if intermediate STUN bindings work (before the final
USE-CANDIDATE), which may cause the peer not to generate relay
candidates == connectivity fails.

This adds the `public.kurento.gatheringTimeout` option to forcefully extend
the candidate gathering window in peers that act as offerers. The
behavior is as follows: if the flag is set (ms), the peer will wait
either the gathering completed stage or, _at most_,
public.kurento.gatheringTimeout ms before proceeding with calls chained
to setLocalDescription.

This option is disabled by default and intentionally ommited from the
base settings.yml file as to not encourage its use. Don't use it unless
you know what you're doing :).
2023-04-05 13:22:38 -03:00
prlanzarin
0f24e5634d fix(audio): bypass overconstrained errors in SFU-based audio 2022-09-15 20:42:43 +00:00
prlanzarin
646db91367 fix(webcam): add MediaStream id to 'inactive' event handlers
BBBVideoStream 'inactive' event currently does not send the
MediaStream id as the payload for handlers. This can cause theoretical
race conditions due to media stream mismatches in places where
'inactive' handling is done globally (eg video-preview).

This adds the MediaStream id to BBBVideoStream's 'inactive' event
and uses it in video-preview to avoid such race conditions.
2022-09-06 12:31:26 +00:00
Joao Victor
396f5320a4 feat(camera): set camera brightness 2022-08-26 11:50:46 -03:00
prlanzarin
0e162f1cda feat: configurable DSCP marking for WebRTC media
RTCRTPSender exposes DSCP marking via `networkPriority` in the encodings
configuration dictionaries. That should allow us to control
QoS priorities for different media streams, eg audio with higher network
priority than video. The only browser that implements that right
now is Chromium.

To use this, the public.app.media.networkPriorities configuration in
settings.yml. Audio, camera and screenshare priorities can be controlled
separately. For further info on the possible values, see:
  - https://www.w3.org/TR/webrtc-priority/
  - https://datatracker.ietf.org/doc/html/rfc8837#section-5
2022-08-15 21:24:05 +00:00
prlanzarin
d06ae5ce40 fix: add default gUM factory to new peer wrapper
For scenarios such as preview-less camera sharing, old echo test
2022-07-15 17:07:15 +00:00
prlanzarin
cd9b8ccef4 fix: handle Firefox stream cleanup edge case (peer.js)
Firefox doesn't fire the ended evt/onended callback for live
 MediaStreamTrack(s). We rely on that event.

 Manually emit the ended event which works with the onended callback
 when a track is stopped
2022-07-15 14:25:37 +00:00
prlanzarin
7281475271 feat: add new peer wrapper to phase out kurento-utils
kurento-utils is unmaintained. It's served us well, but its age
shows.  We need to transition to something else if we want to
have better  maintainability and include simulcast, multistream, ...

This introduces a simplified/leaner wrapper kit that's almost
API-compatible with what we use right now - so widespread changes
are minimal). It's easier to maintain/read/transition from. This
can be read as an intermediate step to transitioning to
something definitive (ie mediasoup-client).
2022-07-15 13:51:03 +00:00
prlanzarin
e93440e15a refactor(webcam): fix linter errors in BBBVideoStream 2022-07-12 17:50:16 +00:00
Joao Victor
a7e5869c91 feat(video): upload of own webcam virtual background 2022-05-10 14:17:16 -03:00
prlanzarin
bae731e59e fix(audio): PC loopback workaround for local echo in Chrome
Works around the fact that Chrome doesnt have AEC on streams that dont go through PCs
2022-04-13 14:37:39 +00:00
Joao Victor
380e2009d3 fix: unexpected blurred effect 2021-12-03 09:49:32 -03:00
prlanzarin
9071ba8bc4 refactor(virtual-backgrounds): re-organize virtual background code
Changes (maybe not a complete list):
  - Disable virtualbgs by default
  - Move the virtualbg selector in video-preview to the side below the
profile selection
  - Restore old video-preview sizes
  - Add a wrapper class for MediaStreams (BBBVideoStream)
  - Centralize virtualbg services and business logic code into BBBVideoStream
  - Refactor and centralize virtualbg constant fetching
  - Refactor and centralize virtualbg config fetching
  - Organize virtualbg type definitions
  - Remove added states in video-provider to prevent further bloat
  - Remove added states in video-preview to prevent further bloat
  - Lock virtual bg switching while video-preview itself is locked
  - Add proper virtualbg error surfacing via toasts
  - Refactor iOS availability detection to use centralized UA checker
  - Avoid calling gUM when toggling virtualbgs on/off
  - Make virtualbg video-list-item action a toggle instead of a
state-aware action
  - Make virtualbg switching work in video-preview for cameras that are
already shared. Especially useful when there are multiple source
cameras, and will be important in the near future
  - Add Derivative Work notices in files that are partially copied from
jitsi-meet
  - Simplify track replacing in video-provider
  - Split video-preview UI code for virtualbgs into a separate functional component
2021-07-22 18:53:42 +00:00