File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -24,6 +24,7 @@ import {
2424
2525const SUCCESS_METRIC_POLLING_TIMEOUT_MS = 15000 ; // After this time we will stop polling for the first frame and consider the session a failure.
2626const STATS_COLLECTION_INTERVAL_MS = 5000 ;
27+ const ICE_CANDIDATE_POOL_SIZE = 2 ; // Optimisation to speed up connection time
2728
2829export class StreamingClient {
2930 private publicEventEmitter : PublicEventEmitter ;
@@ -340,6 +341,7 @@ export class StreamingClient {
340341 private async initPeerConnection ( ) {
341342 this . peerConnection = new RTCPeerConnection ( {
342343 iceServers : this . iceServers ,
344+ iceCandidatePoolSize : ICE_CANDIDATE_POOL_SIZE ,
343345 } ) ;
344346 // set event handlers
345347 this . peerConnection . onicecandidate = this . onIceCandidate . bind ( this ) ;
You can’t perform that action at this time.
0 commit comments