@@ -1001,10 +1001,10 @@ shaka.media.StreamingEngine = class {
10011001 if ( bufferedAhead >= scaledBufferingGoal ) {
10021002 shaka . log . v2 ( logPrefix , 'buffering goal met' ) ;
10031003
1004- // Do not try to predict the next update. Just poll twice every second.
1005- // The playback rate can change at any time, so any prediction we make now
1006- // could be terribly invalid soon.
1007- return 0.5 ;
1004+ // Do not try to predict the next update. Just poll according to
1005+ // configuration (seconds). The playback rate can change at any time, so
1006+ // any prediction we make now could be terribly invalid soon.
1007+ return this . config_ . updateIntervalSeconds / 2 ;
10081008 }
10091009
10101010 const bufferEnd =
@@ -1016,7 +1016,7 @@ shaka.media.StreamingEngine = class {
10161016 // In any case just try again... if the manifest is incomplete or is not
10171017 // being updated then we'll idle forever; otherwise, we'll end up getting
10181018 // a SegmentReference eventually.
1019- return 1 ;
1019+ return this . config_ . updateIntervalSeconds ;
10201020 }
10211021
10221022 // Do not let any one stream get far ahead of any other.
@@ -1047,7 +1047,7 @@ shaka.media.StreamingEngine = class {
10471047 // For example, let video buffering catch up to audio buffering before
10481048 // fetching another audio segment.
10491049 shaka . log . v2 ( logPrefix , 'waiting for other streams to buffer' ) ;
1050- return 1 ;
1050+ return this . config_ . updateIntervalSeconds ;
10511051 }
10521052
10531053 const p = this . fetchAndAppend_ ( mediaState , presentationTime , reference ) ;
0 commit comments