2018-04-26 15:33:47 +02:00
/ *
2022-01-13 11:18:47 +01:00
* ( C ) Copyright 2017 - 2022 OpenVidu ( https : //openvidu.io)
2018-04-26 15:33:47 +02:00
*
* Licensed under the Apache License , Version 2.0 ( the "License" ) ;
* you may not use this file except in compliance with the License .
* You may obtain a copy of the License at
*
* http : //www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing , software
* distributed under the License is distributed on an "AS IS" BASIS ,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND , either express or implied .
* See the License for the specific language governing permissions and
* limitations under the License .
*
* /
2018-06-27 15:15:40 +02:00
/ * *
* See [ [ OpenVidu . setAdvancedConfiguration ] ]
* /
2018-04-26 15:33:47 +02:00
export interface OpenViduAdvancedConfiguration {
/ * *
2018-06-27 15:15:40 +02:00
* Array of [ RTCIceServer ] ( https : //developer.mozilla.org/en-US/docs/Web/API/RTCIceServer) to be used by OpenVidu Browser. By default OpenVidu will generate the required credentials to use the COTURN server hosted along OpenVidu Server
* You can also set this property to string 'freeice' to force the use of free STUN servers instead ( got thanks to [ freeice ] ( https : //github.com/DamonOehlman/freeice) library).
2018-04-26 15:33:47 +02:00
* /
2018-06-08 11:07:38 +02:00
iceServers? : RTCIceServer [ ] | string ;
2018-04-26 15:33:47 +02:00
/ * *
* URL to a custom screen share extension for Chrome ( always based on ours : [ openvidu - screen - sharing - chrome - extension ] ( https : //github.com/OpenVidu/openvidu-screen-sharing-chrome-extension)) to be used instead of the default one.
* Must be something like this : ` https://chrome.google.com/webstore/detail/YOUR_WEBSTORE_EXTENSION_NAME/YOUR_EXTENSION_ID `
* /
screenShareChromeExtension? : string ;
/ * *
2020-04-05 20:03:46 +02:00
* Custom configuration for the [ [ PublisherSpeakingEvent ] ] feature and the [ StreamManagerEvent . streamAudioVolumeChange ] ( / e n / s t a b l e / a p i / o p e n v i d u - b r o w s e r / c l a s s e s / s t r e a m m a n a g e r e v e n t . h t m l ) f e a t u r e . I t i s a n o b j e c t w h i c h i n c l u d e s t h e f o l l o w i n g o p t i o n a l p r o p e r t i e s :
2019-12-10 14:14:54 +01:00
* - ` interval ` : ( number ) how frequently the analyser polls the audio stream to check if speaking has started / stopped or audio volume has changed . Default * * 100 * * ( ms )
2018-04-26 15:33:47 +02:00
* - ` threshold ` : ( number ) the volume at which _publisherStartSpeaking_ and _publisherStopSpeaking_ events will be fired . Default * * - 50 * * ( dB )
2019-12-10 14:14:54 +01:00
*
* This sets the global default configuration that will affect all streams , but you can later customize these values for each specific stream by calling [ [ StreamManager . updatePublisherSpeakingEventsOptions ] ]
2018-04-26 15:33:47 +02:00
* /
2021-05-27 21:53:01 +02:00
publisherSpeakingEventsOptions ? : {
interval? : number ;
threshold? : number ;
} ;
2018-04-26 15:33:47 +02:00
2020-02-19 09:35:10 +01:00
/ * *
* Determines the automatic reconnection process policy . Whenever the client ' s network drops , OpenVidu Browser starts a reconnection process with OpenVidu Server . After network is recovered , OpenVidu Browser automatically
* inspects all of its media streams to see their status . For any of them that are broken , it asks OpenVidu Server for a forced and silent reconnection .
*
* This policy is technically enough to recover any broken media connection after a network drop , but in practice it has been proven that OpenVidu Browser may think a media connection has properly recovered when in fact it has not .
* This is not a common case , and it only affects Publisher streams , but it may occur . This property allows * * forcing OpenVidu Browser to reconnect all of its outgoing media streams * * after a network drop regardless of their supposed status .
*
* Default to ` false ` .
* /
forceMediaReconnectionAfterNetworkDrop? : boolean ;
2021-05-25 20:22:31 +02:00
/ * *
2021-09-29 11:44:18 +02:00
* The milliseconds that must elapse after triggering [ [ ExceptionEvent ] ] of name [ ` ICE_CONNECTION_DISCONNECTED ` ] ( / e n / s t a b l e / a p i / o p e n v i d u - b r o w s e r / e n u m s / e x c e p t i o n e v e n t n a m e . h t m l # i c e _ c o n n e c t i o n _ d i s c o n n e c t e d ) t o p e r f o r m a n a u t o m a t i c r e c o n n e c t i o n p r o c e s s o f t h e a f f e c t e d m e d i a s t r e a m .
2021-05-25 20:22:31 +02:00
* This automatic reconnection process can only take place if the client still has network connection to OpenVidu Server . If the ICE connection has broken because of a total network drop ,
* then no reconnection process will be possible at all .
*
* Default to ` 4000 ` .
* /
iceConnectionDisconnectedExceptionTimeout? : number ;
/ * *
2021-09-29 11:44:18 +02:00
* The milliseconds that must elapse for the [ [ ExceptionEvent ] ] of name [ ` NO_STREAM_PLAYING_EVENT ` ] ( / e n / s t a b l e / a p i / o p e n v i d u - b r o w s e r / e n u m s / e x c e p t i o n e v e n t n a m e . h t m l # n o _ s t r e a m _ p l a y i n g _ e v e n t ) t o b e f i r e d .
2021-05-25 20:22:31 +02:00
*
* Default to ` 4000 ` .
* /
noStreamPlayingEventExceptionTimeout? : number ;
2022-01-05 15:12:51 +01:00
}