diff --git a/dist/shaka-player.compiled.debug.js b/dist/shaka-player.compiled.debug.js index 20947c01f3..77deca3643 100644 --- a/dist/shaka-player.compiled.debug.js +++ b/dist/shaka-player.compiled.debug.js @@ -737,8 +737,8 @@ a.segmentIterator&&a.segmentIterator.next().value);null==f&&shaka.log.warning(d, shaka.media.StreamingEngine.prototype.fetchAndAppend_=function(a,b,c){var d=this,e,f,g,h,k,l,m,n,p,q,r,u,v,t,y,x;return $jscomp.asyncExecutePromiseGeneratorProgram(function(w){switch(w.nextAddress){case 1:return e=shaka.util.ManifestParserUtils.ContentType,f=shaka.media.StreamingEngine,g=f.logPrefix_(a),shaka.log.v1(g,"fetchAndAppend_:","presentationTime="+b,"reference.startTime="+c.startTime,"reference.endTime="+c.endTime),h=a.stream,k=a.segmentIterator,a.performingUpdate=!0,w.setCatchFinallyBlocks(2), w.yield(d.initSourceBuffer_(a,c),4);case 4:l=w.yieldResult;d.destroyer_.ensureNotDestroyed();if(d.fatalError_)return w["return"]();shaka.log.v2(g,"fetching segment");m="video/mp4"==h.mimeType||"audio/mp4"==h.mimeType;n=window.ReadableStream;if(d.config_.lowLatencyMode&&n&&m)return r=new Uint8Array(0),u=function(z){var B,A,F;return $jscomp.asyncExecutePromiseGeneratorProgram(function(H){d.destroyer_.ensureNotDestroyed();if(d.fatalError_)return H["return"]();r=d.concatArray_(r,z);B=!1;A=0;(new shaka.util.Mp4Parser).box("mdat", function(C){A=C.size+C.start;B=!0}).parse(r,!1,!0);if(!B)return H.jumpTo(0);F=r.subarray(0,A);r=r.subarray(A);return H.yield(d.append_(a,b,h,c,F),0)})},w.yield(d.fetch_(a,c,u),6);d.config_.lowLatencyMode&&!n&&shaka.log.warning("Low latency streaming mode is enabled, but ReadableStream is not supported by the browser.");p=d.fetch_(a,c);return w.yield(p,7);case 7:q=w.yieldResult;d.destroyer_.ensureNotDestroyed();if(d.fatalError_)return w["return"]();if(a.waitingToClearBuffer)return shaka.log.info(g, -"waitingToClearBuffer, skip append"),a.performingUpdate=!1,d.scheduleUpdate_(a,0),w["return"]();l&&(new shaka.util.Mp4Parser).box("moof",shaka.util.Mp4Parser.children).box("traf",shaka.util.Mp4Parser.children).fullBox("tfdt",function(z){var B,A,F,H,C;return $jscomp.asyncExecutePromiseGeneratorProgram(function(G){goog.asserts.assert(null!=z.version,"TFDT is a full box and should have a valid version.");B=shaka.util.Mp4BoxParsers.parseTFDT(z.reader,z.version);A=B.baseMediaDecodeTime;if(!A)return G["return"](); -F=A/l;if(!(Math.abs(a.lastTimestampOffset)>F))return G.jumpTo(0);H=0+a.lastAppendWindowEnd;C=0+a.lastAppendWindowStart;shaka.log.v1(g,"setting timestamp offset to "+-F);return G.yield(d.playerInterface_.mediaSourceEngine.setStreamProperties(a.type,-F,C,H),0)})}).parse(q,!1,!0);return w.yield(d.append_(a,b,h,c,q),6);case 6:d.destroyer_.ensureNotDestroyed();if(d.fatalError_)return w["return"]();a.lastSegmentReference=c;v=k.next().value;shaka.log.v2(g,"advancing to next segment",v);a.performingUpdate= +"waitingToClearBuffer, skip append"),a.performingUpdate=!1,d.scheduleUpdate_(a,0),w["return"]();l&&(new shaka.util.Mp4Parser).box("moof",shaka.util.Mp4Parser.children).box("traf",shaka.util.Mp4Parser.children).fullBox("tfdt",function(z){var B,A,F,H,C,G;return $jscomp.asyncExecutePromiseGeneratorProgram(function(D){goog.asserts.assert(null!=z.version,"TFDT is a full box and should have a valid version.");B=shaka.util.Mp4BoxParsers.parseTFDT(z.reader,z.version);A=B.baseMediaDecodeTime;if(!A)return D["return"](); +F=-A/l;H=Number(a.lastTimestampOffset)||0;if(!(H=f+a.m.presentationTimeline.g)return 1;mj(a,b,c,e)["catch"](function(){});return null} function lj(a,b,c,d){if(b.aa)return b.aa.current();if(b.ya||d)return b.aa=b.stream.segmentIndex.tb(b.ya?b.ya.endTime:d),b.aa&&b.aa.next().value;a=a.l.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.aa=b.stream.segmentIndex.tb(d),e=b.aa&&b.aa.next().value);e||(b.aa=b.stream.segmentIndex.tb(c),e=b.aa&&b.aa.next().value);return e} function mj(a,b,c,d){var e,f,g,h,k,l,m,n,p,q,u,y,w;return L(function(x){switch(x.g){case 1:return e=re,f=b.stream,g=b.aa,b.Ga=!0,C(x,2),v(x,nj(a,b,d),4);case 4:h=x.h;Re(a.i);if(a.s)return x["return"]();k="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;l=window.ReadableStream;if(a.l.lowLatencyMode&&l&&k)return p=new Uint8Array(0),q=function(D){var B,z,E;return L(function(F){Re(a.i);if(a.s)return F["return"]();p=oj(p,D);B=!1;z=0;(new xb).box("mdat",function(H){z=H.size+H.start;B=!0}).parse(p,!1,!0); -if(!B)return F.A(0);E=p.subarray(0,z);p=p.subarray(z);return v(F,pj(a,b,c,f,d,E),0)})},v(x,qj(a,b,d,q),6);m=qj(a,b,d);return v(x,m,7);case 7:n=x.h;Re(a.i);if(a.s)return x["return"]();if(b.lb)return b.Ga=!1,Zi(a,b,0),x["return"]();h&&(new xb).box("moof",Bb).box("traf",Bb).P("tfdt",function(D){var B,z,E,F,H;return L(function(I){B=Nd(D.reader,D.version);z=B.nc;if(!z)return I["return"]();E=z/h;if(!(Math.abs(b.Cc)>E))return I.A(0);F=0+b.zc;H=0+b.Ac;return v(I,rf(a.g.N,b.type,-E,H,F),0)})}).parse(n,!1, -!0);return v(x,pj(a,b,c,f,d,n),6);case 6:Re(a.i);if(a.s)return x["return"]();b.ya=d;g.next();b.Ga=!1;b.td=!1;u=a.g.N.tc();y=u[b.type];ab(JSON.stringify(y));b.lb||a.g.rd();Zi(a,b,0);ua(x,0);break;case 2:w=G(x);Re(a.i,w);if(a.s)return x["return"]();b.Ga=!1;if(7001==w.code)b.Ga=!1,b.Ja=null,Zi(a,b,0),x.A(0);else if(b.type==e.Z&&a.l.ignoreTextStreamFailures)a.h["delete"](e.Z),x.A(0);else if(3017==w.code)rj(a,b,w),x.A(0);else if(1001==w.code&&w.data&&404==w.data[1])b.Ga=!1,b.Ja=null,Zi(a,b,1),x.A(0);else return b.Tb= -!0,w.severity=2,v(x,jj(a,w),0)}})}function oj(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}function rj(a,b,c){if(!Array.from(a.h.values()).some(function(e){return e!=b&&e.td})){var d=Math.round(100*a.u);if(20a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)? !1:Hb()?!0:Ib("application/x-mpegurl")};U.setAdManagerFactory=function(a){gk=a};U.registerSupportPlugin=function(a,b){Pl[a]=b};U.prototype.destroy=U.prototype.destroy; var Ll="abrstatuschanged",Fl="adaptation",Cl="buffering",Pk="drmsessionupdate",sj="emsg",Ml="error",Ol="expirationupdated",zk="loaded",xk="loading",Kk="manifestparsed",nl="metadata",sk="onstatechange",tk="onstateidle",Dl="ratechange",Zk="streaming",Jl="textchanged",Kl="texttrackvisibility",Hk="timelineregionadded",pl="timelineregionenter",ql="timelineregionexit",Hl="trackschanged",Ck="unloading",Il="variantchanged",Ql={Hf:Ll,If:Fl,Jf:Cl,Kf:Pk,Mf:sj,Error:Ml,Nf:Ol,Of:"largegap",Pf:zk,Qf:xk,Rf:Kk,Metadata:nl, -Sf:sk,Tf:tk,Uf:Dl,Vf:"sessiondata",Wf:Zk,Xf:Jl,Yf:Kl,Zf:Hk,$f:pl,ag:ql,bg:Hl,cg:Ck,dg:Il},uk=0,dk=1,Yk=2,il=3;U.LoadMode={DESTROYED:uk,NOT_LOADED:dk,MEDIA_SOURCE:Yk,SRC_EQUALS:il};U.version="v3.1.8-41-g991915f7e-dirty";var Rl=["3","1"];Ub=new function(a){this.g=a;this.i=Vb;this.h=Wb}(new Sb(Number(Rl[0]),Number(Rl[1])));var Nl=["output-restricted","internal-error"],Pl={},gk=null;function Sl(){this.h=[];this.j=this.i=this.g=0};function V(a,b){var c=this;this.h=a;this.g=b;this.i=!1;this.l=this.g.getVolume();this.j=new Ue;this.j.v(this.g,google.ima.AdEvent.Type.PAUSED,function(){c.i=!0});this.j.v(this.g,google.ima.AdEvent.Type.RESUMED,function(){c.i=!1})}r=V.prototype;r.getDuration=function(){return this.h.getDuration()};r.getMinSuggestedDuration=function(){return this.h.getMinSuggestedDuration()};r.getRemainingTime=function(){return this.g.getRemainingTime()};r.isPaused=function(){return this.i}; +Sf:sk,Tf:tk,Uf:Dl,Vf:"sessiondata",Wf:Zk,Xf:Jl,Yf:Kl,Zf:Hk,$f:pl,ag:ql,bg:Hl,cg:Ck,dg:Il},uk=0,dk=1,Yk=2,il=3;U.LoadMode={DESTROYED:uk,NOT_LOADED:dk,MEDIA_SOURCE:Yk,SRC_EQUALS:il};U.version="v3.1.8-42-g0ca77099b-dirty";var Rl=["3","1"];Ub=new function(a){this.g=a;this.i=Vb;this.h=Wb}(new Sb(Number(Rl[0]),Number(Rl[1])));var Nl=["output-restricted","internal-error"],Pl={},gk=null;function Sl(){this.h=[];this.j=this.i=this.g=0};function V(a,b){var c=this;this.h=a;this.g=b;this.i=!1;this.l=this.g.getVolume();this.j=new Ue;this.j.v(this.g,google.ima.AdEvent.Type.PAUSED,function(){c.i=!0});this.j.v(this.g,google.ima.AdEvent.Type.RESUMED,function(){c.i=!1})}r=V.prototype;r.getDuration=function(){return this.h.getDuration()};r.getMinSuggestedDuration=function(){return this.h.getMinSuggestedDuration()};r.getRemainingTime=function(){return this.g.getRemainingTime()};r.isPaused=function(){return this.i}; r.isSkippable=function(){return 0<=this.h.getSkipTimeOffset()};r.getTimeUntilSkippable=function(){var a=this.h.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};r.canSkipNow=function(){return this.g.getAdSkippableState()};r.skip=function(){return this.g.skip()};r.pause=function(){return this.g.pause()};r.play=function(){return this.g.resume()};r.getVolume=function(){return this.g.getVolume()};r.setVolume=function(a){return this.g.setVolume(a)};r.isMuted=function(){return 0==this.g.getVolume()}; r.resize=function(a,b){this.g.resize(a,b,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};r.setMuted=function(a){a?(this.l=this.getVolume(),this.setVolume(0)):this.setVolume(this.l)};r.getSequenceLength=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getTotalAds()};r.getPositionInSequence=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getAdPosition()};r.release=function(){this.g=this.h=null};N("shaka.ads.ClientSideAd",V); V.prototype.release=V.prototype.release;V.prototype.getPositionInSequence=V.prototype.getPositionInSequence;V.prototype.getSequenceLength=V.prototype.getSequenceLength;V.prototype.setMuted=V.prototype.setMuted;V.prototype.resize=V.prototype.resize;V.prototype.isMuted=V.prototype.isMuted;V.prototype.setVolume=V.prototype.setVolume;V.prototype.getVolume=V.prototype.getVolume;V.prototype.play=V.prototype.play;V.prototype.pause=V.prototype.pause;V.prototype.skip=V.prototype.skip; -V.prototype.canSkipNow=V.prototype.canSkipNow;V.prototype.getTimeUntilSkippable=V.prototype.getTimeUntilSkippable;V.prototype.isSkippable=V.prototype.isSkippable;V.prototype.isPaused=V.prototype.isPaused;V.prototype.getRemainingTime=V.prototype.getRemainingTime;V.prototype.getMinSuggestedDuration=V.prototype.getMinSuggestedDuration;V.prototype.getDuration=V.prototype.getDuration;function Tl(a,b,c,d){var e=this;this.m=a;this.i=b;this.s=null;this.u=NaN;this.j=d;this.o=null;this.h=new Ue;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.m,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v3.1.8-41-g991915f7e-dirty");this.g=null;this.h.ra(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){Ul(e,f)});this.h.v(this.l,google.ima.AdErrorEvent.Type.AD_ERROR, +V.prototype.canSkipNow=V.prototype.canSkipNow;V.prototype.getTimeUntilSkippable=V.prototype.getTimeUntilSkippable;V.prototype.isSkippable=V.prototype.isSkippable;V.prototype.isPaused=V.prototype.isPaused;V.prototype.getRemainingTime=V.prototype.getRemainingTime;V.prototype.getMinSuggestedDuration=V.prototype.getMinSuggestedDuration;V.prototype.getDuration=V.prototype.getDuration;function Tl(a,b,c,d){var e=this;this.m=a;this.i=b;this.s=null;this.u=NaN;this.j=d;this.o=null;this.h=new Ue;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.m,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v3.1.8-42-g0ca77099b-dirty");this.g=null;this.h.ra(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){Ul(e,f)});this.h.v(this.l,google.ima.AdErrorEvent.Type.AD_ERROR, function(f){Vl(e,f)});this.i.onended=function(){e.l.contentComplete()}}Tl.prototype.stop=function(){this.g&&this.g.stop();this.m&&Fj(this.m)};Tl.prototype.release=function(){this.stop();this.s&&this.s.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy()};function Vl(a,b){b.getError();Wl(a,null);a.j(new Q("ad-cue-points-changed",(new Map).set("cuepoints",[])))} function Ul(a,b){a.j(new Q("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.u)));a.g=b.getAdsManager(a.i);a.j(new Q("ima-ad-manager-loaded",(new Map).set("imaAdManager",a.g)));var c=a.g.getCuePoints();if(c.length){var d=[];c=t(c);for(var e=c.next();!e.done;e=c.next())d.push(new Xl(e.value));a.j(new Q("ad-cue-points-changed",(new Map).set("cuepoints",d)))}Yl(a);try{a.g.init(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL), a.h.v(a.i,"loadeddata",function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),"ResizeObserver"in window&&(a.s=new ResizeObserver(function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),a.s.observe(a.i)),a.g.start()}catch(f){Wl(a,null)}} @@ -470,8 +470,8 @@ this.h.v(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,function(){e.i(new function am(a,b){a.i(new Q("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.F)));var c=b.getStreamData().url;a.j.resolve(c);a.j=null;a.C||a.h.v(a.l,"seeked",function(){var d=a.l.currentTime;if(0!=d){a.g.streamTimeForContentTime(d);var e=a.g.previousCuePointForStreamTime(d);e&&!e.played&&(a.o=d,a.l.currentTime=e.start)}})};function Y(){Mg.call(this);this.g=this.i=null;this.h=new Sl;this.j=navigator.language}pa(Y,Mg);r=Y.prototype;r.setLocale=function(a){this.j=a};r.initClientSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new O(2,10,1E4);this.i&&this.i.release();this.i=new Tl(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})}; r.release=function(){this.i&&(this.i.release(),this.i=null);this.g&&(this.g.release(),this.g=null);Mg.prototype.release.call(this)};r.onAssetUnload=function(){this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new Q("ad-stopped"));this.h=new Sl};r.requestClientSideAds=function(a){if(!this.i)throw new O(1,10,10001);var b=this.i;b.u=Date.now()/1E3;b.l.requestAds(a)}; r.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new O(2,10,10002);this.g&&this.g.release();this.g=new $l(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})}; -r.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new O(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v3.1.8-41-g991915f7e-dirty";c=this.g;var d=b;c.j?c=Promise.reject(new O(1,10,10004)):(a instanceof -google.ima.dai.api.LiveStreamRequest&&(c.C=!0),c.j=new se,c.g.requestStream(a),c.B=d||"",c.F=Date.now()/1E3,c=c.j);return c};r.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new O(1,10,10003);(a.mpt||a.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v3.1.8-41-g991915f7e-dirty";this.g.g.replaceAdTagParameters(a)}; +r.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new O(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v3.1.8-42-g0ca77099b-dirty";c=this.g;var d=b;c.j?c=Promise.reject(new O(1,10,10004)):(a instanceof +google.ima.dai.api.LiveStreamRequest&&(c.C=!0),c.j=new se,c.g.requestStream(a),c.B=d||"",c.F=Date.now()/1E3,c=c.j);return c};r.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new O(1,10,10003);(a.mpt||a.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v3.1.8-42-g0ca77099b-dirty";this.g.g.replaceAdTagParameters(a)}; r.getStats=function(){var a=this.h;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};r.onDashTimedMetadata=function(a){if(this.g&&"urn:google:dai:2018"==a.schemeIdUri){var b=a.schemeIdUri,c=a.eventElement?a.eventElement.getAttribute("messageData"):null;this.g.g.processMetadata(b,c,a.startTime)}};r.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};r.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};N("shaka.ads.AdManager",Y); Y.prototype.onCueMetadataChange=Y.prototype.onCueMetadataChange;Y.prototype.onHlsTimedMetadata=Y.prototype.onHlsTimedMetadata;Y.prototype.onDashTimedMetadata=Y.prototype.onDashTimedMetadata;Y.prototype.getStats=Y.prototype.getStats;Y.prototype.replaceServerSideAdTagParameters=Y.prototype.replaceServerSideAdTagParameters;Y.prototype.requestServerSideStream=Y.prototype.requestServerSideStream;Y.prototype.initServerSide=Y.prototype.initServerSide;Y.prototype.requestClientSideAds=Y.prototype.requestClientSideAds; Y.prototype.onAssetUnload=Y.prototype.onAssetUnload;Y.prototype.release=Y.prototype.release;Y.prototype.initClientSide=Y.prototype.initClientSide;Y.prototype.setLocale=Y.prototype.setLocale;function Xl(a,b){this.start=a;this.end=void 0===b?null:b}Y.ADS_LOADED="ads-loaded";Y.AD_STARTED="ad-started";Y.AD_FIRST_QUARTILE="ad-first-quartile";Y.AD_MIDPOINT="ad-midpoint";Y.AD_THIRD_QUARTILE="ad-third-quartile";Y.AD_COMPLETE="ad-complete";Y.AD_STOPPED="ad-stopped";Y.AD_SKIPPED="ad-skipped"; @@ -548,30 +548,30 @@ function go(a){var b=a.g.X(),c=a.g.W();if(0==c)throw new O(2,3,3002);c=8-Math.fl function jo(a){if(8h()&&!R.length?null:R})}return Promise.resolve(H)} +function Co(a,b,c,d,e){function f(I){var K=(I-q)*p,R=K+b.Sa,M=K+l;K=M+p;var W=Math.min(K,h());M=new hi(M,W,function(){var fa=Wn(y,x,I,w,R*u);return le(D,[fa])},0,null,d,B,l,h());M.j=K;return M}function g(){var I=[Math.max(k.Qa(),l),Math.min(k.bb(),h())].map(function(K){return K-l});return[Math.ceil(I[0]/p),Math.ceil(I[1]/p)-1].map(function(K){return K+q})}function h(){var I=null!=m&&e[m]||n;return I?l+I:Infinity}var k=a.presentationTimeline,l=a.T.start,m=a.ca.id,n=a.T.duration,p=b.ga,q=b.Db,u=b.timescale, +y=b.md,w=a.bandwidth||null,x=a.H.id,D=a.H.wa,B=l-b.Sa,z=g();a=a.Za?Math.max(z[0],z[1]-c+1):z[0];z=z[1];c=[];for(var E=a;E<=z;++E){var F=f(E);c.push(F)}var H=new T(c);c=k.bb()h()&&!R.length?null:R})}return Promise.resolve(H)} function Do(a,b,c){var d=a.T.start,e=a.T.duration,f=d-b.Sa;e=e?d+e:Infinity;for(var g=[],h={},k=0;k=c?g.push(new Set(b[h])):g.push(new Set);k=t(a);l=k.next();case 2:if(l.done){K.A(4);break}m=l.value;return v(K,To(m,b,c,e,g),5);case 5:n=K.h;if(!n)throw new O(2,4,4037);l=k.next();K.A(2);break;case 4:p=t(g),q=p.next();case 6:if(q.done){K.A(8);break}u=q.value;y=t(u);w=y.next();case 9:if(w.done){q=p.next();K.A(6);break}x=w.value;return v(K,Uo(x,b,d,e,g),12); -case 12:(D=K.h)&&a.push(D);w=y.next();K.A(9);break;case 8:B=t(g);for(q=B.next();!q.done;q=B.next())for(z=q.value,E={},F=t(z),w=F.next();!w.done;E={Ua:E.Ua},w=F.next())if(E.Ua=w.value,H=E.Ua.type==f.Z&&!E.Ua.language,I=E.Ua.type==f.ic&&!E.Ua.tilesLayout,!H&&!I&&(J=a.some(function(R){return function(M){return M.mimeType==R.Ua.mimeType&&Fe(M.codecs)==Fe(R.Ua.codecs)}}(E))))throw new O(2,4,4037);return K["return"](a)}})} +function Mo(a,b,c,d,e){var f,g,h,k,l,m,n,p,q,u,y,w,x,D,B,z,E,F,H,J,I;return L(function(K){switch(K.g){case 1:f=re;g=[];for(h=0;h=c?g.push(new Set(b[h])):g.push(new Set);k=t(a);l=k.next();case 2:if(l.done){K.A(4);break}m=l.value;return v(K,To(m,b,c,e,g),5);case 5:n=K.h;if(!n)throw new O(2,4,4037);l=k.next();K.A(2);break;case 4:p=t(g),q=p.next();case 6:if(q.done){K.A(8);break}u=q.value;y=t(u);w=y.next();case 9:if(w.done){q=p.next();K.A(6);break}x=w.value;return v(K,Uo(x,b,d,e,g),12); +case 12:(D=K.h)&&a.push(D);w=y.next();K.A(9);break;case 8:B=t(g);for(q=B.next();!q.done;q=B.next())for(z=q.value,E={},F=t(z),w=F.next();!w.done;E={Ua:E.Ua},w=F.next())if(E.Ua=w.value,H=E.Ua.type==f.Z&&!E.Ua.language,J=E.Ua.type==f.ic&&!E.Ua.tilesLayout,!H&&!J&&(I=a.some(function(R){return function(M){return M.mimeType==R.Ua.mimeType&&Fe(M.codecs)==Fe(R.Ua.codecs)}}(E))))throw new O(2,4,4037);return K["return"](a)}})} function To(a,b,c,d,e){var f;return L(function(g){if(1==g.g)return(f=Vo(b,a))?v(g,Wo(f),2):g["return"](!1);Xo(a,f,c,d,e);return g["return"](!0)})}function Wo(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,b.push(c.createSegmentIndex()),c.trickModeVideo&&!c.trickModeVideo.segmentIndex&&b.push(c.trickModeVideo.createSegmentIndex());return Promise.all(b)} function Uo(a,b,c,d,e){var f,g;return L(function(h){if(1==h.g)return f=c(a),(g=Vo(b,f))?f.createSegmentIndex?v(h,Wo(g),2):h.A(2):h["return"](null);Xo(f,g,0,d,e);return h["return"](f)})}function Xo(a,b,c,d,e){for(var f=0;f=c){var g=b[f];d(a,g);var h=!0;"audio"==a.type&&0==Bf(a.language,g.language)&&(h=!1);h&&e[f]["delete"](g)}} function No(a){a=Object.assign({},a);a.originalId=null;a.createSegmentIndex=function(){return Promise.resolve()};a.segmentIndex=new Gi;a.emsgSchemeIdUris=[];a.keyIds=new Set;a.closedCaptions=null;a.trickModeVideo=null;return a}function Ro(a){a=Object.assign({},a);a.keyIds=new Set;a.segments=[];a.variantIds=[];a.closedCaptions=null;return a} @@ -591,8 +591,8 @@ r.start=function(a,b){var c=this,d;return L(function(e){if(1==e.g)return c.m=b.i r.update=function(){var a=this,b;return L(function(c){if(1==c.g)return C(c,2),v(c,lp(a),4);if(2!=c.g)return ua(c,0);b=G(c);if(!a.h||!b)return c["return"]();a.h.onError(b);A(c)})};r.onExpirationUpdated=function(){}; function lp(a){var b,c,d,e,f,g,h;return L(function(k){if(1==k.g)return b=Vg(a.l,a.g.retryParameters),c=a.h.networkingEngine,d=Date.now(),e=c.request(0,b),Qg(a.o,e),v(k,e.promise,2);if(3!=k.g){f=k.h;if(!a.h)return k["return"](0);f.uri&&!a.l.includes(f.uri)&&a.l.unshift(f.uri);return v(k,np(a,f.data,f.uri),3)}g=Date.now();h=(g-d)/1E3;a.K.sample(1,h);return k["return"](h)})} function np(a,b,c){var d,e,f,g,h;return L(function(k){if(1==k.g){d=Ln(b,"MPD");if(!d)throw new O(2,4,4001,c);if(e=a.g.dash.disableXlinkProcessing)return k["return"](op(a,d,c));f=a.g.dash.xlinkFailGracefully;g=ao(d,a.g.retryParameters,f,c,a.h.networkingEngine);Qg(a.o,g);return v(k,g.promise,2)}h=k.h;return k["return"](op(a,h,c))})} -function op(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,u,y,w,x,D,B,z,E,F,H,I,J,K,R,M,W,fa,Ua,Fa,Ka,Ga,pb,Pa;return L(function(Va){switch(Va.g){case 1:d=[c];e=tn(b,"Location").map(zn).filter(Mc);0=c&&202!=c)return{uri:e||d,Zd:d,data:b,headers:a,fromCache:!!a["x-shaka-from-cache"]};e=null;try{e=rb(b)}catch(g){}throw new O(401==c||403==c?2:1,1,1001,d,c,e,a,f);};function Mq(){}function Nq(a,b,c,d){var e=new Oq;gh(b.headers).forEach(function(k,l){e.append(l,k)});var f=new Pq,g={Jd:!1,ke:!1};a=Qq(a,c,{body:b.body||void 0,headers:e,method:b.method,signal:f.signal,credentials:b.allowCrossSiteCredentials?"include":void 0},g,d,b.streamDataCallback);a=new Eg(a,function(){g.Jd=!0;f.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var h=new P(function(){g.ke=!0;f.abort()});h.S(b/1E3);a["finally"](function(){h.stop()})}return a} -function Qq(a,b,c,d,e,f){var g,h,k,l,m,n,p,q,u,y,w,x,D,B;return L(function(z){switch(z.g){case 1:return g=Rq,h=Sq,n=m=0,p=Date.now(),C(z,2),v(z,g(a,c),4);case 4:return k=z.h,q=k.clone().body.getReader(),y=(u=k.headers.get("Content-Length"))?parseInt(u,10):0,w=function(E){function F(){var H,I;return L(function(J){switch(J.g){case 1:return C(J,2),v(J,q.read(),4);case 4:H=J.h;ua(J,3);break;case 2:return G(J),J["return"]();case 3:if(H.done){J.A(5);break}m+=H.value.byteLength;if(!f){J.A(5);break}return v(J, -f(H.value),5);case 5:I=Date.now();if(100F))return G.jumpTo(0);H=0+a.lastAppendWindowEnd;C=0+a.lastAppendWindowStart;shaka.log.v1(g,"setting timestamp offset to "+-F);return G.yield(d.playerInterface_.mediaSourceEngine.setStreamProperties(a.type,-F,C,H),0)})}).parse(q,!1,!0);return w.yield(d.append_(a,b,h,c,q),6);case 6:d.destroyer_.ensureNotDestroyed();if(d.fatalError_)return w["return"]();a.lastSegmentReference=c;v=k.next().value;shaka.log.v2(g,"advancing to next segment",v);a.performingUpdate= +"waitingToClearBuffer, skip append"),a.performingUpdate=!1,d.scheduleUpdate_(a,0),w["return"]();l&&(new shaka.util.Mp4Parser).box("moof",shaka.util.Mp4Parser.children).box("traf",shaka.util.Mp4Parser.children).fullBox("tfdt",function(z){var B,A,F,H,C,G;return $jscomp.asyncExecutePromiseGeneratorProgram(function(D){goog.asserts.assert(null!=z.version,"TFDT is a full box and should have a valid version.");B=shaka.util.Mp4BoxParsers.parseTFDT(z.reader,z.version);A=B.baseMediaDecodeTime;if(!A)return D["return"](); +F=-A/l;H=Number(a.lastTimestampOffset)||0;if(!(Ha.end(0)-a.start(0))retur function Te(a,b){if(!Qe.get("muxjs")()||!Ue(a))return!1;if(b)return MediaSource.isTypeSupported(Ve(b,a));var c=Ve("audio",a),d=Ve("video",a);return MediaSource.isTypeSupported(c)||MediaSource.isTypeSupported(d)}function Ue(a){return"mp2t"==a.toLowerCase().split(";")[0].split("/")[1]} function Ve(a,b){var c=b.replace(/mp2t/i,"mp4");"audio"==a&&(c=c.replace("video","audio"));var d=/avc1\.(66|77|100)\.(\d+)/.exec(c);if(d){var e="avc1.",f=d[1],g=Number(d[2]);e=("66"==f?e+"4200":"77"==f?e+"4d00":e+"6400")+(g>>4).toString(16);e+=(g&15).toString(16);c=c.replace(d[0],e)}return c}function We(a,b){a.l=!0;a.h=new Oe;a.m=[];a.j=[];a.i=[];var c=hc(b);a.g.push(c);a.g.flush();a.l&&a.h.reject(new Q(2,3,3018));return a.h};function Xe(a,b){var c=a;b&&(c+='; codecs="'+b+'"');return c}function Ye(a,b,c){a=Xe(a,b);return Qe.get("muxjs")()&&Ue(a)?Ve(c,a):a}function Ze(a){var b=[a.mimeType];$e.forEach(function(c,d){var e=a[d];e&&b.push(c+'="'+e+'"')});"PQ"==a.hdr&&b.push('eotf="smpte2084"');return b.join(";")}function af(a){a=a.split(".");var b=a[0];a.pop();return b}function bf(a){a=a.split(/ *; */);a.shift();return(a=a.find(function(b){return b.startsWith("codecs=")}))?a.split("=")[1].replace(/^"|"$/g,""):""} var $e=(new Map).set("codecs","codecs").set("frameRate","framerate").set("bandwidth","bitrate").set("width","width").set("height","height").set("channelsCount","channels");function cf(a){this.l=null;this.i=a;this.j=this.B=0;this.m=Infinity;this.h=this.g=null;this.A="";this.v=new Map}function df(a){return ef[a]||"application/cea-608"==a||"application/cea-708"==a?!0:!1}cf.prototype.destroy=function(){this.i=this.l=null;this.v.clear();return Promise.resolve()}; -function ff(a,b,c,d){var e,f,g;return J(function(h){if(1==h.g)return A(h,Promise.resolve(),2);if(!a.l||!a.i)return h["return"]();if(null==c||null==d)return a.l.parseInit(hc(b)),h["return"]();e={periodStart:a.B,segmentStart:c,segmentEnd:d};f=a.l.parseMedia(hc(b),e);g=f.filter(function(k){return k.startTime>=a.j&&k.startTime=c.h||(a<=c.g&&b>=c.h?c.g=c.h=null:a<=c.g&&bc.g&&b>=c.h&&(c.h=a));C(d)})};function gf(a,b,c){a.j=b;a.m=c}function hf(a,b,c){a.A=b;if(b=a.v.get(b))for(var d=t(b.keys()),e=d.next();!e.done;e=d.next())(e=b.get(e.value).filter(function(f){return f.endTime<=c}))&&a.i.append(e)} +function ff(a,b,c,d){var e,f,g;return K(function(h){if(1==h.g)return A(h,Promise.resolve(),2);if(!a.l||!a.i)return h["return"]();if(null==c||null==d)return a.l.parseInit(hc(b)),h["return"]();e={periodStart:a.B,segmentStart:c,segmentEnd:d};f=a.l.parseMedia(hc(b),e);g=f.filter(function(k){return k.startTime>=a.j&&k.startTime=c.h||(a<=c.g&&b>=c.h?c.g=c.h=null:a<=c.g&&bc.g&&b>=c.h&&(c.h=a));C(d)})};function gf(a,b,c){a.j=b;a.m=c}function hf(a,b,c){a.A=b;if(b=a.v.get(b))for(var d=t(b.keys()),e=d.next();!e.done;e=d.next())(e=b.get(e.value).filter(function(f){return f.endTime<=c}))&&a.i.append(e)} function jf(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,b.push({stream:c.stream,cue:new gd(c.startTime,c.endTime,c.text)});return b}function kf(a,b,c){b.startTime+=c;b.endTime+=c;b=t(b.nestedCues);for(var d=b.next();!d.done;d=b.next())kf(a,d.value,c)} function lf(a,b,c,d,e){var f=c+" "+d,g=new Map;b=t(b);for(var h=b.next();!h.done;h=b.next()){var k=h.value;h=k.stream;k=k.cue;g.has(h)||g.set(h,new Map);g.get(h).has(f)||g.get(h).set(f,[]);kf(a,k,e);k.startTime>=a.j&&k.startTimec.end(0)-c.start(0)?null:1==c.length&&0>c.start(0)?0:c.length?c.start(0):null;return c}function Df(a,b){return b==Mb?a.g.h:Je(Cf(a,b))} function Ef(a,b,c){if(b==Mb)return a=a.g,null==a.h||a.h=e?zf(a,b):a.h[b].remove(0,e)}),0)})}q.flush=function(a){var b=this,c;return J(function(d){c=Nb;return a==c.ka?d["return"]():A(d,Hf(b,a,function(){b.j.currentTime-=.001;zf(b,a)}),0)})}; -function Lf(a,b,c,d,e){var f;return J(function(g){f=Nb;return b==f.ka?(a.g.B=c,gf(a.g,d,e),g["return"]()):A(g,Promise.all([Hf(a,b,function(){var h=a.h[b].appendWindowStart,k=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=h;a.h[b].appendWindowEnd=k;zf(a,b)}),Hf(a,b,function(){var h=c;0>h&&(h+=.001);a.h[b].timestampOffset=h;zf(a,b)}),Hf(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;zf(a,b)})]),0)})} -q.endOfStream=function(a){var b=this;return J(function(c){return A(c,Mf(b,function(){Af(b)||(a?b.m.endOfStream(a):b.m.endOfStream())}),0)})};q.Za=function(a){var b=this;return J(function(c){return A(c,Mf(b,function(){b.m.duration=a}),0)})};q.getDuration=function(){return this.m.duration};function zf(a,b){var c=a.i[b][0];c&&(c.p.resolve(),Nf(a,b))}function Hf(a,b,c){nf(a.D);c={start:c,p:new Oe};a.i[b].push(c);1==a.i[b].length&&Of(a,b);return c.p} -function Mf(a,b){var c,d,e,f,g,h;return J(function(k){switch(k.g){case 1:nf(a.D);c=[];d={};for(e in a.h)d.kc=new Oe,f={start:function(l){return function(){return l.kc.resolve()}}(d),p:d.kc},a.i[e].push(f),c.push(d.kc),1==a.i[e].length&&f.start(),d={kc:d.kc};G(k,2);return A(k,Promise.all(c),4);case 4:ua(k,3);break;case 2:throw g=I(k),g;case 3:try{b()}catch(l){throw new Q(2,3,3015,l);}finally{for(h in a.h)Nf(a,h)}C(k)}})}function Nf(a,b){a.i[b].shift();Of(a,b)} +function Ff(a,b,c,d,e,f){var g,h,k,l,m,n,p,r;return K(function(v){if(1==v.g){g=Nb;if(b==g.ka)return A(v,ff(a.g,c,d,e),0);if(a.A[b])return A(v,We(a.A[b],c),10);if(f)return a.g||yf(a,"text/vtt"),null==d&&null==e?a.B.init(c):(h=Ie(a.B,c),h.length&&(k=a.h[g.bb].timestampOffset,lf(a.g,h,d,e,k))),c=Gf(a,c,d,b),A(v,Hf(a,b,function(){a.h[b].appendBuffer(c)}),0);c=Gf(a,c,d,b);return A(v,Hf(a,b,function(){a.h[b].appendBuffer(c)}),0)}l=v.h;a.g||yf(a,"text/vtt");l.metadata&&(m=a.h[b].timestampOffset,a.J(l.metadata, +m,e));l.captions&&l.captions.length&&(n=a.h[g.bb].timestampOffset,p=jf(l.captions),lf(a.g,p,d,e,n));r=l.data;r=Gf(a,r,d,b);return A(v,Hf(a,b,function(){a.h[b].appendBuffer(r)}),0)})}function If(a,b){var c=Df(a,"video")||0;hf(a.g,b,c)}function Jf(a){a.g&&hf(a.g,"",0)}q.remove=function(a,b,c){var d=this,e;return K(function(f){e=Nb;return a==e.ka?A(f,d.g.remove(b,c),0):A(f,Hf(d,a,function(){c<=b?zf(d,a):d.h[a].remove(b,c)}),0)})}; +function Kf(a,b){var c;return K(function(d){c=Nb;return b==c.ka?a.g?A(d,a.g.remove(0,Infinity),0):d["return"]():A(d,Hf(a,b,function(){var e=a.m.duration;0>=e?zf(a,b):a.h[b].remove(0,e)}),0)})}q.flush=function(a){var b=this,c;return K(function(d){c=Nb;return a==c.ka?d["return"]():A(d,Hf(b,a,function(){b.j.currentTime-=.001;zf(b,a)}),0)})}; +function Lf(a,b,c,d,e){var f;return K(function(g){f=Nb;return b==f.ka?(a.g.B=c,gf(a.g,d,e),g["return"]()):A(g,Promise.all([Hf(a,b,function(){var h=a.h[b].appendWindowStart,k=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=h;a.h[b].appendWindowEnd=k;zf(a,b)}),Hf(a,b,function(){var h=c;0>h&&(h+=.001);a.h[b].timestampOffset=h;zf(a,b)}),Hf(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;zf(a,b)})]),0)})} +q.endOfStream=function(a){var b=this;return K(function(c){return A(c,Mf(b,function(){Af(b)||(a?b.m.endOfStream(a):b.m.endOfStream())}),0)})};q.Za=function(a){var b=this;return K(function(c){return A(c,Mf(b,function(){b.m.duration=a}),0)})};q.getDuration=function(){return this.m.duration};function zf(a,b){var c=a.i[b][0];c&&(c.p.resolve(),Nf(a,b))}function Hf(a,b,c){nf(a.D);c={start:c,p:new Oe};a.i[b].push(c);1==a.i[b].length&&Of(a,b);return c.p} +function Mf(a,b){var c,d,e,f,g,h;return K(function(k){switch(k.g){case 1:nf(a.D);c=[];d={};for(e in a.h)d.kc=new Oe,f={start:function(l){return function(){return l.kc.resolve()}}(d),p:d.kc},a.i[e].push(f),c.push(d.kc),1==a.i[e].length&&f.start(),d={kc:d.kc};G(k,2);return A(k,Promise.all(c),4);case 4:ua(k,3);break;case 2:throw g=I(k),g;case 3:try{b()}catch(l){throw new Q(2,3,3015,l);}finally{for(h in a.h)Nf(a,h)}C(k)}})}function Nf(a,b){a.i[b].shift();Of(a,b)} function Of(a,b){var c=a.i[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new Q(2,3,3017,b)):c.p.reject(new Q(2,3,3015,d)),Nf(a,b)}}function Gf(a,b,c,d){var e=a.j.mediaKeys;null==c&&e&&Jc()&&"mp4"==a.I[d].split(";")[0].split("/")[1]&&(b=Zc(b));return b}var wf=window.URL.createObjectURL;function Pf(a,b){var c=Qf(a.variants,b);c=Rf(c);c=Sf(c);var d=Tf(c);a.variants=a.variants.filter(function(e){return Uf(e)==d?!0:!1})}function Rf(a){var b=new $a;a=t(a);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=Uf(c);b.push(d,c)}return b} function Sf(a){var b=0,c=new Map,d=a.size();ab(a,function(e,f){for(var g=t(f),h=g.next();!h.done;h=g.next()){h=h.value;var k=h.video;if(k&&k.width&&k.height){k=k.width*k.height*(k.frameRate||1);c.has(k)||c.set(k,new $a);var l=c.get(k);l.push(e,h);l.size()===d&&(b=Math.max(b,k))}}});return b?c.get(b):a}function Tf(a){var b="",c=Infinity;ab(a,function(d,e){for(var f=0,g=0,h=t(e),k=h.next();!k.done;k=h.next())f+=k.value.bandwidth||0,++g;f/=g;f=g&&f<=h}var e=a.video;return e&&e.width&&e.height&&(!d(e.width,b.minWidth,Math.min(b.maxWidth,c.width))||!d(e.height,b.minHeight,Math.min(b.maxHeight,c.height))||!d(e.width*e.height,b.minPixels,b.maxPixels))||a&&a.video&&a.video.frameRate&&!d(a.video.frameRate,b.minFrameRate,b.maxFrameRate)||!d(a.bandwidth,b.minBandwidth,b.maxBandwidth)?!1:!0} -function Xf(a,b,c,d){return J(function(e){if(1==e.g)return d?A(e,ag(c,0=a.l)if(a.i)a.g=1,a.h=a.j;else throw new Q(2,7,1010);b=a.g;a.g++;if(0==b)return d["return"]();c=a.h*(1+(2*Math.random()-1)*a.v);return A(d,new Promise(function(e){(new R(e)).R(c/1E3)}),2)}a.h*=a.m;C(d)})}function Og(){return{maxAttempts:2,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:3E4,stallTimeout:5E3,connectionTimeout:1E4}};function Qg(a,b){this.promise=a;this.i=b;this.g=!1}function Rg(a){return new Qg(Promise.reject(a),function(){return Promise.resolve()})}function Sg(){var a=Promise.reject(new Q(2,7,7001));a["catch"](function(){});return new Qg(a,function(){return Promise.resolve()})}function Tg(a){return new Qg(Promise.resolve(a),function(){return Promise.resolve()})}function Ug(a){return new Qg(a,function(){return a["catch"](function(){})})}Qg.prototype.abort=function(){this.g=!0;return this.i()}; +function Pg(a){var b,c;return K(function(d){if(1==d.g){if(a.g>=a.l)if(a.i)a.g=1,a.h=a.j;else throw new Q(2,7,1010);b=a.g;a.g++;if(0==b)return d["return"]();c=a.h*(1+(2*Math.random()-1)*a.v);return A(d,new Promise(function(e){(new R(e)).R(c/1E3)}),2)}a.h*=a.m;C(d)})}function Og(){return{maxAttempts:2,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:3E4,stallTimeout:5E3,connectionTimeout:1E4}};function Qg(a,b){this.promise=a;this.i=b;this.g=!1}function Rg(a){return new Qg(Promise.reject(a),function(){return Promise.resolve()})}function Sg(){var a=Promise.reject(new Q(2,7,7001));a["catch"](function(){});return new Qg(a,function(){return Promise.resolve()})}function Tg(a){return new Qg(Promise.resolve(a),function(){return Promise.resolve()})}function Ug(a){return new Qg(a,function(){return a["catch"](function(){})})}Qg.prototype.abort=function(){this.g=!0;return this.i()}; function Vg(a){return new Qg(Promise.all(a.map(function(b){return b.promise})),function(){return Promise.all(a.map(function(b){return b.abort()}))})}Qg.prototype["finally"]=function(a){this.promise.then(function(){return a(!0)},function(){return a(!1)});return this}; Qg.prototype.ma=function(a,b){function c(h){return function(k){if(e.g&&h)f.reject(g);else{var l=h?a:b;l?d=Wg(l,k,f):(h?f.resolve:f.reject)(k)}}}function d(){f.reject(g);return e.abort()}var e=this,f=new Oe,g=new Q(2,7,7001);this.promise.then(c(!0),c(!1));return new Qg(f,function(){return d()})}; function Wg(a,b,c){try{var d=a(b);if(d&&d.promise&&d.abort)return c.resolve(d.promise),function(){return d.abort()};c.resolve(d);return function(){return Promise.resolve(d).then(function(){},function(){})}}catch(e){return c.reject(e),function(){return Promise.resolve()}}}N("shaka.util.AbortableOperation",Qg);Qg.prototype.chain=Qg.prototype.ma;Qg.prototype["finally"]=Qg.prototype["finally"];Qg.all=Vg;Qg.prototype.abort=Qg.prototype.abort;Qg.notAbortable=Ug;Qg.completed=Tg;Qg.aborted=Sg;Qg.failed=Rg;function Xg(a){function b(d){switch(typeof d){case "undefined":case "boolean":case "number":case "string":case "symbol":case "function":return d;default:if(!d||d.buffer&&d.buffer.constructor==ArrayBuffer)return d;if(c.has(d))return null;var e=d.constructor==Array;if(d.constructor!=Object&&!e)return null;c.add(d);var f=e?[]:{},g;for(g in d)f[g]=b(d[g]);e&&(f.length=d.length);return f}}var c=new Set;return b(a)}function Yg(a){var b={},c;for(c in a)b[c]=a[c];return b};function Zg(){this.g=[]}function $g(a,b){a.g.push(b["finally"](function(){dd(a.g,b)}))}Zg.prototype.destroy=function(){for(var a=[],b=t(this.g),c=b.next();!c.done;c=b.next())c=c.value,c.promise["catch"](function(){}),a.push(c.abort());this.g=[];return Promise.all(a)};function ah(a){db.call(this);this.i=!1;this.l=new Zg;this.g=new Set;this.h=new Set;this.j=a||null;this.m=!1}u(ah,db);q=ah.prototype;q.ge=function(a){this.m=a};function bh(a,b,c,d){c=c||ch;var e=dh[a];if(!e||c>=e.priority)dh[a]={priority:c,pg:b,qg:void 0===d?!1:d}}q.rg=function(a){this.g.add(a)};q.Hg=function(a){this.g["delete"](a)};q.vf=function(){this.g.clear()};q.sg=function(a){this.h.add(a)};q.Ig=function(a){this.h["delete"](a)};q.wf=function(){this.h.clear()}; @@ -218,41 +218,41 @@ x&&(p=new R(function(){v=!0;w.abort()}),p.R(x/1E3));var D=c.retryParameters.stal return ih(a,b,c,d,e,w,g)}}throw w;})}function jh(a,b,c){var d=Tg(void 0),e={};a=t(a.h);for(var f=a.next();!f.done;e={Dd:e.Dd},f=a.next())e.Dd=f.value,d=d.ma(function(g){return function(){var h=c.response;h.data&&(h.data=ic(h.data));return g.Dd(b,h)}}(e));return d.ma(function(){return c},function(g){var h=2;if(g instanceof Q){if(7001==g.code)throw g;h=g.severity}throw new Q(h,1,1007,g);})}N("shaka.net.NetworkingEngine",ah);ah.prototype.request=ah.prototype.request;ah.prototype.destroy=ah.prototype.destroy; ah.makeRequest=eh;ah.defaultRetryParameters=function(){return Og()};ah.prototype.clearAllResponseFilters=ah.prototype.wf;ah.prototype.unregisterResponseFilter=ah.prototype.Ig;ah.prototype.registerResponseFilter=ah.prototype.sg;ah.prototype.clearAllRequestFilters=ah.prototype.vf;ah.prototype.unregisterRequestFilter=ah.prototype.Hg;ah.prototype.registerRequestFilter=ah.prototype.rg;ah.unregisterScheme=function(a){delete dh[a]};ah.registerScheme=bh;ah.prototype.setForceHTTPS=ah.prototype.ge; function fh(){this.g=0}ah.NumBytesRemainingClass=fh;function gh(a,b,c){Qg.call(this,a,b);this.h=c}u(gh,Qg);ah.PendingRequest=gh;var kh=1;ah.RequestType={MANIFEST:0,SEGMENT:kh,LICENSE:2,APP:3,TIMING:4};var ch=3;ah.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:ch};var dh={};function lh(){}function mh(a){a=qc(a);return(new kb(a)).Va}function nh(a,b,c){function d(h){kc(f).setUint32(g,h.byteLength,!0);g+=4;f.set(hc(h),g);g+=h.byteLength}if(!c||!c.byteLength)throw new Q(2,6,6015);var e;"string"==typeof b?e=sc(b,!0):e=b;a=qc(a);a=sc(a,!0);var f=new Uint8Array(12+a.byteLength+e.byteLength+c.byteLength),g=0;d(a);d(e);d(c);return f}N("shaka.util.FairPlayUtils",lh);lh.initDataTransform=nh;lh.defaultGetContentId=mh;function oh(a){for(var b=new Map,c=t(Object.keys(a)),d=c.next();!d.done;d=c.next())d=d.value,b.set(d,a[d]);return b}function ph(a){var b={};a.forEach(function(c,d){b[d]=c});return b}function qh(a,b){if(a||b){if(a&&!b||b&&!a)return!1}else return!0;if(a.size!=b.size)return!1;for(var c=t(a),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;if(!b.has(d))return!1;d=b.get(d);if(d!=e||void 0==d)return!1}return!0};function rh(a,b){var c=this;b=void 0===b?1:b;this.I=a;this.D=new Set;this.j=this.A=null;this.$=this.M=!1;this.J=0;this.g=null;this.v=new of;this.i=new Map;this.F=[];this.B=new Oe;this.h=null;this.m=function(d){c.B.reject(d);a.onError(d)};this.aa=new Map;this.ua=new Map;this.U=new R(function(){return sh(c)});this.G=!1;this.K=[];this.P=!1;this.Z=(new R(function(){th(c)})).ha(b);this.B["catch"](function(){});this.l=new mf(function(){return uh(c)});this.X=!1}q=rh.prototype;q.destroy=function(){return this.l.destroy()}; -function uh(a){return J(function(b){switch(b.g){case 1:return a.v.release(),a.v=null,a.B.reject(),a.Z.stop(),a.Z=null,a.U.stop(),a.U=null,A(b,vh(a),2);case 2:if(!a.j){b.C(3);break}G(b,4);return A(b,a.j.setMediaKeys(null),6);case 6:ua(b,5);break;case 4:I(b);case 5:a.j=null;case 3:a.g=null,a.D.clear(),a.A=null,a.F=[],a.h=null,a.m=function(){},a.I=null,a.X=!1,C(b)}})}q.configure=function(a){this.h=a};function wh(a,b,c,d){a.$=!0;a.F=[];a.G=c;return xh(a,b,!!d)} +function uh(a){return K(function(b){switch(b.g){case 1:return a.v.release(),a.v=null,a.B.reject(),a.Z.stop(),a.Z=null,a.U.stop(),a.U=null,A(b,vh(a),2);case 2:if(!a.j){b.C(3);break}G(b,4);return A(b,a.j.setMediaKeys(null),6);case 6:ua(b,5);break;case 4:I(b);case 5:a.j=null;case 3:a.g=null,a.D.clear(),a.A=null,a.F=[],a.h=null,a.m=function(){},a.I=null,a.X=!1,C(b)}})}q.configure=function(a){this.h=a};function wh(a,b,c,d){a.$=!0;a.F=[];a.G=c;return xh(a,b,!!d)} function yh(a,b,c,d){a.F=c;a.G=0h&&(h+=Math.pow(2,32));h="0x"+h.toString(16)}a.m(new Q(2,6,6006,f.message,f,h))}})}function Wh(a,b,c){"skd"==b&&(b=c.serverCertificate,c=mh(a),a=nh(a,c,b));return a} -function Gh(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,v,y;J(function(w){switch(w.g){case 1:return c=b.target,a.h.logLicenseExchange&&Uc(b.message),d=a.i.get(c),e=a.g.licenseServerUri,f=a.h.advanced[a.g.keySystem],"individualization-request"==b.messageType&&f&&f.individualizationServer&&(e=f.individualizationServer),g=eh([e],a.h.retryParameters),g.body=b.message,g.method="POST",g.licenseRequestType=b.messageType,g.sessionId=c.sessionId,Oh(a.g.keySystem)&&Xh(g),h=Date.now(),G(w,2),l=a.I.Zb.request(2,g),A(w, +function Gh(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,v,y;K(function(w){switch(w.g){case 1:return c=b.target,a.h.logLicenseExchange&&Uc(b.message),d=a.i.get(c),e=a.g.licenseServerUri,f=a.h.advanced[a.g.keySystem],"individualization-request"==b.messageType&&f&&f.individualizationServer&&(e=f.individualizationServer),g=eh([e],a.h.retryParameters),g.body=b.message,g.method="POST",g.licenseRequestType=b.messageType,g.sessionId=c.sessionId,Oh(a.g.keySystem)&&Xh(g),h=Date.now(),G(w,2),l=a.I.Zb.request(2,g),A(w, l.promise,4);case 4:k=w.h;ua(w,3);break;case 2:return m=I(w),n=new Q(2,6,6007,m),a.m(n),d&&d.$a&&d.$a.reject(n),w["return"]();case 3:if(a.l.g)return w["return"]();a.J+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&Uc(k.data);G(w,5);return A(w,c.update(k.data),7);case 7:ua(w,6);break;case 5:return p=I(w),r=new Q(2,6,6008,p.message),a.m(r),d&&d.$a&&d.$a.reject(r),w["return"]();case 6:v=new O("drmsessionupdate"),a.I.onEvent(v),d&&(d.$a&&d.$a.resolve(),y=new R(function(){d.loaded=!0;Vh(a)&&a.B.resolve()}), y.R(Yh)),C(w)}})}function Xh(a){var b=oc(a.body,!0,!0);if(b.includes("PlayReadyKeyMessage")){b=(new DOMParser).parseFromString(b,"application/xml");for(var c=t(b.getElementsByTagName("HttpHeader")),d=c.next();!d.done;d=c.next())d=d.value,a.headers[d.getElementsByTagName("name")[0].textContent]=d.getElementsByTagName("value")[0].textContent;a.body=Vc(b.getElementsByTagName("Challenge")[0].textContent)}else a.headers["Content-Type"]="text/xml; charset=utf-8"} function Uh(a,b){var c=b.target,d=a.i.get(c),e=!1;c.keyStatuses.forEach(function(g,h){if("string"==typeof h){var k=h;h=g;g=k}if(Oh(a.g.keySystem)&&16==h.byteLength&&navigator.userAgent.match(/Edge?\//)){k=kc(h);var l=k.getUint32(0,!0),m=k.getUint16(4,!0),n=k.getUint16(6,!0);k.setUint32(0,l,!1);k.setUint16(4,m,!1);k.setUint16(6,n,!1)}"status-pending"!=g&&(d.loaded=!0);"expired"==g&&(e=!0);k=Xc(h);a.aa.set(k,g)});var f=c.expiration-Date.now();(0>f||e&&1E3>f)&&d&&!d.$a&&(a.i["delete"](c),c.close()["catch"](function(){})); Vh(a)&&(a.B.resolve(),a.U.R(Zh))}function sh(a){var b=a.aa,c=a.ua;c.clear();b.forEach(function(d,e){return c.set(e,d)});b=Array.from(c.values());b.length&&b.every(function(d){return"expired"==d})&&a.m(new Q(2,6,6014));a.I.jd(ph(c))} -function $h(){var a,b,c,d,e,f,g,h;return J(function(k){return 1==k.g?(a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.3_0 com.apple.fps.2_0 com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),b=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],c={initDataTypes:["cenc"],videoCapabilities:b},d={videoCapabilities:b,persistentState:"required",sessionTypes:["persistent-license"]},e=[d, -c],f=new Map,g=function(l){var m,n,p;return J(function(r){switch(r.g){case 1:return G(r,2),A(r,navigator.requestMediaKeySystemAccess(l,e),4);case 4:return m=r.h,p=(n=m.getConfiguration().sessionTypes)?n.includes("persistent-license"):!1,Kc("Tizen 3")&&(p=!1),f.set(l,{persistentState:p}),A(r,m.createMediaKeys(),5);case 5:ua(r,0);break;case 2:I(r),f.set(l,null),C(r)}})},h=a.map(function(l){return g(l)}),A(k,Promise.all(h),2)):k["return"](ph(f))})} -function ai(a){var b;return J(function(c){if(1==c.g)return b=new Promise(function(d,e){(new R(e)).R(bi)}),G(c,2),A(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return ua(c,0);I(c);C(c)})} -function vh(a){var b;return J(function(c){b=Array.from(a.i.entries());a.i.clear();return A(c,Promise.all(b.map(function(d){d=t(d);var e=d.next().value,f=d.next().value;return J(function(g){if(1==g.g)return G(g,2),a.$||a.F.includes(e.sessionId)||"persistent-license"!==f.type?A(g,ai(e),5):A(g,e.remove(),5);if(2!=g.g)return ua(g,0);I(g);C(g)})})),0)})} +function $h(){var a,b,c,d,e,f,g,h;return K(function(k){return 1==k.g?(a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.3_0 com.apple.fps.2_0 com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),b=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],c={initDataTypes:["cenc"],videoCapabilities:b},d={videoCapabilities:b,persistentState:"required",sessionTypes:["persistent-license"]},e=[d, +c],f=new Map,g=function(l){var m,n,p;return K(function(r){switch(r.g){case 1:return G(r,2),A(r,navigator.requestMediaKeySystemAccess(l,e),4);case 4:return m=r.h,p=(n=m.getConfiguration().sessionTypes)?n.includes("persistent-license"):!1,Kc("Tizen 3")&&(p=!1),f.set(l,{persistentState:p}),A(r,m.createMediaKeys(),5);case 5:ua(r,0);break;case 2:I(r),f.set(l,null),C(r)}})},h=a.map(function(l){return g(l)}),A(k,Promise.all(h),2)):k["return"](ph(f))})} +function ai(a){var b;return K(function(c){if(1==c.g)return b=new Promise(function(d,e){(new R(e)).R(bi)}),G(c,2),A(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return ua(c,0);I(c);C(c)})} +function vh(a){var b;return K(function(c){b=Array.from(a.i.entries());a.i.clear();return A(c,Promise.all(b.map(function(d){d=t(d);var e=d.next().value,f=d.next().value;return K(function(g){if(1==g.g)return G(g,2),a.$||a.F.includes(e.sessionId)||"persistent-license"!==f.type?A(g,ai(e),5):A(g,e.remove(),5);if(2!=g.g)return ua(g,0);I(g);C(g)})})),0)})} function eg(a,b){var c=b.audio,d=b.video;if(c&&c.encrypted&&(c=Rh(c),!Ph(a,c))||d&&d.encrypted&&(d=Rh(d),!Ph(a,d)))return!1;var e=Nh(a.g);d=Dh(b);return 0==d.length||d.some(function(f){return f.keySystem==e})} function ci(a,b){if(!a.length)return b;if(!b.length)return a;for(var c=[],d=t(a),e=d.next();!e.done;e=d.next()){e=e.value;for(var f={},g=t(b),h=g.next();!h.done;f={Sa:f.Sa},h=g.next())if(h=h.value,e.keySystem==h.keySystem){f.Sa=[];f.Sa=f.Sa.concat(e.initData||[]);f.Sa=f.Sa.concat(h.initData||[]);f.Sa=f.Sa.filter(function(k){return function(l,m){return void 0===l.keyId||m===k.Sa.findIndex(function(n){return n.keyId===l.keyId})}}(f));g=e.keyIds&&h.keyIds?new Set([].concat(ia(e.keyIds),ia(h.keyIds))): e.keyIds||h.keyIds;c.push({keySystem:e.keySystem,licenseServerUri:e.licenseServerUri||h.licenseServerUri,distinctiveIdentifierRequired:e.distinctiveIdentifierRequired||h.distinctiveIdentifierRequired,persistentStateRequired:e.persistentStateRequired||h.persistentStateRequired,videoRobustness:e.videoRobustness||h.videoRobustness,audioRobustness:e.audioRobustness||h.audioRobustness,serverCertificate:e.serverCertificate||h.serverCertificate,initData:f.Sa,keyIds:g});break}}return c} @@ -261,8 +261,8 @@ function Ch(a,b){var c=[];b.forEach(function(f,g){c.push({keySystem:g,licenseSer function Th(a,b,c,d,e){var f={};a=t(a);for(var g=a.next();!g.done;f={Ma:f.Ma},g=a.next()){f.Ma=g.value;b.includes(f.Ma.licenseServerUri)||b.push(f.Ma.licenseServerUri);f.Ma.serverCertificate&&(c.some(function(l){return function(m){return fc(m,l.Ma.serverCertificate)}}(f))||c.push(f.Ma.serverCertificate));if(f.Ma.initData){g={};for(var h=t(f.Ma.initData),k=h.next();!k.done;g={Ic:g.Ic},k=h.next())g.Ic=k.value,d.some(function(l){return function(m){var n=l.Ic;return m.keyId&&m.keyId==n.keyId?!0:m.initDataType== n.initDataType&&fc(m.initData,n.initData)}}(g))||d.push(g.Ic)}if(f.Ma.keyIds)for(g=t(f.Ma.keyIds),h=g.next();!h.done;h=g.next())e.add(h.value)}} function Eh(a,b,c){if(a.keySystem&&("org.w3.clearkey"!=a.keySystem||!a.licenseServerUri)){b.size&&(b=b.get(a.keySystem)||"",a.licenseServerUri=b);a.keyIds||(a.keyIds=new Set);if(c=c.get(a.keySystem))a.distinctiveIdentifierRequired||(a.distinctiveIdentifierRequired=c.distinctiveIdentifierRequired),a.persistentStateRequired||(a.persistentStateRequired=c.persistentStateRequired),a.videoRobustness||(a.videoRobustness=c.videoRobustness),a.audioRobustness||(a.audioRobustness=c.audioRobustness),a.serverCertificate|| -(a.serverCertificate=c.serverCertificate),c.sessionType&&(a.sessionType=c.sessionType);window.cast&&window.cast.__platform__&&"com.microsoft.playready"==a.keySystem&&(a.keySystem="com.chromecast.playready")}}var bi=1,Yh=5,Zh=.5,di=new lc(function(){return ic(new Uint8Array([0]))});function ei(){}function fi(a,b,c,d){var e,f,g,h;return J(function(k){if(1==k.g){if(d&&(e=gi[d.toLowerCase()]))return k["return"](e);if(f=hi(a))if(g=ii[f])return k["return"](g);return d?k.C(2):A(k,ji(a,b,c),3)}if(2!=k.g&&(d=k.h)&&(h=gi[d]))return k["return"](h);throw new Q(2,4,4E3,a);})} -function ji(a,b,c){var d,e,f;return J(function(g){if(1==g.g)return d=eh([a],c),d.method="HEAD",A(g,b.request(0,d).promise,2);e=g.h;f=e.headers["content-type"];return g["return"](f?f.toLowerCase().split(";").shift():"")})}function hi(a){a=(new kb(a)).Ka.split("/").pop().split(".");return 1==a.length?"":a.pop().toLowerCase()}N("shaka.media.ManifestParser",ei);ei.unregisterParserByMime=function(a){delete gi[a]};ei.registerParserByMime=function(a,b){gi[a]=b}; +(a.serverCertificate=c.serverCertificate),c.sessionType&&(a.sessionType=c.sessionType);window.cast&&window.cast.__platform__&&"com.microsoft.playready"==a.keySystem&&(a.keySystem="com.chromecast.playready")}}var bi=1,Yh=5,Zh=.5,di=new lc(function(){return ic(new Uint8Array([0]))});function ei(){}function fi(a,b,c,d){var e,f,g,h;return K(function(k){if(1==k.g){if(d&&(e=gi[d.toLowerCase()]))return k["return"](e);if(f=hi(a))if(g=ii[f])return k["return"](g);return d?k.C(2):A(k,ji(a,b,c),3)}if(2!=k.g&&(d=k.h)&&(h=gi[d]))return k["return"](h);throw new Q(2,4,4E3,a);})} +function ji(a,b,c){var d,e,f;return K(function(g){if(1==g.g)return d=eh([a],c),d.method="HEAD",A(g,b.request(0,d).promise,2);e=g.h;f=e.headers["content-type"];return g["return"](f?f.toLowerCase().split(";").shift():"")})}function hi(a){a=(new kb(a)).Ka.split("/").pop().split(".");return 1==a.length?"":a.pop().toLowerCase()}N("shaka.media.ManifestParser",ei);ei.unregisterParserByMime=function(a){delete gi[a]};ei.registerParserByMime=function(a,b){gi[a]=b}; ei.registerParserByExtension=function(a,b){ii[a]=b};var gi={},ii={};function ki(a,b,c){this.Da=a;this.xa=b;this.ra=c}ki.prototype.wc=function(){return this.xa};ki.prototype.rc=function(){return this.ra};function li(a,b){return a&&b?a.wc()==b.wc()&&a.rc()==b.rc()&&fd(a.Da(),b.Da()):a==b}N("shaka.media.InitSegmentReference",ki);ki.prototype.getEndByte=ki.prototype.rc;ki.prototype.getStartByte=ki.prototype.wc; function mi(a,b,c,d,e,f,g,h,k,l){l=void 0===l?[]:l;this.startTime=a;this.j=this.endTime=b;this.i=c;this.xa=d;this.ra=e;this.h=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.g=l}q=mi.prototype;q.Da=function(){return this.i()};q.getStartTime=function(){return this.startTime};q.Kf=function(){return this.endTime};q.wc=function(){return this.xa};q.rc=function(){return this.ra};N("shaka.media.SegmentReference",mi);mi.prototype.getEndByte=mi.prototype.rc; mi.prototype.getStartByte=mi.prototype.wc;mi.prototype.getEndTime=mi.prototype.Kf;mi.prototype.getStartTime=mi.prototype.getStartTime;mi.prototype.getUris=mi.prototype.Da;function S(a,b,c){this.l=a;this.md=b;this.m=this.i=Infinity;this.g=1;this.h=this.j=null;this.A=0;this.B=!0;this.D=0;this.F=void 0===c?!0:c;this.v=0}q=S.prototype;q.getDuration=function(){return this.i};q.Sf=function(){return this.g};q.Za=function(a){this.i=a};q.Xf=function(){return this.l};q.Tf=function(){return this.h};q.Df=function(){return this.v};q.bf=function(a){this.A=a};q.Fc=function(a){this.B=a};q.le=function(a){this.m=a};q.Fg=function(a){this.md=a};q.Jf=function(){return this.md}; @@ -290,35 +290,35 @@ Ni.prototype.seek=Ni.prototype.seek;function Pi(){Mi.call(this,[]);this.j=[]}u(P q.get=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;b+=d.h+d.N.length}return null};q.offset=function(){};q.gd=function(){};q.zb=function(){};q.Yb=function(){};q.sb=function(){};q.qd=function(){};N("shaka.media.MetaSegmentIndex",Pi);Pi.prototype.updateEvery=Pi.prototype.qd;Pi.prototype.fit=Pi.prototype.sb;Pi.prototype.mergeAndEvict=Pi.prototype.Yb;Pi.prototype.evict=Pi.prototype.zb;Pi.prototype.merge=Pi.prototype.gd; Pi.prototype.offset=Pi.prototype.offset;Pi.prototype.get=Pi.prototype.get;Pi.prototype.find=Pi.prototype.find;Pi.prototype.release=Pi.prototype.release;function Qi(a){var b=this;this.g=a;this.j=!1;this.i=this.g.$c();this.h=new R(function(){b.g.Te(.25*b.i)})}Qi.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};Qi.prototype.set=function(a){this.i=a;Ri(this)};Qi.prototype.Xc=function(){return this.g.Xc()};function Ri(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.$c()!=b&&a.g.je(b);return}catch(c){}a.h.ha(.25);0!=a.g.$c()&&a.g.je(0)};function Si(a){var b=this;this.h=a;this.g=new Set;this.i=(new R(function(){Ti(b,!1)})).ha(.25)}Si.prototype.release=function(){this.i.stop();for(var a=t(this.g),b=a.next();!b.done;b=a.next())b.value.release();this.g.clear()}; function Ti(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next()){d=d.value;for(var e=a.h.currentTime,f=b,g=t(d.i.g),h=g.next();!h.done;h=g.next()){h=h.value;var k=d.g.get(h),l=eh.endTime?Vi:Wi;d.g.set(h,l);for(var m=t(d.j),n=m.next();!n.done;n=m.next())n=n.value,n.Ob==k&&n.Nb==l&&n.Eb(h,f)}}};function Xi(a){db.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new R(function(){for(var c=b.i(),d=t(b.g),e=d.next();!e.done;e=d.next())e=e.value,e.endTimeh?!0:!1):f=!1;f&&b.Ja.abort();C(e)})}function pj(a,b){b.pc||b.Mb||(b.Ya?(b.Mb=!0,b.Sc=0):null==Bf(a.g.S,b.type)?null==b.ab&&hj(a,b,0):(cj(b),nj(a,b,!1,0)["catch"](function(c){if(a.g)a.g.onError(c)})))} -function ej(a){var b,c,d,e,f,g,h,k,l,m;return J(function(n){if(1==n.g){b=Nb;if(!a.j)throw new Q(2,5,5006);c=new Map;d=new Set;a.j.audio&&(c.set(b.wb,a.j.audio),d.add(a.j.audio));a.j.video&&(c.set(b.bb,a.j.video),d.add(a.j.video));a.v&&(c.set(b.ka,a.v),d.add(a.v));e=a.g.S;f=a.l.forceTransmuxTS;return A(n,e.init(c,f),2)}nf(a.i);var p=a.m.presentationTimeline.getDuration();Infinity>p?a.g.S.Za(p):a.g.S.Za(Math.pow(2,32));g=t(c.keys());for(h=g.next();!h.done;h=g.next())k=h.value,l=c.get(k),a.h.has(k)|| +function ej(a){var b,c,d,e,f,g,h,k,l,m;return K(function(n){if(1==n.g){b=Nb;if(!a.j)throw new Q(2,5,5006);c=new Map;d=new Set;a.j.audio&&(c.set(b.wb,a.j.audio),d.add(a.j.audio));a.j.video&&(c.set(b.bb,a.j.video),d.add(a.j.video));a.v&&(c.set(b.ka,a.v),d.add(a.v));e=a.g.S;f=a.l.forceTransmuxTS;return A(n,e.init(c,f),2)}nf(a.i);var p=a.m.presentationTimeline.getDuration();Infinity>p?a.g.S.Za(p):a.g.S.Za(Math.pow(2,32));g=t(c.keys());for(h=g.next();!h.done;h=g.next())k=h.value,l=c.get(k),a.h.has(k)|| (m=gj(l),a.h.set(k,m),hj(a,m,0));C(n)})}function gj(a){return{stream:a,type:a.type,oa:null,Qa:null,ed:null,fd:null,dd:null,cd:null,Kb:null,endOfStream:!1,Ya:!1,ab:null,Mb:!1,Sc:0,td:!1,pc:!1,Xd:!1,xc:!1,Ja:null}} -function qj(a,b){var c,d,e,f,g;return J(function(h){switch(h.g){case 1:nf(a.i);if(b.Ya||null==b.ab||b.pc)return h["return"]();b.ab=null;if(!b.Mb){h.C(2);break}return A(h,nj(a,b,b.td,b.Sc),3);case 3:return h["return"]();case 2:if(b.stream.segmentIndex){h.C(4);break}c=b.stream;return A(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return null==b.ab&&hj(a,b,0),h["return"]();case 4:G(h,6);d=rj(a,b);null!=d&&(hj(a,b,d),b.xc=!1);ua(h,7);break;case 6:return e=I(h),A(h,sj(a,e),8);case 8:return h["return"](); +function qj(a,b){var c,d,e,f,g;return K(function(h){switch(h.g){case 1:nf(a.i);if(b.Ya||null==b.ab||b.pc)return h["return"]();b.ab=null;if(!b.Mb){h.C(2);break}return A(h,nj(a,b,b.td,b.Sc),3);case 3:return h["return"]();case 2:if(b.stream.segmentIndex){h.C(4);break}c=b.stream;return A(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return null==b.ab&&hj(a,b,0),h["return"]();case 4:G(h,6);d=rj(a,b);null!=d&&(hj(a,b,d),b.xc=!1);ua(h,7);break;case 6:return e=I(h),A(h,sj(a,e),8);case 8:return h["return"](); case 7:f=Array.from(a.h.values());if(!a.D||!f.every(function(k){return k.endOfStream})){h.C(0);break}return A(h,a.g.S.endOfStream(),10);case 10:nf(a.i),g=a.g.S.getDuration(),0!=g&&ga.m.presentationTimeline.getDuration()-d)return b.endOfStream=!0,"video"==b.type&&(c=a.h.get(Mb))&&tj(c)&&(c.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return.5;e=Df(a.g.S,b.type);e=uj(a,b,c,e);if(!e)return 1;f=Infinity;var g=Array.from(a.h.values());g=t(g);for(var h= g.next();!h.done;h=g.next())h=h.value,tj(h)||h.oa&&!h.oa.current()||(f=Math.min(f,h.Qa?h.Qa.endTime:c));if(d>=f+a.m.presentationTimeline.g)return 1;vj(a,b,c,e)["catch"](function(){});return null} function uj(a,b,c,d){if(b.oa)return b.oa.current();if(b.Qa||d)return b.oa=b.stream.segmentIndex.Ub(b.Qa?b.Qa.endTime:d),b.oa&&b.oa.next().value;a=a.l.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.oa=b.stream.segmentIndex.Ub(d),e=b.oa&&b.oa.next().value);e||(b.oa=b.stream.segmentIndex.Ub(c),e=b.oa&&b.oa.next().value);return e} -function vj(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,v,y,w;return J(function(x){switch(x.g){case 1:return e=Nb,f=b.stream,g=b.oa,b.Ya=!0,G(x,2),A(x,wj(a,b,d),4);case 4:h=x.h;nf(a.i);if(a.A)return x["return"]();k="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;l=window.ReadableStream;if(a.l.lowLatencyMode&&l&&k)return p=new Uint8Array(0),r=function(D){var B,z,E;return J(function(F){nf(a.i);if(a.A)return F["return"]();p=xj(p,D);B=!1;z=0;(new wc).box("mdat",function(H){z=H.size+H.start;B=!0}).parse(p,!1,!0); -if(!B)return F.C(0);E=p.subarray(0,z);p=p.subarray(z);return A(F,yj(a,b,c,f,d,E),0)})},A(x,zj(a,b,d,r),6);m=zj(a,b,d);return A(x,m,7);case 7:n=x.h;nf(a.i);if(a.A)return x["return"]();if(b.Mb)return b.Ya=!1,hj(a,b,0),x["return"]();h&&(new wc).box("moof",Ac).box("traf",Ac).V("tfdt",function(D){var B,z,E,F,H;return J(function(K){B=De(D.reader,D.version);z=B.Qc;if(!z)return K["return"]();E=z/h;if(!(Math.abs(b.fd)>E))return K.C(0);F=0+b.cd;H=0+b.dd;return A(K,Lf(a.g.S,b.type,-E,H,F),0)})}).parse(n,!1, -!0);return A(x,yj(a,b,c,f,d,n),6);case 6:nf(a.i);if(a.A)return x["return"]();b.Qa=d;g.next();b.Ya=!1;b.Xd=!1;v=a.g.S.Wc();y=v[b.type];Va(JSON.stringify(y));b.Mb||a.g.Ud();hj(a,b,0);ua(x,0);break;case 2:w=I(x);nf(a.i,w);if(a.A)return x["return"]();b.Ya=!1;if(7001==w.code)b.Ya=!1,b.ab=null,hj(a,b,0),x.C(0);else if(b.type==e.ka&&a.l.ignoreTextStreamFailures)a.h["delete"](e.ka),x.C(0);else if(3017==w.code)Aj(a,b,w),x.C(0);else if(1001==w.code&&w.data&&404==w.data[1])b.Ya=!1,b.ab=null,hj(a,b,1),x.C(0); +function vj(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,v,y,w;return K(function(x){switch(x.g){case 1:return e=Nb,f=b.stream,g=b.oa,b.Ya=!0,G(x,2),A(x,wj(a,b,d),4);case 4:h=x.h;nf(a.i);if(a.A)return x["return"]();k="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;l=window.ReadableStream;if(a.l.lowLatencyMode&&l&&k)return p=new Uint8Array(0),r=function(D){var B,z,E;return K(function(F){nf(a.i);if(a.A)return F["return"]();p=xj(p,D);B=!1;z=0;(new wc).box("mdat",function(H){z=H.size+H.start;B=!0}).parse(p,!1,!0); +if(!B)return F.C(0);E=p.subarray(0,z);p=p.subarray(z);return A(F,yj(a,b,c,f,d,E),0)})},A(x,zj(a,b,d,r),6);m=zj(a,b,d);return A(x,m,7);case 7:n=x.h;nf(a.i);if(a.A)return x["return"]();if(b.Mb)return b.Ya=!1,hj(a,b,0),x["return"]();h&&(new wc).box("moof",Ac).box("traf",Ac).V("tfdt",function(D){var B,z,E,F,H,L;return K(function(J){B=De(D.reader,D.version);z=B.Qc;if(!z)return J["return"]();E=-z/h;F=Number(b.fd)||0;if(!(F=g?h["return"]():A(h,a.g.S.remove(b.type,e,e+g),2)}nf(a.i);C(h)})}function tj(a){return a&&a.type==Mb&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)} -function zj(a,b,c,d){var e,f,g,h;return J(function(k){if(1==k.g)return e=kh,f=$i(c.Da(),c.xa,c.ra,a.l.retryParameters,d),g=a.g.Zb.request(e,f),b.Ja=g,A(k,g.promise,2);h=k.h;b.Ja=null;return k["return"](h.data)})} -function nj(a,b,c,d){var e,f;return J(function(g){if(1==g.g)return b.Mb=!1,b.td=!1,b.Sc=0,b.pc=!0,b.Qa=null,b.ed=null,b.oa=null,d?(e=a.g.Zc(),f=a.g.S.getDuration(),A(g,a.g.S.remove(b.type,e+d,f),3)):A(g,Kf(a.g.S,b.type),4);if(3!=g.g)return nf(a.i),c?A(g,a.g.S.flush(b.type),3):g.C(3);nf(a.i);b.pc=!1;b.endOfStream=!1;hj(a,b,0);C(g)})} -function hj(a,b,c){var d=b.type;if(d!=Mb||a.h.has(d))b.ab=(new Fc(function(){var e;return J(function(f){if(1==f.g)return G(f,2),A(f,qj(a,b),4);if(2!=f.g)return ua(f,0);e=I(f);if(a.g)a.g.onError(e);C(f)})})).R(c)}function cj(a){null!=a.ab&&(a.ab.stop(),a.ab=null)}function dj(a){return J(function(b){return a.Ja?A(b,a.Ja.abort(),0):b.C(0)})}function sj(a,b){return J(function(c){if(1==c.g)return A(c,Pg(a.F),2);nf(a.i);a.g.onError(b);b.handled||a.l.failureCallback(b);C(c)})};function Dj(a,b){var c=Ej(),d=this;this.j=b;this.i=a;this.l=c;this.v=null;this.m=[];this.h=this.g=null;this.B=Promise.resolve().then(function(){return Fj(d)});this.A=new mf(function(){return Gj(d)})}Dj.prototype.destroy=function(){return this.A.destroy()};function Gj(a){var b,c,d;return J(function(e){if(1==e.g)return a.h&&a.h.abort(),Hj(a),A(e,a.B,2);a.g&&a.g.Wa.Ib();b=t(a.m);for(c=b.next();!c.done;c=b.next())d=c.value,d.Wa.Ib();a.g=null;a.m=[];a.j=null;C(e)})} +function Cj(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g){d=Math.max(a.l.bufferBehind,a.m.presentationTimeline.g);e=Bf(a.g.S,b.type);if(null==e)return h["return"]();f=c-e;g=f-d;return.01>=g?h["return"]():A(h,a.g.S.remove(b.type,e,e+g),2)}nf(a.i);C(h)})}function tj(a){return a&&a.type==Mb&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)} +function zj(a,b,c,d){var e,f,g,h;return K(function(k){if(1==k.g)return e=kh,f=$i(c.Da(),c.xa,c.ra,a.l.retryParameters,d),g=a.g.Zb.request(e,f),b.Ja=g,A(k,g.promise,2);h=k.h;b.Ja=null;return k["return"](h.data)})} +function nj(a,b,c,d){var e,f;return K(function(g){if(1==g.g)return b.Mb=!1,b.td=!1,b.Sc=0,b.pc=!0,b.Qa=null,b.ed=null,b.oa=null,d?(e=a.g.Zc(),f=a.g.S.getDuration(),A(g,a.g.S.remove(b.type,e+d,f),3)):A(g,Kf(a.g.S,b.type),4);if(3!=g.g)return nf(a.i),c?A(g,a.g.S.flush(b.type),3):g.C(3);nf(a.i);b.pc=!1;b.endOfStream=!1;hj(a,b,0);C(g)})} +function hj(a,b,c){var d=b.type;if(d!=Mb||a.h.has(d))b.ab=(new Fc(function(){var e;return K(function(f){if(1==f.g)return G(f,2),A(f,qj(a,b),4);if(2!=f.g)return ua(f,0);e=I(f);if(a.g)a.g.onError(e);C(f)})})).R(c)}function cj(a){null!=a.ab&&(a.ab.stop(),a.ab=null)}function dj(a){return K(function(b){return a.Ja?A(b,a.Ja.abort(),0):b.C(0)})}function sj(a,b){return K(function(c){if(1==c.g)return A(c,Pg(a.F),2);nf(a.i);a.g.onError(b);b.handled||a.l.failureCallback(b);C(c)})};function Dj(a,b){var c=Ej(),d=this;this.j=b;this.i=a;this.l=c;this.v=null;this.m=[];this.h=this.g=null;this.B=Promise.resolve().then(function(){return Fj(d)});this.A=new mf(function(){return Gj(d)})}Dj.prototype.destroy=function(){return this.A.destroy()};function Gj(a){var b,c,d;return K(function(e){if(1==e.g)return a.h&&a.h.abort(),Hj(a),A(e,a.B,2);a.g&&a.g.Wa.Ib();b=t(a.m);for(c=b.next();!c.done;c=b.next())d=c.value,d.Wa.Ib();a.g=null;a.m=[];a.j=null;C(e)})} function Ij(a,b){var c={ac:function(){},hd:function(){},Ib:function(){},onError:function(){},kd:function(){},Xh:function(){}};a.m.push({create:b,Wa:c});a.h&&a.h.abort();Hj(a);return c} -function Fj(a){return J(function(b){if(a.A.g)b=b.C(0);else{if(0==a.m.length||a.g&&!a.g.Db)var c=!1;else{a.g&&(a.g.Wa.Ib(),a.g=null);c=a.m.shift();var d=c.create(a.l);d?(c.Wa.ac(),a.g={node:d.node,payload:d.payload,Db:d.Db,Wa:c.Wa}):c.Wa.kd();c=!0}c?c=Promise.resolve():a.g?c=Jj(a):(a.j.mg(a.i),a.v=new Oe,c=a.v);b=A(b,c,1)}return b})} -function Jj(a){var b,c;return J(function(d){switch(d.g){case 1:return a.i=a.j.Vf(a.i,a.l,a.g.node,a.g.payload),G(d,2),a.h=a.j.Af(a.i,a.l,a.g.payload),A(d,a.h.promise,4);case 4:a.h=null;a.i==a.g.node&&(a.g.Wa.hd(),a.g=null);ua(d,0);break;case 2:b=I(d);if(7001==b.code)a.g.Wa.Ib();else a.g.Wa.onError(b);a.g=null;a.h=null;c=a;return A(d,a.j.handleError(a.l,b),5);case 5:c.i=d.h,C(d)}})}function Hj(a){a.v&&(a.v.resolve(),a.v=null)};function Kj(a){this.g=null;for(var b=t(Array.from(a.textTracks)),c=b.next();!c.done;c=b.next())c=c.value,c.mode="disabled","Shaka Player TextTrack"==c.label&&(this.g=c);this.g||(this.g=a.addTextTrack("subtitles","Shaka Player TextTrack"));this.g.mode="hidden"}q=Kj.prototype;q.remove=function(a,b){if(!this.g)return!1;Lj(this.g,function(c){return c.startTimea});return!0}; +function Fj(a){return K(function(b){if(a.A.g)b=b.C(0);else{if(0==a.m.length||a.g&&!a.g.Db)var c=!1;else{a.g&&(a.g.Wa.Ib(),a.g=null);c=a.m.shift();var d=c.create(a.l);d?(c.Wa.ac(),a.g={node:d.node,payload:d.payload,Db:d.Db,Wa:c.Wa}):c.Wa.kd();c=!0}c?c=Promise.resolve():a.g?c=Jj(a):(a.j.mg(a.i),a.v=new Oe,c=a.v);b=A(b,c,1)}return b})} +function Jj(a){var b,c;return K(function(d){switch(d.g){case 1:return a.i=a.j.Vf(a.i,a.l,a.g.node,a.g.payload),G(d,2),a.h=a.j.Af(a.i,a.l,a.g.payload),A(d,a.h.promise,4);case 4:a.h=null;a.i==a.g.node&&(a.g.Wa.hd(),a.g=null);ua(d,0);break;case 2:b=I(d);if(7001==b.code)a.g.Wa.Ib();else a.g.Wa.onError(b);a.g=null;a.h=null;c=a;return A(d,a.j.handleError(a.l,b),5);case 5:c.i=d.h,C(d)}})}function Hj(a){a.v&&(a.v.resolve(),a.v=null)};function Kj(a){this.g=null;for(var b=t(Array.from(a.textTracks)),c=b.next();!c.done;c=b.next())c=c.value,c.mode="disabled","Shaka Player TextTrack"==c.label&&(this.g=c);this.g||(this.g=a.addTextTrack("subtitles","Shaka Player TextTrack"));this.g.mode="hidden"}q=Kj.prototype;q.remove=function(a,b){if(!this.g)return!1;Lj(this.g,function(c){return c.startTimea});return!0}; q.append=function(a){function b(g){var h=[],k=700<=g.fontWeight,l="italic"==g.fontStyle,m=g.textDecoration.includes("underline");k&&h.push("b");l&&h.push("i");m&&h.push("u");k=h.reduce(function(n,p){return n+"<"+p+">"},"");h=h.reduceRight(function(n,p){return n+""},"");return g.lineBreak||g.spacer?(g.spacer&&yb("shaka.extern.Cue","Please use lineBreak instead of spacer."),"\n"):g.nestedCues.length?g.nestedCues.map(b).join(""):k+g.payload+h}var c=a.map(function(g){if(g.nestedCues.length){var h= g.clone();h.nestedCues=[];h.payload=b(g);return h}return g}),d=[];a=this.g.cues?Array.from(this.g.cues):[];var e={};c=t(c);for(var f=c.next();!f.done;e={Pb:e.Pb},f=c.next())e.Pb=f.value,a.some(function(g){return function(h){return h.startTime==g.Pb.startTime&&h.endTime==g.Pb.endTime&&h.text==g.Pb.payload?!0:!1}}(e))||(f=Mj(e.Pb))&&d.push(f);a=d.slice().sort(function(g,h){return g.startTime!=h.startTime?g.startTime-h.startTime:g.endTime!=h.endTime?g.endTime-h.startTime:"line"in VTTCue.prototype?d.indexOf(h)- d.indexOf(g):d.indexOf(g)-d.indexOf(h)});a=t(a);for(e=a.next();!e.done;e=a.next())this.g.addCue(e.value)};q.destroy=function(){this.g&&(Lj(this.g,function(){return!0}),this.g.mode="disabled");this.g=null;return Promise.resolve()};q.isTextVisible=function(){return"showing"==this.g.mode};q.setTextVisibility=function(a){this.g.mode=a?"showing":"hidden"}; @@ -342,9 +342,9 @@ k),g=!1)}return g}function ak(a,b){for(var c={},d=c,e=0,f=0;;){e=a.indexOf(".",e function ck(){var a=Infinity;navigator.connection&&navigator.connection.saveData&&(a=360);var b={retryParameters:Og(),servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,initDataTransform:Wh,logLicenseExchange:!1,updateExpirationTime:1},c={retryParameters:Og(),availabilityWindowOverride:NaN,disableAudio:!1,disableVideo:!1,disableText:!1,disableThumbnails:!1,defaultPresentationDelay:0,dash:{clockSyncUri:"",ignoreDrmInfo:!1,disableXlinkProcessing:!1,xlinkFailGracefully:!1,ignoreMinBufferTime:!1, autoCorrectDrift:!0,initialSegmentLimit:1E3,ignoreSuggestedPresentationDelay:!1,ignoreEmptyAdaptationSet:!1,ignoreMaxSegmentDuration:!1,keySystemsByURI:{"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime"}, requestInterval:0},hls:{ignoreTextStreamFailures:!1,useFullSegmentsForStartTime:!1}},d={retryParameters:Og(),failureCallback:function(g){return[g]},rebufferingGoal:2,bufferingGoal:10,bufferBehind:30,ignoreTextStreamFailures:!1,alwaysStreamText:!1,startAtSegmentBoundary:!1,gapDetectionThreshold:.1,smallGapLimit:.5,jumpLargeGaps:!1,durationBackoff:1,forceTransmuxTS:!1,safeSeekOffset:5,stallEnabled:!0,stallThreshold:1,stallSkip:.1,useNativeHlsOnSafari:!0,inaccurateManifestTolerance:2,lowLatencyMode:!1, -autoLowLatencyMode:!1,forceHTTPS:!1,preferNativeHls:!1};if(navigator.userAgent.match(/Edge\//)||Lc()||Mc())d.gapDetectionThreshold=.5;if(Kc("Web0S")||Lc()||Mc())d.stallSkip=0;var e={trackSelectionCallback:function(g){return J(function(h){return h["return"](g)})},downloadSizeCallback:function(g){var h;return J(function(k){if(1==k.g)return navigator.storage&&navigator.storage.estimate?A(k,navigator.storage.estimate(),3):k["return"](!0);h=k.h;return k["return"](h.usage+g<.95*h.quota)})},progressCallback:function(g, +autoLowLatencyMode:!1,forceHTTPS:!1,preferNativeHls:!1};if(navigator.userAgent.match(/Edge\//)||Lc()||Mc())d.gapDetectionThreshold=.5;if(Kc("Web0S")||Lc()||Mc())d.stallSkip=0;var e={trackSelectionCallback:function(g){return K(function(h){return h["return"](g)})},downloadSizeCallback:function(g){var h;return K(function(k){if(1==k.g)return navigator.storage&&navigator.storage.estimate?A(k,navigator.storage.estimate(),3):k["return"](!0);h=k.h;return k["return"](h.usage+g<.95*h.quota)})},progressCallback:function(g, h){return[g,h]},usePersistentLicense:!0},f={drm:b,manifest:c,streaming:d,offline:e,abrFactory:function(){return new xg},abr:{enabled:!0,useNetworkInformation:!0,defaultBandwidthEstimate:1E6,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:a,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity}},preferredAudioLanguage:"",preferredTextLanguage:"",preferredVariantRole:"", -preferredTextRole:"",preferredAudioChannelCount:2,preferForcedSubs:!1,restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:Infinity,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity},playRangeStart:0,playRangeEnd:Infinity,useMediaCapabilities:!1,textDisplayFactory:function(){return null}};e.trackSelectionCallback=function(g){return J(function(h){return h["return"](dk(g,f.preferredAudioLanguage))})};return f} +preferredTextRole:"",preferredAudioChannelCount:2,preferForcedSubs:!1,restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:Infinity,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity},playRangeStart:0,playRangeEnd:Infinity,useMediaCapabilities:!1,textDisplayFactory:function(){return null}};e.trackSelectionCallback=function(g){return K(function(h){return h["return"](dk(g,f.preferredAudioLanguage))})};return f} function ek(a,b,c){var d={".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),individualizationServer:""}};return Zj(a,b,c||ck(),d,"")} function dk(a,b){var c=a.filter(function(h){return"variant"==h.type}),d=[],e=Wb(b,c.map(function(h){return h.language}));e&&(d=c.filter(function(h){return Pb(h.language)==e}));0==d.length&&(d=c.filter(function(h){return h.primary}));0==d.length&&(c.map(function(h){return h.language}),d=c);var f=d.filter(function(h){return h.height&&480>=h.height});f.length&&(f.sort(function(h,k){return k.height-h.height}),d=f.filter(function(h){return h.height==f[0].height}));c=[];if(d.length){var g=Math.floor(d.length/ 2);d.sort(function(h,k){return h.bandwidth-k.bandwidth});c.push(d[g])}d=t(a);for(g=d.next();!g.done;g=d.next())g=g.value,g.type!=Mb&&"image"!=g.type||c.push(g);return c}N("shaka.util.PlayerConfiguration",bk);bk.mergeConfigObjects=ek;function fk(){this.g=null;this.h=[]}function gk(a,b){if(null==a.g)a.g={timestamp:Date.now()/1E3,state:b,duration:0};else{var c=Date.now()/1E3;a.g.duration=c-a.g.timestamp;a.g.state!=b&&(a.h.push(a.g),a.g={timestamp:c,state:b,duration:0})}}function hk(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);for(var d=t(a.h),e=d.next();!e.done;e=d.next())e=e.value,c+=e.state==b?e.duration:0;return c} @@ -352,8 +352,8 @@ function ik(a){function b(f){return{timestamp:f.timestamp,state:f.state,duration this.xb=[];b&&b(this);this.G=pk(this);this.G.ge(this.h.streaming.forceHTTPS);this.J=null;qk&&(this.J=Gb(qk));this.l.o(window,"online",function(){c.Yd()});this.P={name:"detach"};this.U={name:"attach"};this.Z={name:"unload"};this.Wd={name:"manifest-parser"};this.Od={name:"manifest"};this.za={name:"media-source"};this.Kd={name:"drm-engine"};this.X={name:"load"};this.Zd={name:"src-equals-drm-engine"};this.Na={name:"src-equals"};var d=new Map;d.set(this.U,function(e,f){return Ug(rk(c,e,f))});d.set(this.P, function(e){e.H&&(c.l.La(e.H,"error"),e.H=null);c.J&&c.J.release();c.g=null;e=Promise.resolve();return Ug(e)});d.set(this.Z,function(e){return Ug(sk(c,e))});d.set(this.za,function(e){e=tk(c,e);return Ug(e)});d.set(this.Wd,function(e,f){var g=uk(c,e,f);return Ug(g)});d.set(this.Od,function(e){return vk(c,e)});d.set(this.Kd,function(e){e=wk(c,e);return Ug(e)});d.set(this.X,function(e,f){return Ug(xk(c,e,f))});d.set(this.Zd,function(e,f){var g=yk(c,e,f);return Ug(g)});d.set(this.Na,function(e,f){return zk(c, e,f)});this.aa=new Dj(this.P,{Vf:function(e,f,g,h){var k=null;e==c.P&&(k=g==c.P?c.P:c.U);e==c.U&&(k=g==c.P||f.H!=h.H?c.P:g==c.U?c.U:g==c.za||g==c.X?c.za:g==c.Na?c.Zd:null);e==c.za&&(k=g==c.X&&f.H==h.H?c.Wd:c.Z);e==c.Wd&&(k=Ak(c.X,c.Od,c.Z,g,f,h));e==c.Od&&(k=Ak(c.X,c.Kd,c.Z,g,f,h));e==c.Kd&&(k=Ak(c.X,c.X,c.Z,g,f,h));e==c.Zd&&(k=g==c.Na&&f.H==h.H?c.Na:c.Z);if(e==c.X||e==c.Na)k=c.Z;e==c.Z&&(k=h.H&&f.H==h.H?c.U:c.P);return k},Af:function(e,f,g){c.dispatchEvent(Bk(Ck,(new Map).set("state",e.name)));return d.get(e)(f, -g)},handleError:function(e){return J(function(f){return 1==f.g?A(f,sk(c,e),2):f["return"](e.H?c.U:c.P)})},mg:function(e){c.dispatchEvent(Bk(Dk,(new Map).set("state",e.name)))}});a&&this.nc(a,!0)}u(V,db);function Bk(a,b){return new O(a,b)}q=V.prototype; -q.destroy=function(){var a=this,b;return J(function(c){switch(c.g){case 1:if(a.m==Ek)return c["return"]();a.m=Ek;b=Ij(a.aa,function(){return{node:a.P,payload:Ej(),Db:!1}});return A(c,new Promise(function(d){b.ac=function(){};b.hd=function(){d()};b.Ib=function(){d()};b.onError=function(){d()};b.kd=function(){d()}}),2);case 2:return A(c,a.aa.destroy(),3);case 3:a.l&&(a.l.release(),a.l=null);a.Id=null;a.B=null;a.h=null;a.A=null;a.rb=null;if(!a.G){c.C(4);break}return A(c,a.G.destroy(),5);case 5:a.G=null; +g)},handleError:function(e){return K(function(f){return 1==f.g?A(f,sk(c,e),2):f["return"](e.H?c.U:c.P)})},mg:function(e){c.dispatchEvent(Bk(Dk,(new Map).set("state",e.name)))}});a&&this.nc(a,!0)}u(V,db);function Bk(a,b){return new O(a,b)}q=V.prototype; +q.destroy=function(){var a=this,b;return K(function(c){switch(c.g){case 1:if(a.m==Ek)return c["return"]();a.m=Ek;b=Ij(a.aa,function(){return{node:a.P,payload:Ej(),Db:!1}});return A(c,new Promise(function(d){b.ac=function(){};b.hd=function(){d()};b.Ib=function(){d()};b.onError=function(){d()};b.kd=function(){d()}}),2);case 2:return A(c,a.aa.destroy(),3);case 3:a.l&&(a.l.release(),a.l=null);a.Id=null;a.B=null;a.h=null;a.A=null;a.rb=null;if(!a.G){c.C(4);break}return A(c,a.G.destroy(),5);case 5:a.G=null; case 4:db.prototype.release.call(a),C(c)}})}; function Fk(){window.Promise||Pa("A Promise implementation or polyfill is required");window.TextDecoder&&window.TextEncoder||Pa("A TextDecoder/TextEncoder implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&window.TextDecoder&&window.TextEncoder&&Array.prototype.forEach)||Kc("Trident/"))return!1;var a=Oc();return a&&12>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)? !1:Gc()?!0:Hc("application/x-mpegurl")}q.nc=function(a,b){b=void 0===b?!0:b;if(this.m==Ek)return Promise.reject(Gk());var c=Ej();c.H=a;Gc()||(b=!1);var d=b?this.za:this.U,e=Ij(this.aa,function(){return{node:d,payload:c,Db:!1}});e.ac=function(){};return Hk(e)};q.detach=function(){var a=this;if(this.m==Ek)return Promise.reject(Gk());var b=Ij(this.aa,function(){return{node:a.P,payload:Ej(),Db:!1}});b.ac=function(){};return Hk(b)}; @@ -362,24 +362,24 @@ q.load=function(a,b,c){var d=this;if(this.m==Ek)return Promise.reject(Gk());this function(l){return k(l)}})}; function Jk(a,b){if(!Gc())return!0;var c=b.mimeType,d=b.uri||"";c||(c={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav"}[hi(d)]);if(c){if(""==(b.H||Ic()).canPlayType(c))return!1;if(!Gc()||!(c in gi||hi(d)in ii)||a.h.streaming.preferNativeHls)return!0;if(Nc())return a.h.streaming.useNativeHlsOnSafari}return!1} function rk(a,b,c){null==b.H&&(b.H=c.H,a.l.o(b.H,"error",function(){var d=Lk(a);d&&Mk(a,d)}));a.g=b.H;return Promise.resolve()} -function sk(a,b){var c,d,e,f,g,h,k,l,m;return J(function(n){switch(n.g){case 1:return a.m!=Ek&&(a.m=nk),c=a.xb.map(function(p){return p()}),a.xb=[],A(n,Promise.all(c),2);case 2:a.dispatchEvent(Bk(Nk));b.mimeType=null;b.startTime=null;b.uri=null;b.H&&(a.l.La(b.H,"loadedmetadata"),a.l.La(b.H,"playing"),a.l.La(b.H,"pause"),a.l.La(b.H,"ended"),a.l.La(b.H,"ratechange"));a.Aa&&(a.Aa.release(),a.Aa=null);a.ob&&(a.ob.stop(),a.ob=null);if(!a.I){n.C(3);break}return A(n,a.I.stop(),4);case 4:a.I=null,a.Uc=null; +function sk(a,b){var c,d,e,f,g,h,k,l,m;return K(function(n){switch(n.g){case 1:return a.m!=Ek&&(a.m=nk),c=a.xb.map(function(p){return p()}),a.xb=[],A(n,Promise.all(c),2);case 2:a.dispatchEvent(Bk(Nk));b.mimeType=null;b.startTime=null;b.uri=null;b.H&&(a.l.La(b.H,"loadedmetadata"),a.l.La(b.H,"playing"),a.l.La(b.H,"pause"),a.l.La(b.H,"ended"),a.l.La(b.H,"ratechange"));a.Aa&&(a.Aa.release(),a.Aa=null);a.ob&&(a.ob.stop(),a.ob=null);if(!a.I){n.C(3);break}return A(n,a.I.stop(),4);case 4:a.I=null,a.Uc=null; case 3:if(!a.B){n.C(5);break}return A(n,a.B.stop(),5);case 5:if(!a.j){n.C(7);break}return A(n,a.j.destroy(),8);case 8:a.j=null;case 7:a.F&&(a.F.release(),a.F=null);a.D&&(a.D.release(),a.D=null);if(!a.M){n.C(9);break}return A(n,a.M.destroy(),10);case 10:a.M=null;case 9:if(a.J)a.J.onAssetUnload();if(!b.H||!b.H.src){n.C(11);break}return A(n,new Promise(function(p){return(new R(p)).R(.1)}),12);case 12:for(b.H.removeAttribute("src"),b.H.load();b.H.lastChild;)b.H.removeChild(b.H.firstChild);case 11:if(!a.v){n.C(13); break}return A(n,a.v.destroy(),14);case 14:a.v=null;case 13:a.cb=null;a.K=null;if(a.i){d=t(a.i.variants);for(e=d.next();!e.done;e=d.next())for(f=e.value,g=t([f.audio,f.video]),h=g.next();!h.done;h=g.next())(k=h.value)&&k.segmentIndex&&k.segmentIndex.release();l=t(a.i.textStreams);for(h=l.next();!h.done;h=l.next())m=h.value,m.segmentIndex&&m.segmentIndex.release()}a.i=null;a.A=new mk;a.Ld=null;Ok(a);C(n)}})} -function tk(a,b){var c,d,e,f;return J(function(g){if(1==g.g)return c=new He,d=a.h.textDisplayFactory,e=Gb(d),a.Ld=d,f=Pk(b.H,c,e,function(h,k,l){h=t(h);for(var m=h.next();!m.done;m=h.next())if(m=m.value,m.data&&m.cueTime&&m.frames){for(var n=m.cueTime+k,p=l,r=t(m.frames),v=r.next();!v.done;v=r.next())Qk(a,n,p,"ID3",v.value);if(a.J)a.J.onHlsTimedMetadata(m,n)}}),A(g,f.F,2);a.M=f;C(g)})} -function uk(a,b,c){var d,e,f,g;return J(function(h){if(1==h.g)return b.mimeType=c.mimeType,b.uri=c.uri,d=b.uri,e=a.G,a.cb=d,f=a,A(h,fi(d,e,a.h.manifest.retryParameters,b.mimeType),2);f.Uc=h.h;a.I=Gb(a.Uc);g=Xg(a.h.manifest);c.H&&"AUDIO"===c.H.nodeName&&(g.disableVideo=!0);a.I.configure(g);C(h)})} -function vk(a,b){var c=b.uri,d=a.G;a.bd=new Xi(function(){return a.Ra()});a.bd.addEventListener("regionadd",function(g){g=g.region;Rk(a,Sk,g);if(a.J)a.J.onDashTimedMetadata(g)});var e={networkingEngine:d,filter:function(g){return J(function(h){return h["return"](Tk(a,g))})},makeTextStreamsForClosedCaptions:function(g){return Uk(a,g)},onTimelineRegionAdded:function(g){var h=a.bd;a:{var k=t(h.g);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.schemeIdUri==g.schemeIdUri&&l.id==g.id&&l.startTime== -g.startTime&&l.endTime==g.endTime){k=l;break a}k=null}null==k&&(h.g.add(g),g=new O("regionadd",new Map([["region",g]])),h.dispatchEvent(g))},onEvent:function(g){return a.dispatchEvent(g)},onError:function(g){return Mk(a,g)},isLowLatencyMode:function(){return a.h.streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return a.h.streaming.autoLowLatencyMode},enableLowLatencyMode:function(){a.configure("streaming.lowLatencyMode",!0)}},f=Date.now()/1E3;return new Qg(function(){var g,h,k,l;return J(function(m){if(1== +function tk(a,b){var c,d,e,f;return K(function(g){if(1==g.g)return c=new He,d=a.h.textDisplayFactory,e=Gb(d),a.Ld=d,f=Pk(b.H,c,e,function(h,k,l){h=t(h);for(var m=h.next();!m.done;m=h.next())if(m=m.value,m.data&&m.cueTime&&m.frames){for(var n=m.cueTime+k,p=l,r=t(m.frames),v=r.next();!v.done;v=r.next())Qk(a,n,p,"ID3",v.value);if(a.J)a.J.onHlsTimedMetadata(m,n)}}),A(g,f.F,2);a.M=f;C(g)})} +function uk(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g)return b.mimeType=c.mimeType,b.uri=c.uri,d=b.uri,e=a.G,a.cb=d,f=a,A(h,fi(d,e,a.h.manifest.retryParameters,b.mimeType),2);f.Uc=h.h;a.I=Gb(a.Uc);g=Xg(a.h.manifest);c.H&&"AUDIO"===c.H.nodeName&&(g.disableVideo=!0);a.I.configure(g);C(h)})} +function vk(a,b){var c=b.uri,d=a.G;a.bd=new Xi(function(){return a.Ra()});a.bd.addEventListener("regionadd",function(g){g=g.region;Rk(a,Sk,g);if(a.J)a.J.onDashTimedMetadata(g)});var e={networkingEngine:d,filter:function(g){return K(function(h){return h["return"](Tk(a,g))})},makeTextStreamsForClosedCaptions:function(g){return Uk(a,g)},onTimelineRegionAdded:function(g){var h=a.bd;a:{var k=t(h.g);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.schemeIdUri==g.schemeIdUri&&l.id==g.id&&l.startTime== +g.startTime&&l.endTime==g.endTime){k=l;break a}k=null}null==k&&(h.g.add(g),g=new O("regionadd",new Map([["region",g]])),h.dispatchEvent(g))},onEvent:function(g){return a.dispatchEvent(g)},onError:function(g){return Mk(a,g)},isLowLatencyMode:function(){return a.h.streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return a.h.streaming.autoLowLatencyMode},enableLowLatencyMode:function(){a.configure("streaming.lowLatencyMode",!0)}},f=Date.now()/1E3;return new Qg(function(){var g,h,k,l;return K(function(m){if(1== m.g)return g=a,A(m,a.I.start(c,e),2);g.i=m.h;h=Bk(Vk);a.dispatchEvent(h);if(0==a.i.variants.length)throw new Q(2,4,4036);Wk(a.i);k=Date.now()/1E3;l=k-f;a.A.F=l;C(m)})}(),function(){return a.I.stop()})} -function wk(a,b){var c,d;return J(function(e){return 1==e.g?(c=Date.now()/1E3,d=!0,a.v=Xk(a,{Zb:a.G,onError:function(f){Mk(a,f)},jd:function(f){Yk(a,f)},onExpirationUpdated:function(f,g){Zk(a,f,g)},onEvent:function(f){a.dispatchEvent(f);f.type==$k&&d&&(d=!1,a.A.j=Date.now()/1E3-c)}}),a.h.useMediaCapabilities||$f(a.i),a.v.configure(a.h.drm),A(e,yh(a.v,a.i.variants,a.i.offlineSessionIds,a.h.useMediaCapabilities),2)):3!=e.g?A(e,a.v.nc(b.H),3):A(e,Tk(a,a.i),0)})} -function xk(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,v;return J(function(y){switch(y.g){case 1:b.startTime=c.startTime;d=b.H;e=b.uri;a.cb=e;a.F=new Qi({$c:function(){return b.H.playbackRate},Xc:function(){return b.H.defaultPlaybackRate},je:function(w){b.H.playbackRate=w},Te:function(w){b.H.currentTime+=w}});f=function(){return al(a)};g=function(){return bl(a)};a.l.o(d,"playing",f);a.l.o(d,"pause",f);a.l.o(d,"ended",f);a.l.o(d,"ratechange",g);h=a.h.abrFactory;a.B&&a.Id==h||(a.Id=h,a.B=Gb(h),"function"!=typeof a.B.playbackRateChanged&& +function wk(a,b){var c,d;return K(function(e){return 1==e.g?(c=Date.now()/1E3,d=!0,a.v=Xk(a,{Zb:a.G,onError:function(f){Mk(a,f)},jd:function(f){Yk(a,f)},onExpirationUpdated:function(f,g){Zk(a,f,g)},onEvent:function(f){a.dispatchEvent(f);f.type==$k&&d&&(d=!1,a.A.j=Date.now()/1E3-c)}}),a.h.useMediaCapabilities||$f(a.i),a.v.configure(a.h.drm),A(e,yh(a.v,a.i.variants,a.i.offlineSessionIds,a.h.useMediaCapabilities),2)):3!=e.g?A(e,a.v.nc(b.H),3):A(e,Tk(a,a.i),0)})} +function xk(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,v;return K(function(y){switch(y.g){case 1:b.startTime=c.startTime;d=b.H;e=b.uri;a.cb=e;a.F=new Qi({$c:function(){return b.H.playbackRate},Xc:function(){return b.H.defaultPlaybackRate},je:function(w){b.H.playbackRate=w},Te:function(w){b.H.currentTime+=w}});f=function(){return al(a)};g=function(){return bl(a)};a.l.o(d,"playing",f);a.l.o(d,"pause",f);a.l.o(d,"ended",f);a.l.o(d,"ratechange",g);h=a.h.abrFactory;a.B&&a.Id==h||(a.Id=h,a.B=Gb(h),"function"!=typeof a.B.playbackRateChanged&& (yb("AbrManager","Please use an AbrManager with playbackRateChanged function."),a.B.playbackRateChanged=function(){}),a.B.configure(a.h.abr));a.qa=new Fg(a.h.preferredAudioLanguage,a.h.preferredVariantRole,a.h.preferredAudioChannelCount);a.ya=a.h.preferredTextLanguage;a.fb=a.h.preferredTextRole;a.eb=a.h.preferForcedSubs;cl(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.B.init(function(w,x,D){x=void 0===x?!1:x;D=void 0===D?0:D;a.j&&w!=a.j.j&&(kk(a.A.g,w,!0),lj(a.j,w,x,D),dl(a))}); a.D=el(a,b.startTime);a.Aa=fl(a);k=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);gl(a,k);Pf(a.i,a.h.preferredAudioChannelCount);a.j=hl(a);a.j.configure(a.h.streaming);a.m=il;a.dispatchEvent(Bk(jl));l=null;if(m=a.Cb().find(function(w){return w.active})){y.C(2);break}l=kl(a)?a.B.chooseVariant():null;ll(a,l,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){y.C(3);break}n=a.D.m();return A(y,ml(l,n),4);case 4:p=y.h,a.D.v(p);case 3:dl(a);case 2:return r=a.jb().find(function(w){return w.active}), r||((v=ug(a.i.textStreams,a.ya,a.fb,a.eb)[0]||null)&&lk(a.A.g,v,!0),l&&(v?(l.audio&&nl(a,l.audio,v)&&(a.$=!0),a.$&&a.M.l.setTextVisibility(!0),ol(a)):a.$=!1),v&&(a.h.streaming.alwaysStreamText||a.Hb())&&mj(a.j,v)),A(y,a.j.start(),5);case 5:a.h.abr.enabled&&(a.B.enable(),pl(a)),bg(a.j?a.j.j:null,a.i),ql(a.i),rl(a),kl(a),a.i.variants.some(function(w){return w.primary}),a.l.Ia(d,"loadedmetadata",function(){a.A.l=Date.now()/1E3-c.pe}),C(y)}})} -function yk(a,b,c){var d,e,f,g;return J(function(h){return 1==h.g?(d=Nb,e=Date.now()/1E3,f=!0,a.v=Xk(a,{Zb:a.G,onError:function(k){Mk(a,k)},jd:function(k){Yk(a,k)},onExpirationUpdated:function(k,l){Zk(a,k,l)},onEvent:function(k){a.dispatchEvent(k);k.type==$k&&f&&(f=!1,a.A.j=Date.now()/1E3-e)}}),a.v.configure(a.h.drm),g={id:0,language:"und",primary:!1,audio:null,video:{id:0,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:c.mimeType?c.mimeType.split(";")[0]: +function yk(a,b,c){var d,e,f,g;return K(function(h){return 1==h.g?(d=Nb,e=Date.now()/1E3,f=!0,a.v=Xk(a,{Zb:a.G,onError:function(k){Mk(a,k)},jd:function(k){Yk(a,k)},onExpirationUpdated:function(k,l){Zk(a,k,l)},onEvent:function(k){a.dispatchEvent(k);k.type==$k&&f&&(f=!1,a.A.j=Date.now()/1E3-e)}}),a.v.configure(a.h.drm),g={id:0,language:"und",primary:!1,audio:null,video:{id:0,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:c.mimeType?c.mimeType.split(";")[0]: "video/mp4",codecs:c.mimeType?bf(c.mimeType):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",label:null,type:d.bb,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null},bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},a.v.X=!0,A(h,yh(a.v,[g],[]),2)):A(h,a.v.nc(b.H),0)})} function zk(a,b,c){function d(){return al(a)}b.uri=c.uri;b.startTime=c.startTime;a.cb=b.uri;a.D=new Fi(b.H);var e=!1;a.xb.push(function(){e=!0});null!=b.startTime&&a.D.v(b.startTime);a.F=new Qi({$c:function(){return b.H.playbackRate},Xc:function(){return b.H.defaultPlaybackRate},je:function(g){b.H.playbackRate=g},Te:function(g){b.H.currentTime+=g}});gl(a,a.h.streaming.rebufferingGoal);a.l.o(b.H,"playing",d);a.l.o(b.H,"pause",d);a.l.o(b.H,"ended",d);a.l.o(b.H,"ratechange",function(){return bl(a)}); "none"!=a.g.preload&&a.l.Ia(a.g,"loadedmetadata",function(){a.A.l=Date.now()/1E3-c.pe});a.g.audioTracks&&(a.l.o(a.g.audioTracks,"addtrack",function(){return rl(a)}),a.l.o(a.g.audioTracks,"removetrack",function(){return rl(a)}),a.l.o(a.g.audioTracks,"change",function(){return rl(a)}));a.g.textTracks&&(a.l.o(a.g.textTracks,"addtrack",function(g){e||(rl(a),sl(a,g))}),a.l.o(a.g.textTracks,"removetrack",function(){return rl(a)}),a.l.o(a.g.textTracks,"change",function(){return rl(a)}));b.H.src=b.uri;(Lc()|| -Kc("Web0S"))&&b.H.load();a.m=tl;a.dispatchEvent(Bk(jl));var f=new Oe;ti(a.g,HTMLMediaElement.HAVE_METADATA,a.l,function(){f.resolve()});ti(a.g,HTMLMediaElement.HAVE_CURRENT_DATA,a.l,function(){var g;return J(function(h){if(1==h.g){if(e)return h["return"]();ul(a);g=vl(a);return g.find(function(k){return"disabled"!=k.mode})?h.C(2):A(h,new Promise(function(k){a.l.Ia(a.g.textTracks,"change",k);(new R(k)).R(1)}),2)}if(e)return h["return"]();wl(a);C(h)})});a.g.error?f.reject(Lk(a)):"none"==a.g.preload&& +Kc("Web0S"))&&b.H.load();a.m=tl;a.dispatchEvent(Bk(jl));var f=new Oe;ti(a.g,HTMLMediaElement.HAVE_METADATA,a.l,function(){f.resolve()});ti(a.g,HTMLMediaElement.HAVE_CURRENT_DATA,a.l,function(){var g;return K(function(h){if(1==h.g){if(e)return h["return"]();ul(a);g=vl(a);return g.find(function(k){return"disabled"!=k.mode})?h.C(2):A(h,new Promise(function(k){a.l.Ia(a.g.textTracks,"change",k);(new R(k)).R(1)}),2)}if(e)return h["return"]();wl(a);C(h)})});a.g.error?f.reject(Lk(a)):"none"==a.g.preload&& (Pa('With