ReadonlyclosedTrue when connector is closed, in other words when onClose event is fired
ReadonlycodecsIndicate codecs supported, should be set before than onOpen happen
Start a log
ReadonlyopenedTrue when connector is opened, in other words when onOpen event is fired
Optional ReadonlystreamMedia Stream description delivred from the server if we are player, or build from the local camera if we are the streamer.
ReadonlystreamStream name, for example as+bc3f535f-37f3-458b-8171-b4c5e77a6137
Close the connector
Optionalerror: ConnectorErrorthe error reason if is not a proper close
Request connections infos with caching option to save loading cost
OptionalcacheDuration: numberindicate how many time we can cache the last connection informations
Promise with a ConnectionInfos on success
Event unsubscription
Name of event without the 'on' prefix (ex: 'log' to 'onLog' event declared)
Event subscription
Name of event without the on prefix (ex: log to onLog event declared)
Subscriber Function
Optionaloptions: { signal?: AbortSignal }Optionalsignal?: AbortSignalOptional AbortSignal to stop this or multiple subscriptions in same time
Event subscription only one time, once time fired it's automatically unsubscribe
Name of event without the on prefix (ex: log to onLog event declared)
Subscriber Function
Optionaloptions: { signal?: AbortSignal }Optionalsignal?: AbortSignalOptional AbortSignal to stop this or multiple subscriptions in same time
'video' or 'audio' to replace the track of the given kind
Promise that resolves when the track is replaced
Sets server properties for packet error (nack) and delayed packet loss (drop) for a streamer controller and fires an onRTPProps event if changed successfully. NOTE: Method can also retrieve current server values if called without arguments.
Optionalnack: numberWaiting period before declaring a packet error
Optionaldrop: numberWaiting period before considering delayed packets as lost
Configure the audio and video track to play for a player controller
Optionalaudio?: numberAudio track
Optionalvideo?: numberVideo track
Configure the video bitrate on the server side for a streamer controller
video bitrate in bps
Call when connector is closed
Optionalerror: ConnectorErrorerror description on an improper closure
Call to distribute MediaReport
Media report informations
Call when connector is open
MediaStream description provided from the server if we are the player, or build from the local camera if we are the streamer.
Call to distribute PlayingInfos
Current playing informations
Call to distribute video bitrate informations
Current video bitrate
Video bitrate constraint computed by the server
IController is a controller interface extending a stream connector with the capability of sending and receiving commands with the server.
This interface can serve the both roles: player or streamer.