Update dependency twilio-video to v2 #20
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
^1.18.1
->^2.0.0
Release Notes
twilio/twilio-video.js (twilio-video)
v2.28.1
Compare Source
========================
Bug Fixes
v2.28.0
Compare Source
===========================
Bug Fixes
v2.27.0
Compare Source
=======================
Changes
VideoTrack.addProcessor
now works on browsers that supportOffscreenCanvas
as well asHTMLCanvasElement
. When used with@twilio/video-processors v2.0.0, the Virtual
Background feature will work on browsers that supports WebGL2.
See VideoTrack.addProcessor and
@twilio/video-processors v2.0.0 for details.
Example
v2.26.2
Compare Source
==========================
Changes
whenever an audio or a video codec that is specified in
ConnectOptions.preferredAudioCodecs
andConnectOptions.preferredVideoCodecs
is not supported by the browser. (VIDEO-12494)
Bug Fixes
Room.getStats()
did not reject the returned Promise when an exception wasraised while accessing WebRTC stats that due to a TypeError caused by trying to read from the now-removed
RTCMediaStreamTrackStats
. (VIDEO-12534)v2.26.1
Compare Source
=========================
Bug Fixes
Room.getStats()
raises an unhandled exception due to aTypeError caused by trying to read from the now-removed
RTCMediaStreamTrackStats
. Instead, the SDK now reads fromthe
RTCMediaSourceStats
. (VIDEO-12411)attach()
method ofAudioTrack
andVideoTrack
. (VIDEO-12242)createLocalAudioTrack()
. (VIDEO-12383)v2.26.0
Compare Source
==========================
New Features
The
LocalAudioTrack
andLocalVideoTrack
classes now provide anew boolean property called
isMuted
, which lets you know if the audio or video source is currently providing raw mediasamples. The classes also emit
muted
andunmuted
events if the value ofisMuted
toggles. The application can usethese APIs to detect temporary loss of microphone or camera to other applications (ex: an incoming phone call on an iOS device),
and update the user interface accordingly. (VIDEO-11360)
The
Room
class provides a new method called refreshInactiveMedia,which restarts any muted local media Tracks, and plays any inadvertently paused HTMLMediaElements that are attached to
local and remote media Tracks. This is useful especially on iOS devices, where sometimes your application's media may
not recover after an incoming phone call. You can use this method in conjunction with the local media Track's
isMuted
property described previously to recover local and remote media after an incoming phone call as shown below. (VIDEO-11360)
Vanilla JS
html
js
React
src/hooks/useLocalMediaMuted.js
src/components/room.js
v2.25.0
Compare Source
==========================
New Features
Auto-switch default audio input devices
This release adds a new feature that preserves audio continuity in situations where end-users change the default audio input device.
A LocalAudioTrack is said to be capturing audio from the default audio input device if:
{ audio: true }
, or{ audio: { deviceId: 'foo' } }
, and "foo" is not available, or{ audio: { deviceId: { ideal: 'foo' } } }
and "foo" is not availableIn previous versions of the SDK, if the default device changed (ex: a bluetooth headset is connected to a mac or windows laptop),
the LocalAudioTrack continued to capture audio from the old default device (ex: the laptop microphone). Now, a LocalAudioTrack
will switch automatically from the old default audio input device to the new default audio input device (ex: from the laptop microphone to the headset microphone).
This feature is controlled by a new CreateLocalAudioTrackOptions
property
defaultDeviceCaptureMode
, which defaults toauto
(new behavior) or can be set tomanual
(old behavior).The application can decide to capture audio from a specific audio input device by creating a LocalAudioTrack:
{ audio: { deviceId: 'foo' } }
, and "foo" is available, or{ audio: { deviceId: { ideal: 'foo' } } }
and "foo" is available, or{ audio: { deviceId: { exact: 'foo' } } }
and "foo" is availableIn this case, the LocalAudioTrack DOES NOT switch to another audio input device if the current audio input device is no
longer available. See below for the behavior of this property based on how the LocalAudioTrack is created. (VIDEO-11701)
Limitations
v2.24.3
Compare Source
=========================
Bug Fixes
v2.24.2
Compare Source
===========================
Bug Fixes
MediaClientRemoteDescFailedError
was raised when a Chrome Participant who had enabledAdaptive Simulcast (
ConnectOptions.preferredVideoCodecs = 'auto'
) tried to publish a camera Track after publishing a<canvas>
Track. (VIDEO-11516)directives
default-src self unsafe-eval
are used. (VIDEO-11537)v2.24.1
Compare Source
==========================
Bug Fixes
Unhandled Runtime Error: TypeError: null is not an object (evaluating 'el.paused')
logLevel
as an optional property. (VIDEO-10659)import
keyword was causing problems in webpack and typescript projects. (VIDEO-11220)v2.24.0
Compare Source
========================
New Features
Bug Fixes
localAudioTrack.stop()
when using noiseCancellation (VIDEO-11047)v2.23.0
Compare Source
======================
New Features
Once you get the access to the plugin, You can install it from npm with:
Once installed, you need to host the contents of
./node_modules/<noise_cancellation_plugin>/dist/
from your web server. We recommend that you add plugin version number to the hosted path to ensure that browser does not use stale version when its updated. You need to pass the path to the hosted files totwilio-video
sdk when creating audio track as shown in the example below. The example below assumes that you have hosted the files at/noise_cancellation_plugin/1.0.0/dist
on your web server.NOTE: If your application is using the
default-src self
content security policy directive, then you should addanother directive
unsafe-eval
, which is required for the Krisp Audio Plugin to load successfully.v2.22.2
Compare Source
======================
Changes
isSupported
flag now returnsfalse
if the browser does not support the Unified Plan SDP format. (VIDEO-10307)The following is a list of browsers with Unified Plan as the default SDP format.
v2.22.1
Compare Source
======================
Bug Fixes
their quality in limited network conditions. (VIDEO-10212)
v2.22.0
Compare Source
====================
New Features
This release include the Media Warnings API (Beta) to help surface media related warning events on the SDK whenever the media server is not able to detect media from a published audio or video track.
Example
API Definitions
ConnectOptions
notifyWarnings - An array of warnings to listen to. By default, this array is empty and no warning events will be raised. Possible warning values include:
recording-media-lost
- Raised when the media server has not detected any media on the published track that is being recorded in the past 30 seconds. This usually happens when there are network interruptions or when the track has stopped.Events
The SDK raises warning events when it detects certain conditions. You can implement callbacks on these events to act on them, or to alert the user of an issue. Subsequently, "warningsCleared" event is raised when conditions have returned to normal.
LocalTrackPublication.on('warning', callback(name)) - Raised when the published Track encounters a warning.
LocalTrackPublication.on('warningsCleared', callback()) - Raised when the published Track cleared all warning.
LocalParticipant.on('trackWarning', callback(name, publication)) - Raised when one of the LocalParticipant's published tracks encounters a warning.
LocalParticipant.on('trackWarningsCleared', callback(publication)) - Raised when one of the LocalParticipant's published tracks cleared all warning.
Room.on('trackWarning', callback(name, publication, participant)) - Raised when one of the LocalParticipant's published tracks in the Room encounters a warning.
Room.on('trackWarningsCleared', callback(publication, participant)) - Raised when one of the LocalParticipant's published tracks in the Room cleared all warning.
v2.21.3
Compare Source
====================
Bug Fixes
v2.21.2
Compare Source
=====================
Bug Fixes
dimensionsChanged
event was not firing when the track dimensions first became available. (VIDEO-3576)v2.21.1
Compare Source
=======================
Bug Fixes
v2.21.0
Compare Source
======================
New Features
twilio-video.js now supports WKWebView and SFSafariViewController on iOS version 14.3 or later. The
isSupported
flag relies partly on the User-Agent string to determine if twilio-video.js officially supports the user's browser. If your application modifies the default value for the User-Agent string, the new value should follow the correct format.Additionally, for iOS applications, your application will need to include the camera usage description, microphone usage description and inline media playback in order for the SDK to work on WKWebView.
Note: As with Safari, WKWebViews only support only one local media track of each kind at a time.
We also would like to thank @cbxp for his contribution. (VIDEO-8374)
Known Issue
Some common issues such as interruptions on mobile devices which includes, backgrounding the application, or switching between applications can sometimes cause VideoTracks to go black or AudioTracks to stop.
v2.20.1
Compare Source
===================== Bug Fixes
v2.20.0
Compare Source
==========================
Changes
The Preflight API (runPreflight), originally released in 2.16.0, has been promoted to GA.
Thank you @morninng @eroidaaruqaj #1622 for your feedback. Based on this feedback, we have made the following changes to
runPreflight
. (VIDEO-7728)The failed event now provides a PreflightTestReport which include partial results gathered during the test. Use this in addition to the error object to get more insights on the failure.
Signaling and Media Connection errors are now properly surfaced via the failed event.
PreflightTestReport now includes a
progressEvents
property. This new property is an array of PreflightProgress events detected during the test. Use this information to determine which steps were completed and which ones were not.You can learn more about
runPreflight
usage in the documentation, here.Other changes in this release includes:
v2.19.1
Compare Source
=========================
Bug Fixes
v2.19.0
Compare Source
=========================
New Features
preferredVideoCodecs="auto"
in ConnectOptions. When joining a group room with this feature enabled, the SDK will use VP8 simulcast, and will enable/disable simulcast layers dynamically, thus improving bandwidth and CPU usage for the publishing client. It works best when used along withClient Track Switch Off Control
andVideo Content Preferences
. These two flags allow the SFU to determine which simulcast layers are needed, thus allowing it to disable the layers not needed on publisher side. This feature cannot be used alongsidemaxVideoBitrate
.If your application is currently using VP8 simulcast we recommend that you switch to this option.
Example:
Known Limitations
preferredVideoCodecs="auto"
will revert to unicast in the following cases:Bug Fixes
clientTrackSwitchOffControl
andcontentPreferencesMode
sometimes did not work as expected during network glitches. (VIDEO-7654)v2.18.3
Compare Source
========================
Bug Fixes
audioLevel
,frameRate
, andcaptureDimensions
WebRTC stats are returning null on certain browsers. With this release, these stats are now populated whenever they are available. (VIDEO-3600)v2.18.2
Compare Source
==========================
Bug Fixes
clientTrackSwitchOffControl
toauto
caused the RemoteVideoTracks to get switched off while playing in picture-in-picture mode. Note that this fix does not apply to Firefox as it does not yet implement picture-in-picture APIs. (VIDEO-6677)v2.18.1
Compare Source
=========================
Changes
runPreflight
). There are no changes to the public APIs in this release. (VIDEO-6891)v2.18.0
Compare Source
=========================
New Features
it will fail with a RoomTrackKindNotSupportedError. (VIDEO-7242)
Known Issue
In Firefox, although the publishing of a LocalVideoTrack in an Audio Only Group Room fails,
the RoomTrackKindNotSupportedError is not raised. We are actively working on fixing this issue.
v2.17.1
Compare Source
=========================== Bug Fixes
2.17.0
which caused Chrome screen share tracks to be encoded at lower dimensions. (VIDEO-7000)v2.17.0
Compare Source
=========================== New Features
Bug Fixes
v2.16.0
Compare Source
======================== New Features
This release includes the Preflight API Public Beta (
runPreflight
) to help test connectivity with Twilio servers. It can be used to detect issues prior to joining a Video Room or as part of a troubleshooting page.The API connects two peer connections using Twilio's Signaling and TURN servers. It publishes synthetic audio and video tracks from one participant and ensures that other participant receives media on those tracks. After successfully verifying connectivity, it generates a report with information on the connection.
runPreflight
was originally introduced as an experimental API in2.8.0-beta1
and has been updated based on feedback. In short, usage of the API will now be free of charge.Example:
The PreflightTestReport generated by
preflightTest
oncompleted
provides statistics that can be useful in cases where there is a poor connection. Some of the useful statistics in the report are as follows:progress
events, such as time to connect or to receive media.preflightTest
emits afailed
event to indicate test failures. You can use the PreflightProgress events to better understand where the test failed and refer tothis guide for interpreting common errors.
A few things to note:
testMediaConnectionBitrate
from the RTC Diagnostics SDK.Bug Fixes
Fixed a bug where the SDK was holding on to internally maintained audio elements longer than needed, now they will be cleaned up once track has started. (VIDEO-6480)
v2.15.3
Compare Source
======================
Bug Fixes
Fixed a bug where the SDK was not cleaning up internally maintained media elements. This causes memory leaks on certain use cases such as reconnecting or republishing to a room (VIDEO-6336).
Additionally, Chrome 92 started enforcing limit on number of WebMediaPlayers. This blocks creation of WebMediaPlayers once the limit is reached - 75 for desktop and 40 for mobile. This SDK update will help prevent running into this limit issue on use cases such as reconnecting or republishing to a room. Please ensure that your application cleans up media elements as well after they are detached.
Please be aware that your application may still run into the Chrome's WebMediaPlayers limit for large rooms where participants exceeds this limit.
v2.15.2
Compare Source
======================
Bug Fixes
Fixed a bug where setting clientTrackSwitchOffControl to
auto
caused the tracks to get switched off aggressively, which resulted in momentary black track during app layout changes (VIDEO-5226).v2.15.1
Compare Source
=====================
New Features
Updated June 24, 2021
Bug Fixes
v2.15.0
Compare Source
=====================
Breaking Change on Video Processor API (Beta)
VideoProcessor.processFrame method signature has been changed in order to improve the performance of the Video Processor API. With this update, the output frame buffer is now provided to the
processFrame
method which should be used to draw the processed frame.Old signature:
New signature:
Example:
Bug Fixes
Fixed a bug where
isSupported
was returningtrue
on certain unsupported mobile browsers. With this release,isSupported
should now return true only for the browsers supported by twilio-video.js.Updated NetworkQualityBandwidthStats documentation to reflect the correct bandwidth units, in bits per second, instead of bytes.
v2.14.0
Compare Source
=====================
New Features
This release contains a significant update to the Bandwidth Profile API. It allows for more efficient use of bandwidth and CPU in multi-party applications. In addition it provides developers with more dynamic control over which video tracks are delivered to the client and the preferred video resolution of the tracks. These capabilities are provided via the Client Track Switch Off Control and Content Preferences settings.
Existing Bandwidth Profile settings will continue to function as before, however we recommend developers update their Bandwidth Profile settings to make use of these new capabilities at their earliest convenience.
Client Track Switch Off Control
RemoteVideoTrack.switchOff()
/switchOn()
methods.maxTracks
property to limit the number of tracks visible, you should migrate to usingclientTrackSwitchOffControl
to take advantage of this feature.Video Content Preferences
RemoteVideoTrack.setContentPreferences()
.renderDimensions
property, you should migrate to usingcontentPreferencesMode
to take advantage of this feature.Both of these features are available in Group Rooms and are enabled by default if your application specifies Bandwidth Profile Options during connect.
Migrating to Attach APIs
The automatic behaviors rely on applications using the attach and detach methods of
RemoteVideoTrack
. If your application currently uses the underlyingMediaStreamTrack
to associate Tracks to video elements, you will need to update your application to use the attach/detach methods or use the manual APIs.Manual Controls
When manual controls are used you can operate directly on
RemoteVideoTrack
to specify preferences. For example, applications can:v2.13.1
Compare Source
=======================
New Features
Bug Fixes
v2.13.0
Compare Source
======================
New Features
Video Processor API Pilot (Chrome only)
You can now register a
VideoProcessor
with a VideoTrack in order to process its video frames. In a LocalVideoTrack, video frames are processed before being sent to the encoder. In a RemoteVideoTrack, video frames are processed before being sent to the attached<video>
element(s). TheVideoProcessor
should implement the interface shown below. (VIDEO-3560, VIDEO-3561)A VideoTrack provides new methods addProcessor and removeProcessor which can be used to add and remove a VideoProcessor. It also provides a new property
processor
which points to the current VideoProcessor being used by the VideoTrack. For example, you can toggle a blur filter on a LocalVideoTrack as shown below.You can also toggle a blur filter on a RemoteVideoTrack as shown below.
v2.12.0
Compare Source
=====================
New Features
100 Participant Rooms Pilot
A Room created with Max Participants greater than 50 is structured to support a small number of presenters and a large number of viewers. It has the following behavioral differences compared to regular Group Rooms:
publishes the first LocalTrack.
stops publishing all of its LocalTracks.
to publish more Tracks will be rejected with a
ParticipantMaxTracksExceededError
. (JSDK-3021)Bug Fixes
LocalMediaTrack.restart()
logged a warning about PeerConnection being closed in Peer to Peer Rooms. (JSDK-2912)switchedOff
event forRemoteVideoTrack
to not get emitted, which also resulted in wrong value forRemoteVideoTrack.isSwitchedOff
property. (VIDEO-3695)v2.11.0
Compare Source
=========================
You can access the types of the public API classes from the
Video
namespace as shown below:Bug Fixes
Video
namespace is not exported properly when using RequireJS. (JSDK-3129)v2.10.0
Compare Source
==========================
New Features
You can now intercept logs generated by twilio-video.js using the loglevel module. This allows for real-time processing of the logs which include but not limited to inspecting the log data and sending it to your own server. (JSDK-2373)
ConnectOptions
'slogLevel
property is now deprecated. You can instead uselogger.setLevel
to set the desired log level.Additionally,
ConnectOptions
'seventListener
property is now deprecated. You can listen for the signaling events by intercepting the logger's messages as shown in the example below. (JSDK-2977)Example:
v2.9.0
Compare Source
========================
Changes
Room.isRecording
indicated whether recording is enabled for the Room.Now it indicates if the Track published to the Room are being recorded. If recording is
enabled for the Room, then
Room.isRecording
is set totrue
when the first Track is publishedto the Room. It is set to
false
when the last Track is unpublished from the Room.The
recordingStarted
andrecordingStopped
events will be emitted on the Roomwhen
Room.isRecording
toggles. (JSDK-3064)Bug Fixes
v2.8.0
Compare Source
=========================
New Features
Enabled discontinuous transmission (DTX) in the Opus audio codec by default, which
will result in bandwidth and CPU savings during silence and background noise. You
can control this feature using the ConnectOptions property
preferredAudioCodecs
. (JSDK-3022)Bug Fixes
on some android devices. (JSDK-3003)
to a race condition. (JSDK-2807)
v2.7.3
Compare Source
========================
Bug Fixes
handling an incoming phone call. (JSDK-3031)
v2.7.2
Compare Source
=======================
Bug Fixes
Fixed a bug where a Participant in a large Group Room sometimes gets inadvertently
disconnected with a MediaServerRemoteDescFailedError. (JSDK-2893)
Fixed a bug where
Room.getStats()
returned stats for only one of the temporallayers of a VP8 simulcast VideoTrack. Now, you will have a
LocalVideoTrackStats
object for each temporal layer, which you can recognize by the
trackId
andtrackSid
properties. (JSDK-2920)Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.