@castlabs/prestoplay 6.14.0 → 6.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +25 -0
- package/cjs/cl.adobe.js +3 -3
- package/cjs/cl.airplay.js +3 -3
- package/cjs/cl.broadpeak.js +7 -7
- package/cjs/cl.cast.js +113 -111
- package/cjs/cl.conviva.js +33 -33
- package/cjs/cl.core.js +550 -529
- package/cjs/cl.crypto.js +9 -9
- package/cjs/cl.dash.js +74 -73
- package/cjs/cl.externs.js +191 -64
- package/cjs/cl.freewheel.js +24 -24
- package/cjs/cl.hls.js +69 -68
- package/cjs/cl.hlssmpte.js +6 -6
- package/cjs/cl.htmlcue.js +29 -30
- package/cjs/cl.ima.js +23 -23
- package/cjs/cl.mse.js +290 -275
- package/cjs/cl.muxdata.js +15 -15
- package/cjs/cl.onboard.js +3 -3
- package/cjs/cl.persistent.js +13 -13
- package/cjs/cl.playlist.js +6 -6
- package/cjs/cl.simid.js +15 -15
- package/cjs/cl.smooth.js +72 -71
- package/cjs/cl.thumbnails.js +26 -26
- package/cjs/cl.tizen.js +70 -70
- package/cjs/cl.ttml.js +28 -28
- package/cjs/cl.verimatrix.js +5 -5
- package/cjs/cl.vimond.js +13 -13
- package/cjs/cl.vr.js +19 -19
- package/cjs/cl.vtt.js +14 -14
- package/cjs/cl.youbora.js +20 -20
- package/cl.adobe.js +3 -3
- package/cl.airplay.js +3 -3
- package/cl.broadpeak.js +5 -5
- package/cl.cast.js +89 -88
- package/cl.conviva.js +27 -27
- package/cl.core.js +457 -438
- package/cl.crypto.js +9 -9
- package/cl.dash.js +70 -68
- package/cl.externs.js +187 -64
- package/cl.freewheel.js +19 -19
- package/cl.hls.js +71 -69
- package/cl.hlssmpte.js +5 -5
- package/cl.htmlcue.js +26 -26
- package/cl.ima.js +17 -17
- package/cl.mse.js +255 -240
- package/cl.muxdata.js +13 -13
- package/cl.onboard.js +4 -4
- package/cl.persistent.js +11 -11
- package/cl.playlist.js +5 -5
- package/cl.simid.js +13 -13
- package/cl.smooth.js +59 -59
- package/cl.thumbnails.js +19 -19
- package/cl.tizen.js +57 -57
- package/cl.ttml.js +22 -22
- package/cl.verimatrix.js +4 -4
- package/cl.vimond.js +8 -8
- package/cl.vr.js +15 -15
- package/cl.vtt.js +12 -12
- package/cl.youbora.js +15 -15
- package/clpp.styles.css +2 -0
- package/package.json +1 -1
- package/typings.d.ts +387 -90
package/cjs/cl.core.js
CHANGED
|
@@ -1,464 +1,476 @@
|
|
|
1
1
|
(function(){var g={}; var _ = {};
|
|
2
|
-
(function(window){var aa,da,ea,fa,
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
_.
|
|
7
|
-
|
|
8
|
-
ub="License verification failed: ";_.
|
|
9
|
-
_.Ib="Player sources";_.
|
|
10
|
-
|
|
11
|
-
tc="X-
|
|
12
|
-
_.Tc="application/dash+xml";
|
|
13
|
-
_.nd="castingstarted";_.
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
_.
|
|
20
|
-
Mg=function(a){return function(){return _.
|
|
21
|
-
_.w=function(a,b){a.prototype=
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
_.H=function(a,b){var c=a.split("."),d=
|
|
29
|
-
_.
|
|
30
|
-
_.L=function(a,b){if(b)for(var c in b)this[c]=b[c];this.defaultPrevented=this.cancelable=this.bubbles=!1;this.timeStamp=window.performance&&window.performance.now?window.performance.now():Date.now();this.type=a;this.isTrusted=!1;this.target=this.currentTarget=null;this.f=this.a=!1};
|
|
31
|
-
_.
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
f.next())if(g=g.value,!
|
|
35
|
-
else{if(l=a.a)l=a.a,m=a.m.getPosition(),l=l.endTime<=m;l&&(l=a.a,a.a=null,a.m.trigger(new _.L(_.
|
|
36
|
-
|
|
37
|
-
_.
|
|
38
|
-
_.
|
|
39
|
-
_.
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
_.
|
|
47
|
-
_.
|
|
48
|
-
_.
|
|
49
|
-
_.
|
|
50
|
-
_.
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
_.
|
|
55
|
-
_.
|
|
56
|
-
_.
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
[]
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
_.
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
_.
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
_.
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
Zk=function(
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
_.
|
|
97
|
-
|
|
2
|
+
(function(window){var aa,ca,da,ea,fa,ha,qa,ta,wa,xa,Aa,Da,Ea,Ga,Ia,Ma,Ra,Sa,Va,Xa,Ya,fb,gb,hb,ib,jb,kb,lb,mb,nb,ob,pb,qb,rb,sb,ub,vb,zb,Ab,Bb,Cb,Db,Eb,Fb,Hb,Ib,Lb,Ob,Qb,Ub,Yb,Zb,$b,ac,bc,ec,gc,lc,mc,pc,qc,sc,tc,uc,vc,wc,Wc,ad,gd,nd,od,vd,wd,xd,Ad,Bd,Cd,Dd,Ed,Gd,Hd,Id,Jd,Kd,Ld,Qd,Sd,Vd,be,ce,de,ee,fe,ge,ie,le,me,oe,te,Ae,Be,De,Fe,Le,cf,kf,mf,nf,of,pf,qf,uf,vf,wf,xf,yf,Cf,Df,Ef,Ff,Gf,Hf,If,Jf,Nf,Pf,cg,fg,mg,wg,xg,Lg,Pg,Qg,Rg,Sg,Tg,Vg,Wg,Xg,Zg,$g,dh,hh,jh,ih,kh,lh,mh,nh,rh,uh,sh,th,vh,xh,yh,Ch,Eh,Jh,Oh,Qh,Rh,Wh,Uh,Xh,
|
|
3
|
+
Zh,Yh,ai,di,hi,ji,ii,vi,wi,xi,zi,Ci,Di,Fi,Gi,Ki,Mi,Oi,Ii,Si,gj,jj,nj,pj,qj,tj,oj,kj,uj,Bj,Hj,Lj,Mj,Nj,Qj,Rj,dk,ek,fk,lk,nk,ok,uk,vk,yk,Ak,zk,xk,Bk,wk,Ek,Ck,Dk,Fk,Gk,Mk,Sk,Uk,Wk,hl,jl,kl,ll,vl,Zk,ml,yl,Al,Cl,Dl,Bl,Fl,Gl,zl,Hl,Il,Jl,Kl,Ll,Pl,Ql,Rl,Sl,Ml,Wl,Xl,Zl,am,cm,im,jm,km,lm,mm,nm,om,pm,qm,rm,sm,tm,zm,Lm,Tm,Wm,Xm,Zm,$m,gn,ln,mn,rn,xn,yn,An,Bn,Gn,Hn,Sn,Tn,$n,go,po,ro,to,xo,yo,Co,no,lo,Jo,Ao,Ko,Mo,Lo,Ro,Qo,Oo,Po,bo,so,No,co,Io,ko,Eo,Fo,Uo,Ho,mo,fo,Zo,ap,bp,cp,dp,ip,mp,np,pp,tp,yp,lp,zp,Ap,Dp,Gp,
|
|
4
|
+
Hp,Jp,Kp,Fp,Ep,Lp,Mp,Np,Op,Tp,Yp,Zp,$p,dq,cq,fq,eq,hq,iq,jq,kq,gq,mq,oq,pq,qq,rq,sq,tq,uq,vq,xq,yq,zq,Aq,wq,Dq,X,Eq,Iq,Gq,Jq,Mq,Lq,Kq,Nq,Pq,Uq,Tq,Qq,Wq,Xq,Yq,ar,br,$q,Zq,cr,fr,hr,gr,kr,ir,nr,or,mr,qr,rr,sr,pr,er,tr,dr,wr,xr,Ar,Br,Cr,Dr,Gr,Er,Hr,Jr,Lr,Kr,Nr,Fr,Or,zr,Pr,yr,Ur,Wr,Vr,$r,Yr,Zr,Rr,Sr,Xr,gs,cs,ds,es,os,ps,ms,ws,xs,ys,zs,As,Sp,Bs,Ds,Es,Fs,Gs,Hs,Is,Js,Ks,Ls,Ms,Ns,Os,Ps,Qs,Rs,Ss,Vs,Ts,Ws,Ys,Zs,Us,Xs,$s,at,bt,ct,dt,et,ft,gt,ht,it,lt,nt,ot,pt,mt,rt,st,yt,Dt,Et,Gt,Ft,ak,It,Lt,Kt,Mt,Nt,Jt,Pt,Qt,
|
|
5
|
+
Ot,Rt,St,iu,bk,nu,Uj,Au,Du,bh,Fu;aa=" coming up at ";_.ba=" is registered.";ca=" is unsupported on this platform.";da=" to a log level. Falling back to default!";ea="': 'output-restricted'";fa="() is ongoing!";ha=".start";_.ia="6.15.0";_.ja="AdaptationSet";_.ka="Already destroyed. No-op";_.la="Already released. No-op";_.ma="Autoplay is not allowed due to browser policy.";_.na="BANDWIDTH";_.pa="BASIC";qa="CHECKSUM";_.ra="CLOSED-CAPTIONS";_.sa="CODECS";ta="Can not set volume to ";_.ua="Cannot retrieve buffer information due to platform limitations";
|
|
6
|
+
_.va="CastlabsPlayer";wa="Content-Length";xa="Content-Type";_.ya="Could not find configured DRM environment.";_.za="DRM environment '";Aa="DRM licenses loaded";Da="DRMtoday";Ea="DRMtodayOnboard";_.Fa="DURATION";Ga="Destroying player";_.Ha="Disable track type ";Ia="EXT-X-BYTERANGE";_.Ja="EXT-X-DATERANGE";_.Ka="EXT-X-DISCONTINUITY";_.La="EXT-X-DISCONTINUITY-SEQUENCE";Ma="EXT-X-ENDLIST";_.Na="EXT-X-KEY";_.Oa="EXT-X-MAP";_.Qa="EXT-X-MEDIA-SEQUENCE";Ra="EXT-X-PART-INF";Sa="EXT-X-PLAYLIST-TYPE";_.Ta="EXT-X-PRELOAD-HINT";
|
|
7
|
+
_.Ua="EXT-X-PROGRAM-DATE-TIME";Va="EXT-X-SERVER-CONTROL";_.Wa="EXT-X-STREAM-INF";Xa="EXT-X-TARGETDURATION";Ya="Error while decoding string!";_.Za="Error while fetching license!";_.bb="FairPlay Certificate URL is not defined";_.cb="FairPlay License URL is not defined";_.eb="GROUP-ID";fb="HW_SECURE_ALL";gb="HW_SECURE_CRYPTO";hb="HW_SECURE_DECODE";ib="HeaderDrm";jb="Hide video element .";kb="Interstitial ";lb="Interstitial cue ";mb="Interstitials ";nb="Invalid track type: ";ob="InvalidStateError";
|
|
8
|
+
pb="Item failed (ID: ";qb="Item loading (ID: ";rb="Item not found (ID: ";sb="Key status for Key ID '";_.tb="LANGUAGE";ub="License verification failed: ";vb="Load interrupted while a player release is pending";_.wb="Loading player with configuration";_.xb="MaxHeight";_.yb="MaxWidth";zb="Missing media element";Ab="No drmtoday configuration found in player configuration. Unable to modify the DRM license request!";Bb="No event provided!";Cb="No items in the playlist";Db="No sources provided!";Eb="No track data attached to the event, unable to add track!";
|
|
9
|
+
Fb="Not a persistent session.";_.Gb="Not supported";Hb="NotAllowedError";Ib="NotSupportedError";_.Jb="PLAYLIST";_.Kb="PlayReady License URL is not defined";Lb="Player not ready yet.";_.Mb="Player sources";_.Nb="Player state change: ";Ob="Playing interstitial asset ";_.Pb="Please make sure ";Qb="Preloading is not supported by this player.";_.Rb="QualityLevel";_.Sb="RESOLUTION";_.Tb="Representation";Ub="STANDARD";_.Vb="SUBTITLES";_.Wb="SW_SECURE_CRYPTO";_.Xb="SW_SECURE_DECODE";Yb="Session is closed";
|
|
10
|
+
Zb="Setting native ";$b="Show video element .";ac="Signature Verification failed";bc="Skipping Session creation. License for init data was already requested in Session: '";_.cc="SmoothStreamingMedia";_.dc="TYPE";ec="The index is not in the allowed range.";_.fc="URI";gc="Unable to translate ";_.hc="Unhandled/ignored event";_.jc="Unregistering listeners";lc="Unsupported keySystem";mc="Using VTTCue polyfill from 3 argument TextTrackCue.";_.nc="VIDEO";_.oc="VOD";pc="Wait for preloading to finish";
|
|
11
|
+
qc="WebkitEmeManager.MediaKeySession.load";_.rc="Widevine License URL is not defined";sc="Will create EME Manager: ";tc="X-ASSET-LIST";uc="X-ASSET-URI";vc="X-PLAYOUT-LIMIT";wc="X-RESUME-OFFSET";_.xc="ad-break-started";_.yc="ad-break-stopped";_.zc="ad-buffering";_.Ac="ad-clicked";_.Bc="ad-completed";_.Cc="ad-first-quartile";_.Dc="ad-impression";_.Ec="ad-loaded";_.Fc="ad-midpoint";_.Gc="ad-paused";_.Hc="ad-progress";_.Ic="ad-resumed";_.Jc="ad-skipped";_.Kc="ad-started";_.Lc="ad-stopped";_.Mc="ad-third-quartile";
|
|
12
|
+
_.Nc="addtrack";_.Oc="ads-timeline-changed";_.Pc="airplay-casting-ended";_.Qc="airplay-casting-started";_.Rc="airplay-status-changed";_.Sc="application";_.Tc="application/cea-608";_.Uc="application/dash+xml";Wc="application/mp4";_.Xc='application/mp4; codecs\x3d"stpp"';_.Yc='application/mp4; codecs\x3d"wvtt"';_.Zc="application/ttml+xml";_.$c="application/vnd.ms-sstr+xml";ad="application/x-www-form-urlencoded";_.bd="audio";_.cd="audio/aac";_.dd="audio/ac3";_.ed="audio/eac3";_.fd="audio/mp4";gd='audio/mp4;codecs\x3d"mp4a.40.2"';
|
|
13
|
+
_.hd="audiobufferchanged";_.id="autoplaynotallowed";_.jd="bitratechanged";_.kd="boolean";_.ld="bufferingended";_.md="bufferingstarted";nd="canplay";od="canplaythrough";_.pd="caption";_.qd="castingstarted";_.rd="caststatuschanged";_.sd="cdn-switch-success";_.td="cenc";_.ud="center";vd="certificate-request";wd="change";xd="chrome";_.yd="clpp-fill";Ad="clpp-hidden";Bd="clpp-mc-playlist";Cd="clpp-mc-playlist-item";Dd="clpp-mc-playlist-video-el";Ed="clpp-visible";_.Fd="clpp.cast.CastSender";Gd="clpp.drm.HeaderDrm";
|
|
14
|
+
Hd="clpp.drm.eme.AppleEmeManager";Id="clpp.interstitial.Player";Jd="clpp.native.Player";Kd="clpp.plist.McPlaylist";Ld="clpp.utils.Platform";_.Md="codecs";_.Nd="column-reverse";_.Od="com.adobe.primetime";_.Pd="com.apple.fps";Qd="com.apple.hls.interstitial";_.Rd="com.microsoft.playready";Sd="com.microsoft.playready.recommendation";_.Td="com.widevine.alpha";_.Ud="config.drm.customData is not defined";Vd="controls";_.Xd="cuechange";_.Yd="decoder";_.Zd="destroy()";_.$d="disabled";_.ae="div";be="drm.license.req.";
|
|
15
|
+
ce="drm.mediaKeys.end";de="drm.mediaKeys.start";ee="drm.onPlay.end";fe="drm.onPlay.start";ge="drm.sess.update.";_.he="drmexpirationupdate";ie="drmrenewalstarted";_.je="drmsessionpersisted";_.ke="drmsessionupdate";le="drmtoday";me="durationchange";_.ne="ec-3";oe="encrypted";_.pe="end";_.qe="ended";_.re="error";_.se="forced";te="fullscreenElement";_.ue="function";_.ve="height";_.we="hidden";_.xe="html";_.ye="image";_.ze="internal-error";Ae="itemchange";Be="keystatuseschange";_.Ce="left";De="license-renewal";
|
|
16
|
+
Fe="license-request";_.Ge="line-left";_.He="line-right";_.Ie="live-turned-static";_.Je="loadeddata";_.Ke="loadedmetadata";Le="loadstart";_.Me="main";_.Ne="mdat";_.Oe="mdia";_.Pe="message";_.Qe="metadata";_.Re="mimeType";_.Se="minf";_.Te="moov";_.Ue="mpd-type-changed";_.Ve="mpeg-dash-callback-event";_.We="none";_.k="number";_.Xe="object";_.Ye="onBitrateChanged()";_.Ze="onPlayerError()";_.$e="onPlayerWillDestroy";_.af="onPlayerWillRelease";_.bf="onStateChanged()";cf="online-status-changed";_.df="optional";
|
|
17
|
+
_.ef="org.w3.clearkey";_.ff="output-restricted";_.gf="pause";_.hf="persistent";_.jf="persistent-license";kf="picture-in-picture";_.lf="play";mf="player.afterLoad.end";nf="player.afterLoad.start";of="player.appendLoad.end";pf="player.appendLoad.start";qf="player.beforeLoad.end";uf="player.beforeLoad.start";vf="player.load.end";wf="player.load.start";xf="player.setupPlaylist.end";yf="player.setupPlaylist.start";_.zf="playing";_.Af="playlist-item-changed";_.Bf="playlist-modified";Cf="playlist.next.end";
|
|
18
|
+
Df="playlist.next.start";Ef="preload-aborted";Ff="preload-failed";Gf="preloaded";Hf="preloading";If="primary-before-load";Jf="primary-content";_.Kf="progress";_.Lf="px";_.Mf="ratechange";Nf="released";_.Of="releasing";Pf="removetrack";_.Qf="required";_.Rf="resize";_.Sf="right";_.Tf="sc-playlist-ended";_.Uf="sc-playlist-item-changed";_.Vf="sc-playlist-live-turned-static";_.Wf="sc-playlist-timeline-changed";_.Xf="seeked";_.Yf="seeking";_.Zf="showing";_.$f="simid-creative-started";_.ag="simid-creative-stopped";
|
|
19
|
+
_.bg="sinf";cg="stalled";_.dg="start";_.eg="statechanged";fg="status-pending";_.gg="stbl";_.hg="string";_.ig="stsd";_.jg="style";_.kg="subtitle";_.lg="subtitles-htmlcue";mg="temporary";_.ng="text/vtt";_.og="text/xml";_.rg="timeupdate";_.sg="trak";_.ug="ttml-xml";_.vg="und";wg="unknown";xg="update";_.yg="urn:scte:scte35";_.zg="urn:scte:scte35:2014";_.Ag="user-seeked";_.Bg="user-seeking";_.Cg="value";_.Dg="vertical-lr";_.Eg="vertical-rl";_.Fg="video";_.Gg="video/mp2t";_.Hg="video/mp4";_.Ig="videobufferchanged";
|
|
20
|
+
_.Jg="videotrackchanged";_.Kg="vimond-response";Lg="visibilitychange";_.Mg="vtt-xml";_.Ng="waiting";_.Og="waitingforkey";Pg="webkit-org.w3.clearkey";Qg="webkitkeyadded";Rg="webkitkeyerror";Sg="webkitkeymessage";Tg="webkitneedkey";_.Ug="width";Vg="x-dt-csl-tracking-token";Wg="x-dt-follow-up-token";Xg="x-dt-resp-code";Zg=function(a){return function(){return _.Yg[a].apply(this,arguments)}};$g=function(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}};
|
|
21
|
+
_.t=function(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:$g(a)}};_.ah=function(a){if(!(a instanceof Array)){a=_.t(a);for(var b,c=[];!(b=a.next()).done;)c.push(b.value);a=c}return a};_.w=function(a,b){a.prototype=bh(b.prototype);a.prototype.constructor=a;if(ch)ch(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c]};
|
|
22
|
+
dh=function(){dh=function(){};eh.Symbol||(eh.Symbol=fh)};hh=function(a,b){this.a=a;gh(this,"description",{configurable:!0,writable:!0,value:b})};jh=function(){dh();var a=eh.Symbol.iterator;a||(a=eh.Symbol.iterator=eh.Symbol("Symbol.iterator"));typeof Array.prototype[a]!=_.ue&&gh(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return ih($g(this))}});jh=function(){}};ih=function(a){jh();a={next:a};a[eh.Symbol.iterator]=function(){return this};return a};
|
|
23
|
+
kh=function(){this.w=!1;this.l=null;this.f=void 0;this.a=1;this.j=this.o=0;this.B=this.h=null};lh=function(a){if(a.w)throw new TypeError("Generator is already running");a.w=!0};mh=function(a,b){a.h={Rg:b,rh:!0};a.a=a.o||a.j};_.x=function(a,b,c){a.a=c;return{value:b}};_.y=function(a){a.a=0};_.A=function(a,b,c){a.o=b;void 0!=c&&(a.j=c)};nh=function(a){a.o=0;a.j=2};_.oh=function(a,b){a.a=b;a.o=0};_.C=function(a){a.o=0;var b=a.h.Rg;a.h=null;return b};_.ph=function(a){a.B=[a.h];a.o=0;a.j=0};
|
|
24
|
+
_.qh=function(a,b){var c=a.B.splice(0)[0];(c=a.h=a.h||c)?c.rh?a.a=a.o||a.j:void 0!=c.F&&a.j<c.F?(a.a=c.F,a.h=null):a.a=a.j:a.a=b};rh=function(a){this.a=new kh;this.f=a};uh=function(a,b){lh(a.a);var c=a.a.l;if(c)return sh(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.a["return"]);a.a["return"](b);return th(a)};
|
|
25
|
+
sh=function(a,b,c,d){try{var e=b.call(a.a.l,c);if(!(e instanceof Object))throw new TypeError("Iterator result "+e+" is not an object");if(!e.done)return a.a.w=!1,e;var f=e.value}catch(g){return a.a.l=null,mh(a.a,g),th(a)}a.a.l=null;d.call(a.a,f);return th(a)};th=function(a){for(;a.a.a;)try{var b=a.f(a.a);if(b)return a.a.w=!1,{value:b.value,done:!1}}catch(c){a.a.f=void 0,mh(a.a,c)}a.a.w=!1;if(a.a.h){b=a.a.h;a.a.h=null;if(b.rh)throw b.Rg;return{value:b["return"],done:!0}}return{value:void 0,done:!0}};
|
|
26
|
+
vh=function(a){this.next=function(b){lh(a.a);a.a.l?b=sh(a,a.a.l.next,b,a.a.A):(a.a.A(b),b=th(a));return b};this["throw"]=function(b){lh(a.a);a.a.l?b=sh(a,a.a.l["throw"],b,a.a.A):(mh(a.a,b),b=th(a));return b};this["return"]=function(b){return uh(a,b)};jh();this[Symbol.iterator]=function(){return this}};_.wh=function(a,b){var c=new vh(new rh(b));ch&&ch(c,a.prototype);return c};
|
|
27
|
+
xh=function(a,b){if(b){for(var c=eh,d=a.split("."),e=0;e<d.length-1;e++){var f=d[e];f in c||(c[f]={});c=c[f]}d=d[d.length-1];e=c[d];f=b(e);f!=e&&null!=f&&gh(c,d,{configurable:!0,writable:!0,value:f})}};yh=function(a){function b(d){return a.next(d)}function c(d){return a["throw"](d)}return new Promise(function(d,e){function f(g){g.done?d(g.value):Promise.resolve(g.value).then(b,c).then(f,e)}f(a.next())})};_.E=function(a){return yh(new vh(new rh(a)))};
|
|
28
|
+
_.H=function(a,b){var c=a.split("."),d=zh;c[0]in d||"undefined"==typeof d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d[e]&&d[e]!==Object.prototype[e]?d=d[e]:d=d[e]={}:d[e]=b};Ch=function(a){return a&&0<=Ah[a]?Ah[a]:Bh};Eh=function(a){if(!a)return _.J("clpp.log",gc+a+da),-1;var b=Dh[a.toUpperCase()];return void 0===b?(_.J("clpp.log",gc+a+da),-1):b};_.K=function(a){(this.tag=a)&&void 0===Ah[a]&&(Ah[a]=-1)};_.Gh=function(a){Fh.info.apply(Fh,arguments)};
|
|
29
|
+
_.Hh=function(a){Fh.debug.apply(Fh,arguments)};_.J=function(a){Fh.warn.apply(Fh,arguments)};_.Ih=function(a){Fh.error.apply(Fh,arguments)};Jh=function(a,b){this.Qb=a;this.sourceIndex=b};_.Nh=function(a){if(a){var b=a.a();b in _.Kh?_.Mh.warn("Player-Factory '"+b+"' already registered"):(_.Kh[b]=a,_.Mh.info("Registered Player-Factory: '"+b+"'"))}};Oh=function(a){return Object.values(_.Kh).find(a)||null};_.Ph=function(){this.a={}};Qh=function(a,b,c,d){this.f=a;this.Nc=b;this.a=c;this.ym=!!d};
|
|
30
|
+
_.L=function(a,b){if(b)for(var c in b)this[c]=b[c];this.defaultPrevented=this.cancelable=this.bubbles=!1;this.timeStamp=window.performance&&window.performance.now?window.performance.now():Date.now();this.type=a;this.isTrusted=!1;this.target=this.currentTarget=null;this.f=this.a=!1};Rh=function(a){this.a=new _.Ph;this.f=a};_.Sh=function(){this.a=new _.Ph};
|
|
31
|
+
_.Th=function(a,b,c,d){function e(h){for(var l=_.t(c),m=l.next();!m.done;m=l.next())a.off(b,m.value,e);d(h)}for(var f=_.t(c),g=f.next();!g.done;g=f.next())a.on(b,g.value,e)};_.Vh=function(a){var b=a.a,c=[],d;for(d in b.a)c.push.apply(c,b.a[d]);for(b=0;b<c.length;++b)Uh(c[b]);a.a.clear()};Wh=function(a,b,c,d){this.target=a;this.type=b;this.a=c;this.f=d;this.target.addEventListener(b,c,d)};Uh=function(a){a.target.removeEventListener(a.type,a.a,a.f);a.target=null;a.a=null};
|
|
32
|
+
Xh=function(a){this.m=a;this.o=a.getConfiguration().streaming.addMissingTimelineCues||!1;this.j=null;this.f=new _.Sh;this.a=this.l=null;this.h=[];this.g=new _.K("clpp.native.Metadata")};Zh=function(a,b){a.j=b;a.l=a.j.textTracks;a.f.on(a.l,_.Nc,function(c){c=c.track;c.kind===_.Qe&&Yh(a,c)})};
|
|
33
|
+
Yh=function(a,b){function c(l){for(var m=_.t(d),n=m.next();!n.done;n=m.next())if(n=n.value,l.startTime===n.startTime&&l.endTime===n.endTime)return n;m={schemeIdUri:"",value:"",startTime:0,endTime:0,id:"",type:_.$h,eventElement:null};a.o&&e&&"SCTE35-IN"===l.value.key&&0<l.startTime?(m.startTime=0,m.endTime=l.startTime):(m.startTime=l.startTime,m.endTime=l.endTime);e=!1;d.push(m);return d[d.length-1]}a.g.debug("onMetadata_()");b.mode=_.we;var d=[],e=!0;if(b.cues){for(var f=_.t(b.cues),g=f.next();!g.done;g=
|
|
34
|
+
f.next())if(g=g.value,!ai(a,g)){var h=c(g);switch(g.value.key){case "SCTE35-IN":case "SCTE35-OUT":h.schemeIdUri=_.zg;h.type=_.bi;break;case "X-CUSTOM-ID":h.id=g.value.data}}f=_.t(d);for(g=f.next();!g.done;g=f.next())a.m.trigger(new _.L(_.ci,{detail:g.value}));Array.prototype.push.apply(a.h,d);di(a,d,b);a.f.off(b,_.Xd);a.f.on(b,_.Xd,function(l){l=l.target.activeCues;l=l.length?ai(a,l[0]):a.a;var m;if(m=l)m=a.m.getPosition(),m=l.startTime<=m&&m<l.endTime;if(m)a.a=l,a.m.trigger(new _.L(_.ei,{detail:l}));
|
|
35
|
+
else{if(l=a.a)l=a.a,m=a.m.getPosition(),l=l.endTime<=m;l&&(l=a.a,a.a=null,a.m.trigger(new _.L(_.fi,{detail:l})))}})}};ai=function(a,b){for(var c=_.t(a.h),d=c.next();!d.done;d=c.next())if(d=d.value,b.startTime===d.startTime&&b.endTime===d.endTime)return d;return null};di=function(a,b,c){if(a.o){for(;0<c.cues.length;)c.removeCue(c.cues[0]);b.forEach(function(d){c.addCue(new DataCue(d.startTime,d.endTime,{key:"SCTE35-OUT",data:null}))})}};_.gi=function(a){return Array.isArray(a)?a:[a]};
|
|
36
|
+
hi=function(a,b){return a===b?!0:a.length===b.length&&a.every(function(c,d){return c===b[d]})};ji=function(a,b,c){if(null==a&&null==b)return!0;if(null==a||null==b)return!1;a=c?a.map(c):a;b=c?b.map(c):b;return ii(a,b)&&ii(b,a)};ii=function(a,b){var c=new Set(a);return b.every(function(d){return c.has(d)})};
|
|
37
|
+
_.ki=function(a,b){b=void 0===b?{}:b;if(b.Jg){for(var c=[],d={},e=_.t(a),f=e.next();!f.done;d={ce:d.ce},f=e.next())d.ce=f.value,c.some(function(g){return function(h){return b.Jg(g.ce,h)}}(d))||c.push(d.ce);return c}return Array.from((new Set(a)).values())};
|
|
38
|
+
_.ri=function(a,b,c,d){d=void 0===d?_.li:d;this.startTime=a;this.endTime=b;this.payload=c;this.payloadType=d;this.positionAlign=this.position=null;this.size=100;this.textAlign=_.mi;this.writingMode=_.ni;this.lineInterpretation=_.oi;this.line=null;this.lineAlign=_.pi;this.direction=qi;this.region=null;this.cssClassList=[];this.id=this.backgroundImage="";this.containerRows=null};
|
|
39
|
+
_.ui=function(){this.id="";this.regionAnchorY=this.regionAnchorX=this.viewportAnchorY=this.viewportAnchorX=0;this.height=this.width=100;this.viewportAnchorUnits=this.widthUnits=this.heightUnits=_.si;this.scroll=ti;this.cssClassList=[];this.writingMode=this.displayAlign=null};vi=function(a){this.m=a;this.l=a.getTextDisplayer();this.f=this.h=null;this.a=new _.Sh;this.j=!1;this.g=new _.K("clpp.native.CueHandler")};
|
|
40
|
+
wi=function(a,b){var c=b.track;c.kind!==_.Qe&&(c.mode===_.Zf&&(c.mode=_.we),a.a.on(c,_.Xd,function(d){d=d.target||d.srcElement;d.mode=_.we;d.activeCues&&(d=Array.from(d.activeCues).map(a.o),a.l.append(d,[]))}))};_.P=function(a,b,c,d,e){var f=Error.call(this,xi(a,b,c,d));this.message=f.message;"stack"in f&&(this.stack=f.stack);this.severity=a;this.category=b;this.code=c;this.data=!d||_.O.ca(d)?{}:d;this.cause=void 0===e?null:e;this.f=!1;Error.captureStackTrace&&Error.captureStackTrace(this,_.P)};
|
|
41
|
+
xi=function(a,b,c,d){a=(a===_.Q?"FATAL":"RECOVERABLE")+" Clpp-Error [Category "+b+" - Code "+c+"]";if(_.O.ca(d))a+=": "+d;else if(null!=d)if(null!=d.message)a+=": "+d.message,delete d.message;else try{a+=": "+JSON.stringify(d)}catch(e){}return a};_.yi=function(a,b){var c=Error.call(this,a);this.message=c.message;"stack"in c&&(this.stack=c.stack);this.code=b};
|
|
42
|
+
zi=function(a,b){var c=b||hi,d=null,e=null,f=!1;return function(g){for(var h=[],l=0;l<arguments.length;++l)h[l]=arguments[l];if(f&&c(h,d))return e;f=!0;d=h;return e=a.apply(null,_.ah(h))}};_.Ai=function(a,b){return a.concat(b)};_.Bi=function(a){return null!=a};Ci=function(a){for(var b=[],c=0;c<arguments.length;++c)b[c]=arguments[c];for(c=0;c<b.length;c++){var d=b[c];if(null!==d&&void 0!==d)return d}throw new _.yi("No non-null, non-undefined value found");};
|
|
43
|
+
Di=function(a){for(var b=[],c=0;c<arguments.length;++c)b[c]=arguments[c];for(c=0;c<b.length;c++){var d=b[c];if(null!==d&&void 0!==d)return d}};_.Ei=function(a){var b;a instanceof _.Ei?(Fi(this,a.gb),this.zc=a.zc,this.Na=a.Na,Gi(this,a.dd),this.za=a.za,_.Hi(this,Ii(a.a)),this.kc=a.kc):a&&(b=String(a).match(Ji))?(Fi(this,b[1]||"",!0),this.zc=Ki(b[2]||""),this.Na=Ki(b[3]||"",!0),Gi(this,b[4]),this.za=Ki(b[5]||"",!0),_.Hi(this,b[6]||"",!0),this.kc=Ki(b[7]||"")):this.a=new _.Li(null)};
|
|
44
|
+
Fi=function(a,b,c){a.gb=c?Ki(b,!0):b;a.gb&&(a.gb=a.gb.replace(/:$/,""))};Gi=function(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.dd=b}else a.dd=null};_.Hi=function(a,b,c){b instanceof _.Li?a.a=b:(c||(b=Mi(b,Ni)),a.a=new _.Li(b))};Ki=function(a,b){return a?b?decodeURI(a):decodeURIComponent(a):""};Mi=function(a,b,c){return typeof a===_.hg?(a=encodeURI(a).replace(b,Oi),c&&(a=a.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),a):null};
|
|
45
|
+
Oi=function(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)};_.Li=function(a){this.f=a||null};Ii=function(a){var b=new _.Li;b.f=a.f;if(a.a){var c={},d;for(d in a.a)c[d]=a.a[d].concat();b.a=c;b.h=a.h}return b};_.Pi=function(a,b){if(0===b.length)return a;var c=b.map(function(d){return new _.Ei(d)});return a.map(function(d){return new _.Ei(d)}).map(function(d){return c.map(d.resolve.bind(d))}).reduce(_.Ai,[]).map(function(d){return d.toString()})};
|
|
46
|
+
Si=function(a,b){for(var c=_.t(Qi[a]),d=c.next();!d.done;d=c.next()){d=d.value;for(var e=_.t(b),f=e.next();!f.done;f=e.next())if(f=f.value,d.test(f.trim()))return f.trim()}return a===_.Ri?"":null};_.Ui=function(a,b){for(var c=Ti[a],d=0;d<c.length;d++)for(var e=0;e<b.length;e++)if(c[d].test(b[e].trim()))return b[e].trim();return a===_.Ri?"":null};_.Xi=function(a,b,c){return a.map(function(d){d=_.Vi(d)||"";return(d=_.Wi[b][d])?d:b===_.Ri?c&&"vtt"!==c?Wc:_.ng:null}).filter(Boolean)[0]||null};
|
|
47
|
+
_.Vi=function(a){a=(new _.Ei(a)).za.split(".");return 1>=a.length?null:a.pop()};_.Yi=function(a,b,c,d){this.id=a;this.name=b;this.attributes=c;this.value=void 0===d?null:d};_.Zi=function(a,b,c,d){d=void 0===d?{}:d;a=a.getAttribute(b);if(!a&&d.required)throw new _.P(_.Q,4,4023,"Required attribute missing: "+b);return a?a.value:c||null};_.$i=function(a,b){return _.Zi(a,b,void 0,{required:!0})};_.aj=function(a,b){this.name=a;this.value=b};
|
|
48
|
+
_.bj=function(a,b,c,d,e,f,g,h,l,m,n,p,q,u){l=void 0===l?!1:l;m=void 0===m?null:m;n=void 0===n?null:n;p=void 0===p?null:p;q=void 0===q?null:q;u=void 0===u?[]:u;this.position=a;this.startTime=b;this.endTime=c;this.wa=g;this.Qa=d;this.va=e;this.ja=f;this.keyInfo=(void 0===h?null:h)||null;this.Sc=_.O.R(l)?!1:!!l;this.timescale=m;this.horizontalTiles=n;this.verticalTiles=p;this.durationPerTile=q;this.a=u||[];this.h=!1};
|
|
49
|
+
_.cj=function(a,b,c,d,e,f,g,h,l,m,n,p,q,u){u=void 0===u?[]:u;_.bj.call(this,a,b,c,d,e,f,g,void 0===h?null:h,void 0===l?!1:l,void 0===m?null:m,void 0===n?null:n,void 0===p?null:p,void 0===q?null:q,u);this.initSegment=void 0;this.ga=0};_.ej=function(a,b){a=_.dj(a);b=_.dj(b);return a.split("-")[0]===b.split("-")[0]};_.dj=function(a){var b=(a||"").split("-");a=b[0]||"";b=b[1]||"";a=a.toLowerCase();a=fj.get(a)||a;return(b=b.toUpperCase())?a+"-"+b:a};gj=function(a){if(null!==a&&void 0!==a)return Number(a)};
|
|
50
|
+
_.hj=function(a){if(typeof a!==_.hg)return null;var b=a.trim().match(/^(\d+)x(\d+)$/);if(!b)return null;a=parseInt(b[1],10);b=parseInt(b[2],10);return 0>=a||0>=b?null:{Fd:a,Zd:b,Rm:a*b}};_.ij=function(a,b){for(var c=_.t(a),d=c.next();!d.done;d=c.next())if(!b(d.value))return!1;return!0};jj=function(){};
|
|
51
|
+
nj=function(a,b){if(!a&&!b)return!0;if(!a||!b||a.byteLength!==b.byteLength)return!1;if(kj(a)===kj(b)&&(a.byteOffset||0)===(b.byteOffset||0))return!0;for(var c=_.lj(a),d=_.lj(b),e=_.t(mj(a.byteLength)),f=e.next();!f.done;f=e.next())if(f=f.value,c[f]!==d[f])return!1;return!0};_.lj=function(a,b,c){c=void 0===c?Infinity:c;return oj(a,void 0===b?0:b,c,Uint8Array)};pj=function(a,b,c){c=void 0===c?Infinity:c;return oj(a,void 0===b?0:b,c,Uint16Array)};
|
|
52
|
+
qj=function(a,b,c){c=void 0===c?Infinity:c;return oj(a,void 0===b?0:b,c,Uint32Array)};_.rj=function(a,b,c){c=void 0===c?Infinity:c;return oj(a,void 0===b?0:b,c,Int32Array)};_.sj=function(a,b,c){c=void 0===c?Infinity:c;return oj(a,void 0===b?0:b,c,DataView)};tj=function(a){return a instanceof ArrayBuffer?a:0===a.byteOffset&&a.byteLength===a.buffer.byteLength?a.buffer:(new Uint8Array(a)).buffer};
|
|
53
|
+
oj=function(a,b,c,d){var e=d.BYTES_PER_ELEMENT||1,f=kj(a),g=(a.byteOffset||0)+a.byteLength;a=Math.max(0,Math.min((a.byteOffset||0)+b*e,g));c=Math.min(a+Math.max(c*e,0),g);a/=e;return new d(f,a,c/e-a)};kj=function(a){return a instanceof ArrayBuffer?a:a.buffer};uj=function(){};_.wj=function(a,b){b=void 0===b?!0:b;var c=_.vj(a).replace(/\+/g,"-").replace(/\//g,"_");return b?c:c.replace(/[=]*$/,"")};
|
|
54
|
+
_.xj=function(a){a=window.atob(a.replace(/-/g,"+").replace(/_/g,"/"));for(var b=new Uint8Array(a.length),c=0;c<a.length;++c)b[c]=a.charCodeAt(c);return b};_.yj=function(a){for(var b=new Uint8Array(a.length/2),c=0;c<a.length;c+=2)b[c/2]=window.parseInt(a.substr(c,2),16);return b};_.zj=function(a){for(var b="",c=0;c<a.length;++c){var d=a[c].toString(16);1===d.length&&(d="0"+d);b+=d}return b};
|
|
55
|
+
_.Aj=function(a,b){if(!a&&!b)return!0;if(!a||!b||a.length!==b.length)return!1;for(var c=0;c<a.length;++c)if(a[c]!==b[c])return!1;return!0};Bj=function(a){for(var b=0,c=0;c<arguments.length;++c)b+=arguments[c].length;b=new Uint8Array(+b);for(var d=c=0;d<arguments.length;++d)b.set(arguments[d],c),c+=arguments[d].length;return b};_.vj=function(a){a=_.R.fromCharCode(_.lj(a));return btoa(a)};_.Cj=function(a){this.f=a;this.a=0};
|
|
56
|
+
_.Dj=function(a,b){b.lastIndex=a.a;var c=b.exec(a.f);c=null==c?null:{position:c.index,length:c[0].length,results:c};if(a.a===a.f.length||null===c||c.position!==a.a)return null;a.a+=c.length;return c.results};
|
|
57
|
+
_.Ej=function(a,b){var c=b.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!c)throw new _.P(_.Q,4,4016,{invalidTag:b});var d=c[1],e=c[2];c=[];var f;if(e){e=new _.Cj(e);var g;(g=_.Dj(e,/^([^,=]+)(?:,|$)/g))&&(f=g[1]);for(var h=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;g=_.Dj(e,h);)c.push(new _.aj(g[1],g[2]||g[3]))}return new _.Yi(a,d,c,f)};_.Gj=function(){return{maxAttempts:1,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:0,fatalStatusCodes:_.ah(Fj).concat()}};
|
|
58
|
+
Hj=function(a,b){a.timeout=b.timeout;a.baseDelay=b.baseDelay;a.backoffFactor=b.backoffFactor;a.fuzzFactor=b.fuzzFactor;a.maxAttempts=b.maxAttempts;a.fatalStatusCodes=b.fatalStatusCodes||_.ah(Fj).concat()};
|
|
59
|
+
_.Jj=function(a,b){_.O.ca(a)&&(a={uris:[a]});Array.isArray(a)&&(a={uris:a});var c={uris:a.uris||[],type:a.type||_.Ij,uriIndex:0,method:a.method||"GET",body:a.body||null,headers:Object.assign({},a.headers),allowCrossSiteCredentials:a.allowCrossSiteCredentials||!1,onProgress:a.onProgress||null,onFragment:a.onFragment||null,maxAttempts:a.maxAttempts||1,currentAttempt:0,baseDelay:a.baseDelay||1E3,backoffFactor:a.backoffFactor||2,fuzzFactor:a.fuzzFactor||.5,timeout:a.timeout||0,requestModifiers:a.requestModifiers||
|
|
60
|
+
[],responseModifiers:a.responseModifiers||[],startTime:a.startTime||null,endTime:a.endTime||null,contentType:a.contentType||null,licenseRequestType:a.licenseRequestType||null,sessionId:null,bytesRemaining:-1,bytesLoaded:-1,bytesTotal:-1,timescale:a.timescale||null,rateLimitBps:a.rateLimitBps||null,disableFragmentSupport:a.disableFragmentSupport||!1,disableMergedFragments:a.disableMergedFragments||!1,fatalStatusCodes:_.ah(Fj).concat(),requestStartTimestamp:null};a.keyInfo&&(c.keyInfo=a.keyInfo);b&&
|
|
61
|
+
Hj(c,b);return c};_.Kj=function(a,b,c,d,e,f,g,h){e&&(d=e);e={uri:d,data:b||new ArrayBuffer(0),headers:a,status:c,fromCache:!!a["x-shaka-from-cache"],timeMs:g,responseStartMs:h,request:f};if(200<=c&&299>=c&&202!==c)return e;g=null;try{g=_.R.zd(b,!0)}catch(l){}_.Hh("HTTP error text:",g);throw new _.P(0<=(f.fatalStatusCodes||[]).indexOf(c)?_.Q:1,1,1001,{url:d,status:c,responseText:g,headers:a,request:f,response:e});};
|
|
62
|
+
Lj=function(a,b){var c=parseInt(b,10);Number.isNaN(c)&&(c=-1);a.bytesTotal=c;a.bytesLoaded=0;a.bytesRemaining=c};Mj=function(a,b,c){0<a.bytesRemaining&&(a.bytesRemaining-=b);a.bytesLoaded+=b;if(a.onProgress)a.onProgress(b,c)};Nj=function(a,b,c){if(0>=a)return Promise.resolve();var d=8*c/a-b/1E3;return 0<d?new Promise(function(e){setTimeout(e,1E3*d)}):Promise.resolve()};_.Oj=function(){var a,b,c=new Promise(function(d,e){a=d;b=e});c.resolve=a;c.reject=b;return c};
|
|
63
|
+
_.Pj=function(a,b){this.P=a;this.A=b;this.a=!1};Qj=function(a,b){a.P.then(function(){return b(!0)},function(){return b(!1)});return a};Rj=function(a,b,c){try{var d=a(b);if(d&&d.P&&d.abort)return c.resolve(d.P),function(){return d.abort()};c.resolve(d);return function(){return Promise.resolve(d).then(function(){})["catch"](function(){})}}catch(e){return c.reject(e),function(){return Promise.resolve()}}};_.Sj=function(){this.a=[]};
|
|
64
|
+
_.Tj=function(a,b){a.a.push(Qj(b,function(){var c=a.a,d=c.indexOf(b);-1<d&&c.splice(d,1)}))};_.ck=function(){this.f=[];this.h=[];this.o=!1;this.l=new _.Sj;this.a={};this.j=0;this.a.data=Uj;!window.fetch||!window.AbortController||_.Vj(6)||_.Yj()&&68<_.Zj().browserVersion.major?(this.a.http=ak,this.a.https=ak):(this.a.http=bk,this.a.https=bk)};dk=function(a,b){var c,d;return _.E(function(e){if(1==e.a)return c=_.R,_.x(e,a.fetch(b),2);d=e.f;return e["return"](c.Ah(c.aa(d.data)))})};
|
|
65
|
+
ek=function(a,b){var c,d;return _.E(function(e){if(1==e.a)return _.x(e,dk(a,b),2);c=e.f;try{d=JSON.parse(c);if(null==d||typeof d!==_.Xe)throw Error("Not an object");return e["return"](d)}catch(f){throw new _.yi("Failed to parse JSON response","json-failed");}})};
|
|
66
|
+
fk=function(a,b,c,d){d=void 0===d?"HEAD":d;var e,f;return _.E(function(g){switch(g.a){case 1:if(!navigator.onLine)return g["return"](!1);if(!b){g.F(2);break}e=_.Jj(b,c);e.method=d;c||(e.timeout=5E3);e.headers["cache-control"]="no-cache";_.A(g,4);return _.x(g,a.fetch(e).P,6);case 6:_.oh(g,2);break;case 4:if(f=_.C(g),1002===f.code||1003===f.code)return g["return"](!1);case 2:return g["return"](!0)}})};
|
|
67
|
+
_.gk=function(a,b){this.id=a;this.type=b;this.roles=[];this.frameRate=this.label=this.originalLanguage=this.language=this.kind=null;this.trickPlay=!1;this.channelsCount=this.src=this.mimeType=null;this.spatialAudio=!1;this.renditions=[];this.accessibility=[]};_.hk=function(a){return a&&a!==_.vg?a:null};
|
|
68
|
+
lk=function(a){if(!a)throw new _.P(_.Q,3,3101,nb+a);if(!_.O.ca(a))throw new _.P(_.Q,3,3101,nb+a+". Track type must be a string!");switch(a.toLowerCase()){case _.T:return _.T;case _.ik:return _.ik;case _.jk:return _.jk;case kk:return kk}throw new _.P(_.Q,3,3101,"Unknown track type: "+a+".");};
|
|
69
|
+
nk=function(a,b){a=lk(a);var c=_.hk(b.kind),d=b.id;d||(d=String(_.mk++));d=new _.gk(d,c===_.Qe?kk:a);d.kind=c;d.label=_.hk(b.label);d.language=_.hk(b.language);d.originalLanguage=b.originalLanguage||d.language;return d};ok=function(a){return"@@scheme:"+(a.scheme||"")+("@@value:"+a.value)+("@@id:"+(a.id||"")+"@@type:"+(a.type||""))+("@@protocol:"+(a.protocol||""))};
|
|
70
|
+
_.pk=function(a,b){this.track=b;this.id=a;this.originalId=this.drm=this.drmInfo=this.codec=this.nd=this.bandwidth=this.height=this.width=null};
|
|
71
|
+
_.qk=function(a){this.j=a;this.scheme=null;var b=document.createElement("a"),c=a.match(/^(.*:)(\/\/(.*))$/),d=!1;if(c){if(this.scheme=c[1],b.href=c[2],":"===b.protocol||""===b.host&&""===b.pathname)b.href="//dummy.com/"+c[3],d=!0}else{b.href=a;if(":"===b.protocol||""===b.host&&""===b.pathname)b.href="//dummy.com/"+a.match(/\/?\/?(.*)/)[1],d=!0;this.scheme=b.protocol}""===this.scheme&&(this.scheme=window.location.protocol);this.a=d?"":b.hostname;this.port=b.port;this.path=b.pathname;_.R.startsWith(this.path,
|
|
72
|
+
"/")||(this.path="/"+this.path);this.f=b.search;this.h=b.hash};_.rk=function(a){return a.scheme+"//"+(a.a+(a.port?":"+a.port:"")+a.path+a.h+a.f)};_.sk=function(a,b,c){return a?(c||Object.keys(a).sort()).reduce(function(d,e){if(!(e in a))return d;var f=a[e],g="\x26";""===d&&(g=b?"":"?");d=d+g+encodeURIComponent(e);return d=d+"\x3d"+encodeURIComponent(void 0===f?"":f)},""):""};
|
|
73
|
+
_.tk=function(a){var b={};a=a||"";a=a.substring(a.indexOf("?")+1);a=_.t(a.split("\x26"));for(var c=a.next();!c.done;c=a.next()){var d=c.value.split("\x3d");c=decodeURIComponent(d[0]);d=decodeURIComponent(d[1]||"");c&&(b[c]=d)}return b};uk=function(a,b){return a.startsWith("http:://")||a.startsWith("https:://")?a:(new URL(a,b)).toString()};
|
|
74
|
+
vk=function(a){this.f=a;this.g=new _.K("clpp.native.hls.HlsMetadataParser");this.a=zi(this.h.bind(this),function(b,c){return b[0]===c[0]&&b[1].enableHlsVideoTrackInfo===c[1].enableHlsVideoTrackInfo&&b[1].enableMetadata===c[1].enableMetadata})};
|
|
75
|
+
yk=function(a,b,c){var d,e,f,g,h;return _.E(function(l){if(1==l.a)return _.x(l,wk(a,b,c),2);d=l.f;e=d.mimeType;f=d.renditions;g=new _.gk("dummy",_.jk);h=f.map(function(m,n){var p=new _.pk("R"+n,g);p.bandwidth=m.bandwidth;p.nd=m.nd;p.codec=m.codec;p.width=m.width;p.height=m.height;return p});xk(h);return l["return"]({renditions:h,mimeType:e||void 0})})};
|
|
76
|
+
Ak=function(a){a=a.split("\n").filter(function(c){return c.trim().startsWith("#EXT-X-MEDIA:")}).map(function(c){return zk(c)});var b=new Map;a.forEach(function(c){if(c.type&&c.name){var d=c.type+":"+c.name;if(b.has(d))throw Error("#EXT-X-MEDIA:NAME attributes are not unique. It is impossible to map HLS metadata to Safari data structures.");b.set(d,c)}});return b};
|
|
77
|
+
zk=function(a){function b(d){return(d=c.getAttribute(d))?d.value:void 0}var c=_.Ej(0,a);a=b(_.dc);a=null!=a?{AUDIO:_.ik,VIDEO:_.jk,SUBTITLES:_.T}[a]:void 0;return{type:a,groupId:b(_.eb),name:b("NAME"),language:b(_.tb),vn:b("AUTOSELECT"),"default":b("DEFAULT"),Fn:b("FORCED"),xg:b("CHARACTERISTICS"),uri:b(_.fc)}};xk=function(a){var b=new Set;a.forEach(function(c){b.add(c.width+"x"+c.height)});if(b.size<a.length)throw Error("Playlist contains multiple renditions with the same resolution.");};
|
|
78
|
+
Bk=function(a,b){var c,d;return _.E(function(e){if(1==e.a)return c=_.Jj(b),_.x(e,dk(a.f,c),2);d=e.f;return e["return"](d)})};wk=function(a,b,c){var d,e,f,g;return _.E(function(h){if(1==h.a)return d=Ck(b),e=Dk(b,c),f=d[0]?d[0].codec:null,_.x(h,Ek(a,e,f),2);g=h.f;return h["return"]({mimeType:g,renditions:d})})};Ek=function(a,b,c){var d,e;return _.E(function(f){if(1==f.a)return b&&c?_.x(f,Bk(a,b),2):f["return"](null);d=f.f;e=[Fk(d,b),Gk(d,b)].filter(Boolean);return f["return"](_.Xi(e,_.Fg,c))})};
|
|
79
|
+
Ck=function(a){return a.split("\n").filter(function(b){return b.trim().startsWith("#EXT-X-STREAM-INF:")}).map(function(b){var c=_.Ej(0,b);if(c.getAttribute(_.nc))throw Error("Playlist contains alternative video streams.");var d=_.Zi(c,_.Sb);b=d?Number(d.split("x")[0]):null;d=d?Number(d.split("x")[1]):null;var e=_.Zi(c,_.na);e=e?Number(e):null;var f=_.Zi(c,"AVERAGE-BANDWIDTH");f=f?Number(f):null;c=_.Zi(c,_.sa);c=_.Ui(_.Fg,c?c.split(","):[]);return{bandwidth:e,nd:f,codec:c,width:b,height:d,mimeType:null}})};
|
|
80
|
+
Dk=function(a,b){var c=a.split("\n").filter(function(d){return d.trim().endsWith(".m3u8")})[0];return c?uk(c,b):null};Fk=function(a,b){var c=a.split("\n").find(function(d){return!d.startsWith("#")&&0<d.trim().length});return c?uk(c,b):null};Gk=function(a,b){var c=a.split("\n").find(function(d){return d.startsWith("#EXT-X-MAP:")});return c?(c=_.Zi(_.Ej(0,c),_.fc))?uk(c,b):null:null};
|
|
81
|
+
_.Ik=function(a,b,c){for(var d=_.t(_.Hk),e=d.next();!e.done;e=d.next())if(e=e.value,e.probe(b,c))return e.create(a);return null};_.Jk=function(a){a=_.Hk.indexOf(a);0<=a&&_.Hk.splice(a,1)};_.U=function(){};Mk=function(a,b){var c=Kk;Lk.set(a.toLowerCase().split(";")[0]+"-"+c,{priority:c,plugin:b})};_.Qk=function(a,b){for(var c=_.t([Nk,Ok,Pk,Kk]),d=c.next();!d.done;d=c.next())if(d=Lk.get(a.toLowerCase().split(";")[0]+"-"+d.value)){var e=d.plugin(),f=e.isSupported(a,b);e.destroy();if(f)return d.plugin}return null};
|
|
82
|
+
_.Rk=function(a,b){var c=a;b&&(c+=';codecs\x3d"'+b+'"');return c};Sk=function(a){a=a.split(/ *; */);a.shift();return(a=a.find(function(b){return b.startsWith("codecs\x3d")}))?a.split("\x3d")[1].replace(/^"|"$/g,"").split(/ *, */).join(","):""};_.Tk=function(a){this.f=a;this.a=null};Uk=function(a,b,c){function d(){e&&a.f()}a.stop();var e=!0,f=null;a.a=function(){c?clearInterval(f):clearTimeout(f);e=!1};f=c?setInterval(d,1E3*b):setTimeout(d,1E3*b);return a};_.Vk=function(a){this.f=a;this.a=null};
|
|
83
|
+
Wk=function(){};_.Xk=function(){return!!navigator.userAgent.match(/Edge?\//)};_.Vj=function(a){return _.Yk("Tizen"+(a?" "+String(a):""))};_.Yj=function(){return _.Yk("Web0S")};_.$k=function(){return _.Yj()&&79===Zk().major};_.al=function(){return _.Yk("CrKey")};_.bl=function(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!_.Vj()};_.dl=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:_.bl()&&1<navigator.maxTouchPoints};_.el=function(){return/(?:iPhone|iPad|iPod)/.test(navigator.userAgent)};
|
|
84
|
+
_.Yk=function(a){return(navigator.userAgent||"").includes(a)};hl=function(){if(fl)return fl;gl||(gl=new _.Vk(function(){fl=null}));(fl=document.querySelector(_.Fg)||document.querySelector(_.bd))||(fl=document.createElement(_.Fg));gl.da(1);return fl};jl=function(a,b){try{return parseInt(b,10)}catch(c){il.warn("Unable to parse version number for '"+b+"' from '"+a+"'")}return-1};
|
|
85
|
+
kl=function(a){var b={major:-1,name:wg};if(!a)return b;var c=a.replace(/_/g,".");b.name=c;c=c.split(".");1<=c.length&&(b.major=jl(a,c[0]));2<=c.length&&(b.minor=jl(a,c[1]));3<=c.length&&(b.patch=jl(a,c[2]));4<=c.length&&(b.build=jl(a,c[3]));return b};ll=function(a,b){if(!a||!b||0===b.length)return!1;for(var c=0;c<b.length;c++)if(0<=a.indexOf(b[c]))return!0;return!1};
|
|
86
|
+
vl=function(){var a=ml();if(!a)return nl;var b=a.match(/^.+?(?=\))/);if(!b)return nl;b=b[0];if(ll(b,["iphone","ipad"]))return ol;if(ll(b,["android"]))return pl;if(ll(b,["macintosh"]))return ql;if(ll(b,["windows nt"]))return rl;if(ll(b,["tizen"]))return sl;if(ll(b,["web0s"]))return tl;if(ll(b,["linux"]))return ul;il.warn("Unable to identify OS from user agent: "+a);return nl};
|
|
87
|
+
Zk=function(){var a=ml(),b=["ie","edge","opera","firefox","safari",xd];var c=vl();for(var d=wl[c],e=0,f=b.length;e<f;e++)if(c=d[b[e]]&&a.match(d[b[e]]))return kl(c[1]);return kl("")};ml=function(){var a=window.navigator.userAgent;return a=a.toLowerCase()};
|
|
88
|
+
_.Zj=function(){var a=vl();var b=vl();var c=wl[b];if(c){c=ml().match(c.os_version)[1];c=kl(c);if(b===rl)if("5.1"===c.name)c.name="xp";else if("6.1"===c.name)c.name="7";else if("6.2"===c.name||"6.3"===c.name)c.name="8";b=c}else b=kl("");a:{c=ml();var d=["ie","edge","opera","firefox","safari",xd],e=vl();e=wl[e];for(var f=0,g=d.length;f<g;f++)if(e[d[f]]&&c.match(e[d[f]])){c=d[f];break a}c=xl}return{os:a,osVersion:b,browser:c,browserVersion:Zk()}};
|
|
89
|
+
yl=function(){this.g=new _.K("clpp.native.TrackManager");this.m=null;this.f=new _.Sh;this.h=[];this.B=0;this.o={};this.D=[];this.a=new Map;this.w=null;this.l=new Map;this.A=!0;this.J=this.Mf.bind(this,_.T);this.L=this.Of.bind(this,_.T);this.K=this.Nf.bind(this,_.T);this.N=this.Mf.bind(this,_.jk);this.V=this.Of.bind(this,_.jk);this.T=this.Nf.bind(this,_.jk);this.G=this.Mf.bind(this,_.ik);this.I=this.Of.bind(this,_.ik);this.H=this.Nf.bind(this,_.ik);this.j=null};
|
|
90
|
+
Al=function(a,b){var c,d,e,f,g,h,l,m;return _.E(function(n){if(1==n.a){c=a.m.getConfiguration();d=_.Ik(c,b.mimeType,_.ng);if(!d)return a.g.warn("Track MIME type is not supported",b),n["return"]();e=_.Jj(b.url);return _.x(n,a.m.getNetworkEngine().fetch(e).P,2)}(f=n.f)&&f.data&&(g="External_"+a.B++,a.o[g]=b,h=d.a(_.lj(f.data)),l=URL.createObjectURL(new Blob([h])),m={url:l,kind:b.kind,language:b.language,label:b.label,mimeType:_.ng},zl(a,m,g));_.y(n)})};Cl=function(a,b,c){return Bl(a)&&b===_.jk&&!!c.enableHlsVideoTrackInfo};
|
|
91
|
+
Dl=function(a,b,c){return Bl(a)&&(b===_.ik||b===_.T)&&!!c.enableMetadata};Bl=function(a){a=a.m.getLoadedSource();return!(!a||a.type!==_.El&&!a.url.endsWith(".m3u8"))&&_.bl()};Fl=function(a,b,c){var d,e;return _.E(function(f){if(1==f.a)return(d=a.m.getLoadedSource())&&a.j?_.x(f,a.j.a(d.url,c),2):f["return"]();e=f.f;e.mimeType&&(b.mimeType=e.mimeType);e.renditions&&0<e.renditions.length&&(b.renditions=e.renditions,b.renditions.forEach(function(g){g.track=b}));_.y(f)})};
|
|
92
|
+
Gl=function(a,b,c){var d,e,f,g;return _.E(function(h){if(1==h.a)return(d=a.m.getLoadedSource())&&a.j?_.x(h,a.j.a(d.url,c),2):h["return"]();e=h.f;e.$c&&(f=b.type+":"+b.label,(g=e.$c.get(f))&&g.xg&&(b.accessibility=g.xg.split(",").map(function(l){return l.trim()}).map(function(l){return{value:l,type:b.type,protocol:"HLS"}})));_.y(h)})};
|
|
93
|
+
zl=function(a,b,c){if(a.m){var d=a.m.getSurface().getMedia();if(d){var e=document.createElement("track");e.id=c;e.kind=b.kind;e.srclang=b.language;b.label&&(e.label=b.label);_.R.empty(b.url)?e.src=URL.createObjectURL(new Blob([])):e.src=b.url;d.appendChild(e);a.D.push(e)}}};Hl=function(a,b){if(!a.m)return null;var c=a.m.getSurface();if(!c)return null;c=c.getMedia();if(!c)return null;switch(b){case _.ik:return c.audioTracks;case _.jk:return c.videoTracks;case _.T:return c.textTracks;default:return null}};
|
|
94
|
+
Il=function(a,b){var c=Hl(a,b);c&&(c=Array.from(c),b===_.T&&(c=c.filter(function(d){return d.kind!==_.Qe})));return c};Jl=function(a,b){return a.h.filter(function(c){return c.type===b})};Kl=function(a,b){var c=a.a.get(b)||null;return c&&c.renditions[0]};Ll=function(a,b){var c=a.l.get(b);return c&&c.renditions[0]};
|
|
95
|
+
Pl=function(a,b,c){var d=Il(a,b);if(c){if(void 0===a.h.find(function(l){return l.id===c.id}))throw Error("Unknown track with ID "+c.id+" and type "+b);if(c.type!==b)throw Error("Types mismatch for track "+c.type+" and arg "+b);a.g.debug("Activate track type "+b+" with ID: "+c.id);if(d){a.l.set(b,c);var e=!0,f=!1;switch(b){case _.T:var g="mode";e=_.Zf;f=_.$d;break;case _.ik:g="enabled";break;case _.jk:g="selected"}if(g){d=_.t(d);for(var h=d.next();!h.done;h=d.next())h=h.value,h[g]=Ml(c,h,c.type)?e:
|
|
96
|
+
f}}}else if(a.g.debug(_.Ha+b),a.a.get(b)&&d&&b===_.T){g=_.t(d);for(h=g.next();!h.done;h=g.next())h.value.mode=_.$d;a.a.set(b,null)}b===_.ik?a.m.trigger(new _.L(_.Nl)):b===_.T&&a.m.trigger(new _.L(_.Ol))};Ql=function(a){return a.enabled||a.selected||a.mode===_.Zf||a.mode===_.we};
|
|
97
|
+
Rl=function(a,b,c){c=_.gi(c).filter(function(e){return e});a.g.info("Find preferred tracks for",b,c);var d=Jl(a,b);c.some(function(e){var f=_.dj(e);return(e=d.find(function(g){g=_.dj(g.language||"");return _.ej(f,g)}))?(a.g.info("Will select track with id",e.id),Pl(a,b,e),!0):!1})};Sl=function(a){(a=a.m.getTextDisplayer())&&a.remove(0,Infinity)};
|
|
98
|
+
Ml=function(a,b,c){return a.type!==c?!1:void 0!==b.id&&null!==b.id&&""!==b.id?a.id===b.id:_.O.ka(a,{kind:_.hk(b.kind),language:_.hk(b.language),label:_.hk(b.label)},["kind","language","label"])};_.Tl=function(a,b){this.length=(this.f=a)?a.length:0;this.a=[];this.type=void 0===b?"total":b};_.Ul=function(){this.xd=new Rh(this);this.ud=[]};Wl=function(a){return a.name===Hb&&Vl.some(function(b){return a.message.startsWith(b)})};Xl=function(){};
|
|
99
|
+
_.$l=function(){var a=Infinity;navigator.connection&&navigator.connection.saveData&&_.dl()&&(a=360);var b=_.Gj();b.maxAttempts=3;a={source:"",license:Yl,viewerId:void 0,autoplay:void 0,pauseWhenInBackground:!1,manifest:{attemptParameters:_.Gj(),availabilityWindowOverride:NaN,clockSyncUri:"",ignoreDrmInfo:!1,xlinkFailGracefully:!1,autoCorrectDrift:!0,timeline:{version:1}},abr:{enabled:!0,defaultBandwidthEstimate:1E3,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,useSwitchIntervalForInitialSwitch:!1,
|
|
100
|
+
restrictions:Zl(a),useCmsd:!1},drm:null,enableHtmlCue:!0,preferredAudioLanguage:"",preferredTextLanguage:"",preferredAudioRole:_.Me,preferredTextRole:"",preferredAudioChannelCount:2,preferredAudioCodec:[],preferredVideoCodec:[],preferSpatialAudio:!1,preferForcedSubtitles:!1,volume:null,startTime:null,loop:!1,lowLatencyMode:!1,suggestedPresentationDelay:void 0,muted:void 0,forceWaitForTracks:!1,streaming:{attemptParameters:b,bufferingGoal:10,rebufferingGoal:2,bufferBehind:30,ignoreTextStreamFailures:!1,
|
|
98
101
|
alwaysStreamText:!1,relativeTextTimestamp:!1,startAtSegmentBoundary:!1,gapDetectionThreshold:.1,disableAudioTracks:!1,disableVideoTracks:!1,smallGapLimit:.5,jumpLargeGaps:!0,durationBackoff:1,maxSegmentToMediaOffset:1,forceNativeTS:!1,preferNativeHlsOnSafari:!0,safeSeekOffset:5,stallEnabled:!0,stallThreshold:3,stallSkip:.5,bufferLimitUpdateInterval:.5,overridePasp:!1,enableLiveEdgeChasing:!1,chasingRate:1.15,startChasingAt:5,stopChasingAt:2,chaseJumpDistance:10,patchEdgeWhenMixedContent:!1,ignoreDrift:!1,
|
|
99
|
-
disableFragmentSupport:!1,disableMergedFragments:!1,ignoreManagedMediaSourceStreamingHints:!1},restrictions:
|
|
100
|
-
|
|
101
|
-
_.
|
|
102
|
-
e.suggestedPresentationDelay&&c.push({manifest:{suggestedPresentationDelay:e.suggestedPresentationDelay}}));c=_.
|
|
103
|
-
if(!_.
|
|
104
|
-
7,7100,"config.preferredVideoCodec is not a string or an array");if(!_.
|
|
105
|
-
if(!_.
|
|
106
|
-
if(!_.
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
a.maxBandwidth=Number(a.maxBandwidth);a.minPixels=Number(a.minPixels);a.maxPixels=Number(a.maxPixels);if(Number.isNaN(a.minWidth)||Number.isNaN(a.maxWidth)||Number.isNaN(a.minHeight)||Number.isNaN(a.maxHeight)||Number.isNaN(a.minBandwidth)||Number.isNaN(a.maxBandwidth)||Number.isNaN(a.minPixels)||Number.isNaN(a.maxPixels))throw new _.P(_.Q,7,7100,"Restrictions contain NaN");};
|
|
110
|
-
_.
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
_.
|
|
115
|
-
(b.ignoreUnrecognizedInitData=!!a.ignoreUnrecognizedInitData),a.env)){var c=_.
|
|
116
|
-
_.
|
|
117
|
-
serverCertificate:void 0===f?g.serverCertificate:null===f?null:typeof f===_.
|
|
118
|
-
return c};_.
|
|
119
|
-
_.
|
|
120
|
-
_.
|
|
121
|
-
_.
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
_.
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
_.
|
|
129
|
-
a=["assetId","variantId"];b.f=_.
|
|
130
|
-
|
|
131
|
-
_.
|
|
132
|
-
_.R.
|
|
133
|
-
_.
|
|
134
|
-
_.
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
_.
|
|
138
|
-
_.
|
|
139
|
-
_.
|
|
140
|
-
_.
|
|
141
|
-
_.
|
|
142
|
-
_.
|
|
143
|
-
e=_.
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
_.
|
|
147
|
-
this.w=this.
|
|
148
|
-
|
|
149
|
-
if(2!=m.a)return _.
|
|
150
|
-
_.
|
|
151
|
-
_.
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
_.
|
|
155
|
-
_.
|
|
156
|
-
throw e;}})};_.
|
|
157
|
-
|
|
158
|
-
_.
|
|
159
|
-
_.
|
|
160
|
-
".")),
|
|
161
|
-
_.
|
|
162
|
-
_.
|
|
163
|
-
_.
|
|
164
|
-
!0}return!1}
|
|
165
|
-
|
|
166
|
-
e=f.next()){e=e.value;g=e.audio;var h=e.video;c.
|
|
167
|
-
p){return function(q){var
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
var
|
|
172
|
-
a.
|
|
173
|
-
a.a
|
|
174
|
-
|
|
102
|
+
disableFragmentSupport:!1,disableMergedFragments:!1,ignoreManagedMediaSourceStreamingHints:!1},restrictions:Zl(),tizen:{sideStreamText:_.Vj(2)},safari:{enableHlsVideoTrackInfo:!1,enableMetadata:!1},trickPlay:{speedUpMode:_.Yd,preferTrickPlayTracks:!0},playlist:{timeline:"basic",content:_.oc,cropTimeline:!1}};if(_.Yk("Edge/")||_.Vj())a.streaming.gapDetectionThreshold=.5;_.Yj()&&(a.streaming.stallEnabled=!1);_.$k()&&(a.streaming.stallEnabled=!0,a.streaming.stallThreshold=1,a.streaming.stallSkip=1,a.streaming.gapDetectionThreshold=
|
|
103
|
+
.02);_.Vj()&&(a.streaming.stallEnabled=!0,a.streaming.stallThreshold=1,a.streaming.stallSkip=0);a.vr={enable:!1,attachMouseListener:!0,fieldOfView:70,sensitivity:1,invertHorizontalControl:!1,invertVerticalControl:!1};return a};
|
|
104
|
+
_.bm=function(a){for(var b=[],c=0;c<arguments.length;++c)b[c]=arguments[c];if(!b)return _.$l();c=[_.$l()];var d=!1;b=_.t(b);for(var e=b.next();!e.done;e=b.next())e=e.value,null!==e&&void 0!==e&&(_.O.ca(e)&&(e={source:e}),e.lowLatencyMode&&!d&&(c.push({streaming:{rebufferingGoal:.1,bufferLimitUpdateInterval:.01,ignoreDrift:!0,attemptParameters:{maxAttempts:3,baseDelay:250,backoffFactor:1}},abr:{bandwidthUpgradeTarget:.6,bandwidthDowngradeTarget:.95},manifest:{lowLatencyMode:!0}}),d=!0),c.push(e),null!=
|
|
105
|
+
e.suggestedPresentationDelay&&c.push({manifest:{suggestedPresentationDelay:e.suggestedPresentationDelay}}));c=_.O.na.apply(null,c);_.O.ca(c.volume)&&(""===""+c.volume?c.volume=null:c.volume=Number(c.volume));if(!_.O.R(c.volume)&&(!_.O.qa(c.volume)||_.O.isNaN(c.volume)))throw new _.P(_.Q,7,7100,"config.volume is not a number");if(!_.O.R(c.preferredTextLanguage)&&!_.O.ca(c.preferredTextLanguage)&&!Array.isArray(c.preferredTextLanguage))throw new _.P(_.Q,7,7100,"config.preferredTextLanguage is not a string or an array");
|
|
106
|
+
if(!_.O.R(c.preferredAudioLanguage)&&!_.O.ca(c.preferredAudioLanguage)&&!Array.isArray(c.preferredAudioLanguage))throw new _.P(_.Q,7,7100,"config.preferredAudioLanguage is not a string or an array");if(!_.O.R(c.preferredAudioCodec)&&!_.O.ca(c.preferredAudioCodec)&&!Array.isArray(c.preferredAudioCodec))throw new _.P(_.Q,7,7100,"config.preferredAudioCodec is not a string or an array");if(!_.O.R(c.preferredVideoCodec)&&!_.O.ca(c.preferredVideoCodec)&&!Array.isArray(c.preferredVideoCodec))throw new _.P(_.Q,
|
|
107
|
+
7,7100,"config.preferredVideoCodec is not a string or an array");if(!_.O.R(c.drm)){if(c.drm.env&&!_.O.ca(c.drm.env))throw new _.P(_.Q,7,7100,"config.drm.env is not a string");if(c.drm.offlineId&&!_.O.ca(c.drm.offlineId))throw new _.P(_.Q,7,7100,"config.drm.offlineId is not a string");}if(d=c.streaming){d.bufferingGoal=Number(d.bufferingGoal);d.rebufferingGoal=Number(d.rebufferingGoal);d.bufferBehind=Number(d.bufferBehind);d.smallGapLimit=Number(d.smallGapLimit);d.durationBackoff=Number(d.durationBackoff);
|
|
108
|
+
if(!_.O.qa(d.bufferingGoal)||_.O.isNaN(d.bufferingGoal))throw new _.P(_.Q,7,7100,"config.streaming.bufferingGoal is not a number");if(!_.O.qa(d.rebufferingGoal)||_.O.isNaN(d.rebufferingGoal))throw new _.P(_.Q,7,7100,"config.streaming.rebufferingGoal is not a number");if(d.rebufferingGoal>d.bufferingGoal)throw new _.P(_.Q,7,7100,"config.streaming.rebufferingGoal must be \x3e\x3d bufferingGoal");if(!_.O.qa(d.bufferBehind)||_.O.isNaN(d.bufferBehind))throw new _.P(_.Q,7,7100,"config.streaming.bufferBehind is not a number");
|
|
109
|
+
if(!_.O.qa(d.smallGapLimit)||_.O.isNaN(d.smallGapLimit))throw new _.P(_.Q,7,7100,"config.streaming.smallGapLimit is not a number");if(!_.O.qa(d.durationBackoff)||_.O.isNaN(d.durationBackoff))throw new _.P(_.Q,7,7100,"config.streaming.durationBackoff is not a number");d=c.manifest;if(_.O.R(d.availabilityWindowOverride))d.availabilityWindowOverride=NaN;else if(typeof d.availabilityWindowOverride!==_.k)throw new _.P(_.Q,7,7100,"Invalid value for |manifest.availabilityWindowOverride|");am(c.restrictions);
|
|
110
|
+
am(c.abr.restrictions);c.abr.initialRestrictions&&am(c.abr.initialRestrictions)}return c};Zl=function(a){a=void 0===a?Infinity:a;return{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:a,minPixels:0,maxPixels:Infinity,minBandwidth:0,maxBandwidth:Infinity}};
|
|
111
|
+
am=function(a){_.O.R(a.maxPixels)&&(a.maxPixels=Infinity);_.O.R(a.maxBandwidth)&&(a.maxBandwidth=Infinity);_.O.R(a.maxHeight)&&(a.maxHeight=Infinity);_.O.R(a.maxWidth)&&(a.maxWidth=Infinity);_.O.R(a.minPixels)&&(a.minPixels=0);_.O.R(a.minBandwidth)&&(a.minBandwidth=0);_.O.R(a.minHeight)&&(a.minHeight=0);_.O.R(a.minWidth)&&(a.minWidth=0);a.minWidth=Number(a.minWidth);a.maxWidth=Number(a.maxWidth);a.minHeight=Number(a.minHeight);a.maxHeight=Number(a.maxHeight);a.minBandwidth=Number(a.minBandwidth);
|
|
112
|
+
a.maxBandwidth=Number(a.maxBandwidth);a.minPixels=Number(a.minPixels);a.maxPixels=Number(a.maxPixels);if(Number.isNaN(a.minWidth)||Number.isNaN(a.maxWidth)||Number.isNaN(a.minHeight)||Number.isNaN(a.maxHeight)||Number.isNaN(a.minBandwidth)||Number.isNaN(a.maxBandwidth)||Number.isNaN(a.minPixels)||Number.isNaN(a.maxPixels))throw new _.P(_.Q,7,7100,"Restrictions contain NaN");};cm=function(a){return typeof a===_.Xe&&!Array.isArray(a)&&"source"in a};
|
|
113
|
+
_.dm=function(a){_.Ul.call(this);this.log=new _.K(a);this.configuration=this.Ic=_.$l();this.Z=this.D=null;this.Od=this.Uf=!1;this.kg=new _.K("clpp.video.events");this.wd=null;this.we=-1;this.ni=this.xm.bind(this);this.Sf=new _.ck;this.N=new _.Sh;this.Hc=this.Tc=this.ba=null};_.fm=function(a){return _.em.get(a)||null};_.hm=function(a){_.em.get(a.id())?gm.warn("Component already in use."):_.em.set(a.id(),a)};im=function(a){return Array.from(_.em.values()).find(function(b){return b instanceof a})||null};
|
|
114
|
+
jm=function(a){for(var b=_.t(_.em.values()),c=b.next();!c.done;c=b.next())a(c.value)};km=function(a){jm(function(b){b.o(a)})};lm=function(a){jm(function(b){b.h(a)})};mm=function(){jm(function(){})};nm=function(){jm(function(){})};om=function(a){if(null!==im(a))return null;a=new a;a.f();_.hm(a);gm.info("Installed component:",a.id());return a};pm=function(a){if(a=im(a))a.a(),_.em["delete"](a.id()),gm.info("Uninstalled component:",a.id())};qm=function(){this.a=this.f=null;this.g=new _.K("clpp.drm.csl")};
|
|
115
|
+
rm=function(a,b){3===b.type&&(a.f&&(a.g.debug("Attaching tracking token"),b.headers[Vg]=a.f),a.a&&(b.headers[Wg]=a.a))};sm=function(a,b){if(b.request&&3===b.request.type){a.f=b.headers[Vg];a.a=b.headers[Wg];var c=b.headers["x-dt-csl-renewal-info"];a.f&&a.g.debug("Loaded tracking token "+a.f);a.a&&a.g.debug("Loaded followup token "+a.a);if(c)return c=JSON.parse(_.R.aa(_.xj(c))),{delay:c.renewalPeriod,sn:{maxAttempts:c.retryCount,baseDelay:1E3*c.retryPeriod,backoffFactor:1,fuzzFactor:0,timeout:0}}}return null};
|
|
116
|
+
tm=function(a){return _.R.startsWith(a,_.Pd)||_.R.startsWith(a,_.Rd)};_.vm=function(a){_.um[a.J]=a};
|
|
117
|
+
_.xm=function(a){var b={attemptParameters:_.Gj(),enforceSingleSession:!1,delayLicenseRequestUntilPlayed:!1,enableSessionCacheForSkd:!1,ignoreUnrecognizedInitData:!0,Za:{}};if(a&&(b.enforceSingleSession=!!a.enforceSingleSession,b.delayLicenseRequestUntilPlayed=!!a.delayLicenseRequestUntilPlayed,b.preferredDrmSystem=a.preferredDrmSystem,b.emeApi=a.emeApi,a.attemptParameters&&(b.attemptParameters=a.attemptParameters),b.enableSessionCacheForSkd=!!a.enableSessionCacheForSkd,void 0!==a.ignoreUnrecognizedInitData&&
|
|
118
|
+
(b.ignoreUnrecognizedInitData=!!a.ignoreUnrecognizedInitData),a.env)){var c=_.um[a.env]||null;if(!c)throw _.Hh(_.ya,_.Pb+a.env+_.ba),new _.P(_.Q,6,6015,_.za+a.env+"' is missing.");b.Za=_.wm(c,a.customData)||{};_.R.startsWith(a.env.toLowerCase(),le)&&(b.enforceSingleSession=!0)}return b};zm=function(a){a=ym[a];if(!a)return null;var b=_.Zj();return b.os===pl&&4===b.osVersion.major&&4===b.osVersion.minor?null:new Uint8Array(a)};_.Am=function(a){this.J=a;this.f={}};
|
|
119
|
+
_.wm=function(a,b){var c={},d=b?b.widevineVideoRobustness:void 0,e=b?b.widevineAudioRobustness:void 0,f=b?b.serverCertificate:void 0,g=a.f[_.Td];g&&(c[_.Td]={licenseUrl:g.licenseUrl,videoRobustness:Di(d,g.videoRobustness),audioRobustness:Di(e,g.audioRobustness),modifiers:g.modifiers,distinctiveIdentifierRequired:Ci(b?b.widevineDistinctiveIdentifierRequired:void 0,g.distinctiveIdentifierRequired,!1),persistentStateRequired:Ci(b?b.widevinePersistentStateRequired:void 0,g.persistentStateRequired,!1),
|
|
120
|
+
serverCertificate:void 0===f?g.serverCertificate:null===f?null:typeof f===_.hg?zm(f):f});(g=a.f[_.Pd])&&(c[_.Pd]={licenseUrl:g.licenseUrl,certificateUrl:g.certificateUrl,modifiers:g.modifiers});d=b?b.playReadyVideoRobustness:void 0;e=b?b.playReadyAudioRobustness:void 0;(g=a.f[_.Rd])&&(c[_.Rd]={licenseUrl:g.licenseUrl,videoRobustness:d||g.videoRobustness,audioRobustness:e||g.audioRobustness,individualizationServer:g.individualizationServer,useLegacySystem:g.useLegacySystem,modifiers:g.modifiers});
|
|
121
|
+
return c};_.Bm=function(a,b){b=void 0===b?!1:b;this.f=_.O.qa(a)?new DataView(new ArrayBuffer(a),0,a):a;this.a=0;this.h=b;this.buffer=this.f.buffer};_.Dm=function(a,b,c){var d=c||0;c=b.byteLength-d;var e=_.lj(a.f.buffer);b=_.lj(b.buffer,d,c);try{e.set(b,a.a),a.a+=c}catch(f){_.Cm()}};_.V=function(a,b){try{a.f.setUint32(a.a,b,a.h),a.a+=4}catch(c){_.Cm()}};_.Cm=function(){throw new _.P(_.Q,3,3E3);};_.Em=function(a,b){this.f=a;this.h=void 0===b?!0:b;this.a=0};_.Fm=function(a){return a.a<a.f.byteLength};
|
|
122
|
+
_.Hm=function(a){try{var b=a.f.getUint8(a.a);a.a+=1;return b}catch(c){_.Gm()}};_.Im=function(a){try{var b=a.f.getUint16(a.a,a.h);a.a+=2;return b}catch(c){_.Gm()}};_.W=function(a){try{var b=a.f.getUint32(a.a,a.h);a.a+=4;return b}catch(c){_.Gm()}};_.Jm=function(a){try{var b=a.f.getInt32(a.a,a.h);a.a+=4;return b}catch(c){_.Gm()}};
|
|
123
|
+
_.Km=function(a){var b=0,c=0;try{!0===a.h?(b=a.f.getUint32(a.a,!0),c=a.f.getUint32(a.a+4,!0)):(c=a.f.getUint32(a.a,!1),b=a.f.getUint32(a.a+4,!1))}catch(d){_.Gm()}if(2097151<c)throw new _.P(_.Q,3,3001);a.a+=8;return c*Math.pow(2,32)+b};Lm=function(a,b){for(var c=new Uint8Array(b),d=0;d<b;d++)c[d]=_.Hm(a);return c};_.Mm=function(a,b){a.a+b>a.f.byteLength&&_.Gm();var c=a.a+a.f.byteOffset;c=a.f.buffer.slice(c,c+b);a.a+=b;return _.lj(c)};
|
|
124
|
+
_.Gm=function(){throw new _.P(_.Q,3,3E3,"Buffer read out of bounds.");};_.Pm=function(){this.h=[];this.f=[];this.a=!1;this.g=new _.K("clpp.mp4")};_.Qm=function(a){for(;_.Fm(a.reader)&&!a.parser.a;)a.parser.Ge(a.start+a.headerSize,a.reader,a.partialOkay)};_.Rm=function(a){for(var b=_.W(a.reader);0<b&&!a.parser.a;--b)a.parser.Ge(a.start+a.headerSize,a.reader,a.partialOkay)};_.Sm=function(a){return function(b){var c=b.reader.Fa()-b.reader.getPosition();a(_.Mm(b.reader,c))}};
|
|
125
|
+
Tm=function(a){for(var b=0,c=0;c<a.length;c++)b=b<<8|a.charCodeAt(c);return b};_.Um=function(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)};_.Vm=function(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)};Wm=function(){};Xm=function(a){var b="";try{b=_.R.zd(a)}catch(c){}return b};_.Ym=function(a){a=Xm(a);var b="";a.length&&(b=(new _.qk(a)).a);return b};
|
|
126
|
+
Zm=function(a){if(!a)return null;var b=null;try{var c=JSON.parse(_.R.aa(a)),d=_.xj(c.sinf[0]);(new _.Pm).M(_.bg,_.Qm).M("schi",_.Qm).M("tenc",function(e){e.reader.skip(6);_.Hm(e.reader)&&(e.reader.skip(1),b=_.zj(_.Mm(e.reader,16)));e.parser.stop()}).parse(d)}catch(e){}return b};
|
|
127
|
+
$m=function(a,b,c){if(!c||!c.byteLength)throw new _.P(_.Q,6,6102);var d;typeof b===_.hg?d=_.R.Le(b,!0):d=b;a=_.R.Le(Xm(a),!0);b=new _.Bm(12+a.byteLength+d.byteLength+c.byteLength,!0);_.V(b,a.byteLength);_.Dm(b,_.lj(a));_.V(b,d.byteLength);_.Dm(b,_.lj(d));_.V(b,c.byteLength);_.Dm(b,_.lj(c));return _.lj(b.buffer)};_.an=function(a){var b=_.lj(a.body);b=_.wj(b);a.headers[xa]=ad;a.body=_.R.Ua("spc\x3d"+b).buffer};
|
|
128
|
+
_.bn=function(a){try{var b=_.R.aa(a.data)}catch(d){return}b=b.trim();"\x3cckc\x3e"===b.substr(0,5)&&"\x3c/ckc\x3e"===b.substr(-6)&&(b=b.slice(5,-6));try{var c=JSON.parse(b);c.ckc&&(b=c.ckc);c.CkcMessage&&(b=c.CkcMessage);c.License&&(b=c.License)}catch(d){}a.data=tj(_.xj(b))};
|
|
129
|
+
gn=function(){var a=cn;if(a===dn)return"https://lic.drmtoday.com";if(a===en)return"https://lic.staging.drmtoday.com";if(a===fn)return"https://lic.test.drmtoday.com";throw Error("Unknown DRMtoday environment '"+a+"'. Can not infer DRMtoday base URL!");};ln=function(a){var b=gn();if(a===_.Td)return b+hn;if(a===_.Rd)return b+jn;if(a===_.Pd)return b+kn;throw Error("Unknown DRM Key-System '"+a+"'. Can not infer license URL!");};
|
|
130
|
+
mn=function(a){a=a.replace(/assetid/gi,"assetId");a=a.replace(/variantid/gi,"variantId");return a=a.replace(/keyid/gi,"keyId")};
|
|
131
|
+
_.on=function(a,b,c){b=Xm(b);c=c&&c.customData?c.customData:{};b=new _.qk(mn(b));var d=_.tk(b.f);if(a&&a.drm&&a.drm.customData){var e=a.drm.customData;a=e.assetId;e=e.variantId;a&&_.R.Ae(""+a)&&(d.assetId=a,nn.debug("Using assetId from the configuration instead of the value from the HLS manifest."));e&&_.R.Ae(""+e)&&(d.variantId=e,nn.info("Using variantId from the configuration instead of the value from the HLS manifest."))}d.keyId?(a=["keyId"],nn.debug("KeyId found in FPS SKD. Removing other parameters")):
|
|
132
|
+
a=["assetId","variantId"];b.f=_.sk(d,!1,a);"/"!==b.path||b.j.includes(b.a+"/")||(b.path="");b=_.rk(b);return c.fpsContentId=b};_.qn=function(a,b,c,d){d=void 0===d?!0:d;c=a.drm;c&&c.env.startsWith(Da)?c.customData&&(_.pn(b,a),a=b.uris[0],d&&c.customData.assetId&&(a+="?assetId\x3d"+encodeURI(""+c.customData.assetId),c.customData.variantId&&(a+="\x26variantId\x3d"+encodeURI(""+c.customData.variantId)),b.uris[0]=a)):nn.warn(Ab)};
|
|
133
|
+
rn=function(a,b,c){_.qn(a,b,c);a=a.drm;a=!(!a||!a.offlineId);c=new _.Ei(b.uris[0]);c.a.add(_.hf,a);b.uris[0]=c.toString()};
|
|
134
|
+
_.sn=function(a,b,c){var d=c&&c.customData&&c.customData.fpsContentId;_.qn(a,b,c,!1);b.headers[xa]=ad;c={spc:_.vj(b.body)};if((a=a.drm)&&a.env.startsWith(Ea)&&d){a={};var e=_.tk((new _.qk(mn(d))).f);d=e.keyId;if(e=e.assetId)nn.info("Applying assetId from HLS manifest."),a.assetId=e;d&&(nn.info("Applying keyId from HLS manifest."),a.keyId=d);a.keyId&&(nn.info("Adding keyID to FPS payload:",a.keyId),c.keyId=a.keyId);a.assetId&&(nn.info("Adding assetID to FPS payload:",a.assetId),c.assetId=a.assetId)}b.body=
|
|
135
|
+
_.R.gd(_.sk(c,!0))};_.tn=function(a,b){nn.debug("Clearing response data");if(200===b.status){var c=_.R.aa(b.data).trim();"\x3cckc\x3e"===c.substr(0,5)&&"\x3c/ckc\x3e"===c.substr(-6)&&(c=c.slice(5,-6));b.data=_.xj(c).buffer}};_.un=function(a,b){var c=a.drm;if(!c||!c.env.startsWith(Da))nn.warn(Ab);else if(c.customData&&c.customData.merchant&&!c.env.startsWith(Ea)){var d=new _.Ei(b.uris[0]),e=d.za;e.endsWith("/")||(e+="/");e+=c.customData.merchant;d.za=e;b.uris[0]=d.toString()}};
|
|
136
|
+
_.vn=function(a,b){try{var c=_.lj(b.data),d=JSON.parse(String.fromCharCode.apply(null,c));nn.debug("Widevine License response",d);var e=atob(d.license),f=new Uint8Array(e.length);for(c=0;c<e.length;++c)f[c]=e.charCodeAt(c);b.data=f.buffer}catch(g){nn.debug("Unable to parse DRMtoday response JSON, assuming the response contained raw data")}};
|
|
137
|
+
_.pn=function(a,b){var c=b.drm;if(c&&c.customData){var d={userId:c.customData.userId,sessionId:c.customData.sessionId,merchant:c.customData.merchant};_.O.Hd(d)&&(a.headers["dt-custom-data"]=btoa(JSON.stringify(d)));(c=c.customData.authToken)&&(a.headers["x-dt-auth-token"]=c)}};xn=function(a){var b={},c=a?a[Xg]:void 0;a=wn[a?a[Xg]:void 0];c&&(b.drmTodayErrorCode=c);a&&(b.drmTodayErrorMessage=a);return b};yn=function(){};
|
|
138
|
+
An=function(a,b){b=void 0===b?0:b;_.Gh("Registering EME Factory: "+a.a());for(var c={priority:b,Qb:a},d=0;d<zn.length;++d)if(zn[d].priority<b){zn.splice(d,0,c);return}zn.push(c)};
|
|
139
|
+
Bn=function(a){if(a){var b=zn.find(function(d){return d.Qb.a()===a}).Qb;if(b&&b.isSupported())return _.Gh(sc+b.a()),b.create();_.Gh("Cannot create selected EME manager. Choosing by priority list.")}b=_.t(zn);for(var c=b.next();!c.done;c=b.next())if(c=c.value.Qb,c.isSupported())return _.Gh(sc+c.a()),c.create();throw Error("Missing EME managers");};_.Dn=function(a,b){var c=_.Cn(a,b);return 1!==c.length?null:c[0]};
|
|
140
|
+
_.Cn=function(a,b){return Array.prototype.filter.call(a.childNodes,function(c){return c instanceof Element&&c.tagName===b})};_.En=function(a){return Array.prototype.every.call(a.childNodes,function(b){return b.nodeType===Node.TEXT_NODE||b.nodeType===Node.CDATA_SECTION_NODE})?a.textContent.trim():null};
|
|
141
|
+
_.Fn=function(a,b){var c=new DOMParser,d=null,e=null;try{e=c.parseFromString(a,_.og)}catch(f){}e&&e.documentElement.tagName===b&&(d=e.documentElement);return d&&0<d.getElementsByTagName("parsererror").length?null:d};Gn=function(a,b,c){this.j=new Uint8Array(a);this.a=b;this.f=c};Hn=function(){Gn.apply(this,arguments)};_.Jn=function(a){var b=_.yj(a);b=parseInt(b.byteLength,10).toString(16);b=_.yj("12"+b+a);return new Hn(In,a,b)};
|
|
142
|
+
_.Qn=function(a){function b(u){switch(u){case 0:do if(!_.Fm(d))throw Error("not enough data to skip!");while(_.Hm(d)&128);break;case 1:d.skip(8);break;case 2:d.skip(c());break;case 3:for(;4!==(u=c()&7);)b(u);break;case 5:d.skip(4);break;default:throw Error("invalid wire type "+u);}}function c(){for(var u=_.Hm(d),v=(u&127)>>>0,z=7;128<=u&&28>=z;)u=_.Hm(d),v=(v|(u&(28>z?127:15))<<z)>>>0,z+=7;return 28<z?-1:v}var d=new _.Em(new DataView(a.buffer,a.byteOffset,a.byteLength),!1);a=_.W(d);var e=_.W(d);e=
|
|
143
|
+
_.Um(e);var f=_.W(d),g=f>>>24;f&=16777215;var h=_.Mm(d,16);h=_.zj(h);if(0<g){var l=_.W(d);d.skip(16*l)}l=_.W(d);for(var m=[],n=null;_.Fm(d);){var p=c(),q=p&7;p>>>=3;if(2===q){q=c();if(0>q)throw Error("unable to read length of field "+p);q=Lm(d,q);2===p?m.push(q):4===p&&(n=q)}else b(q)}_.Hh("Parsed WV PSSH Box","size",a,"name",e,"version",g,"flags",f,"size",l,"systemId",h,"contentId (base64)",n?_.vj(n):"","keyIds",m.map(function(u){return _.zj(u)}));return 0<m.length?_.Jn(_.zj(m[0])):null};
|
|
144
|
+
_.Rn=function(a,b,c,d,e,f){f=void 0===f?null:f;Gn.call(this,a,b,d);this.version=e;this.h=c;this.l=f};
|
|
145
|
+
_.Wn=function(a){a:{var b=new _.Em(new DataView(a.buffer),!0);_.W(b);for(_.Im(b);_.Fm(b);)if(1===_.Im(b)){var c=_.Im(b);b=_.Mm(b,c);break a}b=null}b||(b=a);a=_.R.lc(b,!0);c=_.Fn(a,"WRMHEADER");a=c.getAttribute("version");var d=_.Dn(c,"DATA");c=(c=_.Dn(d,"LA_URL"))?_.En(c):"";var e;if(e=_.Dn(d,"KID"))if(e=_.En(e)){var f=_.Dn(d,qa);e={value:e,hf:f?f.textContent.trim():null}}else e=null;else e=null;d=e?[e]:(e=Sn(d))?[e]:(d=Tn(d))?d:null;e=d&&d[0]||{};d=e.hf;e=_.xj(void 0===e.value?"":e.value);e=_.Un(e);
|
|
146
|
+
e=_.zj(e);return new _.Rn(_.Vn,e,c,b,a,d)};_.Un=function(a){var b=[];b.push(a[3]);b.push(a[2]);b.push(a[1]);b.push(a[0]);b.push(a[5]);b.push(a[4]);b.push(a[7]);b.push(a[6]);a=_.lj(a);a.set(b,0);return a};Sn=function(a){a=_.Dn(a,"PROTECTINFO");if(!a)return null;var b=_.Dn(a,"KID");if(!b)return null;a=b.getAttribute("VALUE");if(!a)return null;var c=b.getAttribute(qa);b=b.getAttribute("ALGID");return{value:a,hf:c,Ci:b}};
|
|
147
|
+
Tn=function(a){a=_.Dn(a,"PROTECTINFO");if(!a)return null;a=_.Dn(a,"KIDS");if(!a)return null;var b=_.Cn(a,"KID");if(!b.length)return null;a=[];b=_.t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value;if(c=d.getAttribute("VALUE")){var e=d.getAttribute(qa);d=d.getAttribute("ALGID");a.push({value:c,hf:e,Ci:d})}}return a.length?a:null};_.Yn=function(a){Xn&&performance.mark(a)};_.Zn=function(a,b,c){Xn&&performance.measure(a,b,c)};
|
|
148
|
+
$n=function(a){this.f=[];this.h=[];this.a=[];8<=a.byteLength&&(new _.Pm).Y("pssh",this.j.bind(this)).parse(a.buffer);0===this.a.length&&_.J("No pssh box found!")};
|
|
149
|
+
_.eo=function(a){var b=this;this.C=a;this.J=new Set;this.B=this.I=this.o=null;this.$=!1;this.a=null;this.K=ao;this.A=new _.Sh;this.N=new qm;this.f=new Map;this.L=[];this.H=new _.Oj;this.h=null;this.U=function(c){b.w=!0;b.D=!1;b.H.reject(c);a.onError(c)};this.l=new Map;this.fa=new Map;this.ba=new _.Vk(function(){return bo(b)});this.j=!1;this.Ca=new _.Oj;this.G=!1;this.ea=[];this.Ka=!1;this.V=0;this.g=new _.K("clpp.drm.DrmEngine");this.ia=(new _.Vk(function(){co(b)})).kb(1);this.H["catch"](function(){});
|
|
150
|
+
this.w=this.D=!1;this.T=null};
|
|
151
|
+
go=function(a){var b,c,d,e,f;return _.E(function(g){switch(g.a){case 1:a.A.release();a.A=null;a.N.release();a.N=null;a.w=!1;a.D=!1;a.H.reject();a.ia.stop();a.ia=null;a.ba.stop();a.ba=null;b=Array.from(a.f.keys());c=_.t(a.f.values());for(d=c.next();!d.done;d=c.next())e=d.value,e.Qc&&e.Qc.stop();a.f.clear();return _.x(g,Promise.all(b.map(function(h){return Promise.resolve().then(function(){var l;return _.E(function(m){if(1==m.a)return a.g.debug("Closing session",h.sessionId),_.A(m,2),_.x(m,fo(h),4);
|
|
152
|
+
if(2!=m.a)return _.oh(m,0);l=_.C(m);a.g.warn("Error while closing session",l);_.y(m)})})})),2);case 2:if(!a.B){g.F(3);break}_.A(g,4);return _.x(g,a.o.qd(null),6);case 6:_.oh(g,5);break;case 4:f=_.C(g),a.g.warn("Error while resetting media keys",f);case 5:a.B=null;case 3:a.o=null,a.a=null,a.J.clear(),a.I=null,a.L=[],a.h=null,a.U=null,a.C=null,a.V=0,a.T=null,_.y(g)}})};
|
|
153
|
+
_.jo=function(a,b,c){c=void 0===c?[]:c;a.K=ho;a.L=c;a.G=0<c.length;a.g.debug("Using Persisted Licenses: "+a.G);a.h&&a.h.enableSessionCacheForSkd&&a.g.info("Enabled session cache for SKD license requests");return _.io(a,b)};
|
|
154
|
+
_.io=function(a,b){var c=b.some(function(g){return 0<g.drmInfos.length});if(!c){var d=_.O.mg(a.h.Za);ko(b,d)}var e=lo(a);if(e){var f=_.t(b);for(d=f.next();!d.done;d=f.next())d.value.drmInfos=[e]}e=_.t(b);for(d=e.next();!d.done;d=e.next())for(d=_.t(d.value.drmInfos),f=d.next();!f.done;f=d.next())mo(f.value,a.h.Za);d=no(a,b);if(!d.size)return a.$=!0,Promise.resolve();_.Yn(de);d=_.oo(a,d);return(c?d:d["catch"](function(){})).then(function(){_.Yn(ce);_.Zn("DRM queryMediaKeys_()",de,ce)})};
|
|
155
|
+
po=function(a){var b;return _.E(function(c){switch(c.a){case 1:if(a.o.te())return c["return"]();if(!a.T){c.F(2);break}return _.x(c,a.T,3);case 3:return c["return"]();case 2:return _.A(c,4),a.T=a.o.qd(a.I),_.x(c,a.T,6);case 6:_.oh(c,0);break;case 4:b=_.C(c);if(a.j)return c["return"]();a.U(new _.P(_.Q,6,6003,b.message,b));_.y(c)}})};
|
|
156
|
+
ro=function(a,b){return _.E(function(c){if(1==c.a)return a.g.info("Handle encrypted event for type "+b.initDataType),_.x(c,po(a),2);if(!b.initData)return c["return"]();_.qo(a,b.initDataType,_.lj(b.initData));_.y(c)})};
|
|
157
|
+
_.wo=function(a,b){if(!a.I)return _.Th(a.A,b,[oe,"msneedkey",Tg,"needkey"],function(){a.U(new _.P(_.Q,6,6010))}),Promise.resolve();a.B=b;a.o.ne(b);a.A.one(a.B,_.lf,function(){return so(a)});a.A.on(a.B,_.Og,function(e){var f=a.D;a.D=!a.w;!f&&a.D&&(a.g.info("Waiting for DRM license key delivery"),a.C.onEvent(e))});var c=a.a.initData.find(function(e){return 0<e.initData.length}),d=Promise.resolve();if(c||a.o.pd()!==Ub||a.L.length)d=po(a);c=Promise.resolve();_.Yj()&&38===Zk().major||(a.a&&a.a.keySystem!==
|
|
158
|
+
_.ef&&!a.a.serverCertificate&&(c=to(a)),c=c.then(function(){return _.uo(a)}));return Promise.all([d,c]).then(function(){a.j||(_.vo(a),a.A.on(a.B,oe,function(e){return ro(a,e)}))})["catch"](function(e){if(!a.j){if(6004===e.code&&a.a&&a.a.keySystem===_.Td&&1>a.V&&a.a.serverCertificate&&a.a.serverCertificate.length)return a.g.warn("Detected invalid widevine server certificate!. Retrying"),a.U(new _.P(1,6,6004)),a.a.serverCertificate=null,a.V++,_.wo(a,b);1<=a.V&&a.g.info("Could not get valid widevine server certificate. Giving up");
|
|
159
|
+
throw e;}})};_.uo=function(a){var b,c;return _.E(function(d){if(1==d.a){if(!(a.I&&a.a&&a.a.serverCertificate&&a.a.serverCertificate.length))return d.F(0);_.A(d,3);return _.x(d,a.I.setServerCertificate(a.a.serverCertificate),5)}if(3!=d.a)return b=d.f,void 0===b||b||a.g.debug("Server certificates are not supported by the key system. The server certificate has been ignored."),_.oh(d,0);c=_.C(d);throw new _.P(_.Q,6,6004,{browserError:c.message});})};
|
|
160
|
+
to=function(a){var b=a.keySystem(),c=a.h.Za[b],d=c.certificateUrl||"";if(""===d)return Promise.resolve();var e=a.C.getConfiguration();return xo(a,e).then(function(){var f=c.modifiers,g=f&&f.certificateRequest,h=f&&f.certificateResponse;f=_.Jj([d],a.h.attemptParameters);f.type=3;f.licenseRequestType=vd;g&&f.requestModifiers.push(function(l){return g(e,l)});h&&f.responseModifiers.push(function(l){return h(e,l)});a.g.debug("Fetching certificate");return a.C.tb.fetch(f).P}).then(function(f){a.a.serverCertificate=
|
|
161
|
+
_.lj(f.data)})["catch"](function(f){var g=f.data.headers;g=Object.assign({message:"Error while fetching certificate!",url:f.data.url,status:f.data.status,response:f.data.response},g?{headers:g}:{},xn(g));throw new _.P(_.Q,6,6100,g,f);})};xo=function(a,b){var c,d;return _.E(function(e){c=a.C.Vc();return c?(d=b&&b.drm&&b.drm.customData)?_.x(e,c(d),0):e["return"]():e["return"]()})};yo=function(a,b){if(!a)return!1;for(var c=0;c<b.qe.length;c++)if(_.Aj(a,b.qe[c]))return!0;return!1};
|
|
162
|
+
_.vo=function(a){for(var b=a.a?a.a.initData||[]:[],c=_.t(b),d=c.next();!d.done;d=c.next()){d=d.value;var e=!_.Vj(2);if(a.h.enforceSingleSession&&!a.keySystem().startsWith(_.Pd)){var f=a.f.values();f=_.t(f);for(var g=f.next();!g.done;g=f.next())g=g.value,_.Aj(d.initData,g.initData)?(a.g.info("Skipping Session creation. Existing init data in single session mode!"),e=!1):g.periodId===d.periodId&&(a.g.info("Skipping Session creation. Merging init data for period in single session mode for Key ID "+(d.keyId+
|
|
163
|
+
".")),yo(d.initData,g)||(g.qe.push(d.initData),d.keyId&&!g.ab.includes(d.keyId)&&g.ab.push(d.keyId),a.l.get(d.keyId)||a.l.set(d.keyId,fg)),e=!1)}!e||a.G&&a.K===ho||(_.zo(a,d.keyId,d.initData)&&(e=!1),e&&(a.g.info("Request new media key session on create"),Ao(a,d.keyId,d.periodId,d.initDataType,d.initData)))}c=_.t(a.L);for(d=c.next();!d.done;d=c.next())_.Bo(a,d.value);b.length||a.L.length||(a.w||a.g.info(Aa),a.w=!0,a.D=!1,a.H.resolve());return a.H};
|
|
164
|
+
_.qo=function(a,b,c,d){d=void 0===d?"":d;if(c.length&&(!a.G||a.K!==ho)){var e=a.keySystem();if(!e.startsWith(_.Pd)&&b===_.td){var f=new $n(c);if(1<f.a.length&&(e={"org.w3.clearkey":"1077efecc0b24d02ace33c1e52e2fb4b","com.widevine.alpha":"edef8ba979d64acea3c827dcd51d21ed","com.microsoft.playready":"9a04f07998404286ab92e65be0885f95","com.adobe.primetime":"f239e769efa348509c16a903c6932efb"}[e]))for(var g=0;g<f.f.length;g++)if(e===f.f[g]){c=c.subarray(f.a[g].start,f.a[g].end+1);break}}(a.B.webkitCurrentPlaybackTargetIsWireless||
|
|
165
|
+
_.Vj(2)||a.keySystem().startsWith(_.Pd)||!_.zo(a,d,c,!0))&&Ao(a,d,null,b,c)}};
|
|
166
|
+
_.zo=function(a,b,c,d){d=void 0===d?!1:d;for(var e=_.t(a.f.keys()),f=e.next();!f.done;f=e.next()){f=f.value;var g=a.f.get(f);if(_.Aj(c,g.initData))return b?g.ab.includes(b)?d&&a.g.info("Skipping Session creation. License for init data with Key ID "+(b+" was already requested in Session: '")+(f.sessionId+"'. ")):(g.ab.push(b),a.l.get(b)||a.l.set(b,fg),d&&a.g.info(bc+(f.sessionId+"'Adding Key ID ")+(b+" to session meta-data."))):d&&a.g.info(bc+(f.sessionId+"'")),!0;if(yo(c,g))return d&&a.g.info("Skipping Session creation. License for init data was already requested [extra]"),
|
|
167
|
+
!0}return!1};Co=function(a){var b=Infinity;a=a.f.keys();a=_.t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,isNaN(c.expiration)||(b=Math.min(b,c.expiration));return b};
|
|
168
|
+
no=function(a,b){for(var c=new Set,d=_.t(b),e=d.next();!e.done;e=d.next()){var f=_.t(e.value.drmInfos);for(e=f.next();!e.done;e=f.next())e=e.value,mo(e,a.h.Za),c.add(e)}f=a.G?_.Qf:_.df;var g=a.G?[_.jf]:[mg];d=new Map;c=_.t(c);for(e=c.next();!e.done;e=c.next())e=e.value,d.set(e.keySystem,{initDataTypes:[_.td],audioCapabilities:[],videoCapabilities:[],distinctiveIdentifier:_.df,persistentState:f,sessionTypes:g,label:e.keySystem,drmInfos:[]});c={};f=_.t(b);for(e=f.next();!e.done;c={Qe:c.Qe,hd:c.hd,af:c.af,
|
|
169
|
+
jd:c.jd},e=f.next()){e=e.value;g=e.audio;var h=e.video;c.Qe=g?_.Do(g):"";c.hd=null;g&&"ac-3"===g.codecs.toLowerCase()&&_.Vj()&&(c.hd=_.Do(g,_.ne));c.af=h?_.Do(h):"";c.jd=null;h&&"ac-3"===h.codecs.toLowerCase()&&_.Vj()&&(c.jd=_.Do(h,_.ne));var l={},m=_.t(e.drmInfos);for(e=m.next();!e.done;l={Va:l.Va},e=m.next())e=e.value,l.Va=d.get(e.keySystem),l.Va.drmInfos.push(e),e.initData&&e.initData.length&&(l.Va.initDataTypes=_.ah(new Set(e.initData.map(function(n){return n.initDataType}))).concat()),e.distinctiveIdentifierRequired&&
|
|
170
|
+
(l.Va.distinctiveIdentifier=_.Qf),e.persistentStateRequired&&(l.Va.persistentState=_.Qf),g&&_.gi(e.audioRobustness).forEach(function(n,p){return function(q){var u={robustness:q||"",contentType:n.Qe};p.Va.audioCapabilities.find(function(v){return v.robustness===u.robustness&&v.contentType===u.contentType})||p.Va.audioCapabilities.push(u);n.hd&&p.Va.audioCapabilities.push({robustness:q||"",contentType:n.hd})}}(c,l)),h&&_.gi(e.videoRobustness).forEach(function(n,p){return function(q){var u={robustness:q||
|
|
171
|
+
"",contentType:n.af};p.Va.videoCapabilities.find(function(v){return v.robustness===u.robustness&&v.contentType===u.contentType})||p.Va.videoCapabilities.push(u);n.jd&&p.Va.videoCapabilities.push({robustness:q||"",contentType:n.jd})}}(c,l))}return d};_.Do=function(a,b){var c=_.Rk(a.mimeType,b||a.codecs);if(_.Qk(c,a.type)){var d=a.type,e=_.Qk(c,d);e&&(e=e(),c=e.convertCodecs(d,c),e.destroy())}return c};
|
|
172
|
+
_.oo=function(a,b){function c(m,n,p){n.drmInfos.some(function(q){return!!q.licenseServerUri})===m&&(f=f["catch"](function(){if(a.j)return null;if(p===_.Rd){if(_.Xk()&&!a.h.Za[p].useLegacySystem)return n.label=Sd,a.o.ic(Sd,[n])["catch"](function(){a.g.warn("Unable to create com.microsoft.playready.recommendation. Falling back to com.microsoft.playready.");n.label=_.Rd;Eo(n);return a.o.ic(p,[n])});Eo(n)}return a.o.ic(p,[n])["catch"](function(q){a:{if(p===_.Td&&Fo(n)){var u=_.Zj();if(Fo(n)&&u.os===pl&&
|
|
173
|
+
u.browser===xd){a.g.warn("requestMediaKeySystemAccess() failed",q);a.g.warn("Will try to recover by removing the robustness attribute of videoCapabilities and audioCapabilities.");Eo(n);q=a.o.ic(p,[n]);break a}}throw q;}return q})}))}if(1===b.size&&b.has(""))return Promise.reject(new _.P(_.Q,6,6E3));null===a.o&&(a.o=Bn(a.h.emeApi));for(var d=_.t(b.values()),e=d.next();!e.done;e=d.next())e=e.value,0===e.audioCapabilities.length&&delete e.audioCapabilities,0===e.videoCapabilities.length&&delete e.videoCapabilities;
|
|
174
|
+
var f=d=new _.Oj,g=a.h.preferredDrmSystem;if(!g)if(e=_.Zj(),e.os===rl&&10<=e.osVersion.major&&"edge"===e.browser)g=_.Rd;else if("safari"===e.browser)g=_.Pd;else if(e.browser===xd||"firefox"===e.browser)g=_.Td;g&&(e=b.get(g))&&(c(!0,e,g),c(!1,e,g));e={};for(var h=_.t([!0,!1]),l=h.next();!l.done;e={Ye:e.Ye},l=h.next())e.Ye=l.value,b.forEach(function(m){return function(n,p){p!==g&&c(m.Ye,n,p)}}(e));f=f["catch"](function(m){throw new _.P(_.Q,6,6001,null,m);});f=f.then(function(m){if(a.j)return null;a.J.clear();
|
|
175
|
+
var n=m.getConfiguration();a.g.info("Got MediaKeySystemAccess with configuration",n);var p=n.videoCapabilities||[],q=_.t(n.audioCapabilities||[]);for(n=q.next();!n.done;n=q.next())a.J.add(n.value.contentType.toLowerCase());p=_.t(p);for(n=p.next();!n.done;n=p.next())a.J.add(n.value.contentType.toLowerCase());p=m.keySystem;n=b.get(_.Go(m.keySystem));q=[];var u=[],v=[],z=[];Ho(n.drmInfos,q,u,v,z);1<u.length&&_.J("Multiple unique server certificates found! Only the first will be used.");1<q.length&&_.J("Multiple unique license server URIs found! Only the first will be used.");
|
|
176
|
+
a.a={keySystem:p,licenseServerUri:q[0],distinctiveIdentifierRequired:n.distinctiveIdentifier===_.Qf,persistentStateRequired:n.persistentState===_.Qf,audioRobustness:n.audioCapabilities?n.audioCapabilities[0].robustness:"",videoRobustness:n.videoCapabilities?n.videoCapabilities[0].robustness:"",serverCertificate:u[0],initData:v,keyIds:z,periodId:null};if(!a.a.licenseServerUri)throw new _.P(_.Q,6,6012,a.a.keySystem);return m.createMediaKeys()}).then(function(m){a.j||(a.g.info("Created MediaKeys for key system",
|
|
177
|
+
a.a.keySystem),a.I=m,a.$=!0)})["catch"](function(m){if(!a.j){a.a=null;a.J.clear();if(m instanceof _.P)throw m;throw new _.P(_.Q,6,6002,{browserError:m.message});}});d.reject();return f};
|
|
178
|
+
lo=function(a){a=_.O.mg(a.h.Za[_.ef]||{});if(0===a.size)return null;var b=[],c=[];a.forEach(function(e,f){var g=_.yj(f),h=_.yj(e);g={kty:"oct",kid:_.wj(g,!1),k:_.wj(h,!1)};b.push(g);c.push(g.kid)});a=JSON.stringify({keys:b});var d=JSON.stringify({kids:c});d=[{initData:_.R.Ua(d),initDataType:"keyids"}];return{keySystem:_.ef,licenseServerUri:"data:application/json;base64,"+window.btoa(a),distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,
|
|
175
179
|
initData:d,keyIds:[],periodId:null}};
|
|
176
|
-
_.
|
|
177
|
-
b,f);if(!f)return a.f["delete"](c),a.U(new _.P(_.Q,6,6013)),null;e.loaded=!0;
|
|
178
|
-
|
|
179
|
-
initData:e}),a.h.ignoreUnrecognizedInitData)return
|
|
180
|
-
break;case 4:if(l)return a.g.warn("Skip creating a new session for "+h),
|
|
181
|
-
|
|
182
|
-
drmSystemConfig:
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
_.
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
a.h.attemptParameters);h.type=3;h.body=b.message;h.method="POST";h.licenseRequestType=b.messageType===
|
|
190
|
-
var p=Date.now()-m,q=
|
|
191
|
-
expirationTime:z,expectedRenewalTime:
|
|
192
|
-
a.
|
|
193
|
-
d.
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
_.
|
|
198
|
-
_.
|
|
199
|
-
distinctiveIdentifierRequired:g.distinctiveIdentifierRequired||f.distinctiveIdentifierRequired,persistentStateRequired:g.persistentStateRequired||f.persistentStateRequired,videoRobustness:g.videoRobustness||f.videoRobustness,audioRobustness:g.audioRobustness||f.audioRobustness,serverCertificate:g.serverCertificate||f.serverCertificate,initData:h,keyIds:e.
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
d.some(function(m){return function(n){var p=m.
|
|
205
|
-
|
|
206
|
-
d.serverCertificate||null)))}};
|
|
207
|
-
_.
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
f+", Current state: "+
|
|
216
|
-
|
|
217
|
-
a.a.on(c,_.
|
|
218
|
-
_.
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
b.url,uri:b.url},d.error))})).
|
|
228
|
-
return new _.
|
|
229
|
-
|
|
230
|
-
_.
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
b
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
_.
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
b
|
|
295
|
-
|
|
180
|
+
_.Bo=function(a,b){try{a.g.debug("Attempting to load an offline session",b);var c=a.I.createSession(_.jf)}catch(f){var d=new _.P(_.Q,6,6005,{browserError:f.message});a.U(d);return Promise.reject(d)}a.A.on(c,_.Pe,a.Nh.bind(a));a.A.on(c,Be,a.Ih.bind(a));var e={initData:null,loaded:!1,Ff:Infinity,vb:null,Ia:new _.Oj,periodId:null,qe:[],keyId:null,ab:[],initDataType:null,jc:null,sessionContext:{ldlDelay:0,customData:{}}};e.Ia["catch"](function(){});a.f.set(c,e);return c.load(b).then(function(f){if(a.j)return null;a.g.debug("Loaded offline session",
|
|
181
|
+
b,f);if(!f)return a.f["delete"](c),a.U(new _.P(_.Q,6,6013)),null;e.loaded=!0;Io(a)&&(a.w||a.g.info(Aa),a.w=!0,a.D=!1,a.H.resolve());return c},function(f){a.j||(a.f["delete"](c),a.U(new _.P(_.Q,6,6005,{browserError:f.message})))})};Jo=function(a,b,c,d){if(!b&&c!==_.bg)return!1;d=b||Zm(d);a=_.t(a.f.values());for(var e=a.next();!e.done;e=a.next())if(e=e.value,b&&e.keyId===b||b&&e.ab.includes(b)||c===_.bg&&(e.keyId||Zm(e.initData))===d)return!0;return!1};
|
|
182
|
+
Ao=function(a,b,c,d,e,f,g){f=void 0===f?null:f;g=void 0===g?!1:g;var h,l,m,n,p,q,u,v,z,B,I,F,D,G,M,N,S,oa,Ba,$a,ab;_.E(function(Pa){switch(Pa.a){case 1:if(!e.length)return a.g.warn("Empty init data"),Pa["return"]();h=b;if(!h)try{h=Ko(a,d,e,f)}catch(Ca){if(a.g.warn("Ignoring unrecognized init data. This may be caused by unsupported or malformed init data. Set `drm.ignoreUnrecognizedInitData \x3d false` if you want to override this behavior and use the init data after all.",{error:Ca,initDataType:d,
|
|
183
|
+
initData:e}),a.h.ignoreUnrecognizedInitData)return Pa["return"]()}if(g){Pa.F(2);break}if(!Jo(a,h,d,e)){Pa.F(2);break}l=!0;if("skd"!==d||a.h.enableSessionCacheForSkd){Pa.F(4);break}m=_.t(a.f.keys());n=m.next();case 5:if(n.done){Pa.F(4);break}p=n.value;q=a.f.get(p);if(!h||q.keyId!==h){Pa.F(6);break}a.g.warn("Close and re-open session for "+h);_.A(Pa,9);return _.x(Pa,p.close(),11);case 11:_.oh(Pa,10);break;case 9:u=_.C(Pa),a.g.warn("Unable to close session",u);case 10:l=!1;case 6:n=m.next();Pa.F(5);
|
|
184
|
+
break;case 4:if(l)return a.g.warn("Skip creating a new session for "+h),Pa["return"]();case 2:try{z=a.G?_.jf:mg,v=a.I.createSession(z),a.g.info("Created new "+z+" session for Key ID: '"+h+"'. Init data type: "+(d+"."))}catch(Ca){return a.U(new _.P(_.Q,6,6005,{browserError:Ca.message})),Pa["return"]()}a.A.on(v,_.Pe,a.Nh.bind(a));a.A.on(v,Be,a.Ih.bind(a));B={jc:f,qe:[],initData:e,initDataType:d,keyId:h,ab:h?[h]:[],loaded:!1,Ff:Infinity,periodId:c,vb:null,Ia:new _.Oj,sessionContext:{ldlDelay:0,customData:{}}};
|
|
185
|
+
B.Ia["catch"](function(){});f&&(I=a.f.get(f),B.sessionContext=I.sessionContext);a.f.set(v,B);h&&!a.l.get(h)&&a.l.set(h,fg);if(e)for(F=0;F<a.a.initData.length;F++)D=a.a.initData[F],D.keyId&&!B.ab.includes(D.keyId)&&_.Aj(D.initData,e)&&(B.keyId||(B.keyId=D.keyId),B.ab.push(D.keyId),a.l.get(D.keyId)||a.l.set(D.keyId,fg));G=_.O;M=G.sb;N=a.C.getConfiguration();S=a.keySystem();oa=a.h.Za[S];$a=(Ba=oa.modifiers)&&Ba.transformInitData;M($a)||($a=Lo);try{e=$a({playerConfig:N,initData:e,initDataType:d,drmInfo:a.a,
|
|
186
|
+
drmSystemConfig:oa,sessionContext:B.sessionContext,emeApi:a.o.pd()})}catch(Ca){return ab=Ca,Ca instanceof _.P||(ab=new _.P(_.Q,6,6016,Ca)),B.Ia&&B.Ia.reject(Ca),a.U(ab),Pa["return"]()}a.g.info("Generate License Request for key ID: '"+h+"'");v.generateRequest(d,e.buffer)["catch"](function(Ca){if(!a.j){var db=null;Ca.errorCode&&Ca.errorCode.systemCode&&(db=Ca.errorCode.systemCode,0>db&&(db+=Math.pow(2,32)),db="0x"+db.toString(16));a.U(new _.P(_.Q,6,6006,{browserError:Ca.message,error:Ca,extended:db},
|
|
187
|
+
Ca))}});_.y(Pa)}})};
|
|
188
|
+
Ko=function(a,b,c,d){d=void 0===d?null:d;if("skd"===b){a:{var e=d;e=void 0===e?null:e;var f=a.keySystem(),g=a.h.Za[f];f=a.C.getConfiguration();g=g&&g.modifiers&&g.modifiers.extractContentId;_.O.sb(g)||(g=Mo);try{var h={ldlDelay:0,customData:{}};e&&(h=a.f.get(e).sessionContext);var l=g(f,c,h);a.g.debug("Extracted Content ID '"+l+"' from SKD");var m=l;break a}catch(F){a.g.warn("Unable to extract Content ID from SKD",F)}m=""}return m}if(b===_.bg)return Zm(c)||"";if(b===_.td){m=a.keySystem();try{if(m.match(/^com\.widevine\.alpha/)){var n=
|
|
189
|
+
_.Qn(c);if(n)return n.a}else if(No(m)){e=new _.Em(new DataView(c.buffer,c.byteOffset,c.byteLength),!1);f=_.W(e);var p=_.W(e);g=_.Um(p);var q=_.W(e);c=q>>>24;l=q&16777215;h=_.Mm(e,16);var u=_.zj(h);if(0<c){var v=_.W(e);e.skip(16*v)}var z=_.W(e),B=_.Mm(e,z),I=_.Wn(B);_.Hh("Parsed PR PSSH Box","size",f,"name",g,"version",c,"flags",l,"size",z,"systemId",u,"keyId",I.a);if(I)return I.a}}catch(F){throw a.g.warn("Unable to extract Key ID from PSSH data.",{error:F,keySystem:m}),F;}}return""};
|
|
190
|
+
Mo=function(a,b){var c=_.Ym(b);_.Hh("Using default Content ID extractor. The hostname part from HLS #EXT-X-KEY:URI skd:// will be used.","Extracted Content ID: "+c);return c};
|
|
191
|
+
Lo=function(a){var b=a.playerConfig,c=a.initData,d=a.drmInfo,e=a.drmSystemConfig,f=a.sessionContext,g=a.emeApi;if("skd"===a.initDataType&&"APPLE"===g){a=_.O.sb;d=d.serverCertificate;e=e&&e.modifiers&&e.modifiers.extractContentId;a(e)||(e=Mo);a="";try{a=e(b,c,f)}catch(h){throw new _.P(_.Q,6,6103);}if(!a.length)throw new _.P(_.Q,6,6101,"Content ID is an empty string");c=$m(c,a,d)}return c};
|
|
192
|
+
Ro=function(a,b){var c=b.target,d=a.f.get(c),e=a.keySystem(),f=!1;e.match(/^com\.widevine\.alpha/)&&b.message&&2===b.message.byteLength?(f=!0,a.g.info("WV Server certificate request for SID:'"+(c.sessionId+" from msg '")+(b.messageType+"'"))):a.g.info("License request for SID:'"+(c.sessionId+"'/KID:'"+d.keyId+"' from msg '")+(b.messageType+"'"));var g=a.a.licenseServerUri;e=a.h.Za[e];"individualization-request"===b.messageType&&e&&e.individualizationServer&&(g=e.individualizationServer);var h=_.Jj([g],
|
|
193
|
+
a.h.attemptParameters);h.type=3;h.body=b.message;h.method="POST";h.licenseRequestType=b.messageType===Fe&&d.jc?De:f?vd:b.messageType;h.sessionId=c.sessionId;if(h.licenseRequestType===De)a.C.onEvent(new _.L(ie));No(a.a.keySystem)&&Oo(a,h);rm(a.N,h);var l=Math.floor(b.timeStamp),m=Date.now();return Po(a,h,d.sessionContext).then(function(){_.Yn(be+l+ha);a.g.debug("Sending DRM license request to",g,h);return a.C.tb.fetch(h).P}).then(function(n){_.Yn(be+l+".end");_.Zn(be+l,be+l+ha,be+l+".end");if(a.j)return Promise.reject();
|
|
194
|
+
var p=Date.now()-m,q=Qo(a,n),u="";q&&(u=" RID:"+q);q=n&&n.data?n.data.byteLength:-1;f?a.g.info("WV Server certificate response for SID:'"+(c.sessionId+"' ")+(q+" bytes in ")+(p+"ms"+u)):a.g.info("License response for SID:'"+(c.sessionId+"'/KID:'")+(d.keyId+"' ")+(q+" bytes in ")+(p+"ms"+u));var v=sm(a.N,n);_.Yn(ge+l+ha);return c.update(n.data).then(function(){_.Yn(ge+l+".end");_.Zn(ge+l,ge+l+ha,ge+l+".end");if(!f){var z=Co(a),B=v?Date.now()+1E3*v.delay:Number.NaN;z=new _.L(_.ke,{keySystem:a.keySystem(),
|
|
195
|
+
expirationTime:z,expectedRenewalTime:B});a.C.onEvent(z);d&&(d.vb&&d.vb.resolve(),d.jc&&(z=d.jc,a.g.info("Closing expired session '"+z.sessionId+"'"),fo(z)["catch"](function(){a.g.warn("Unable to close expired session in time")}),(z=a.f.get(d.jc))&&z.Qc&&z.Qc.stop(),a.f["delete"](d.jc),d.jc=null),(new _.Vk(function(){a.j||(d.loaded=!0,d.Ia&&d.Ia.resolve(),Io(a)&&(a.w||a.g.info(Aa),a.w=!0,a.D=!1,a.H.resolve()))})).da(5),null!==d.initData&&(0<d.sessionContext.ldlDelay||v&&tm(a.keySystem()))&&(z=new _.Vk(function(){!a.j&&
|
|
196
|
+
a.N&&(a.g.info("Updating CSL Sessions"),No(a.keySystem())?Ao(a,d.keyId,d.periodId,d.initDataType,d.initData,c,!0):a.keySystem().startsWith(_.Pd)&&c.update(_.R.Ua("renew")))}),d.Qc=z,z.da(v?v.delay:d.sessionContext.ldlDelay)))}})},function(n){var p,q,u,v;return _.E(function(z){if(a.j)return z["return"]();p=n.data.headers;q=xn(p);u=Object.assign({message:_.Za,url:n.data.url,status:n.data.status,response:n.data.response},p?{headers:p}:{},q);v=new _.P(_.Q,6,6007,u,n);a.U(v);d&&d.vb&&d.vb.reject(v);d&&
|
|
197
|
+
d.Ia&&d.Ia.reject(v);_.y(z)})})["catch"](function(n){a.j||(n===Yb?a.g.info("Ignore update for closed sessions"):(n=new _.P(_.Q,6,6008,{browserError:n.message}),a.U(n),d&&d.vb&&d.vb.reject(n),d&&d.Ia&&d.Ia.reject(n)))})};Qo=function(a,b){if(!b||!b.headers)return"";var c=b.headers["x-dt-li"];if(c)try{return JSON.parse(_.R.aa(_.xj(c))).ti}catch(d){a.g.warn("Unable to parse DRMtoday Request ID",d)}return""};
|
|
198
|
+
Oo=function(a,b){var c=_.R.lc(b.body,!0,!0);if(c.includes("PlayReadyKeyMessage")){a.g.debug("Unwrapping PlayReady request.");c=(new DOMParser).parseFromString(c,"application/xml");for(var d=c.getElementsByTagName("HttpHeader"),e=0;e<d.length;++e)b.headers[d[e].querySelector("name").textContent]=d[e].querySelector(_.Cg).textContent;b.body=_.xj(c.querySelector("Challenge").textContent).buffer}else a.g.debug("PlayReady request is already unwrapped."),b.headers[xa]="text/xml; charset\x3dutf-8"};
|
|
199
|
+
Po=function(a,b,c){var d,e,f,g,h,l;return _.E(function(m){if(1==m.a)return d=a.C.getConfiguration(),_.x(m,xo(a,d),2);e=a.keySystem();h=(g=(f=a.h.Za[e])&&f.modifiers)&&g.licenseRequest;l=g&&g.licenseResponse;h?b.requestModifiers.push(function(n){return h(d,n,c)}):e.startsWith(_.Pd)&&b.requestModifiers.push(function(n){return _.an(n)});l?b.responseModifiers.push(function(n){return l(d,n,c)}):e.startsWith(_.Pd)&&b.responseModifiers.push(function(n){return _.bn(n)});_.y(m)})};
|
|
200
|
+
bo=function(a){var b=a.l,c=a.fa;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.U(new _.P(_.Q,6,6014));a.C.Kf(_.O.ng(c));a.w||a.g.info(Aa);a.w=!0;a.D=!1};so=function(a){var b;return _.E(function(c){if(1==c.a)return _.Yn(fe),b=a.ea.map(function(d){return Ro(a,d)}),a.Ka=!0,a.ea=[],_.x(c,Promise.all(b),2);_.Yn(ee);_.Zn("drm.onPlay",fe,ee);_.y(c)})};No=function(a){return!!a.match(/^com\.(microsoft|chromecast)\.playready/)};
|
|
201
|
+
_.Go=function(a){return No(a)?_.Rd:a};_.To=function(a,b){return a.length&&b.length?0<_.So(a,b).length:!0};
|
|
202
|
+
_.So=function(a,b){if(!a.length)return b;if(!b.length)return a;for(var c=[],d=0;d<a.length;d++)for(var e={},f=0;f<b.length;e={kd:e.kd},f++)if(a[d].keySystem===b[f].keySystem&&a[d].periodId===b[f].periodId){var g=a[d];f=b[f];var h=[];h=h.concat(g.initData||[]);h=h.concat(f.initData||[]);e.kd=_.ah(g.keyIds||[]).concat();f.keyIds&&f.keyIds.length&&f.keyIds.forEach(function(l){return function(m){l.kd.includes(m)||l.kd.push(m)}}(e));c.push({keySystem:g.keySystem,licenseServerUri:g.licenseServerUri||f.licenseServerUri,
|
|
203
|
+
distinctiveIdentifierRequired:g.distinctiveIdentifierRequired||f.distinctiveIdentifierRequired,persistentStateRequired:g.persistentStateRequired||f.persistentStateRequired,videoRobustness:g.videoRobustness||f.videoRobustness,audioRobustness:g.audioRobustness||f.audioRobustness,serverCertificate:g.serverCertificate||f.serverCertificate,initData:h,keyIds:e.kd,periodId:g.periodId});break}return c};
|
|
204
|
+
co=function(a){a.f.forEach(function(b,c){var d=b.Ff,e=c.expiration;isNaN(e)&&(e=Infinity);e!==d&&(a.C.Jf(c.sessionId,e),b.Ff=e)})};Io=function(a){a=a.f.values();return _.ij(a,function(b){return b.loaded})};
|
|
205
|
+
ko=function(a,b){var c=[];b.forEach(function(f,g){c.push({keySystem:g,licenseServerUri:f.licenseUrl,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,initData:[],keyIds:[]})});for(var d=_.t(a),e=d.next();!e.done;e=d.next())e.value.drmInfos=c};Eo=function(a){for(var b=_.t(a.audioCapabilities||[]),c=b.next();!c.done;c=b.next())delete c.value.robustness;a=_.t(a.videoCapabilities||[]);for(b=a.next();!b.done;b=a.next())delete b.value.robustness};
|
|
206
|
+
Fo=function(a){return(a.audioCapabilities||[]).some(Uo)||(a.videoCapabilities||[]).some(Uo)};Uo=function(a){return null!=a.robustness&&""!==a.robustness};
|
|
207
|
+
Ho=function(a,b,c,d,e){var f={};a=_.t(a);for(var g=a.next();!g.done;f={ya:f.ya},g=a.next()){f.ya=g.value;b.includes(f.ya.licenseServerUri)||b.push(f.ya.licenseServerUri);f.ya.serverCertificate&&(c.some(function(m){return function(n){return _.Aj(n,m.ya.serverCertificate)}}(f))||c.push(f.ya.serverCertificate));if(f.ya.initData){var h=_.t(f.ya.initData);for(g=h.next();!g.done;g=h.next())g.value.periodId=f.ya.periodId;h={};var l=_.t(f.ya.initData);for(g=l.next();!g.done;h={be:h.be},g=l.next())h.be=g.value,
|
|
208
|
+
d.some(function(m){return function(n){var p=m.be;return n.keyId&&n.keyId===p.keyId&&n.periodId===p.periodId?!0:!1}}(h))||d.push(h.be)}if(f.ya.keyIds)for(g=0;g<f.ya.keyIds.length;++g)e.includes(f.ya.keyIds[g])||e.push(f.ya.keyIds[g])}};
|
|
209
|
+
mo=function(a,b){if(a.keySystem){var c=_.Go(a.keySystem),d=b[c];c===_.ef&&a.licenseServerUri||(d&&(a.licenseServerUri=d.licenseUrl||""),a.keyIds||(a.keyIds=[]),d&&(a.distinctiveIdentifierRequired||(a.distinctiveIdentifierRequired=d.distinctiveIdentifierRequired),a.persistentStateRequired||(a.persistentStateRequired=d.persistentStateRequired),a.videoRobustness||(a.videoRobustness=d.videoRobustness||""),a.audioRobustness||(a.audioRobustness=d.audioRobustness||""),a.serverCertificate||(a.serverCertificate=
|
|
210
|
+
d.serverCertificate||null)))}};fo=function(a){var b,c;return _.E(function(d){if(1==d.a)return b=new Promise(function(e){(new _.Vk(e)).da(1)}),_.x(d,Promise.race([a.close().then(function(){return!0}),b.then(function(){return!1})]),2);(c=d.f)||_.J("Timeout waiting for session close");_.y(d)})};_.Xo=function(a,b){a&&b&&(_.Vo.set(a,b),_.Wo.info("Registered TextDisplayerFactory: '"+a+"'"))};
|
|
211
|
+
_.Yo=function(a,b){var c=b.find(function(d){return(d=_.Vo.get(d))?d.isSupported(a):!1});if(null==c)return _.Wo.warn("Subtitles may not work as expected. No compatible text displayer found for this platform."),null;_.Wo.info("Chosen the text displayer: "+c);return _.Vo.get(c)};Zo=function(){this.a=null;this.f=[]};
|
|
212
|
+
_.$o=function(a,b){if(null==a.a)a.a={timestamp:Date.now()/1E3,state:b,duration:0};else{var c=Date.now()/1E3;a.a.duration=c-a.a.timestamp;a.a.state!==b&&(a.f.push(a.a),a.a={timestamp:c,state:b,duration:0})}};ap=function(a,b){var c=0;a.a&&a.a.state===b&&(c+=a.a.duration);for(var d=_.t(a.f),e=d.next();!e.done;e=d.next())e=e.value,c+=e.state===b?e.duration:0;return c};
|
|
213
|
+
bp=function(a){function b(f){return{timestamp:f.timestamp,state:f.state,duration:f.duration}}for(var c=[],d=_.t(a.f),e=d.next();!e.done;e=d.next())c.push(b(e.value));a.a&&c.push(b(a.a));return c};cp=function(){this.h=this.f=this.j=null;this.a=[]};dp=function(a){return a.a.map(function(b){return _.O.Ma(b)})};_.ep=function(){this.f=this.o=this.A=this.D=this.j=this.l=this.h=this.w=NaN;this.a=new Zo;this.B=new cp};
|
|
214
|
+
_.fp=function(){return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,estimatedBandwidth:NaN,loadLatency:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,switchHistory:[],stateHistory:[]}};_.gp=function(a){this.f=a;this.a=void 0};ip=function(a,b,c,d){b===HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=hp.value().get(b),c.one(a,b,d))};
|
|
215
|
+
mp=function(a){this.g=new _.K("clpp.StateManager");this.m=a;this.a=new _.Sh;this.f=_.jp;this.A=_.kp;this.I=0;this.w=-1;this.L=this.o=this.J=this.B=0;this.j=this.h=this.G=!1;this.H=0;this.l=null;this.K=0;this.N=_.bl();this.D=!1;this.J=Date.now();lp(this)};np=function(a,b){return Object.keys(b)[a]};
|
|
216
|
+
pp=function(a,b){var c={type:_.eg};b===_.md||b===_.ld?(c.reason=a.w,b===_.md?c.timeSinceLastStateChangeMS=a.I:c.bufferedTimeMS=a.B):(a.f===_.op&&(c.reason=a.w),a.A===_.op&&(c.reason=a.w,c.bufferedTimeMS=a.B),c.currentState=a.f,c.previousState=a.A,c.timeSinceLastStateChangeMS=a.I);return c};
|
|
217
|
+
tp=function(a,b){if(a.f===b)return!1;var c=Date.now(),d=a.f===_.op;a.A=a.f;a.f=b;a.A===_.qp&&(a.J=c,a.o=0);a.o||(a.o=a.J||c);a.I=c-a.o;a.o=c;b===_.op?(a.L=a.o,a.w=a.h?1:2,a.g.info("Buffering started. Reason: "+np(a.w-1,_.rp)),c=pp(a,_.md),a.dc(_.md,c)):d&&(a.B=a.o-a.L,a.g.info("Buffering finished. Reason: "+np(a.w-1,_.rp)+". Buffering time: "+a.B+" ms"),c=pp(a,_.ld),a.dc(_.ld,c));c=np(a.A,_.sp);d=np(a.f,_.sp);a.g.info(_.Nb+c+" -\x3e "+d);a.dc(_.eg,pp(a,""));return!0};
|
|
218
|
+
yp=function(a,b){if(a.f===_.up)a.g.warn("Player is in error state, aborting any further state checks");else{var c=a.m.isPaused(),d=a.m?a.m.isEnded():!1;if(d)a.h||(a.j=!1,tp(a,_.qp));else if(b!==_.rg){var e=a.m.getPosition();e=null!==e&&void 0!==e&&0<=e?a.m.getBufferInfo().La(e,!0):-1;a.H=e;e=a.m.getSurface().getMedia();a.l=e?e.readyState:null;a.K=a.m.getPlaybackRate()||1;e=typeof a.l===_.k&&2>a.l&&2===e.networkState;var f=typeof a.l===_.k&&0>=a.H&&a.f===_.jp,g=typeof a.l===_.k&&2>=a.l&&a.j;e=a.h||
|
|
219
|
+
f||e||g;!a.N||a.m.isLive()||a.f!==_.op||e||(f=b===_.Xf&&4===a.l,(g=a.A===_.vp)&&!a.D?e=!0:g||a.D||f||(e=!0));f=!1;e?f=tp(a,_.op):c?f=tp(a,_.wp):a.G&&(f=tp(a,_.xp));f&&(a.D=!1);a.g.debug("Video state check for event "+b+":: seeking: "+a.h+", waiting: "+a.j+", playing: "+a.G+", paused: "+c+", readyState: "+a.l+", rate: "+a.K+", buffer: "+a.H+", ended: "+d+". Changed state: "+f+", Current state: "+np(a.f,_.sp))}}};
|
|
220
|
+
lp=function(a){function b(d){return yp(a,d.type)}a.g.debug("Start watching for video events for "+a.m.namespace());var c=a.m;a.a.on(c,_.qe,function(){a.h||(a.j=!1,tp(a,_.qp))});a.a.on(c,nd,b);a.a.on(c,_.zf,function(){a.G=!0;a.j=!1;yp(a,_.zf)});a.a.on(c,_.gf,function(){a.G=!1;a.j=!1;yp(a,_.gf)});a.a.on(c,_.rg,b);a.a.on(c,_.Mf,b);a.a.on(c,_.Xf,function(d){a.h=!1;a.j=!1;yp(a,d.type)});a.a.on(c,_.Yf,function(d){a.h=!0;yp(a,d.type)});a.a.on(c,cg,b);a.a.on(c,_.Ng,function(){a.j=!0;yp(a,_.Ng)});a.a.on(c,
|
|
221
|
+
_.re,function(d){return a.U(d)});a.a.on(c,_.Ke,b);a.a.on(c,od,function(){a.D=!0;yp(a,od)});a.a.on(c,_.Bg,function(d){a.h=!0;yp(a,d.type)});a.a.on(c,_.Ag,function(d){a.h=!1;a.j=!1;yp(a,d.type)})};zp=function(a){a=(new _.Ei(a)).za;if(!a)return null;a=a.toUpperCase();return _.R.endsWith(a,".MPD")?_.Uc:_.R.endsWith(a,".M3U8")?_.El:_.R.endsWith(a,".MP4")?_.Hg:_.R.endsWith(a,"MANIFEST")||_.R.endsWith(a,".ISM")?_.$c:null};
|
|
222
|
+
_.Bp=function(a){var b;cm(a)?b=a.source:b=a;Array.isArray(b)||(b=[b]);b=b.filter(function(e){return typeof e===_.hg||"url"in e});a=[];for(var c=0;c<b.length;c++){var d=Ap(b[c]);d&&a.push(d)}return a};
|
|
223
|
+
Ap=function(a){var b=null;_.O.ca(a)&&(a={url:a});typeof a===_.Xe&&!Array.isArray(a)&&"url"in a&&(b={url:a.url,type:a.type?a.type:null},_.O.R(a.drmProtected)||typeof a.drmProtected!==_.kd||(b.drmProtected=a.drmProtected),_.O.R(a.isLive)||typeof a.isLive!==_.kd||(b.isLive=a.isLive),_.O.R(a.name)||typeof a.name!==_.hg||(b.name=a.name),_.O.R(a.Lb)||typeof a.Lb!==_.hg||(b.Lb=a.Lb),_.O.R(a.audioMimeType)||typeof a.audioMimeType!==_.hg||(b.audioMimeType=a.audioMimeType));b&&!b.type&&(b.type=zp(a.url),b.type?
|
|
224
|
+
Cp.debug("Detect media type "+b.type+" for "+a.url):Cp.warn("Unable to detect media type for "+a.url));return b};Dp=function(){_.dm.call(this,Jd);this.w=this.H=!1;this.l=this.A=this.o=this.a=this.j=null;this.h=new _.Sh;this.G=this.B=this.f=this.I=null};
|
|
225
|
+
Gp=function(a,b){return a.w?Ep():new Promise(function(c){a.a||(a.h.on(b,_.re,function(){var d=Fp(a);if(d)a.onError(d)}),a.h.on(b,_.Rf,function(){var d=b.videoWidth,e=b.videoHeight,f=a.getTrackManager();f&&0<d&&0<e&&(f.w={width:d,height:e});a.trigger(new _.L(_.jd,{detail:{width:d,height:e}}))}),a.a=b);c()})};Hp=function(a){return a.w?Ep():new Promise(function(b){if(a.a){var c=a.a;a.h.off(c,_.re);a.h.off(c,_.Rf);a.a=null}b()})};
|
|
226
|
+
Jp=function(a){var b,c,d,e,f;return _.E(function(g){if(1==g.a){if(a.w)return g["return"](Ep());b=a.Z[a.getSourceIndex()];if(!a.configuration.drm||!1===b.drmProtected)return a.log.debug("No DRM configuration present.","Skipping DRM engine initialization"),g["return"](Promise.resolve());c=_.Ip;d=_.xm(a.configuration.drm);a.log.debug("Drm configuration: ",d);e=a.getNetworkEngine();a.o=new _.eo({tb:e,onError:function(h){return a.onError(h)},Kf:function(){},Jf:function(h,l){a.trigger(new _.L(_.he,{expirationTime:l}))},
|
|
227
|
+
onEvent:function(h){h instanceof _.L?a.dispatchEvent(h):a.log.debug(_.hc,h.type)},getConfiguration:function(){return a.getConfiguration()},Vc:function(){return a.Vc()}});a.o.h=d;f={id:0,language:_.vg,primary:!1,audio:null,video:{id:0,originalId:null,createSegmentIndex:Promise.resolve.bind(Promise),findSegmentPosition:function(){return null},getSegmentReference:function(){return null},adjustSegmentDurations:function(){},getDuration:a.getDuration.bind(a),initSegmentReference:null,wa:0,mimeType:_.Hg,
|
|
228
|
+
codecs:"",encrypted:!0,keyId:null,language:_.vg,originalLanguage:_.vg,label:null,type:c.VIDEO,primary:!1,frameRate:void 0,Ln:void 0,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],channelsCount:null,spatialAudio:!1,tn:null,closedCaptions:null},bandwidth:100,drmInfos:[],allowedByApplication:!0,allowedByKeySystem:!0};return _.x(g,_.jo(a.o,[f]),2)}return 3!=g.a?_.x(g,_.wo(a.o,a.a),3):g["return"](Promise.resolve())})};
|
|
229
|
+
Kp=function(a,b){ip(a.a,HTMLMediaElement.HAVE_CURRENT_DATA,a.h,function(){a.getState()!==_.up&&a.seek(b)["catch"](function(c){a.log.warn("Error while seeking to start position.",c)})})};Fp=function(a){if(null===a.Z||!a.a.error)return null;var b=a.a.error.code;if(1===b)return null;var c=a.a.error.msExtendedCode;c&&(0>c&&(c+=Math.pow(2,32)),c=c.toString(16));return new _.P(_.Q,3,3016,{code:b,Dn:c,message:a.a.error.message})};Ep=function(){return Promise.reject(new _.P(_.Q,7,7E3))};
|
|
230
|
+
Lp=function(a){if(a.w)return new _.Pj(Ep(),function(){});var b=a.Z[a.getSourceIndex()],c=a.configuration.startTime||null,d=a.a,e=a.I;c&&Kp(a,c);if(d.preload!==_.We)a.h.one(d,_.Ke,function(){var g=Date.now()/1E3-e;a.f.A=g;a.log.debug("Time to load: ",g)});d.src=b.url;(_.Vj()||_.Yj())&&d.load();var f=new _.Oj;a.h.one(d,cg,function(){var g=a.getConfiguration().manifest.attemptParameters.timeout||30;a.B||(a.B=(new _.Vk(function(){f.reject(new _.P(_.Q,3,3100,{message:"Unable to load media source successfully from "+
|
|
231
|
+
b.url,uri:b.url},d.error))})).da(g))});ip(d,a.configuration.forceWaitForTracks?HTMLMediaElement.HAVE_CURRENT_DATA:HTMLMediaElement.HAVE_METADATA,a.h,function(){return f.resolve()});d.error?f.reject(Fp(a)):d.preload===_.We&&(a.log.warn('With \x3cvideo preload\x3d"none"\x3e, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way. Please do not use preload\x3d"none" with PRESTOplay for Web Apps.'),f.resolve());a.h.one(d,_.re,function(){f.reject(Fp(a))});
|
|
232
|
+
return new _.Pj(f,function(){var g=new _.P(_.Q,7,7001);f.reject(g);return Promise.resolve()})};
|
|
233
|
+
Mp=function(a,b){ip(b,HTMLMediaElement.HAVE_CURRENT_DATA,a.h,function(){if(a.isLive()&&a.getState()!==_.up){var c=a.getSeekRange().end,d=a.getPosition();Infinity===c||20>c-d||(a.log.warn("Detected that HLS live stream was not started from close to the live edge. Auto-fixing, seeking to seek range end.(position: "+(d+", seek range end: "+c+")")),a.seek(c)["catch"](function(e){a.log.warn("Error while seeking to seek range edge.",e)}))}})};
|
|
234
|
+
Np=function(a,b){var c=!1;a.h.on(b,_.Yf,function(){c=b.paused});a.h.on(b,_.Xf,function(){.2>b.duration-b.currentTime&&b.paused&&!c&&(a.log.warn("Player was auto-paused during seek to the end, auto-resuming."),b.play())})};Op=function(){};_.Rp=function(a){a&&(0<=Pp.indexOf(a)?Qp.warn("Factory '"+a.name()+"' is already registered"):(Pp.push(a),Qp.info("Factory "+a.name()+"' has been registered.")))};
|
|
235
|
+
Tp=function(a,b){var c=Pp.find(function(d){return d.isSupported(a,b)});c||(c=new Sp);Qp.info("Chosen ads: "+c.name());return c};_.Up=function(a,b){var c=document.createElement(a),d;for(d in b){var e=b[d];null===e||void 0===e?c.setAttribute(d,""):c.setAttribute(d,e)}return c};_.Vp=function(a,b){a.classList.add(b)};_.Wp=function(a,b){if(a&&typeof b===_.Xe)for(var c in b)a.style[c]=b[c]};_.Xp=function(a){return document.createElement(a)};Yp=function(){this.a=null;this.h=new Set;this.f=null;this.set(null)};
|
|
236
|
+
Zp=function(a,b){a.a&&0!==b.length&&(a.a.classList.add(b),a.h.add(b))};$p=function(a,b){var c=new MutationObserver(function(){var d=Array.from(a.h.values());ii(Array.from(b.classList),Array.from(d))||b.classList.add.apply(b.classList,_.ah(d))});c.observe(b,{attributes:!0,attributeFilter:["class"]});return c};
|
|
237
|
+
dq=function(a,b){this.g=new _.K("clpp.PlayerSurface");this.w=_.O.na(aq,b);this.f=new Yp;this.h=null;this.a=new Yp;this.l=bq;bq+=1;this.o="clpp-video-"+this.l;this.j=new _.Sh;if(null==a)throw new _.P(_.Q,7,7102,"No Media element was provided");if(a instanceof Element)var c=a;else if(c=document.getElementById(a),!c)throw new _.P(_.Q,7,7004,"Media element not found");var d=this.w;this.g.debug("Initializing Player Surface on ",c);if("cast-media-player"===c.tagName.toLowerCase())this.h=c;else{if(!(c instanceof
|
|
238
|
+
HTMLMediaElement))throw new _.P(_.Q,7,7005,"Media element is not instance of HTMLMediaElement");if(!c.hasAttribute("crossorigin")){var e=d.crossorigin;this.g.info("Setting media elements crossorigin to "+e);c.setAttribute("crossorigin",e)}this.f.set(c);if(d.disableContainer)e=null;else if(d.containerEl){if(c.parentNode!==d.containerEl)throw new _.P(_.Q,7,7006,"Container element is not a direct parent of media element");e=d.containerEl}else{e=document.createElement(_.ae);c.parentNode?c.parentNode.replaceChild(e,
|
|
239
|
+
c):this.g.warn("Player Surface Element has no parent. Can not inject container. You have to manually add playerSurface.getContainer() to the DOM!");for(var f=[],g=0;g<c.classList.length;g++)f.push(c.classList[g]);f=_.t(f);for(g=f.next();!g.done;g=f.next())g=g.value,c.classList.remove(g),_.Vp(e,g);e.style.cssText=c.style.cssText;c.removeAttribute(_.jg);f=_.t([_.Ug,_.ve]);for(g=f.next();!g.done;g=f.next()){g=g.value;var h=c.getAttribute(g);h=parseInt(h,10);isNaN(h)||(e.style[g]=h+_.Lf);_.Vj()||c.removeAttribute(g)}e.appendChild(c)}e&&
|
|
240
|
+
(this.a.set(e),Zp(this.a,"clpp-container"),Zp(this.a,this.o),Zp(this.f,_.yd),Zp(this.f,"clpp-video"));d.webOSStartupPatch&&cq(this,c,e)}};cq=function(a,b,c){(_.Yj()&&53===Zk().major||_.Yj()&&68===Zk().major||_.$k())&&!b.hasAttribute(Vd)&&(b.style.opacity="0",b.setAttribute(Vd,""),a.j.one(b,me,function(){b.removeAttribute(Vd);b.style.opacity="1";c&&(c.style.opacity="1")}))};fq=function(a){this.m=a;this.j=this.m.getNetworkEngine();this.a=new _.Sh;this.h=null;this.f=!0;eq(this)};
|
|
241
|
+
eq=function(a){a.a.on(window,"offline",function(){gq(a,!1)});a.a.on(window,"online",function(){a.f||hq(a)});a.a.on(a.m,cg,function(){return iq(a)});a.a.on(a.m,"suspend",function(){return iq(a)});a.a.on(a.m,_.Ng,function(){return iq(a)});a.a.on(a.m,_.zf,function(){a.f||hq(a)});a.a.on(a.m,_.Kf,function(){a.f||hq(a)});a.a.on(a.m,_.eg,function(){switch(a.m.getState()){case _.op:iq(a);break;default:iq(a)}})};hq=function(a){a.m.getConfiguration().connectivityCheck&&(jq(a),a.h=(new _.Vk(function(){return kq(a)})).da(5))};
|
|
242
|
+
iq=function(a){a.f&&hq(a)};jq=function(a){a.h&&(a.h.stop(),a.h=null)};kq=function(a){var b,c;return _.E(function(d){if(1==d.a)return(b=a.m.getConfiguration().connectivityCheck)&&a.m?_.x(d,fk(a.j,b.url,b.attemptParameters,b.method),2):d["return"]();c=d.f;gq(a,c);_.y(d)})};gq=function(a,b){jq(a);a.f!==b&&(a.f=b,a.m&&a.m.getConfiguration().connectivityCheck&&a.m.trigger(new _.L(cf,{online:a.f})))};mq=function(){for(var a=0;a<lq.length;++a)lq[a].Nc()};
|
|
243
|
+
_.nq=function(a,b){b=b||0;for(var c={priority:b,Nc:a},d=0;d<lq.length;d++)if(lq[d].priority<b){lq.splice(d,0,c);return}lq.push(c)};oq=function(a,b){a.onError(b);a.release().then(function(){return a.destroy()})};pq=function(a,b,c){var d=_.R.aa;this.h=a;this.f=b;JSON.parse(d(_.xj(a)));this.a=JSON.parse(d(_.xj(b)));this.j=c};qq=function(a){this.license=a;this.a=null;this.g=new _.K("clpp.utils.LicenseKey")};
|
|
244
|
+
rq=function(a){if(!a.a){var b=a.license.split(".");if(3!==b.length)throw Error("Expected to find 3 data sections in JWT raw data");b=new pq(b[0],b[1],b[2]);a.a=b}return a.a};sq=function(a){switch((a.Z[0]||{src:"",type:""}).type){case _.Uc:a="dash";break;case _.$c:a="ss";break;case _.El:a="hls";break;case _.Hg:a="mp4";break;default:a=""}return a};tq=function(a){return a.viewerId?a.viewerId:(a=a.drm||null)&&a.customData&&a.customData.userId?""+a.customData.userId:""};
|
|
245
|
+
uq=function(a){return(a=a.drm||null)&&a.customData&&a.customData.assetId?""+a.customData.assetId:""};vq=function(a){return(a=a.drm||null)&&a.customData&&a.customData.sessionId?""+a.customData.sessionId:""};xq=function(a){var b=a.configuration,c="no";b.drm&&!_.O.ka(b.drm,{})&&(c="custom",b.drm.env&&b.drm.env.toLowerCase().startsWith(le)||wq(a).endsWith("drmtoday.com"))&&(c=le);return c};
|
|
246
|
+
yq=function(a){a=a.drmInfo;var b="";if(a)switch(a.keySystem){case _.Td:b="wv";break;case _.Rd:b="pr";break;case _.Pd:b="fps"}return b};zq=function(a){a=a.drmInfo;var b=!1;a&&(b=a.persistentStateRequired);return b.toString()};Aq=function(a){a=a.drmInfo;var b="";if(a)switch(a.videoRobustness){case hb:case fb:b="L1";break;case gb:b="L2";break;case _.Xb:case _.Wb:b="L3"}return b};wq=function(a){a=a.drmInfo;return(new _.Ei(a&&a.licenseServerUri||"")).Na};
|
|
247
|
+
Dq=function(a,b){var c="ie"===_.Zj().browser,d=b.configuration,e=_.ah(Array.from(_.em.keys())).concat(_.ah(b.Wh));d={"CL-KEY":a.license,"CL-LOCATION":window.location.href,"CL-SDK-VERSION":_.ia,"CL-USER-ID":tq(d),"CL-ASSET-ID":uq(d),"CL-SESSION-ID":vq(d),"CL-PLAYBACK-TYPE":b.isLive?Bq:Cq,"CL-CONTENT-TYPE":sq(b),"CL-PLUGINS":e.join(" "),"CL-DRM":xq(b),"CL-DRM-CDM":yq(b),"CL-DRM-SEC-LEVEL":Aq(b),"CL-DRM-OFFLINE":zq(b),"CL-DRM-IP":wq(b)};c&&(e=window.localStorage.getItem("cl_et"))&&(d["CL-ETAG"]=e);e=
|
|
248
|
+
_.Jj(["https://downloads.castlabs.com/r/register/"]);e.method="GET";e.headers=d;return(new _.ck).fetch(e).P.then(function(f){200===f.status&&c&&window.localStorage.setItem("cl_et",f.headers.etag);return Promise.resolve()})["catch"](function(f){a:{var g=rq(a);f=f.data;var h=f.status;if(g.a&&g.a.ilv)f=Promise.resolve();else{switch(h){case 403:case 404:g=7101;var l="castLabs Player license is invalid";if(403===h){h=l;l="";try{l=JSON.parse(decodeURIComponent(f.responseText)).message}catch(m){}f=h+(": "+
|
|
249
|
+
l)}else f=l+"!";l=f;break;case 412:g=7103;l="License requires a viewer ID. It should be supplied either via the `viewerId` config or in case of DRMtoday via the `drm.customData.userID` config.";break;default:f=Promise.resolve();break a}a.g.error(ub+l);f=Promise.reject(new _.P(_.Q,7,g,l))}}return f})};
|
|
250
|
+
X=function(a,b,c){_.Ul.call(this);var d=this;mq();this.g=new _.K("clpp.Player");if(!a)throw new _.P(_.Q,7,7102);this.ea=new _.Sh;this.f=this.A=b||_.$l();this.l=null;void 0===this.f.license&&(this.f.license=Yl,this.g.warn("You are using the embedded demo license!"));if(!this.f.license)throw this.g.error("You provided null or empty string as your license. Please check your license configuration."),new _.P(_.Q,7,7101,"No license provided in configuration!");this.h=new dq(a,c);this.a=this.D=null;this.G=
|
|
251
|
+
new _.ck;this.j=null;this.$=[];this.ba=!0;this.I={};this.fa=null;this.N=!0;this.T=this.L=!1;this.J=this.Tc=null;this.nf=!1;this.ia=new fq(this);this.on(_.eg,function(){d.getState()===_.up&&(d.a?d.a.unload():Promise.resolve())});this.on(_.Qc,this.Ch.bind(this));this.on(_.Pc,this.Ch.bind(this));Eq(this,this.f.license);this.h.getMedia()&&(a=this.h.getMedia(),a.hasAttribute("autoplay")&&(a.removeAttribute("autoplay"),this.g.debug("Removed autoplay attribute from video element. Auto play will be handled by configuration."),
|
|
252
|
+
void 0===this.f.autoplay&&(this.f.autoplay=!0,this.g.debug("Setting autoplay in configuration since it was specified in the video element"))));a=[];b=_.t(Fq);for(c=b.next();!c.done;c=b.next()){c=c.value;try{var e=c.create(this.f);e&&a.push(e)}catch(f){this.g.error("Error while creating player plugin",f)}}Gq(this,a);this.K=_.pa;km(this)};
|
|
253
|
+
_.Hq=function(a,b){null!=b&&b===a.a?a.a.forwardEventsTo(a):(a.a&&(a.a.stopForwardingEventsTo(a),a.a.destroy(),a.a=null),b&&(b.init(a.h,a.A),b.setNetworkEngine(a.getNetworkEngine()),b.forwardEventsTo(a),a.a=b))};Eq=function(a,b){a.D=new qq(b);a.D.verify()["catch"](function(c){setTimeout(function(){a.g.error(ub+c);a.trigger(new _.L(_.re,{detail:new _.P(_.Q,7,7101)}));a.destroy()},1E3)})};
|
|
254
|
+
Iq=function(a,b){var c,d;_.E(function(e){if(1==e.a)return a.h.getMedia()||a.h.getCastElement(),a.D||(a.D=new qq(a.f.license)),_.A(e,2),a.g.debug("Verifying license remotely"),_.x(e,Dq(a.D,b),4);if(2!=e.a)return a.g.debug("License verified remotely"),_.oh(e,0);c=_.C(e);a.g.debug("License rejected by remote",c);d={release:a.release.bind(a),destroy:a.destroy.bind(a),onError:a.onError.bind(a)};setTimeout(oq,1E3,d,c);_.y(e)})};
|
|
255
|
+
Gq=function(a,b){a.$=b;for(var c=_.t(a.$),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.id();e&&(a.I[e]=d)}a.vc("onPlayerCreated")};
|
|
256
|
+
Jq=function(a){var b,c;return _.E(function(d){if(1==d.a){if(a.N)return a.g.debug("The player is already released. No-op"),d["return"](new Promise(function(e){return e()}));a.ea.off(document,Lg);a.trigger(new _.L(_.Of));a.h&&a.h.release();return a.j?_.x(d,a.j.dispose(),3):d.F(2)}2!=d.a&&(a.j=null);if(a.a)return b=null,c=a.a.on(_.eg,function(e){b=e}),d["return"](a.vc(_.af).then(function(){a.a.stopForwardingEventsTo(a);return Promise.all([a.a.release(),a.G.release()])}).then(function(){a.g.debug("Releasing player completed");
|
|
257
|
+
b&&(a.g.debug("Re-post state change event after release"),a.trigger(b))})["finally"](function(){a.a.off(_.eg,c);a.trigger(new _.L(Nf))}));a.trigger(new _.L(Nf));return d["return"](new Promise(function(e){return e()}))})};Mq=function(a,b,c){return a.K===_.Jb?Kq(b,c):Lq(a,b,c)};Lq=function(a,b,c){var d;return _.E(function(e){if((d=2===(a.a?a.a.canPlay(b[0],c):0))&&!a.T)return e["return"]({player:a.a,sourceIndex:0});a.T=!1;return e["return"](Nq(a,b,c))})};
|
|
258
|
+
Kq=function(a,b){var c=Oh(function(d){return d.f(_.Jb)&&a.every(function(e){return 2===d.canPlay(e,b)})});if(!c)throw new _.P(_.Q,7,7003,"No compatible player implementing playlist mode found!");return Promise.resolve({player:c.create(),sourceIndex:0})};
|
|
259
|
+
Nq=function(a,b,c){return new Promise(function(d,e){var f;if(b){for(var g=f=null,h=0;h<b.length;h++);h=Object.values(_.Kh);for(var l=0;l<b.length;l++)for(var m=0;m<h.length;m++){var n={Qb:h[m],confidence:h[m].canPlay(b[l],c)};if(null===f||f.confidence<n.confidence)f=n,g=l}f&&typeof g===_.k&&0<f.confidence?(_.Mh.debug("Player Factory '"+f.Qb.a()+"' can play",b[g]),f=new Jh(f.Qb,g)):(_.Mh.error("No compatible Player Factory found for sources:",b),f=null)}else f=null;f?(g=f.Qb.create(),d({player:g,sourceIndex:f.sourceIndex})):
|
|
260
|
+
(f=new _.L(_.re,{detail:new _.P(_.Q,7,7003)}),a.trigger(f),e(f))})};Pq=function(a){var b;return _.E(function(c){if(1==c.a){if(!a.a)return a.g.warn(Lb),c["return"]();b=a.a;if(!b.Ag)return a.g.warn(Qb),c["return"]();a.trigger(new _.L(Le));return _.x(c,b.Ag(),2)}return _.x(c,_.Oq(a),0)})};
|
|
261
|
+
_.Rq=function(a,b,c){var d,e;return _.E(function(f){switch(f.a){case 1:if(a.L)throw new _.P(_.Q,7,7E3,"Player is already destroyed.");if(!a.h)throw new _.P(_.Q,7,7E3,"No surface associated with this player!");_.Yn(uf);return _.x(f,a.release(),2);case 2:d=c||_.Bp(b);if(!b||0===d.length)throw new _.P(_.Q,7,7003,Db);a.fa=d;a.f=_.bm(a.A,b,{source:d});a.N=!1;return _.x(f,Mq(a,d,a.f),3);case 3:e=f.f;_.Hq(a,e.player);a.a&&a.a.setSourceIndex(e.sourceIndex);Qq(a);a.a&&a.a.setCdnErrorCallback(a.J);a.j=Tp(a,
|
|
262
|
+
a.f).create(a);if(a.f.pauseWhenInBackground)a.ea.on(document,Lg,function(){document.hidden?(a.g.debug("Player is hidden: pausing..."),a.pause()):(a.g.debug("Player is visible: resuming..."),a.play())});lm(a);return _.x(f,a.vc("onContentWillLoad",d[e.sourceIndex]),4);case 4:_.Yn(qf),_.Zn("player.beforeLoad",uf,qf),_.y(f)}})};_.Sq=function(a){return _.E(function(b){a.h.getMedia()||a.h.getCastElement();a.trigger(new _.L(Le));return _.x(b,Promise.all([a.a.load(a.f),a.j.load()]),0)})};
|
|
263
|
+
Uq=function(a){var b,c,d,e;_.E(function(f){if(1==f.a){b=[];if(a.f.remoteTextTracks)for(c=_.t(a.f.remoteTextTracks),d=c.next();!d.done;d=c.next())e=d.value,b.push(a.getTrackManager().addTextTrack(e));return _.x(f,Promise.all(b),2)}Tq(a);_.y(f)})};
|
|
264
|
+
Tq=function(a){var b=_.gi(a.f.preferredTextLanguage).filter(function(f){return f}),c=a.f.preferForcedSubtitles,d=a.getTrackManager().ha().filter(function(f){return c?f.kind===_.se:f.kind!==_.se});if(0===d.length)c&&a.g.warn("Forced subtitles are configured to be preferred, but no forced subtitles are available.");else{if(c&&0===b.length){var e=a.getTrackManager().la();e&&e.language?(e=_.dj(e.language||""),b.push(e)):(e=a.getTrackManager().Ha())&&e.language&&(e=_.dj(e.language||""),b.push(e));0===
|
|
265
|
+
b.length&&a.g.warn("Forced subtitles are configured to be preferred, but neither the preferred text language is set, nor the audio or video track language is available to determine which forced subtitles language to select.")}b.some(function(f){var g=_.dj(f);if(f=d.find(function(h){h=_.dj(h.language||"");return _.ej(h,g)}))return a.getTrackManager().Ja(f),!0;c&&a.g.warn("Forced subtitles are configured to be preferred, but no forced subtitles match the preferred languages: ",b);return!1})}};
|
|
266
|
+
_.Oq=function(a){return _.E(function(b){if(1==b.a)return _.Yn(nf),Iq(a,{configuration:a.getConfiguration(),Z:a.ih(),drmInfo:a.getDrmInfo(),Wh:Object.keys(a.I),isLive:a.isLive()}),Uq(a),mm(),_.x(b,a.vc("onContentLoaded"),2);if(3!=b.a)return a.f.autoplay?_.x(b,a.play(),3):b.F(3);_.Yn(mf);_.Zn("player.afterLoad",nf,mf);_.y(b)})};Qq=function(a){a.a&&a.a.setDrmCustomDataModifier(function(b){return _.E(function(c){if(!a.Tc||!a.nf)return c.F(0);a.nf=!1;return _.x(c,a.Tc(b),0)})})};
|
|
267
|
+
_.Vq=function(a){a&&(0<=Fq.indexOf(a)||Fq.push(a))};Wq=function(a,b,c){X.call(this,a,b,c);a={manifest:{timeline:{version:2},keepTimelineLive:!0},streaming:{preferNativeHlsOnSafari:!1,enableLiveEdgeChasing:!1,startAtSegmentBoundary:!1}};this.A=_.O.na(this.A,a);this.f=_.O.na(this.f,a);this.B=0;this.o=[];this.V=!1;this.w=null;this.H=[]};Xq=function(a){a.H.forEach(function(b){return b()});a.H=[]};
|
|
268
|
+
Yq=function(a,b){function c(f){a.B=a.o.findIndex(function(g){return g.id===f.id})}a.addEventListener(_.Uf,c);a.H.push(function(){a.removeEventListener(_.Uf,c)});if(b.endTime){var d=b.endTime,e=function(){a.getPosition()>=d&&(a.removeEventListener(_.rg,e),a.g.info("Playlist end time reached. Stopping playback."),a.trigger(new _.L(_.Tf)),a.pause())};a.addEventListener(_.rg,e);a.H.push(function(){a.removeEventListener(_.rg,e)})}};
|
|
269
|
+
ar=function(a,b){var c,d;return _.E(function(e){switch(e.a){case 1:return _.A(e,2),_.Yn(yf),a.K=_.Jb,a.ba=!1,c=b.slice(1).map(function(f){return{config:f,Z:_.Bp(f)}}),_.x(e,_.Rq(a,b[0]),4);case 4:return c.forEach(function(f){Zq(a,f.config,f.Z)}),a.trigger(new _.L(Le)),_.x(e,a.a.setupPlaylist(b),5);case 5:return _.x(e,_.Oq(a),6);case 6:c.forEach(function(f){$q(a,f.config,f.Z)});_.Yn(xf);_.Zn("player.setupPlaylist",yf,xf);_.oh(e,0);break;case 2:d=_.C(e);if(a.l)throw a.g.info(vb),new _.P(_.Q,7,7E3);
|
|
270
|
+
throw d;}})};br=function(a,b){var c,d;return _.E(function(e){if(1==e.a)return _.A(e,2),_.Yn(pf),c=_.Bp(b),Zq(a,b,c),_.x(e,a.a.appendLoad(b),4);if(2!=e.a)return $q(a,b,c),_.Yn(of),_.Zn("player.appendLoad",pf,of),_.oh(e,0);d=_.C(e);if(a.l)throw a.g.info(vb),new _.P(_.Q,7,7E3,{id:b.id});throw d;})};$q=function(a,b,c){Iq(a,{configuration:b,Z:c,drmInfo:a.getDrmInfo(),Wh:Object.keys(a.I),isLive:c[0].isLive})};
|
|
271
|
+
Zq=function(a,b,c){if(0===c.length)throw new _.P(_.Q,7,7003,{message:Db,id:b.id});if(1<c.length)throw new _.P(_.Q,7,7003,{message:"Multiple sources not supported!",id:b.id,source:c});if(2!==(a.a?a.a.canPlay(c[0],a.f):0))throw new _.P(_.Q,7,7003,{message:"Source not supported by the current player!",id:b.id,source:c[0]});};cr=function(a){this.a=a.map(function(b){return{videoId:b.getSurface().getMedia().id,player:b,he:!0,ready:Promise.resolve()}});this.g=new _.K("clpp.plist.PlayerPool")};
|
|
272
|
+
fr=function(a){_.Ul.call(this);var b=this;this.o=_.O.na({transition:_.gf,preloadMedia:!1},a);this.h=[];this.a=0;var c=dr(a.anchorId,this.o.config);this.w=new cr(c);this.f=null;this.j=!1;this.l=new Map;this.A=a.toggleVisible;this.g=new _.K(Kd);this.w.a.forEach(function(d){return er(b,d.player,!1)})};hr=function(a){return Promise.all(Array.from(a.l.keys()).map(function(b){return gr(a,b)}))};
|
|
273
|
+
gr=function(a,b){var c;return _.E(function(d){if(1==d.a){c=a.l.get(b);if(!c)return d.F(0);a.g.info("Stop preloading item (index: "+b+")");return c.player?_.x(d,ir(a,c),3):d.F(3)}a.l["delete"](b);_.y(d)})};kr=function(a,b){return _.E(function(c){if(1==c.a)return a.g.info("Stop current playback (index: "+b.index+")"),b.player.pause(),er(a,b.player,!1),_.x(c,ir(a,b),2);b.player=null;b.videoEl=null;b.role=jr;_.y(c)})};
|
|
274
|
+
ir=function(a,b){return _.E(function(c){b.disposers.forEach(function(d){return d()});b.disposers=[];return b.player?_.x(c,a.w.release(b.player),0):c.F(0)})};nr=function(a,b){var c;return _.E(function(d){if(1==d.a)return _.x(d,a.w.get(),2);if(3!=d.a)return c=d.f,a.f=b,b.role=lr,a.f.player=c,a.f.videoEl=c.getSurface().getMedia(),er(a,c,!0),_.x(d,c.load(b.config),3);mr(a,b);return b.config.autoplay?d.F(0):_.x(d,c.play(),0)})};
|
|
275
|
+
or=function(a,b){return _.E(function(c){switch(c.a){case 1:if(!b.player)return c["return"]();if(b.state!==Hf){c.F(2);break}a.g.info(pc);_.A(c,3);return _.x(c,b.preloadPromise,5);case 5:_.oh(c,2);break;case 3:_.C(c);case 2:a.f=b;b.role=lr;er(a,b.player,!0);if(b.state===Gf)return _.Yn(Df),a.o.preloadMedia?_.x(c,b.player.play(),11):_.x(c,Pq(b.player),11);if(b.state!==Ff){c.F(7);break}return _.x(c,b.player.load(b.config),7);case 11:_.Yn(Cf),_.Zn("playlist.next",Df,Cf);case 7:if(mr(a,b),b.config.autoplay)c.F(0);
|
|
276
|
+
else return _.x(c,b.player.play(),0)}})};mr=function(a,b){if(a.o.autoplayNext){var c=function(){a.g.info("Automatically transition to next item");a.Vh()};b.player.on(_.qe,c);var d=b.player;b.disposers.push(function(){d.off(_.qe,c)})}};qr=function(a){var b;return _.E(function(c){b=a.a+1;a.g.info("Preload following item (index: "+b+")");return _.x(c,pr(a,b),0)})};rr=function(a){var b;return _.E(function(c){b=a.a-1;a.g.info("Preload preceding item (index: "+b+")");return _.x(c,pr(a,b),0)})};
|
|
277
|
+
sr=function(a){var b;_.E(function(c){if(0===a.a)return _.x(c,qr(a),0);if(a.a===a.h.length-1)return _.x(c,rr(a),0);b=[a.a-1,a.a+1];a.g.info("Preload items (indices: "+b+")");return _.x(c,Promise.all(b.map(function(d){return pr(a,d)})),0)})};
|
|
278
|
+
pr=function(a,b){var c,d,e;return _.E(function(f){switch(f.a){case 1:return _.x(f,a.w.get(),2);case 2:return c=f.f,d=a.h[b],d.player=c,d.videoEl=c.getSurface().getMedia(),d.role=jr,d.state=Hf,a.trigger(new _.L(xg)),_.A(f,3),a.l.set(b,d),a.o.preloadMedia?(d.config.autoplay&&(a.g.warn("Autoplay should not be used for preloaded streams. Force disabling autoplay (index: "+(b+")")),d.config.autoplay=!1),d.preloadPromise=c.load(d.config)):d.preloadPromise=c.preload(d.config),_.x(f,d.preloadPromise,5);case 5:d.state=
|
|
279
|
+
Gf;a.trigger(new _.L(xg));_.oh(f,0);break;case 3:e=_.C(f),7001===e.code?(a.g.info("Preload aborted (index: "+b+")"),d.state=Ef):(a.g.warn("Preload failed (index: "+b+")",e),a.trigger(new _.L(_.re,{detail:e})),d.state=Ff),a.trigger(new _.L(xg)),_.y(f)}})};er=function(a,b,c){var d=b.getSurface().getMedia();b=b.getSurface().getUniqueCssClass();d&&(c?(a.g.info($b+b),d.classList.add(Ed)):(a.g.info(jb+b),d.classList.remove(Ed)),a.A&&a.A(d,c))};
|
|
280
|
+
tr=function(a){var b;return _.E(function(c){if(1==c.a)return _.x(c,a.w.destroy(),2);b=document.getElementById(a.o.anchorId);if(!b)return c["return"]();b.classList.remove(Bd);b.innerHTML="";_.y(c)})};
|
|
281
|
+
dr=function(a,b){var c=document.getElementById(a);if(!c)throw Error("Anchor element not found");c.classList.add(Bd);return Array.from({length:3}).map(function(){var d=document.createElement(_.Fg);d.classList.add(Dd);var e=document.createElement(_.ae);e.classList.add(Cd);e.appendChild(d);c.appendChild(e);return new X(d,b)})};
|
|
282
|
+
_.vr=function(a){if(ur.has(a))return ur.get(a);if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported(a);ur.set(a,b);return b}return window.MediaSource?(b=MediaSource.isTypeSupported(a),ur.set(a,b),b):!1};wr=function(a){this.h=a;this.f={keepOriginalTimestamps:!0,remux:!1};this.a=new muxjs.mp4.Transmuxer(this.f)};
|
|
283
|
+
xr=function(a,b){var c=b.replace(/mp2t/i,"mp4");a===_.bd&&(c=c.replace(_.Fg,_.bd));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};
|
|
284
|
+
Ar=function(a){_.Ul.call(this);var b=this;this.o=_.O.na({il:2},a);this.j=[];var c=yr(a.anchorEl,this.o.il+1,this.o.bk);this.l=new cr(c);this.a=null;this.h=!1;this.f=new Map;this.A=!1;this.w=a.toggleVisible;this.g=new _.K("clpp.interstitial.MultiController");this.l.a.forEach(function(d){return zr(b,d.player,!1)})};
|
|
285
|
+
Br=function(a){var b;return _.E(function(c){if(1==c.a)return(b=a.a)?"loaded"===b.state?c.F(2):_.x(c,b.Td,2):c["return"]();if(4!=c.a)return _.x(c,b.player.play(),4);b.state=_.zf;b.uc&&b.uc();_.y(c)})};Cr=function(a,b){a.A=b;var c=a.a&&a.a.player;c&&zr(a,c,!b)};
|
|
286
|
+
Dr=function(a,b){var c=b.transition;if(c){if(c.tc){var d=c.tc,e=function(){a.g.info("Transition onEnded to (ID: "+d+")");a.play(d)};b.player.on(_.qe,e);b.disposers.push(function(){b.player.off(_.qe,e)})}if(c.Eh){var f=function(l){var m=c.Eh.find(function(n){return n.cueId===l.detail.id});m&&(a.g.info("Transition onCue to (ID: "+m.itemId+")"),a.play(m.itemId))};b.player.on(_.ei,f);b.disposers.push(function(){b.player.off(_.ei,f)})}if(c.Kh){var g=c.Kh,h=function(){b.player.getPosition()>=g.position&&
|
|
287
|
+
(a.g.info("Transition onPosition to (ID: "+g.itemId+")"),a.play(g.itemId))};b.player.on(_.rg,h);b.disposers.push(function(){b.player.off(_.rg,h)})}}};Gr=function(a){a.a&&(a.a.disposers.forEach(function(b){return b()}),a.a.disposers=[],Dr(a,a.a),Er(a),Fr(a,a.a.next))};Er=function(a){return Promise.all(Array.from(a.f.keys()).map(function(b){return Hr(a,b)}))};
|
|
288
|
+
Hr=function(a,b){var c;return _.E(function(d){if(1==d.a){c=a.f.get(b);if(!c)return d.F(0);a.g.info("Stop preloading item (ID: "+b+")");return c.player?_.x(d,a.l.release(c.player),3):d.F(3)}a.f["delete"](b);_.y(d)})};Jr=function(a,b){var c;return _.E(function(d){if(1==d.a)return a.g.info("Stop current playback (ID: "+b.id+")"),b.disposers.forEach(function(e){return e()}),b.disposers=[],c=b.player,b.player=null,b.videoEl=null,b.role=Ir,c.pause(),_.x(d,a.l.release(c),2);zr(a,c,!1);_.y(d)})};
|
|
289
|
+
Lr=function(a,b){return _.E(function(c){if(1==c.a)return _.x(c,Kr(a,b),2);if(3!=c.a)return b.config.autoplay?c.F(3):_.x(c,b.player.play(),3);b.state=_.zf;_.y(c)})};Kr=function(a,b){var c,d;return _.E(function(e){if(1==e.a)return _.x(e,a.l.get(),2);if(3!=e.a)return c=e.f,a.a=b,b.role=Mr,a.a.player=c,a.a.videoEl=c.getSurface().getMedia(),zr(a,c,!0),b.primary&&a.trigger(new _.L(If,{detail:{player:c}})),b.state="loading",d=b,_.x(e,c.load(b.config),3);d.Td=e.f;b.state="loaded";_.y(e)})};
|
|
290
|
+
Nr=function(a,b){return _.E(function(c){switch(c.a){case 1:if(!b.player)return c["return"]();if(b.state!==Hf){c.F(2);break}a.g.info(pc);_.A(c,3);return _.x(c,b.preloadPromise,5);case 5:_.oh(c,2);break;case 3:_.C(c);case 2:a.a=b;b.role=Mr;zr(a,b.player,!0);b.state="loading";if(b.state===Gf)return _.x(c,b.player.play(),7);if(b.state!==Ff){c.F(7);break}return _.x(c,b.player.load(b.config),7);case 7:if(b.config.autoplay){c.F(11);break}return _.x(c,b.player.play(),11);case 11:b.state=_.zf,_.y(c)}})};
|
|
291
|
+
Fr=function(a,b){var c;_.E(function(d){if(0===b.length)return d["return"]();a.g.info("Preload items (IDs: "+b+")");c=a.j.filter(function(e){return b.includes(e.id)})||[];return _.x(d,Promise.all(c.map(function(e){return Or(a,e)})),0)})};
|
|
292
|
+
Or=function(a,b){var c,d,e;return _.E(function(f){switch(f.a){case 1:return c=b.id,_.x(f,a.l.get(),2);case 2:return d=f.f,b.player=d,b.videoEl=d.getSurface().getMedia(),b.role=Ir,b.state=Hf,a.trigger(new _.L(xg)),_.A(f,3),a.f.set(c,b),b.config.autoplay&&(a.g.warn("Autoplay should not be used for preloaded streams. Force disabling autoplay (ID: "+(c+")")),b.config.autoplay=!1),b.primary&&a.trigger(new _.L(If,{detail:{player:d}})),b.preloadPromise=d.load(b.config),_.x(f,b.preloadPromise,5);case 5:b.state=
|
|
293
|
+
Gf;a.trigger(new _.L(xg));_.oh(f,0);break;case 3:e=_.C(f),7001===e.code?(a.g.info("Preload aborted (ID: "+c+")"),b.state=Ef):(a.g.warn("Preload failed (ID: "+c+")",e),a.trigger(new _.L(_.re,{detail:e})),b.state=Ff),a.trigger(new _.L(xg)),_.y(f)}})};
|
|
294
|
+
zr=function(a,b,c){if(!a.A){var d=b.getSurface().getMedia();b=b.getSurface().getUniqueCssClass();d&&(c?(a.g.info($b+b),d.classList.add(Ed),d.classList.remove("clpp-hide")):(a.g.info(jb+b),d.classList.remove(Ed),d.classList.add("clpp-hide")),a.w&&a.w(d,c))}};Pr=function(a){var b;return _.E(function(c){if(1==c.a)return _.x(c,a.l.destroy(),2);b=a.o.anchorEl;if(!b)return c["return"]();b.classList.remove(Bd);b.innerHTML="";_.y(c)})};
|
|
295
|
+
yr=function(a,b,c){a.classList.add(Bd);return Array.from({length:b}).map(function(){var d=document.createElement(_.Fg);d.classList.add(Dd);var e=document.createElement(_.ae);e.classList.add(Cd);e.appendChild(d);a.appendChild(e);return new X(d,c)})};
|
|
296
|
+
Ur=function(a){_.Ul.call(this);var b=this;this.f=_.O.na({prerollMarginSec:.5,resolutionOffsetSec:35},a);this.g=new _.K(Id);this.l=null;this.a=new Ar({bk:this.f.config,anchorEl:a.anchorEl,preloadMedia:!0});Cr(this.a,!0);this.a.on(Ae,function(c){var d=c.detail;d.primary&&(b.l=d.player.getDuration());b.trigger(new _.L(Qr,c));Rr(b);d.primary&&Sr(b,d.player)});this.h=[];this.a.on(If,function(c){b.trigger(new _.L(Tr,{detail:{player:c.detail.player}}))});this.j=[]};
|
|
297
|
+
Wr=function(a,b,c){var d,e,f,g;return _.E(function(h){if(1==h.a){if(!b.source)return a.g.error("Config must be of type cl.api.PlayerConfiguration"),h["return"]();a.a.ge([{id:Jf,primary:!0,config:_.O.Ma(b),next:[]}]);return _.x(h,a.a.load(Jf),2)}d=a.a.Ab();if(!d||!d.re())return a.g.error("Failed to get cue timeline after load"),h["return"]();e=d.re();f=Array.from(e.cues());if(g=Vr(a,f,c))return h.F(0);Cr(a.a,!1);return c?h.F(0):_.x(h,Br(a.a),0)})};
|
|
298
|
+
Vr=function(a,b,c){function d(g){return g.startTime<a.f.prerollMarginSec}var e=b.filter(function(g){return g.schemeIdUri===Qd&&g.Wa});a.g.info("Interstitial cues found",e);if(!Xr(a,e))return!1;b=e.find(d);var f=e.filter(function(g){return g.startTime<a.f.resolutionOffsetSec&&!d(g)});e=e.filter(function(g){return!(g.startTime<a.f.resolutionOffsetSec)});b&&Yr(a,b,c);0<f.length&&f.forEach(function(g){return Zr(a,g)});e.forEach(function(g){return $r(a,g)});a.trigger(new _.L(as,{detail:a.Cd()}));return!!b};
|
|
299
|
+
$r=function(a,b){var c=b.Wa[wc];c={cueId:b.id,startTime:b.startTime,endTime:b.endTime,state:bs,og:b.Wa[tc],pg:b.Wa[uc],Da:null,resumePosition:null==c?b.endTime:b.startTime+c,playoutLimit:b.Wa[vc]};a.j.push(c);return c};
|
|
300
|
+
Yr=function(a,b,c){var d,e,f;_.E(function(g){if(1==g.a)return d=$r(a,b),_.x(g,cs(a,d),2);e=g.f;f=d.Da?d.Da.length:0;if(e&&0<f)return ds(a,d,c),g.F(0);e?a.g.warn("Preroll interstitial has no assets, skipping"):a.g.error("Preroll interstitial failed, skipping");Cr(a.a,!1);return c?g.F(0):_.x(g,Br(a.a),0)})};
|
|
301
|
+
Zr=function(a,b){var c,d,e,f;return _.E(function(g){if(1==g.a)return c=$r(a,b),a.g.info(kb+c.cueId+aa+(c.startTime+" s")),_.x(g,cs(a,c),2);if(d=g.f){e=a.a.getCurrentItem();if(!e)return a.g.error("Cannot schedule interstitial "+(c.cueId+", no primary content not found in playlist")),g["return"]();if(!e.player)return g["return"]();f=e.player;e.state===_.zf?es(a,c,f):e.uc=function(){es(a,c,f)}}_.y(g)})};Rr=function(a){a.h.forEach(function(b){return b()});a.h=[]};
|
|
302
|
+
Sr=function(a,b){function c(){a.trigger(new _.L(fs))}function d(){var e,f,g;return _.E(function(h){if(1==h.a){e=b.getPosition();f=gs(a,e);if(!f)return h.F(0);a.g.info(kb+f.cueId+aa+(f.startTime+" s"));return _.x(h,cs(a,f),3)}(g=h.f)&&es(a,f,b);_.y(h)})}b.addEventListener(_.rg,d);a.h.push(function(){b.removeEventListener(_.rg,d)});b.on(_.qe,c);a.h.push(function(){b.off(_.qe,c)})};
|
|
303
|
+
Xr=function(a,b){for(var c=b.sort(function(m,n){return m.startTime-n.startTime}),d=a.f.resolutionOffsetSec,e=[],f=0;f<c.length-1;f++){var g=c[f],h=c[f+1];h&&h.startTime-g.endTime<d&&e.push(mb+g.id+" and "+h.id+" are too close to each other (less than "+(d+" s)."));h&&h.startTime<=g.endTime&&e.push(mb+g.id+" and "+h.id+" overlap.")}var l=[];b.forEach(function(m){var n=m.Wa[uc],p=m.Wa[vc];m.Wa[tc]||n?null!=p&&1>p&&a.g.warn(lb+m.id+" is invalid X-PLAYOUT-LIMIT is less than 1 s.",m):l.push(lb+m.id+" is invalid it contains neither X-ASSET-LIST nor X-ASSET-URI.")});
|
|
304
|
+
0<l.length?a.g.error("Invalid interstitials, all interstitials will be skipped. "+l.join(" ")):0<e.length&&a.g.warn("Unsupported format of interstitials, playback may not behave correctly. "+e.join(" "));return 0===l.length};gs=function(a,b){return a.j.find(function(c){var d=c.startTime-b;return c.state===bs&&0<d&&d<=a.f.resolutionOffsetSec})||null};
|
|
305
|
+
cs=function(a,b){var c,d,e;return _.E(function(f){switch(f.a){case 1:b.state=hs;c={id:b.cueId,startTime:b.startTime,endTime:b.endTime,resumePosition:b.resumePosition,itemCount:-1,playoutLimit:b.playoutLimit};a.trigger(new _.L(is,{detail:c}));if(!b.og){b.pg?(b.Da=[{URI:b.pg,DURATION:b.endTime-b.startTime}],b.state=js):b.state=ks;f.F(2);break}_.A(f,3,4);a.g.info("Load X-ASSET-LIST for "+b.cueId);a.trigger(new _.L(ls,{detail:c}));d=b;return _.x(f,ms(a,b.og),6);case 6:d.Da=f.f,b.state=js,c.itemCount=
|
|
306
|
+
b.Da.length;case 4:_.ph(f);a.trigger(new _.L(ns,{detail:c}));_.qh(f,2);break;case 3:e=_.C(f);a.g.error("Failed to load X-ASSET-LIST",e);b.state=ks;f.F(4);break;case 2:return f["return"](b.state===js)}})};ds=function(a,b,c){var d,e;_.E(function(f){if(1==f.a){d=a.a.getCurrentItem();if(!d)return f["return"]();e=os(a,b,"preroll");a.a.ge(e);ps(a,d,b,e,!0);Gr(a.a);b.state=js;return c?_.x(f,a.a.load(e[0].id),3):_.x(f,a.a.play(e[0].id),3)}Cr(a.a,!1);_.y(f)})};
|
|
307
|
+
es=function(a,b,c){if(b.Da)if(0===b.Da.length){var d=function(){c.seek(b.resumePosition)};c.on(_.ei,d);a.h.push(function(){c.off(_.ei,d)});a.g.info(kb+b.cueId+" scheduled to be skipped")}else{var e=a.a.getCurrentItem();if(e){var f=os(a,b);a.a.ge(f);var g=f[0].id;ps(a,e,b,f,!1);e.next=[g];e.transition={Eh:[{cueId:b.cueId,itemId:g}]};Gr(a.a);b.state=js;a.g.info(kb+b.cueId+" scheduled for "+(b.startTime+" s"));a.trigger(new _.L(qs,{detail:{id:b.cueId,startTime:b.startTime,endTime:b.endTime,resumePosition:b.resumePosition,
|
|
296
308
|
itemCount:f.length,playoutLimit:b.playoutLimit}}))}}};
|
|
297
|
-
|
|
298
|
-
if(null!=b.playoutLimit){var f=b.playoutLimit;a.g.info("Playout limit for "+b.cueId+" is "+(f+" s"));e=e.filter(function(l){return l.
|
|
299
|
-
{detail:{id:b.cueId,startTime:b.startTime,endTime:b.endTime,resumePosition:b.resumePosition,itemCount:e.length,playoutLimit:b.playoutLimit}}));a.trigger(new _.L(
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
(d.audioCapabilities.push(l),g=!0));if(e.videoCapabilities)for(e=_.
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
c=_.R.
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
this.a)&&(h.push(m),e=!0));l||(e=b.canPlayType(_.
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
a.f=null}})).
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
_.R.empty(this.h)?this.g.warn(_.cb):_.R.empty(this.a)?this.g.warn(_.bb):this.
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
_.
|
|
324
|
-
|
|
325
|
-
4E3,{url:a});})};
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
q=_.
|
|
329
|
-
_.
|
|
330
|
-
request:a,abort:function(){c.abort();h.reject(new _.P(1,1,7001,{url:b,request:a}));return Promise.resolve()}}};
|
|
331
|
-
|
|
332
|
-
l=h.end-e.start;e={start:e.start,end:h.end,length:l,data:new DataView(a.j.a.buffer,e.start,l),count:f.length}}(f=c(!1,e))&&(g=f)}}return g.then(function(){return
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
return e.plugin(e.request)});var b=0,c=0,d=0;return a.h.then(function(e){var f=e.request;f.currentAttempt+=1;b=f.currentAttempt;c=f.maxAttempts;d=f.uris.length;return e.
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
b.onFragment(
|
|
342
|
-
|
|
343
|
-
_.
|
|
344
|
-
_.
|
|
345
|
-
_.
|
|
346
|
-
_.
|
|
347
|
-
_.
|
|
348
|
-
if(typeof Object.setPrototypeOf==_.
|
|
349
|
-
var
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
g[h];g[h]=null;try{l()}catch(m){this.j(m)}}}this.a=null};c.prototype.j=function(g){this.h(function(){throw g;})};b.prototype.j=function(){function g(m){return function(n){l||(l=!0,m.call(h,n))}}var h=this,l=!1;return{resolve:g(this.
|
|
353
|
-
b.prototype.B=function(g){var h=void 0;try{h=g.then}catch(l){this.h(l);return}typeof h==_.
|
|
354
|
-
g.
|
|
355
|
-
m.f);}}var m=this;null==this.a?f.f(l):this.a.push(l)};b.resolve=d;b.reject=function(g){return new b(function(h,l){l(g)})};b.race=function(g){return new b(function(h,l){for(var m=_.
|
|
356
|
-
|
|
357
|
-
_.
|
|
358
|
-
_.
|
|
359
|
-
_.
|
|
360
|
-
_.
|
|
361
|
-
_.H("clpp.log.setLogLevel",function(a){-1===a&&(a=3);_.
|
|
362
|
-
_.r.log=function(a,b){if(window.console){if(1<arguments.length){var c=arguments[0];Array.prototype.shift.call(arguments)}else c=3;var d=
|
|
363
|
-
1===c?console.error.apply(console,arguments):console.log.apply(console,arguments);d=_.
|
|
364
|
-
_.r.error=function(a){Array.prototype.unshift.call(arguments,1);this.log.apply(this,arguments)};_.r.
|
|
365
|
-
_.H("clpp.log.debug",_.
|
|
366
|
-
_.r.trigger=function(a){var b=this.a.get(a.type);if(b)for(var c=0;c<b.length&&(a.target=this.f,a.currentTarget=this.f,b[c].dc(a),b[c].
|
|
367
|
-
_.
|
|
368
|
-
_.
|
|
369
|
-
|
|
370
|
-
_.
|
|
309
|
+
os=function(a,b,c){c=void 0===c?"":c;var d=0,e=b.Da.map(function(l,m){var n=b.cueId+"-"+m,p=m===b.Da.length-1?Jf:b.cueId+"-"+(m+1);d+=l.DURATION;n={id:n,config:{source:{url:l.URI,type:_.El}},next:[p],transition:{tc:p},duration:l.DURATION,Og:d,Gn:b.cueId};return a.f.interstitialAssetConverter?a.f.interstitialAssetConverter(n):n});e.forEach(function(l,m){l.uc=function(){a.g.info(Ob+l.id,l);a.trigger(new _.L(rs,{detail:{id:l.id,podId:b.cueId,uri:l.config.source.url,duration:l.duration,podOrder:m+1,podCount:b.Da.length}}))}});
|
|
310
|
+
if(null!=b.playoutLimit){var f=b.playoutLimit;a.g.info("Playout limit for "+b.cueId+" is "+(f+" s"));e=e.filter(function(l){return l.Og-l.duration<=f});var g=e[e.length-1],h=Math.abs(g.Og-f);1>h?g.transition.tc=Jf:(g.transition.tc=void 0,g.transition.Kh={position:g.duration-h,itemId:Jf});g.next=[Jf]}e[0].uc=function(){a.g.info("Playing interstitial "+c+" "+b.cueId+" with "+(b.Da.length+" assets and will resume primary content at ")+(b.resumePosition+" s."),e);a.g.info(Ob+e[0].id,e[0]);a.trigger(new _.L(ss,
|
|
311
|
+
{detail:{id:b.cueId,startTime:b.startTime,endTime:b.endTime,resumePosition:b.resumePosition,itemCount:e.length,playoutLimit:b.playoutLimit}}));a.trigger(new _.L(rs,{detail:{id:e[0].id,podId:b.cueId,uri:b.Da[0].URI,duration:b.Da[0].DURATION,podOrder:1,podCount:b.Da.length}}))};return e};
|
|
312
|
+
ps=function(a,b,c,d,e){b.uc=function(){a.g.info("Resuming primary content at "+(b.config.startTime+" s."));a.trigger(new _.L(ts,{detail:{id:c.cueId}}));c.state=us;a.a.removeItems(d.map(function(f){return f.id}));b.next=[];e&&a.trigger(new _.L(vs))};b.config.startTime=c.resumePosition};
|
|
313
|
+
ms=function(a,b){var c,d,e,f,g,h;return _.E(function(l){if(1==l.a){c=a.a.Ab();if(!c)throw Error("No player found");d=c.getNetworkEngine();e=_.Jj(b);return _.x(l,ek(d,e),2)}f=l.f;g=ws(f);if(!g)throw new _.yi("Invalid X-ASSET-LIST list response");h=f;return l["return"](Promise.resolve(h.ASSETS))})};ws=function(a){return a&&a.ASSETS&&Array.isArray(a.ASSETS)?a.ASSETS.every(function(b){return typeof b.URI===_.hg&&typeof b.DURATION===_.k}):!1};xs=function(){};ys=function(){};zs=function(){};As=function(){};
|
|
314
|
+
Sp=function(){};Bs=function(){};_.Cs=function(){};Ds=function(){this.a=null;this.g=new _.K("clpp.drm.eme.StandardEmeManager")};Es=function(){};Fs=function(){this.size=0;this.a=void 0;this.g=new _.K("clpp.drm.eme.MediaKeyStatusMap")};Gs=function(a,b){a.size=void 0===b?0:1;a.g.debug("Setting key status to",b);a.a=b};Hs=function(){};Is=function(){};Js=function(){this.a=this.f=null};
|
|
315
|
+
Ks=function(a,b){this.keySystem=a;if(a.startsWith(_.Pd))for(var c=_.t(b),d=c.next();!d.done;d=c.next()){var e=d.value;if(e.persistentState===_.Qf)d=null;else{d={audioCapabilities:[],videoCapabilities:[],persistentState:_.df,distinctiveIdentifier:_.df,initDataTypes:e.initDataTypes,sessionTypes:[mg],label:e.label};var f=!1,g=!1;if(e.audioCapabilities)for(var h=_.t(e.audioCapabilities),l=h.next();!l.done;l=h.next())l=l.value,l.contentType&&(f=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,l.contentType.split(";")[0])&&
|
|
316
|
+
(d.audioCapabilities.push(l),g=!0));if(e.videoCapabilities)for(e=_.t(e.videoCapabilities),l=e.next();!l.done;l=e.next())h=l.value,h.contentType&&(f=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,h.contentType.split(";")[0])&&(d.videoCapabilities.push(h),g=!0));f||(g=WebKitMediaKeys.isTypeSupported(this.keySystem,_.Hg));d=g?d:null}if(d){this.a=d;return}}c=Error(lc);c.name=Ib;c.code=DOMException.NOT_SUPPORTED_ERR;throw c;};
|
|
317
|
+
Ls=function(a){this.f=null;this.h=new WebKitMediaKeys(a);this.a=new _.Sh;this.j=0;this.g=new _.K(Hd);this.g.info("Created Media Keys for "+a)};
|
|
318
|
+
Ms=function(a,b){a.f=b;_.Vh(a.a);if(!b)return Promise.resolve();a.a.on(b,oe,function(c){_.Hh("AppleEmeManager.cancelNativeMediaEncryptedEvent_",c);"MediaEncryptedEvent"in window&&c instanceof MediaEncryptedEvent&&(a.g.info("Cancel native MediaEncryptedEvent when using Apple-prefixed EME"),c.stopImmediatePropagation())});a.a.on(b,Tg,function(c){a.g.debug("Handle webkitNeedKey event");c=_.lj(c.initData);if(_.sj(c).getUint32(0,!0)+4!==c.byteLength)throw new RangeError("Malformed FairPlay init data");
|
|
319
|
+
c=_.R.lc(c.subarray(4),!0);c=_.R.Ua(c);var d=new Event(oe);d.initDataType="skd";d.initData=tj(c);a.f.dispatchEvent(d)});ip(b,HTMLMediaElement.HAVE_METADATA,a.a,function(){return b.webkitSetMediaKeys(a.h)});return Promise.resolve()};Ns=function(a,b){_.Ul.call(this);this.a=null;this.o=a;this.f=this.h=null;this.j=new _.Sh;this.sessionId=b;this.expiration=NaN;this.closed=new _.Oj;this.l=!1;this.keyStatuses=new Fs;this.g=new _.K(Hd)};Os=function(a,b){Gs(a.keyStatuses,b);a.dispatchEvent(new _.L(Be))};
|
|
320
|
+
Ps=function(){};Qs=function(){this.f=this.a=null;this.h="";HTMLMediaElement.prototype.webkitGenerateKeyRequest&&(this.h="webkit")};
|
|
321
|
+
Rs=function(a,b,c,d){this.h=a;this.a=this.keySystem=c;a=!1;c===_.ef&&(this.a=Pg,a=!1);var e=!1;d=_.t(d);for(var f=d.next();!f.done;f=d.next()){f=f.value;var g=[],h=[],l=!1;if(f.audioCapabilities)for(var m=_.t(f.audioCapabilities),n=m.next();!n.done;n=m.next())n=n.value,n.contentType&&(l=!0,b.canPlayType(n.contentType.split(";")[0],this.a)&&(g.push(n),e=!0));if(f.videoCapabilities)for(g=_.t(f.videoCapabilities),n=g.next();!n.done;n=g.next())m=n.value,m.contentType&&(l=!0,b.canPlayType(m.contentType,
|
|
322
|
+
this.a)&&(h.push(m),e=!0));l||(e=b.canPlayType(_.Hg,this.a)||b.canPlayType("video/webm",this.a));f.persistentState!==_.Qf||a||(e=!1);if(e){this.f=f;return}}b=lc;if(c===_.ef||c===_.Td)b="None of the requested configurations were supported.";c=Error(b);c.name=Ib;c.code=DOMException.NOT_SUPPORTED_ERR;throw c;};Ss=function(a,b){this.h=a;this.o=b;this.a=null;this.f=new _.Sh;this.j=[];this.l=new Map};
|
|
323
|
+
Vs=function(a,b){a.a=b;_.Vh(a.f);b&&(a.f.on(b,a.h+"needkey",function(c){var d=new Event(oe);d.initDataType=_.td;d.initData=tj(c.initData);a.a.dispatchEvent(d)}),a.f.on(b,a.h+"keymessage",function(c){var d=Ts(a,c.sessionId);if(d){var e=void 0===d.keyStatuses.getStatus();c=new _.L(_.Pe,{messageType:e?Fe:De,message:c.message});_.Hh("WebkitEmeManager.MediaKeySession.generated");d.f&&(d.f.resolve(),d.f=null);d.dispatchEvent(c)}else _.Ih("Session not found",c.sessionId)}),a.f.on(b,a.h+"keyadded",function(c){(c=
|
|
324
|
+
Ts(a,c.sessionId))&&c.ready()}),a.f.on(b,a.h+"keyerror",function(c){var d=Ts(a,c.sessionId);if(d){var e=Error("EME v0.1b key error"),f=c.errorCode;f.systemCode=c.systemCode;e.errorCode=f;!c.sessionId&&d.f?(45===c.systemCode&&(e.message="Unsupported session type."),d.f.reject(e),d.f=null):c.sessionId&&d.a?(d.a.reject(e),d.a=null):(e=c.systemCode,c.errorCode.code===MediaKeyError.MEDIA_KEYERR_OUTPUT?Us(d,_.ff):1===e?Us(d,"expired"):Us(d,_.ze))}}))};
|
|
325
|
+
Ts=function(a,b){var c=a.l.get(b);return c?c:(c=a.j.shift())?(c.sessionId=b,a.l.set(b,c),c):null};Ws=function(a,b,c,d){_.Ul.call(this);this.w=a;this.j=b;this.o=!1;this.a=this.f=null;this.h=c;this.l=d;this.sessionId="";this.expiration=NaN;this.closed=new _.Oj;this.keyStatuses=new Fs};
|
|
326
|
+
Ys=function(a,b,c){if(a.o)return Promise.reject(Error("The session is already initialized."));a.o=!0;try{if(a.l===_.jf)if(c)var d=_.lj(_.R.Ua("LOAD_SESSION|"+c));else{var e=_.R.Ua("PERSISTENT|"),f=new Uint8Array(e.byteLength+b.byteLength);f.set(e,0);f.set(_.lj(b),e.byteLength);d=f}else d=_.lj(b)}catch(h){return Promise.reject(h)}a.f=new _.Oj;var g=Xs(a,"generateKeyRequest");try{a.j[g](a.h,d)}catch(h){if(h.name!==ob)return a.f=null,Promise.reject(h);(new _.Vk(function(){try{a.j[g](a.h,d)}catch(l){a.f.reject(l),
|
|
327
|
+
a.f=null}})).da(.01)}return a.f};Zs=function(a,b,c){if(a.a)a.a.then(function(){return Zs(a,b,c)})["catch"](function(){return Zs(a,b,c)});else{a.a=b;if(a.h===Pg){var d=_.R.aa(c);var e=JSON.parse(d);"oct"!==e.keys[0].kty&&(a.a.reject(Error("Response is not a valid JSON Web Key Set.")),a.a=null);d=_.xj(e.keys[0].k);e=_.xj(e.keys[0].kid)}else d=_.lj(c),e=null;var f=Xs(a,"addKey");try{a.j[f](a.h,d,e,a.sessionId)}catch(g){a.a.reject(g),a.a=null}}};Us=function(a,b){Gs(a.keyStatuses,b);a.dispatchEvent(new _.L(Be))};
|
|
328
|
+
Xs=function(a,b){return a.w?a.w+b.charAt(0).toUpperCase()+b.slice(1):b};$s=function(){};
|
|
329
|
+
at=function(a,b,c,d,e){_.Am.call(this,ib);this.l=a;this.j=b;this.h=c;this.a=d;this.o=e;this.g=new _.K(Gd);_.R.empty(this.l)?this.g.warn(_.rc):this.Sa(_.Td,{licenseUrl:this.l,videoRobustness:[_.Xb,void 0],audioRobustness:[_.Wb,void 0],persistentStateRequired:!1,distinctiveIdentifierRequired:!1,serverCertificate:null,modifiers:{licenseRequest:this.Vd.bind(this)}});_.R.empty(this.j)?this.g.warn(_.Kb):this.Sa(_.Rd,{licenseUrl:this.j,videoRobustness:["3000"],audioRobustness:["2000"],modifiers:{licenseRequest:this.Vd.bind(this)}});
|
|
330
|
+
_.R.empty(this.h)?this.g.warn(_.cb):_.R.empty(this.a)?this.g.warn(_.bb):this.Sa(_.Pd,{licenseUrl:this.h,certificateUrl:this.a,modifiers:{licenseRequest:this.Gh.bind(this),licenseResponse:this.Hh.bind(this),certificateRequest:this.Vd.bind(this),extractContentId:this.Tg.bind(this)}})};bt=function(){};ct=function(a){var b=a.type.replace(/^(webkit|moz|MS)/,"").toLowerCase();if(typeof Event===_.ue)var c=new Event(b,a);else c=document.createEvent("Event"),c.initEvent(b,a.bubbles,a.cancelable);a.target.dispatchEvent(c)};
|
|
331
|
+
dt=function(a){a=a.target;if(a.webkitPresentationMode===kf){document.pictureInPictureElement=a;var b=new Event("enterpictureinpicture");a.dispatchEvent(b)}else document.pictureInPictureElement===a&&(document.pictureInPictureElement=null),b=new Event("leavepictureinpicture"),a.dispatchEvent(b)};et=function(){return this.webkitSupportsPresentationMode(kf)?(this.webkitSetPresentationMode(kf),document.pictureInPictureElement=this,Promise.resolve()):Promise.reject(Error("PiP not allowed by video element"))};
|
|
332
|
+
ft=function(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))};gt=function(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}};ht=function(a,b,c){return new window.TextTrackCue(a,b,c)};
|
|
333
|
+
it=function(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)};lt=function(a,b,c){if("input"===a)switch(this.type){case "range":a=wd}jt.call(this,a,b,c)};nt=function(){this.a=mt()};ot=function(a){return mt()-a.a};pt=function(a){var b=new nt;b.a=a.a;return b};mt=function(){return window.performance&&window.performance.now?window.performance.now():Date.now()};_.qt=function(a){var b=[];a=_.t(a);for(var c=a.next();!c.done;c=a.next()){c=_.t(c.value.variants);for(var d=c.next();!d.done;d=c.next())b.push(d.value)}return b};
|
|
334
|
+
rt=function(a){var b=void 0===b?2:b;this.a=new Uint8Array(a);this.h=b;this.f=0};st=function(a,b){var c=a.f+b.byteLength;if(c>a.a.byteLength){var d=a.a;a.a=new Uint8Array(Math.max(Math.ceil(a.a.buffer.byteLength*a.h),c));a.a.set(d)}a.a.set(b,a.f);a.f+=b.byteLength};_.tt=function(a,b,c){this.h=a;this.j=b;this.f=c||this.h.getMedia();this.a=null};_.vt=function(){this.a=new Blob([ut],{type:_.Hg})};_.wt=function(a,b,c,d){this.id=a;this.f=b;this.a=c;this.h=d};_.xt=function(){this.a=[];this.f=-1;this.h=null};
|
|
335
|
+
_.zt=function(a,b,c,d){var e,f;return _.E(function(g){if(1==g.a)return _.A(g,2),_.x(g,yt(a,b,c,d),4);if(2!=g.a)return e=g.f,g["return"](new e);f=_.C(g);f.a(_.Q);throw f;})};
|
|
336
|
+
yt=function(a,b,c,d){var e,f,g,h;return _.E(function(l){if(1==l.a){if(d){if(e=_.At[d.toLowerCase()])return l["return"](e);_.J("Could not determine manifest type using MIME type ",d)}if(f=_.Bt(a)){if(g=_.Ct[f])return l["return"](g);_.J("Could not determine manifest type for extension ",f)}else _.J("Could not find extension for ",a);return d?l.F(2):_.x(l,Dt(a,b,c),3)}if(2!=l.a&&(d=l.f)){if(h=_.At[d])return l["return"](h);_.J("Could not determine manifest type using MIME type",d)}throw new _.P(_.Q,4,
|
|
337
|
+
4E3,{url:a});})};Dt=function(a,b,c){var d,e,f;return _.E(function(g){if(1==g.a)return d=_.Jj(a),Hj(d,c),d.type=1,d.method="HEAD",_.x(g,b.fetch(d).P,2);e=g.f;f=e.headers["content-type"];return g["return"](f?f.toLowerCase():"")})};_.Bt=function(a){a=(new _.Ei(a)).za.split("/").pop().split(".");return 1===a.length?"":a.pop().toLowerCase()};Et=function(a){this.a=new Uint8Array(a||65536);this.f=0;this.h=new nt};
|
|
338
|
+
Gt=function(a,b,c){return b.read().then(function(d){var e=d.done;d=d.value;null!=d&&(Ft(a,d),Mj(c,d.byteLength,ot(a.h)),a.h.a=mt());return e?(e=a.a.buffer,a.a.byteLength!==a.f&&(e=e.slice(0,a.f)),Promise.resolve(e)):Promise.resolve().then(function(){return Gt(a,b,c)})})};Ft=function(a,b){var c=a.f+b.byteLength;if(a.a.byteLength<c){for(var d=a.a.byteLength;d<c;)d*=2;c=new Uint8Array(d);c.set(a.a);a.a=c}a.a.set(b,a.f);a.f+=b.byteLength};
|
|
339
|
+
ak=function(a){var b=a.uris[a.uriIndex],c=new Ht,d=new nt,e=pt(d),f=0,g,h=new _.Oj;c.open(a.method,b,!0);c.responseType="arraybuffer";c.timeout=a.timeout;c.withCredentials=a.allowCrossSiteCredentials;var l=!1,m=!1;c.onreadystatechange=function(p){p=p.target;p.readyState>=XMLHttpRequest.LOADING&&0===f&&(g=ot(e));p.readyState>=XMLHttpRequest.HEADERS_RECEIVED&&!l&&(p=p.getResponseHeader(wa),Lj(a,p),l=!0)};c.onload=function(p){p=p.target;var q=(p.getAllResponseHeaders()||"").trim().split("\r\n"),u={};
|
|
340
|
+
q=_.t(q);for(var v=q.next();!v.done;v=q.next())v=v.value.split(": "),u[v[0].toLowerCase()]=v.slice(1).join(": ");try{var z=ot(e);m||Mj(a,p.response?p.response.length:0,z);var B=_.Kj(u,p.response,p.status,b,p.responseURL,a,z,g);a.rateLimitBps?Nj(a.rateLimitBps,ot(e),a.bytesLoaded).then(function(){h.resolve(B)}):h.resolve(B)}catch(I){h.reject(I)}};c.onerror=function(p){p=p.target;if(0>=p.status)h.reject(new _.P(1,1,1002,{url:b,request:a,status:p.status}));else{var q=p.getAllResponseHeaders(),u={};if(q){q=
|
|
341
|
+
_.t(q.trim().split("\r\n"));for(var v=q.next();!v.done;v=q.next())v=v.value.split(": "),u[v[0].toLowerCase()]=v.slice(1).join(": ")}p=_.Kj(u,p.response,p.status,b,p.responseURL,a,ot(e),g);h.resolve(p)}};c.ontimeout=function(){h.reject(new _.P(1,1,1003,{url:b,request:a}))};c.onprogress=function(p){var q=ot(d);d.a=mt();if(100<q||p.lengthComputable&&p.loaded===p.total)Mj(a,p.loaded-f,q),f=p.loaded,m=!0};for(var n in a.headers)c.setRequestHeader(n.toLowerCase(),a.headers[n]);c.send(a.body);return{P:h,
|
|
342
|
+
request:a,abort:function(){c.abort();h.reject(new _.P(1,1,7001,{url:b,request:a}));return Promise.resolve()}}};It=function(a,b){a=void 0===a?1E6:a;b=void 0===b?!0:b;this.j=new rt(a);this.length=a;this.A=b;this.f=this.a=this.h=0;this.l=null;this.o=-1;this.w=new nt};
|
|
343
|
+
Lt=function(a,b,c,d){return b.read().then(function(e){var f=e.done;e=e.value;d&&e&&(d(e.byteLength,ot(a.w)),a.w.a=mt());if(f)return f=Jt(a),(f=c(!0,f))?f.then(function(){return a.j.a.buffer}):Promise.resolve(a.j.a.buffer);var g=Promise.resolve();if(null!=e){st(a.j,e);a.a=a.h;a.f=a.j.f;a.l=new DataView(a.j.a.buffer,0,a.j.f);e=Kt(a);for(f=[];e;)f.push(e),e=Kt(a);if(!a.A)f.forEach(function(m){g=g.then(function(){return c(!1,m)})});else if(0<f.length){e=f[0];if(1<f.length){e=f[0];var h=f[f.length-1],
|
|
344
|
+
l=h.end-e.start;e={start:e.start,end:h.end,length:l,data:new DataView(a.j.a.buffer,e.start,l),count:f.length}}(f=c(!1,e))&&(g=f)}}return g.then(function(){return Lt(a,b,c,d)})})};Kt=function(a){if(0<=a.o&&a.f<a.o)return null;for(var b=Mt(a);null!==b;){if(b.name===_.Ne){var c={start:a.h,end:b.end,length:b.end-a.h,data:new DataView(a.j.a.buffer,a.h,b.end-a.h),count:1};a.h=b.end;return c}b=Mt(a)}return null};
|
|
345
|
+
Mt=function(a){var b=a.a;if(a.a+4>=a.f)return a.a=a.f,null;var c=Nt(a);if(a.a+4>=a.f)return a.a=a.f,null;var d=Nt(a);d=String.fromCharCode(d>>24&255,d>>16&255,d>>8&255,d&255);switch(c){case 0:c=a.f-b;break;case 1:if(a.a+8>=a.f)return a.a=a.f,null;try{var e=a.l.getUint32(a.a,!1);var f=a.l.getUint32(a.a+4,!1)}catch(g){throw new _.P(_.Q,3,3E3);}if(2097151<e)throw new _.P(_.Q,3,3E3);a.a+=8;c=e*Math.pow(2,32)+f}c=b+c;a.o=c;return a.f>=c?(a.a=c,{name:d,start:b,end:c}):null};
|
|
346
|
+
Nt=function(a){var b=a.l.getUint32(a.a,!1);a.a+=4;return b};Jt=function(a){var b=null;a.h!==a.f&&(b={start:a.h,end:a.f,length:a.f-a.h,data:new DataView(a.j.a.buffer,a.h,a.f-a.h),count:-1});return b};Pt=function(a){_.Pj.call(this,new _.Oj,function(){return Promise.resolve()});this.B=a;this.h=null;this.w=this.P;this.f=-1;this.j=this.l=this.o=null;Ot(this)};Qt=function(a,b,c){a.o=setTimeout(b,c)};
|
|
347
|
+
Ot=function(a){a.h=a.B.then(function(e){a.j=e.request;e.request.uriIndex=e.request.currentAttempt%e.request.uris.length;if(0<e.request.currentAttempt){-1===a.f&&(a.f=Rt(e.request.baseDelay,1E3));var f=a.f*(1+(2*Math.random()-1)*Rt(e.request.fuzzFactor,.5));a.f*=Rt(e.request.backoffFactor,2);if(0<f)return(new Promise(function(g,h){a.l=h;Qt(a,function(){g(e.plugin(e.request))},f)}))["catch"](function(g){if(!a.a)throw g;})}if(a.a)throw new _.P(1,1,7001,{url:e.request.uris[e.request.uriIndex],request:e.request});
|
|
348
|
+
return e.plugin(e.request)});var b=0,c=0,d=0;return a.h.then(function(e){var f=e.request;f.currentAttempt+=1;b=f.currentAttempt;c=f.maxAttempts;d=f.uris.length;return e.P}).then(function(e){a.w.resolve(e)})["catch"](function(e){if(e instanceof _.P){var f=b<d,g=7001!==e.code,h=b<c;if((1===e.severity||f)&&g&&h)return Ot(a);g&&e.a(_.Q);a.w.reject(e)}else a.w.reject(e)})};Rt=function(a,b){return null===a||void 0===a?b:a};_.au=function(a){this.a=!1;this.h=a;this.j=St(this);this.h.ld(this.j);this.f=null};
|
|
349
|
+
St=function(a){return function(b){if(a.a&&(b=_.O.Gk(b.headers))){try{var c=new Map,d=b.split(";");for(b=0;b<d.length;b++){var e=iu(d[b]),f=e.key,g=e.value;Object.values(ju).includes(f)&&c.set(f,g)}var h=c}catch(l){ku.error("CmsdManager parseCmsdDynamicHeader_ failed:",l),h=null}a.f=h}}};
|
|
350
|
+
iu=function(a){var b=a.split("\x3d"),c=b[0];b=b[1];if(!c)throw new _.yi("Parsing CMSD, missing parameter or wrong format");if(c&&!b)return{key:c,value:!0};var d=b[0];if('"'===d&&'"'===b[b.length-1])return{key:c,value:b.replaceAll(/(^")|("$)/g,"")};if(/^[-0-9]/.test(d))return{key:c,value:parseInt(b,10)};if(/^[a-zA-Z*]/.test(d))return{key:c,value:b};throw new _.yi("Parsing CMSD, not recognized value type of "+a);};
|
|
351
|
+
bk=function(a){var b=new lu,c;for(c in a.headers)b.append(c.toLowerCase(),a.headers[c]);var d=new mu,e={od:!1,gi:!1};b={P:nu(a.uris[a.uriIndex],a,{body:a.body||void 0,headers:b,method:a.method,signal:d.signal,credentials:a.allowCrossSiteCredentials?"include":void 0},e),request:a,abort:function(){e.od||(e.od=!0,d.abort());return Promise.resolve()}};if(a=a.timeout){var f=window.setTimeout(function(){e.gi=!0;d.abort()},a);b.P=b.P["finally"](function(){window.clearTimeout(f)})}return b};
|
|
352
|
+
nu=function(a,b,c,d){var e,f,g,h,l,m,n,p,q,u,v,z,B,I,F,D;return _.E(function(G){switch(G.a){case 1:return e=ou,l=new nt,m=pt(l),_.A(G,2),_.x(G,e(a,c),4);case 4:f=G.f;h=ot(l);n=f.headers.get(wa);Lj(b,n);p=n?parseInt(n,10):0;if(b.onFragment&&!b.disableFragmentSupport&&2===b.type)return v=f.body.getReader(),z=new It(p,!b.disableMergedFragments),B=function(M,N){if(d.od)return null;N&&N.data&&(Mj(b,N.data.byteLength,ot(l)),l.a=mt());return b.onFragment&&N?b.rateLimitBps?Nj(b.rateLimitBps,ot(m),b.bytesLoaded).then(function(){return b.onFragment(N)}):
|
|
353
|
+
b.onFragment(N):null},_.x(G,Lt(z,v,B,b.onProgress),10);q=f.body.getReader();u=new Et(p);return _.x(G,Gt(u,q,b),7);case 7:g=G.f;if(!b.rateLimitBps){G.F(6);break}return _.x(G,Nj(b.rateLimitBps,ot(m),g.byteLength),6);case 10:g=G.f;case 6:_.oh(G,3);break;case 2:I=_.C(G);if(d.od)throw new _.P(1,1,7001,{url:a,request:b});if(d.gi)throw new _.P(1,1,1003,{url:a,request:b});_.Ih("Error while fetching data:",I);throw new _.P(1,1,1002,{url:a,error:I,request:b,status:-1},I);case 3:F={};D=f.headers;D.forEach(function(M,
|
|
354
|
+
N){F[N.trim()]=M});if(d.od)throw new _.P(1,1,7001,{url:a,request:b});return G["return"](_.Kj(F,g,f.status,a,f.url,b,ot(m),h))}})};Uj=function(a){try{var b=a.uris[a.uriIndex],c=_.pu(b);return{P:Promise.resolve({uri:b,data:c.data,request:a,headers:{"content-type":c.contentType}}),request:a,abort:function(){return Promise.resolve()}}}catch(d){return{P:Promise.reject(d),request:a,abort:function(){return Promise.resolve()}}}};
|
|
355
|
+
_.pu=function(a){var b=a.split(":");if(2>b.length||"data"!==b[0])throw _.Ih("Bad data URI, failed to parse scheme"),new _.P(_.Q,1,1004,{uri:a});b=b.slice(1).join(":").split(",");if(2>b.length)throw _.Ih("Bad data URI, failed to extract encoding and MIME type"),new _.P(_.Q,1,1004,{uri:a});var c=b[0];a=window.decodeURIComponent(b.slice(1).join(","));b=c.split(";");c=b[0];var d=!1;1<b.length&&"base64"===b[b.length-1]&&(d=!0,b.pop());return{data:d?_.xj(a).buffer:_.R.Ua(a).buffer,contentType:c}};
|
|
356
|
+
_.ru=function(a,b){var c=_.Rk(a.split(";")[0],Sk(a));_.qu[c]=b};_.su=function(a){a=_.Rk(a.split(";")[0],Sk(a));return _.qu[a]||null};_.tu=function(a){a=_.Rk(a.split(";")[0],Sk(a));delete _.qu[a]};
|
|
357
|
+
_.uu=function(a){a=a.getConfiguration();a=_.O.Ma(a.textStyle||a.textstyle||{});this.K=typeof a.backgroundColor===_.hg?a.backgroundColor:null;this.V=typeof a.windowColor===_.hg?a.windowColor:null;this.N=typeof a.fontColor===_.hg?a.fontColor:null;this.T=typeof a.fontFamily===_.hg?a.fontFamily:null;this.I=typeof a.fontSize===_.hg?a.fontSize:null;this.B=typeof a.fontSizePercent===_.k?a.fontSizePercent:null;this.H=typeof a.edgeColor===_.hg?a.edgeColor:"rgba(0, 0, 0, 1)";this.o=null;typeof a.edgeType===
|
|
358
|
+
_.hg&&(this.o=a.edgeType)};_.zu=function(a){if(!a.o)return null;var b=a.H;switch(a.o){case vu:return"-2px -2px 0 "+b+", -1px -1px 0 "+b;case wu:return"2px 2px 0 "+b+", 1px 1px 0 "+b;case xu:return"-1px 0 "+b+", 0 1px "+b+", 1px 0 "+b+", 0 -1px "+b;case yu:return"2px 2px 3px "+b+", 2px 2px 4px "+b+", 2px 2px 5px "+b;default:return _.We}};Au=function(a){this.f=a;this.a=null;this.g=new _.K("clpp.text.Mp4TextParser")};
|
|
359
|
+
_.Cu=function(a){_.uu.call(this,a);this.l=a.getSurface().getMedia();this.f="clpp-video-"+Bu++;this.h=document.createElement(_.jg);this.j=this.w=!1;_.Vp(this.l,this.f);document.head.appendChild(this.h);this.wb()};Du=function(){};_.Eu=function(){};_.Yg=[];bh=typeof Object.create==_.ue?Object.create:function(a){function b(){}b.prototype=a;return new b};
|
|
360
|
+
if(typeof Object.setPrototypeOf==_.ue)Fu=Object.setPrototypeOf;else{var Gu;a:{var Hu={yi:!0},Iu={};try{Iu.__proto__=Hu;Gu=Iu.yi;break a}catch(a){}Gu=!1}Fu=Gu?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}
|
|
361
|
+
var ch=Fu,gh=typeof Object.defineProperties==_.ue?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},eh="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this;hh.prototype.toString=function(){return this.a};var fh=function(){function a(c){if(this instanceof a)throw new TypeError("Symbol is not a constructor");return new hh("jscomp_symbol_"+(c||"")+"_"+b++,c)}var b=0;return a}();
|
|
362
|
+
kh.prototype.A=function(a){this.f=a};kh.prototype["return"]=function(a){this.h={"return":a};this.a=this.j};kh.prototype.F=function(a){this.a=a};
|
|
363
|
+
xh("Promise",function(a){function b(g){this.f=0;this.l=void 0;this.a=[];var h=this.j();try{g(h.resolve,h.reject)}catch(l){h.reject(l)}}function c(){this.a=null}function d(g){return g instanceof b?g:new b(function(h){h(g)})}if(a)return a;c.prototype.f=function(g){if(null==this.a){this.a=[];var h=this;this.h(function(){h.l()})}this.a.push(g)};var e=eh.setTimeout;c.prototype.h=function(g){e(g,0)};c.prototype.l=function(){for(;this.a&&this.a.length;){var g=this.a;this.a=[];for(var h=0;h<g.length;++h){var l=
|
|
364
|
+
g[h];g[h]=null;try{l()}catch(m){this.j(m)}}}this.a=null};c.prototype.j=function(g){this.h(function(){throw g;})};b.prototype.j=function(){function g(m){return function(n){l||(l=!0,m.call(h,n))}}var h=this,l=!1;return{resolve:g(this.D),reject:g(this.h)}};b.prototype.D=function(g){if(g===this)this.h(new TypeError("A Promise cannot resolve to itself"));else if(g instanceof b)this.G(g);else{a:switch(typeof g){case _.Xe:var h=null!=g;break a;case _.ue:h=!0;break a;default:h=!1}h?this.B(g):this.o(g)}};
|
|
365
|
+
b.prototype.B=function(g){var h=void 0;try{h=g.then}catch(l){this.h(l);return}typeof h==_.ue?this.H(h,g):this.o(g)};b.prototype.h=function(g){this.w(2,g)};b.prototype.o=function(g){this.w(1,g)};b.prototype.w=function(g,h){if(0!=this.f)throw Error("Cannot settle("+g+", "+h+"): Promise already settled in state"+this.f);this.f=g;this.l=h;this.A()};b.prototype.A=function(){if(null!=this.a){for(var g=0;g<this.a.length;++g)f.f(this.a[g]);this.a=null}};var f=new c;b.prototype.G=function(g){var h=this.j();
|
|
366
|
+
g.je(h.resolve,h.reject)};b.prototype.H=function(g,h){var l=this.j();try{g.call(h,l.resolve,l.reject)}catch(m){l.reject(m)}};b.prototype.then=function(g,h){function l(q,u){return typeof q==_.ue?function(v){try{m(q(v))}catch(z){n(z)}}:u}var m,n,p=new b(function(q,u){m=q;n=u});this.je(l(g,m),l(h,n));return p};b.prototype["catch"]=function(g){return this.then(void 0,g)};b.prototype.je=function(g,h){function l(){switch(m.f){case 1:g(m.l);break;case 2:h(m.l);break;default:throw Error("Unexpected state: "+
|
|
367
|
+
m.f);}}var m=this;null==this.a?f.f(l):this.a.push(l)};b.resolve=d;b.reject=function(g){return new b(function(h,l){l(g)})};b.race=function(g){return new b(function(h,l){for(var m=_.t(g),n=m.next();!n.done;n=m.next())d(n.value).je(h,l)})};b.all=function(g){var h=_.t(g),l=h.next();return l.done?d([]):new b(function(m,n){function p(v){return function(z){q[v]=z;u--;0==u&&m(q)}}var q=[],u=0;do q.push(void 0),u++,d(l.value).je(p(q.length-1),n),l=h.next();while(!l.done)})};return b});var zh=this||self;
|
|
368
|
+
zh.a=!0;_.O={vi:20,Ma:function(a){var b=_.O.R,c=_.O.uh,d=_.O.na;return b(a)||c(a)?a:d(a)}};_.H("clpp.utils.obj.cloneItem",_.O.Ma);_.O.na=function(a){for(var b=[],c=0;c<arguments.length;++c)b[c]=arguments[c];c={};for(var d=0;d<b.length;d++)null!=b[d]&&(c=_.O.yh(c,{merging:b[d]},1));return c.merging||null};_.H("clpp.utils.obj.merge",_.O.na);_.O.Hd=function(a){for(var b in a)if(void 0!==a[b])return!0;return!1};
|
|
369
|
+
_.O.yh=function(a,b,c){var d=_.O.R,e=_.O.uh,f=_.O.yh,g=_.O.sb,h=_.O.$k,l=_.O.th,m=_.O.Wk,n=_.O.Yc;c+=1;if(d(a)||!n(a))a={};for(var p in b)n=b[p],e(n)||d(n)||g(n)||m(n)?a[p]=n:h(n)?a[p]=n.subarray(0):n instanceof Array?a[p]=f([],n,c):!d(n)&&l(n)&&c<_.O.vi&&(a[p]=f(a[p],n,c));return a};_.O.uh=function(a){a=typeof a;return a===_.hg||a===_.k||a===_.kd};_.O.Wk=function(a){return a instanceof Element};_.O.R=function(a){return null===a||"undefined"===typeof a};_.O.Yc=function(a){return typeof a===_.Xe};
|
|
370
|
+
_.O.sb=function(a){return typeof a===_.ue};_.O.ca=function(a){return typeof a===_.hg};_.O.qa=function(a){return typeof a===_.k};_.O.ph=function(a){return typeof a===_.kd};_.O.th=function(a){var b=_.O.Yc,c=_.O.R;if(c(a)||!b(a))return!1;a=Object.getPrototypeOf(a);return a===Object.prototype||null===a};_.O.$k=function(a){var b=_.O.Yc,c=_.O.sb;return!!(b(a)&&a.buffer&&a.buffer instanceof ArrayBuffer&&c(a.subarray))};
|
|
371
|
+
_.O.ka=function(a,b,c,d){if(a===b||null===a&&null===b||void 0===a&&void 0===b)return!0;if(null===a&&null!==b||null!==a&&null===b||void 0!==a&&void 0===b||void 0===a&&void 0!==b||!_.O.Yc(a)||!_.O.Yc(b))return!1;for(var e=c||Object.keys(a),f={},g=0;g<e.length;g++){var h=e[g];if(_.O.R(d)||0>d.indexOf(h))if(f[h]=!0,a[h]!==b[h])return!1}if(_.O.R(c))for(a=Object.keys(b),b=0;b<a.length;b++)if(c=a[b],(_.O.R(d)||0>d.indexOf(c))&&!f[c])return!1;return!0};
|
|
372
|
+
_.O.isNaN=function(a){return(Number.hasOwnProperty("isNaN")?Number.isNaN:function(b){return b!==b})(a)};_.O.Xk=function(a,b,c){return a>=b&&a<=c};_.O.mg=function(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};_.O.ng=function(a){var b={};a.forEach(function(c,d){b[d]=c});return b};_.O.Gk=function(a){a=_.t(Object.entries(a));for(var b=a.next();!b.done;b=a.next()){var c=_.t(b.value);b=c.next().value;c=c.next().value;if("cmsd-dynamic"===b.toLowerCase())return c}return null};var Dh={DEFAULT:-1,NONE:0,ERROR:1,WARNING:2,INFO:3,DEBUG:4};_.H("clpp.log.Level",Dh);var Bh=3,Ah={},Ju=[];_.H("clpp.log.getLoggers",function(){return _.O.Ma(Ah)});_.H("clpp.log.addInterceptor",function(a){a&&Ju.push(a)});_.H("clpp.log.removeInterceptor",function(a){a&&(a=Ju.indexOf(a),0<=a&&Ju.splice(a,1))});_.H("clpp.log.getTagLevel",Ch);_.H("clpp.log.hasTagLevel",function(a){return void 0===a?!1:0<=Ah[a]});_.H("clpp.log.setTagLevel",function(a,b){a&&(_.O.ca(b)&&(b=Eh(b)),Ah[a]=b)});
|
|
373
|
+
_.H("clpp.log.setLogLevel",function(a){-1===a&&(a=3);_.O.ca(a)&&(a=Eh(a));Bh=a});_.H("clpp.log.getLogLevel",function(){return Bh});_.r=_.K.prototype;
|
|
374
|
+
_.r.log=function(a,b){if(window.console){if(1<arguments.length){var c=arguments[0];Array.prototype.shift.call(arguments)}else c=3;var d=Ch(this.tag);if(0<=d){if(d<c)return}else if(Bh<c)return;this.tag&&Array.prototype.unshift.call(arguments,"["+this.tag+"]");d=new Date;d.toISOString&&(d=d.toISOString().substring(11).replace("Z",""),Array.prototype.unshift.call(arguments,d));4===c?console.log.apply(console,arguments):3===c?console.info.apply(console,arguments):2===c?console.warn.apply(console,arguments):
|
|
375
|
+
1===c?console.error.apply(console,arguments):console.log.apply(console,arguments);d=_.t(Ju);for(var e=d.next();!e.done;e=d.next())e=e.value,e.call(e,c,arguments)}};_.r.info=function(a){Array.prototype.unshift.call(arguments,3);this.log.apply(this,arguments)};_.r.debug=function(a){Array.prototype.unshift.call(arguments,4);this.log.apply(this,arguments)};_.r.warn=function(a){Array.prototype.unshift.call(arguments,2);this.log.apply(this,arguments)};
|
|
376
|
+
_.r.error=function(a){Array.prototype.unshift.call(arguments,1);this.log.apply(this,arguments)};_.r.Xj=function(a){return a?this.tag?new _.K(this.tag+"."+a):new _.K(a):this};_.H("clpp.log.Logger",_.K);_.K.prototype.createChild=_.K.prototype.Xj;_.K.prototype.error=_.K.prototype.error;_.K.prototype.warn=_.K.prototype.warn;_.K.prototype.debug=_.K.prototype.debug;_.K.prototype.info=_.K.prototype.info;_.K.prototype.log=_.K.prototype.log;var Fh=new _.K("clpp");_.H("clpp.log.info",_.Gh);
|
|
377
|
+
_.H("clpp.log.debug",_.Hh);_.H("clpp.log.warn",_.J);_.H("clpp.log.error",_.Ih);(function(){var a=console.assert;a?a.bind||(console.assert=function(){a.apply(console,arguments)}):console.assert=function(){}})();_.Mh=new _.K("clpp.players");_.Kh={};_.Ph.prototype.push=function(a,b){a in this.a?this.a[a].push(b):this.a[a]=[b]};_.Ph.prototype.get=function(a){return(a=this.a[a])?a.slice():[]};_.Ph.prototype.remove=function(a,b){var c=this.a[a];if(!c)return!1;for(var d=!1,e=0;e<c.length;++e)c[e]===b&&(c.splice(e,1),--e,d=!0);return d};_.Ph.prototype.clear=function(){this.a={}};Qh.prototype.dc=function(a){try{this.Nc.handleEvent?this.Nc.handleEvent(a):this.Nc.call(this.a,a)}catch(b){_.Ih("clpp","Uncaught exception in event handler for event '"+this.f+"'",b,b?b.message:null,b?b.stack:null)}};_.L.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)};_.L.prototype.stopImmediatePropagation=function(){this.f=!0};_.L.prototype.stopPropagation=function(){};_.r=Rh.prototype;
|
|
378
|
+
_.r.trigger=function(a){var b=this.a.get(a.type);if(b)for(var c=0;c<b.length&&(a.target=this.f,a.currentTarget=this.f,b[c].dc(a),b[c].ym&&this.a.remove(a.type,b[c]),!a||!a.f);c++);};_.r.on=function(a,b,c){this.a.push(a,new Qh(a,b,c||this.f));return b};_.r.one=function(a,b,c){this.a.push(a,new Qh(a,b,c||this.f,!0));return b};_.r.off=function(a,b){var c=this.a.get(a),d=!1;if(c)for(var e=0;e<c.length;e++)c[e].Nc===b&&(d=this.a.remove(a,c[e])||d);return d};_.r.clear=function(){this.a.clear()};_.Sh.prototype.release=function(){_.Vh(this)};_.Sh.prototype.on=function(a,b,c,d){a=new Wh(a,b,c,void 0===d?!1:d);this.a.push(b,a)};_.Sh.prototype.one=function(a,b,c){function d(f){e.off(a,b,d);return c(f)}var e=this;this.on(a,b,d)};_.Sh.prototype.off=function(a,b,c){for(var d=this.a.get(b)||[],e=0;e<d.length;++e){var f=d[e];f.target!==a||c!==f.a&&c||(Uh(f),this.a.remove(b,f))}};Xh.prototype.release=function(){this.f.release();this.h=[];this.a=null};Xh.prototype.destroy=function(){var a=this;return _.E(function(b){a.release();a.l=null;a.j=null;_.y(b)})};Xh.prototype.getTimelineCues=function(){return this.h};_.ri.prototype.ka=function(a){return this.payload===a.payload&&this.startTime===a.startTime&&this.endTime===a.endTime&&this.payloadType===a.payloadType};_.H("clpp.text.Cue",_.ri);_.ri.positionAlign={LEFT:_.Ge,RIGHT:_.He,CENTER:_.ud,AUTO:"auto"};_.li="text";_.ri.payloadType={TEXT:_.li,VTT_XML:_.Mg,TTML_XML:_.ug};_.mi=_.ud;_.Ku={LEFT:_.Ce,RIGHT:_.Sf,CENTER:_.mi,START:_.Ce,END:_.Sf};_.ri.textAlign=_.Ku;var qi="ltr";_.ri.direction={HORIZONTAL_LEFT_TO_RIGHT:qi,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};_.ni="horizontal-tb";
|
|
379
|
+
_.ri.writingMode={HORIZONTAL_TOP_TO_BOTTOM:_.ni,VERTICAL_LEFT_TO_RIGHT:_.Dg,VERTICAL_RIGHT_TO_LEFT:_.Eg};_.oi=0;_.ri.lineInterpretation={LINE_NUMBER:_.oi,PERCENTAGE:1};_.pi=_.dg;_.Lu={CENTER:_.ud,START:_.pi,END:_.pe};_.ri.lineAlign=_.Lu;_.H("clpp.text.CueRegion",_.ui);_.si=1;_.ui.units={PX:0,PERCENTAGE:_.si,LINES:2};var ti="";_.ui.scrollMode={NONE:ti,UP:"up"};_.ui.displayAlign={BEFORE:"flex-end",CENTER:_.ud,AFTER:"flex-start"};
|
|
380
|
+
_.ui.writingMode={HORIZONTAL_TOP_TO_BOTTOM:_.Nd,VERTICAL_LEFT_TO_RIGHT:"row-reverse",VERTICAL_RIGHT_TO_LEFT:"row"};vi.prototype.destroy=function(){this.a.release();this.j=!1;this.l=this.a=this.h=this.f=null;return Promise.resolve()};vi.prototype.start=function(a){var b=this;this.j?this.g.warn("Already started. Ignoring request..."):(this.j=!0,this.h=a,this.f=this.h.textTracks,this.a.on(this.f,_.Nc,function(c){return wi(b,c)}),this.a.on(this.f,wd,function(){for(var c=b.f,d=0;d<c.length;d++){var e=c[d];e.mode===_.Zf&&(e.mode=_.we)}}))};
|
|
381
|
+
vi.prototype.o=function(a){var b=new _.ri(a.startTime,a.endTime,a.text,_.Mg);if(_.O.ca(a.vertical))switch(a.vertical){case "lr":b.writingMode=_.Dg;break;case "rl":b.writingMode=_.Eg}_.O.qa(a.size)&&(b.size=a.size);if(_.O.ca(a.align))switch(a.align){case _.Ce:case _.dg:b.textAlign=_.Ce;break;case _.ud:b.textAlign=_.mi;break;case _.Sf:case _.pe:b.textAlign=_.Sf}_.O.qa(a.position)&&(b.position=a.position);if(_.O.ca(a.positionAlign))switch(a.positionAlign){case _.Ge:b.positionAlign=_.Ge;break;case _.ud:b.positionAlign=
|
|
382
|
+
_.ud;break;case _.He:b.positionAlign=_.He}_.O.qa(a.line)&&(b.line=a.line);if(_.O.ca(a.lineAlign))switch(a.lineAlign){case _.dg:b.lineAlign=_.pi;break;case _.ud:b.lineAlign=_.ud;break;case _.pe:b.lineAlign=_.pe}_.O.ph(a.snapToLines)&&(b.lineInterpretation=a.snapToLines?_.oi:1);return b};_.w(_.P,Error);_.P.prototype.a=function(a){this.severity!==a&&(this.severity=a,this.message=xi(this.severity,this.category,this.code,this.data))};_.P.prototype.toString=function(){var a=this.message;this.cause&&(a+="\n Caused by "+this.cause);return a};_.H("clpp.Error",_.P);_.Q=2;_.P.Severity={RECOVERABLE:1,FATAL:_.Q};_.P.Category={NETWORK:1,TEXT:2,MEDIA:3,MANIFEST:4,STREAMING:5,DRM:6,PLAYER:7,CAST:8,PLUGIN:9,ADS:10};
|
|
371
383
|
_.P.Code={UNSUPPORTED_SCHEME:1E3,BAD_HTTP_STATUS:1001,HTTP_ERROR:1002,TIMEOUT:1003,MALFORMED_DATA_URI:1004,UNKNOWN_DATA_URI_ENCODING:1005,REQUEST_MODIFIER_ERROR:1006,RESPONSE_MODIFIER_ERROR:1007,MALFORMED_TEST_URI:1008,UNEXPECTED_TEST_REQUEST:1009,ATTEMPTS_EXHAUSTED:1010,INVALID_TEXT_HEADER:2E3,INVALID_TEXT_CUE:2001,UNABLE_TO_DETECT_ENCODING:2003,BAD_ENCODING:2004,INVALID_XML:2005,INVALID_MP4_TTML:2007,INVALID_MP4_VTT:2008,UNABLE_TO_EXTRACT_CUE_START_TIME:2009,FETCH_OR_APPEND_ERROR:2010,INVALID_MP4:2011,
|
|
372
384
|
TEXT_PARSER_MISSING:2012,THUMBNAILS_FAILED_TO_LOAD:2013,THUMBNAIL_ERROR:2014,BUFFER_READ_OUT_OF_BOUNDS:3E3,JS_INTEGER_OVERFLOW:3001,EBML_OVERFLOW:3002,EBML_BAD_FLOATING_POINT_SIZE:3003,MP4_SIDX_WRONG_BOX_TYPE:3004,MP4_SIDX_INVALID_TIMESCALE:3005,MP4_SIDX_TYPE_NOT_SUPPORTED:3006,WEBM_CUES_ELEMENT_MISSING:3007,WEBM_EBML_HEADER_ELEMENT_MISSING:3008,WEBM_SEGMENT_ELEMENT_MISSING:3009,WEBM_INFO_ELEMENT_MISSING:3010,WEBM_DURATION_ELEMENT_MISSING:3011,WEBM_CUE_TRACK_POSITIONS_ELEMENT_MISSING:3012,WEBM_CUE_TIME_ELEMENT_MISSING:3013,
|
|
373
385
|
MEDIA_SOURCE_OPERATION_FAILED:3014,MEDIA_SOURCE_OPERATION_THREW:3015,VIDEO_ERROR:3016,QUOTA_EXCEEDED_ERROR:3017,TRANSMUXING_FAILED:3018,MP4_PARSER_ERROR:3019,MEDIA_LOAD_ERROR:3100,INVALID_TRACK_TYPE:3101,UNKNOWN_TRACK:3102,MEDIA_DECRYPTION_ERROR:3103,PLAY_NOT_ALLOWED:3200,UNABLE_TO_GUESS_MANIFEST_TYPE:4E3,DASH_INVALID_XML:4001,DASH_NO_SEGMENT_INFO:4002,DASH_EMPTY_ADAPTATION_SET:4003,DASH_EMPTY_PERIOD:4004,DASH_WEBM_MISSING_INIT:4005,DASH_UNSUPPORTED_CONTAINER:4006,DASH_PSSH_BAD_ENCODING:4007,DASH_NO_COMMON_KEY_SYSTEM:4008,
|
|
374
386
|
DASH_MULTIPLE_KEY_IDS_NOT_SUPPORTED:4009,DASH_CONFLICTING_KEY_IDS:4010,UNPLAYABLE_PERIOD:4011,RESTRICTIONS_CANNOT_BE_MET:4012,NO_PERIODS:4014,HLS_PLAYLIST_HEADER_MISSING:4015,INVALID_HLS_TAG:4016,HLS_INVALID_PLAYLIST_HIERARCHY:4017,DASH_DUPLICATE_REPRESENTATION_ID:4018,HLS_MULTIPLE_MEDIA_INIT_SECTIONS_FOUND:4020,HLS_COULD_NOT_GUESS_MIME_TYPE:4021,HLS_REQUIRED_ATTRIBUTE_MISSING:4023,HLS_REQUIRED_TAG_MISSING:4024,HLS_COULD_NOT_GUESS_CODECS:4025,HLS_KEYFORMATS_NOT_SUPPORTED:4026,DASH_UNSUPPORTED_XLINK_ACTUATE:4027,
|
|
375
387
|
DASH_XLINK_DEPTH_LIMIT:4028,HLS_COULD_NOT_PARSE_SEGMENT_START_TIME:4030,CONTENT_UNSUPPORTED_BY_BROWSER:4032,SMOOTH_INVALID_MANIFEST_XML:4033,SMOOTH_EMPTY_PRESENTATION:4034,SMOOTH_MEDIA_PROCESSING_ERROR:4035,SMOOTH_INVALID_VERSION:4036,SMOOTH_INVALID_FRAGMENT_METADATA:4037,SMOOTH_REQUIRED_ATTRIBUTE_MISSING:4038,SMOOTH_TRUNCATED_MEDIA_FILE:4039,CANNOT_ADD_EXTERNAL_TEXT_TO_LIVE_STREAM:4040,HLS_MSE_ENCRYPTED_TS_NOT_SUPPORTED:4041,HLS_PLAYLIST_NOT_UTF8:4042,HLS_PLAYLIST_EMPTY:4043,HLS_INVALID_VALUE:4044,
|
|
376
388
|
HLS_DISCONTINUITY_NOT_SUPPORTED:4045,HLS_UNSUPPORTED_FEATURE:4046,HLS_INCOMPATIBLE_PLAYLIST_UPDATE:4047,INVALID_STREAMS_CHOSEN:5005,NO_RECOGNIZED_KEY_SYSTEMS:6E3,REQUESTED_KEY_SYSTEM_CONFIG_UNAVAILABLE:6001,FAILED_TO_CREATE_CDM:6002,FAILED_TO_ATTACH_TO_VIDEO:6003,INVALID_SERVER_CERTIFICATE:6004,FAILED_TO_CREATE_SESSION:6005,FAILED_TO_GENERATE_LICENSE_REQUEST:6006,LICENSE_REQUEST_FAILED:6007,LICENSE_RESPONSE_REJECTED:6008,ENCRYPTED_CONTENT_WITHOUT_DRM_INFO:6010,NO_LICENSE_SERVER_GIVEN:6012,OFFLINE_SESSION_REMOVED:6013,
|
|
377
|
-
EXPIRED:6014,REQUESTED_DRM_ENVIRONMENT_UNAVAILABLE:6015,INIT_DATA_TRANSFORM_ERROR:6016,CERTIFICATE_REQUEST_FAILED:6100,NO_CONTENT_ID:6101,SERVER_CERTIFICATE_REQUIRED:6102,EXTRACT_CONTENT_ID_MODIFIER_ERROR:6103,FAILED_TO_PERSIST_SESSION:6200,FAILED_TO_REMOVE_SESSION:6201,INVALID_SESSION_STORAGE_IMPLEMENTATION:6202,LOAD_INTERRUPTED:7E3,OPERATION_ABORTED:7001,NO_VIDEO_ELEMENT:7002,CANNOT_LOAD_SOURCE:7003,MEDIA_ELEMENT_NOT_FOUND:7004,INVALID_MEDIA_ELEMENT:7005,INVALID_CONTAINER_ELEMENT:7006,
|
|
378
|
-
INVALID_LICENSE:7101,NO_ELEMENT:7102,USER_ID_NOT_PROVIDED:7103,KEY_LOAD_ERROR:7104,TIZEN_INTERNAL_ERROR:7200,CAF_INTERNAL_ERROR:7300,INTERNAL_CAST_ERROR:8E3,CAST_API_NOT_READY:8001,NO_RECEIVERS_AVAILABLE:8002,ALREADY_CASTING:8003,NO_CAST_SESSION:8004,CONVIVA_SDK_NOT_LOADED:9E3,CONVIVA_INVALID_CONFIGURATION:9001,CONVIVA_RUNTIME_ERROR:9002,GL_CONTEXT_ERROR:9003,GL_SHADER_ERROR:9004,YOUBORA_SDK_MISSING:9100,YOUBORA_INVALID_CONFIGURATION:9101,
|
|
379
|
-
VIMOND_SESSION_ERROR:9201,MUXDATA_INVALID_CONFIGURATION:9300,MUX_SDK_MISSING:9301,MUXDATA_INIT_ERROR:9302,IMA_SDK_MISSING:1E4,IMA_INVALID_CONFIGURATION:10001,IMA_UNSUPPORTED_PLATFORM:10002,AD_ERROR:10003,SIMID_CONTAINER_MISSING:10100,BROADPEAK_SDK_MISSING:11E3,BROADPEAK_SESSION_ERROR:11001,FREEWHEEL_SDK_MISSING:12E3,FREEWHEEL_INVALID_CONFIGURATION:12001,CONTENT_TRANSFORMATION_FAILED:14E3};_.w(
|
|
380
|
-
_.r.resolve=function(a){var b=new _.
|
|
381
|
-
".."==h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.
|
|
382
|
-
_.
|
|
383
|
-
_.
|
|
384
|
-
"cs"],["dan","da"],["deu","de"],[_.
|
|
389
|
+
EXPIRED:6014,REQUESTED_DRM_ENVIRONMENT_UNAVAILABLE:6015,INIT_DATA_TRANSFORM_ERROR:6016,CERTIFICATE_REQUEST_FAILED:6100,NO_CONTENT_ID:6101,SERVER_CERTIFICATE_REQUIRED:6102,EXTRACT_CONTENT_ID_MODIFIER_ERROR:6103,FAILED_TO_PERSIST_SESSION:6200,FAILED_TO_REMOVE_SESSION:6201,INVALID_SESSION_STORAGE_IMPLEMENTATION:6202,LOAD_INTERRUPTED:7E3,OPERATION_ABORTED:7001,NO_VIDEO_ELEMENT:7002,CANNOT_LOAD_SOURCE:7003,MEDIA_ELEMENT_NOT_FOUND:7004,INVALID_MEDIA_ELEMENT:7005,INVALID_CONTAINER_ELEMENT:7006,INVALID_ARGUMENT:7007,
|
|
390
|
+
WRONG_ORDER_OF_OPERATIONS:7008,NOT_SUPPORTED:7009,INVALID_CONFIGURATION:7100,INVALID_LICENSE:7101,NO_ELEMENT:7102,USER_ID_NOT_PROVIDED:7103,KEY_LOAD_ERROR:7104,TIZEN_INTERNAL_ERROR:7200,CAF_INTERNAL_ERROR:7300,INTERNAL_CAST_ERROR:8E3,CAST_API_NOT_READY:8001,NO_RECEIVERS_AVAILABLE:8002,ALREADY_CASTING:8003,NO_CAST_SESSION:8004,CONVIVA_SDK_NOT_LOADED:9E3,CONVIVA_INVALID_CONFIGURATION:9001,CONVIVA_RUNTIME_ERROR:9002,GL_CONTEXT_ERROR:9003,GL_SHADER_ERROR:9004,YOUBORA_SDK_MISSING:9100,YOUBORA_INVALID_CONFIGURATION:9101,
|
|
391
|
+
YOUBORA_SDK_VERSION_NOT_SUPPORTED:9102,VIMOND_INVALID_CONFIGURATION:9200,VIMOND_SESSION_ERROR:9201,MUXDATA_INVALID_CONFIGURATION:9300,MUX_SDK_MISSING:9301,MUXDATA_INIT_ERROR:9302,IMA_SDK_MISSING:1E4,IMA_INVALID_CONFIGURATION:10001,IMA_UNSUPPORTED_PLATFORM:10002,AD_ERROR:10003,SIMID_CONTAINER_MISSING:10100,BROADPEAK_SDK_MISSING:11E3,BROADPEAK_SESSION_ERROR:11001,FREEWHEEL_SDK_MISSING:12E3,FREEWHEEL_INVALID_CONFIGURATION:12001,CONTENT_TRANSFORMATION_FAILED:14E3};_.w(_.yi,Error);var Ji=/^(?:([^:/?#.]+):)?(?:\/\/(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\?([^#]*))?(?:#(.*))?$/;_.r=_.Ei.prototype;_.r.gb="";_.r.zc="";_.r.Na="";_.r.dd=null;_.r.za="";_.r.kc="";_.r.toString=function(){var a=[],b=this.gb;b&&a.push(Mi(b,Mu,!0),":");if(b=this.Na){a.push("//");var c=this.zc;c&&a.push(Mi(c,Mu,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.dd;null!=b&&a.push(":",String(b))}if(b=this.za)this.Na&&"/"!=b.charAt(0)&&a.push("/"),a.push(Mi(b,"/"==b.charAt(0)?Nu:Ou,!0));(b=this.a.toString())&&a.push("?",b);(b=this.kc)&&a.push("#",Mi(b,Pu));return a.join("")};
|
|
392
|
+
_.r.resolve=function(a){var b=new _.Ei(this);"data"===b.gb&&(b=new _.Ei);var c=!!a.gb;c?Fi(b,a.gb):c=!!a.zc;c?b.zc=a.zc:c=!!a.Na;c?b.Na=a.Na:c=null!=a.dd;var d=a.za;if(c)Gi(b,a.dd);else if(c=!!a.za){if("/"!=d.charAt(0))if(this.Na&&!this.za)d="/"+d;else{var e=b.za.lastIndexOf("/");-1!=e&&(d=b.za.substr(0,e+1)+d)}if(".."==d||"."==d)d="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){e=0==d.lastIndexOf("/",0);d=d.split("/");for(var f=[],g=0;g<d.length;){var h=d[g++];"."==h?e&&g==d.length&&f.push(""):
|
|
393
|
+
".."==h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.za=d:c=""!==a.a.toString();c?_.Hi(b,Ii(a.a)):c=!!a.kc;c&&(b.kc=a.kc);return b};var Mu=/[#\/\?@]/g,Ou=/[#\?:]/g,Nu=/[#\?]/g,Ni=/[#\?@]/g,Pu=/#/g;_.Li.prototype.a=null;_.Li.prototype.h=null;
|
|
394
|
+
_.Li.prototype.add=function(a,b){if(!this.a&&(this.a={},this.h=0,this.f))for(var c=this.f.split("\x26"),d=0;d<c.length;d++){var e=c[d].indexOf("\x3d"),f=null;if(0<=e){var g=c[d].substring(0,e);f=c[d].substring(e+1)}else g=c[d];g=decodeURIComponent(g.replace(/\+/g," "));f=f||"";this.add(g,decodeURIComponent(f.replace(/\+/g," ")))}this.f=null;(c=this.a.hasOwnProperty(a)&&this.a[a])||(this.a[a]=c=[]);c.push(b);null!==this.h&&this.h++;return this};
|
|
395
|
+
_.Li.prototype.toString=function(){if(this.f)return this.f;if(!this.a)return"";var a=[],b;for(b in this.a)for(var c=encodeURIComponent(b),d=this.a[b],e=0;e<d.length;e++){var f=c;""!==d[e]&&(f+="\x3d"+encodeURIComponent(d[e]));a.push(f)}return this.f=a.join("\x26")};var Qi;_.Ri="text";_.Ip={VIDEO:_.Fg,AUDIO:_.bd,TEXT:_.Ri,bn:_.Sc,IMAGE:_.ye,xi:_.kg};_.Qu=1/15;Qi={audio:[/^vorbis$/,/^Opus$/,/^opus$/,/^fLaC$/,/^flac$/,/^mp4a/,/^[ae]c-3$/,/^ac-4/,/^dts[cex]$/,/^iamf/,/^mhm[12]/],video:[/^avc/,/^hev/,/^hvc/,/^vvc/,/^vvi/,/^vp0?[89]/,/^av01/,/^dvh/,/^dva/,/^dav/]};Qi[_.Ri]=[/^vtt$/,/^wvtt/,/^stpp/];var Ti={audio:[/^vorbis$/,/^opus$/,/^flac$/,/^mp4a/,/^[ae]c-3$/],video:[/^avc/,/^hev/,/^hvc/,/^vp0?[89]/,/^av1$/],text:[/^vtt$/,/^wvtt/,/^stpp/]};_.Wi={text:{mp4:Wc,m4s:Wc,m4i:Wc,cmft:Wc,vtt:_.ng,ttml:_.Zc},video:{mp4:_.Hg,m4s:_.Hg,m4i:_.Hg,m4v:_.Hg,cmfv:_.Hg,ts:_.Gg},audio:{mp4:_.fd,m4s:_.fd,m4i:_.fd,m4a:_.fd,cmfa:_.fd,ts:_.Gg,aac:_.cd,ec3:_.ed,ac3:_.dd},image:{jpg:"image/jpeg",jpeg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}};_.Yi.prototype.toString=function(){function a(d){return d.name+"\x3d"+(isNaN(Number(d.value))?'"'+d.value+'"':d.value)}var b="#"+this.name,c=this.attributes?this.attributes.map(a):[];this.value&&c.unshift(this.value);0<c.length&&(b+=":"+c.join(","));return b};_.Yi.prototype.getAttribute=function(a){var b=this.attributes.filter(function(c){return c.name===a});return b.length?b[0]:null};_.bj.prototype.getPosition=function(){return this.position};_.bj.prototype.Ed=function(){return this.ja?this.ja-this.va+1:null};_.bj.prototype.f=Zg(0);_.w(_.cj,_.bj);var fj=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"],["amh","am"],["ara","ar"],["arg","an"],["arm","hy"],["asm","as"],["ava","av"],["ave","ae"],["aym","ay"],["aze","az"],["bak","ba"],["bam","bm"],["baq","eu"],["bel","be"],["ben","bn"],["bih","bh"],["bis","bi"],["bod","bo"],["bos","bs"],["bre","br"],["bul","bg"],["bur","my"],["cat","ca"],["ces","cs"],["cha","ch"],["che","ce"],["chi","zh"],["chu","cu"],["chv","cv"],["cor","kw"],["cos","co"],["cre","cr"],["cym","cy"],["cze",
|
|
396
|
+
"cs"],["dan","da"],["deu","de"],[_.ae,"dv"],["dut","nl"],["dzo","dz"],["ell","el"],["eng","en"],["epo","eo"],["est","et"],["eus","eu"],["ewe","ee"],["fao","fo"],["fas","fa"],["fij","fj"],["fin","fi"],["fra","fr"],["fre","fr"],["fry","fy"],["ful","ff"],["geo","ka"],["ger","de"],["gla","gd"],["gle","ga"],["glg","gl"],["glv","gv"],["gre","el"],["grn","gn"],["guj","gu"],["hat","ht"],["hau","ha"],["heb","he"],["her","hz"],["hin","hi"],["hmo","ho"],["hrv","hr"],["hun","hu"],["hye","hy"],["ibo","ig"],["ice",
|
|
385
397
|
"is"],["ido","io"],["iii","ii"],["iku","iu"],["ile","ie"],["ina","ia"],["ind","id"],["ipk","ik"],["isl","is"],["ita","it"],["jav","jv"],["jpn","ja"],["kal","kl"],["kan","kn"],["kas","ks"],["kat","ka"],["kau","kr"],["kaz","kk"],["khm","km"],["kik","ki"],["kin","rw"],["kir","ky"],["kom","kv"],["kon","kg"],["kor","ko"],["kua","kj"],["kur","ku"],["lao","lo"],["lat","la"],["lav","lv"],["lim","li"],["lin","ln"],["lit","lt"],["ltz","lb"],["lub","lu"],["lug","lg"],["mac","mk"],["mah","mh"],["mal","ml"],["mao",
|
|
386
398
|
"mi"],["mar","mr"],["may","ms"],["mkd","mk"],["mlg","mg"],["mlt","mt"],["mon","mn"],["mri","mi"],["msa","ms"],["mya","my"],["nau","na"],["nav","nv"],["nbl","nr"],["nde","nd"],["ndo","ng"],["nep","ne"],["nld","nl"],["nno","nn"],["nob","nb"],["nor","no"],["nya","ny"],["oci","oc"],["oji","oj"],["ori","or"],["orm","om"],["oss","os"],["pan","pa"],["per","fa"],["pli","pi"],["pol","pl"],["por","pt"],["pus","ps"],["que","qu"],["roh","rm"],["ron","ro"],["rum","ro"],["run","rn"],["rus","ru"],["sag","sg"],["san",
|
|
387
399
|
"sa"],["sin","si"],["slk","sk"],["slo","sk"],["slv","sl"],["sme","se"],["smo","sm"],["sna","sn"],["snd","sd"],["som","so"],["sot","st"],["spa","es"],["sqi","sq"],["srd","sc"],["srp","sr"],["ssw","ss"],["sun","su"],["swa","sw"],["swe","sv"],["tah","ty"],["tam","ta"],["tat","tt"],["tel","te"],["tgk","tg"],["tgl","tl"],["tha","th"],["tib","bo"],["tir","ti"],["ton","to"],["tsn","tn"],["tso","ts"],["tuk","tk"],["tur","tr"],["twi","tw"],["uig","ug"],["ukr","uk"],["urd","ur"],["uzb","uz"],["ven","ve"],["vie",
|
|
388
|
-
"vi"],["vol","vo"],["wel","cy"],["wln","wa"],["wol","wo"],["xho","xh"],["yid","yi"],["yor","yo"],["zha","za"],["zho","zh"],["zul","zu"]]);var
|
|
389
|
-
_.H("clpp.utils.strings.fromUtf8",_.R.
|
|
390
|
-
_.R.
|
|
391
|
-
_.R.
|
|
392
|
-
};_.H("clpp.utils.strings.fromBytesAutoDetect",_.R.
|
|
393
|
-
_.R.
|
|
394
|
-
_.H("clpp.utils.strings.endsWith",_.R.endsWith);_.R.
|
|
395
|
-
_.R.
|
|
396
|
-
_.R.
|
|
397
|
-
_.R.
|
|
398
|
-
b))?Number(a.value):c},
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
c){return b+c},0)},
|
|
406
|
-
yc:a}:{delay:3*a,yc:a}},
|
|
407
|
-
d=_.Y.
|
|
408
|
-
width:
|
|
409
|
-
g);var h=_.
|
|
410
|
-
c.value,c.name.startsWith("X-")&&(a[c.name]=c.value);return _.
|
|
411
|
-
null):_.
|
|
412
|
-
_.
|
|
413
|
-
_.r.fetch=function(a){var b=this;if(this.o)return new
|
|
414
|
-
d.next())c.push(e.value);a.responseModifiers=c;d=c=new _.
|
|
415
|
-
n.toString());p=b.a[p];if(!p)throw new _.P(_.Q,1,1E3,{url:n.toString()});return{request:m,plugin:p}});var h=new
|
|
416
|
-
if(p&&p.then)return p.then(function(){return Promise.reject(n)})}return Promise.reject(n)}}(g))["catch"](function(m){if(m instanceof _.P)throw m;throw new _.P(_.Q,1,1007,null,m);});_.
|
|
417
|
-
_.
|
|
418
|
-
_.
|
|
419
|
-
h.message);case 6:return _.A(n,9),_.x(n,
|
|
420
|
-
_.r.
|
|
421
|
-
_.U.prototype.findVideoRendition=_.U.prototype.
|
|
422
|
-
_.U.prototype.getAudioTrack=_.U.prototype.
|
|
423
|
-
_.U.prototype.getVideoTracks=_.U.prototype.getVideoTracks;_.U.prototype.canSelectVideoTracks=_.U.prototype.
|
|
424
|
-
_.
|
|
425
|
-
var
|
|
400
|
+
"vi"],["vol","vo"],["wel","cy"],["wln","wa"],["wol","wo"],["xho","xh"],["yid","yi"],["yor","yo"],["zha","za"],["zho","zh"],["zul","zu"]]);var mj=function Ru(a){var c;return _.wh(Ru,function(d){1==d.a&&(c=0);if(3!=d.a)return c<a?_.x(d,c,3):d.F(0);c++;return d.F(2)})};_.H("clpp.utils.BufferUtils",jj);jj.toArrayBuffer=tj;jj.toDataView=_.sj;jj.toInt32Array=_.rj;jj.toUint32Array=qj;jj.toUint16Array=pj;jj.toUint8Array=_.lj;jj.equal=nj;_.R={};_.R.Zc=new _.K("clpp.utils.strings");_.R.si=16E3;_.R.fromCharCode=function(a){for(var b=_.R.si,c="",d=0;d<a.length;d+=b)c+=String.fromCharCode.apply(null,a.subarray(d,d+b));return c};_.R.aa=function(a){if(!a)return"";a=_.lj(a);239===a[0]&&187===a[1]&&191===a[2]&&(a=a.subarray(3));if("TextDecoder"in window){a=(new TextDecoder).decode(a);if(a.includes("\ufffd"))throw Error(Ya);return a}a=escape(_.R.fromCharCode(a));try{return decodeURIComponent(a)}catch(b){throw Error(Ya);}};
|
|
401
|
+
_.H("clpp.utils.strings.fromUtf8",_.R.aa);
|
|
402
|
+
_.R.lc=function(a,b,c){if(!a)return"";var d=_.R.Zc;if(!c&&0!==a.byteLength%2)throw d.error("Data has an incorrect length, must be even."),Error("Data does not seem to be UTF-16 encoded!");c=_.lj(a);if(b&&255===c[0]&&254===c[1]||254===c[0]&&255===c[1])a=c.subarray(2);a instanceof ArrayBuffer?d=a:(c=new Uint8Array(a.byteLength),c.set(_.lj(a)),d=c.buffer);a=Math.floor(a.byteLength/2);c=new Uint16Array(a);d=new DataView(d);for(var e=0;e<a;e++)c[e]=d.getUint16(2*e,b);return _.R.fromCharCode(c)};
|
|
403
|
+
_.R.zd=function(a,b){if(_.O.ca(a))return a;var c="",d=!!b,e=_.lj(a);239===e[0]&&187===e[1]&&191===e[2]?c=_.R.aa(e):254===e[0]&&255===e[1]?c=_.R.lc(e.subarray(2),!1):255===e[0]&&254===e[1]&&(c=_.R.lc(e.subarray(2),!0));var f=function(g,h){return g.byteLength<=h||32<=g[h]&&126>=g[h]}.bind(null,e);_.R.Zc.debug("Unable to find byte-order-mark, making an educated guess.");0===e[0]&&0===e[2]?c=_.R.lc(a,!1):0===e[1]&&0===e[3]?c=_.R.lc(a,!0):f(0)&&f(1)&&f(2)&&f(3)&&(c=_.R.aa(a));if(c)return d&&(c=escape(c)),
|
|
404
|
+
c;throw Error("Unable to detect text encoding");};_.H("clpp.utils.strings.fromBytesAutoDetect",_.R.zd);_.R.Ua=function(a){if("TextEncoder"in window)return(new TextEncoder).encode(a);a=encodeURIComponent(a);a=unescape(a);for(var b=new Uint8Array(a.length),c=0;c<a.length;++c)b[c]=a.charCodeAt(c);return b};_.H("clpp.utils.strings.toUtf8",_.R.Ua);_.R.Le=function(a,b){for(var c=new Uint8Array(2*a.length),d=new DataView(c.buffer),e=0;e<a.length;++e)d.setUint16(2*e,a.charCodeAt(e),b);return c.buffer};
|
|
405
|
+
_.H("clpp.utils.strings.toUtf16",_.R.Le);_.R.gd=function(a,b){var c=b||1,d=a.length,e=new ArrayBuffer(d*c),f;4===c?f=qj(e):2===c?f=pj(e):f=_.lj(e);for(c=0;c<d;c++)f[c]=a.charCodeAt(c);return e};_.H("clpp.utils.strings.toByteArray",_.R.gd);_.R.startsWith=function(a,b){return String.prototype.startsWith?a.startsWith(b):0===a.indexOf(b)};_.H("clpp.utils.strings.startsWith",_.R.startsWith);
|
|
406
|
+
_.R.endsWith=function(a,b){if(String.prototype.endsWith)return a.endsWith(b);var c=a.length-b.length,d=a.lastIndexOf(b,c);return-1!==d&&d===c};_.H("clpp.utils.strings.endsWith",_.R.endsWith);_.R.Ae=function(a){return!!(a&&0<a.length)};_.R.empty=function(a){return!a||0===a.length};_.R.xn=function(a){return a.replace(/([A-Z])/g,"-$1").toLowerCase()};_.R.An=function(a){return a.replace(/-(\w)/g,function(b,c){return c.toUpperCase()})};
|
|
407
|
+
_.R.df=function(a){if(void 0===a||null===a||""===a)return"";try{var b=Number(a);if(_.O.isNaN(b))return"";a="bps";1E3<=Math.abs(b)&&(a="Kbps",b/=1E3);1E3<=Math.abs(b)&&(a="Mbps",b/=1E3);return b.toFixed(2).replace(/[.,]00$/,"")+a}catch(c){return""}};_.H("clpp.utils.strings.bitrateToString",_.R.df);
|
|
408
|
+
_.R.dk=function(a,b){function c(h){return function(l,m){return d(h,m.length-1)}}function d(h,l){return h.length<l?d("0"+h,l):h}b=void 0===b?"%h:%mm:%ss":b;if(null===a||void 0===a)a=0;if(null===b||void 0===b)b="%h:%mm:%ss";var e=Math.floor(a/3600),f=Math.floor((a-3600*e)/60),g=Math.floor(a-3600*e-60*f);return b.replace(/(%h+)/,c(String(e))).replace(/(%m+)/,c(String(f))).replace(/(%s+)/,c(String(g)))};_.H("clpp.utils.strings.durationToString",_.R.dk);
|
|
409
|
+
_.R.fk=function(a,b){for(var c in b)if(b[c]===a)return c;return""};_.R.Pk=function(a){var b=0;if(0===a.length)return b;for(var c=0;c<a.length;c++)b=(b<<5)-b+a.charCodeAt(c),b|=0;return b};_.H("clpp.utils.strings.hashCode",_.R.Pk);_.R.Vm=function(a){_.R.di.innerHTML=a;return _.R.di.textContent};_.R.di=document.createElement("span");_.R.ag=function(a){a=a.replace(/<[^>]+>/gi,"");a=_.R.Vm(a);return a=a.replace(/<[^>]+>/gi,"")};_.R.Ah=function(a){return a.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n")};_.H("clpp.utils.Uint8ArrayUtils",uj);uj.toStandardBase64=_.vj;uj.concat=Bj;uj.equal=_.Aj;uj.toHex=_.zj;uj.fromHex=_.yj;uj.fromBase64=_.xj;uj.toBase64Url=_.wj;_.Y={Rb:function(a,b){return a.filter(function(c){return c.name===b})},sf:function(a,b){var c=Array.isArray(b)?b:[b];return a.filter(function(d){d=_.$i(d,_.dc);return c.includes(d)})},Xb:function(a,b){return a.some(function(c){return c.name===b})},Pa:function(a,b,c){c=void 0===c?{}:c;a=a.find(function(d){return d.name===b})||null;if(!a&&c.required)throw new _.P(_.Q,4,4024,{missingTag:b});return a},hh:function(a,b){return _.Y.Pa(a,b,{required:!0})},zk:function(a,b,c){c=void 0===c?0:c;return(a=_.Y.Pa(a,
|
|
410
|
+
b))?Number(a.value):c},En:function(a,b,c){return a.filter(function(d){var e=d.getAttribute(_.dc);d=d.getAttribute(_.eb);return e.value===b&&d.value===c})},om:function(a){var b=_.Y.Pa(a,"EXT-X-TILES");if(!b)return{Fd:1,Zd:1,durationPerTile:null};a=_.Zi(b,"LAYOUT")||"1x1";b=_.Zi(b,_.Fa);a=_.hj(a);return{Fd:a.Fd,Zd:a.Zd,durationPerTile:b?Number(b):null}},sd:function(a,b){return _.Pi([a],[b])[0]},qh:function(a){return/^#(?!EXT)/m.test(a)},wh:function(a,b){Array.isArray(a)||(a=[a]);a.forEach(function(c){for(var d=
|
|
411
|
+
_.t(_.Y.Je(c)),e=d.next();!e.done;e=d.next())b(e.value,c)})},Je:function(a){var b=new Set;a.variants.forEach(function(c){c.audio&&b.add(c.audio);c.video&&b.add(c.video)});a.textStreams.forEach(function(c){return b.add(c)});a.thumbStreams.forEach(function(c){return b.add(c)});return Array.from(b)},Qk:function(a){return a.some(function(b){return _.Y.Xb(b.X,Ma)})},Gi:function(a){return _.Y.Je(a).filter(_.Y.oh)},nm:function(a,b){var c=_.Y.Pa(a,Ma);if(b&&c)return _.oc;c=_.Y.Pa(a,Sa);if(!c)return"LIVE";
|
|
412
|
+
if(c.value===_.oc)return _.oc;if("EVENT"===c.value)return"EVENT";throw new _.P(_.Q,4,4044,"Invalid EXT-X-PLAYLIST-TYPE value: "+c.value);},Kg:function(a){a={AUDIO:_.bd,VIDEO:_.Fg,SUBTITLES:_.Ri,"CLOSED-CAPTIONS":_.Ri}[a.toUpperCase()];if(!a)throw new _.P(_.Q,4,4044,"EXT-X-MEDIA tag has an invalid TYPE attribute.");return a},Vj:function(a){var b=_.$i(a,_.dc).toUpperCase();if(_.Y.Kg(b)!==_.Ri)return null;a=a.getAttribute("FORCED");a=!(!a||!a.value||"YES"!==a.value.toUpperCase());var c=_.kg;b===_.ra&&
|
|
413
|
+
(c=_.pd);a&&(c=_.se);return c},Qh:function(a,b,c){c=void 0===c?!1:c;var d=0,e=null;if(a){d=a.split("@");a=Number(d[0]);if(0>=a)throw new _.P(_.Q,4,4044,"Byte range length must be positive.");if(d[1]){if(d=Number(d[1]),0>d)throw new _.P(_.Q,4,4044,"Byte range start byte must not be negative.");}else{if(c)throw new _.P(_.Q,4,4044,"Invalid byte range, offset is required but missing.");if(null==b)throw new _.P(_.Q,4,4044,"Invalid byte range, cannot calculate offset based on previous byte ranges.");d=
|
|
414
|
+
b+1}e=d+a-1}return{va:d,ja:e}},Sh:function(a,b){var c=_.Y.Pa(a,Ia);return _.Y.Qh(c?c.value:null,b)},im:function(a){a=_.Y.hh(a,"EXTINF").value.split(",");return{duration:Number(a[0]),title:a[1]||null}},Th:function(a,b){function c(f){return null==f?null:Number(f)}b=void 0===b?{}:b;var d={ke:!1,Ki:!1,Li:null,Rk:null,Uh:null},e=_.Y.Pa(a,Va,{required:b.ai});if(!e)return d;d.ke="YES"===_.Zi(e,"CAN-BLOCK-RELOAD");d.Ki="YES"===_.Zi(e,"CAN-SKIP-DATERANGES");d.Li=c(_.Zi(e,"CAN-SKIP-UNTIL"));d.Rk=c(_.Zi(e,"HOLD-BACK"));
|
|
415
|
+
d.Uh=c(_.Zi(e,"PART-HOLD-BACK",void 0,{required:b.ai}));return d},Rh:function(a,b,c){c=void 0===c?!1:c;a=_.Zi(a,"BYTERANGE");return _.Y.Qh(a,b,c)},lm:function(a){var b=_.Y.Rb(a,"EXT-X-MEDIA"),c=_.Y.Rb(a,_.Wa);a=_.Y.Rb(a,"EXT-X-IMAGE-STREAM-INF");return{$c:{Ei:_.Y.sf(b,["AUDIO",_.nc]),closedCaptions:_.Y.sf(b,_.ra),Pm:_.Y.sf(b,_.Vb)},$d:c,yf:a}},Yj:function(a,b){var c=_.Y.Sh(a.X,null);return new _.cj(0,0,0,function(){return[a.a]},c.va,c.ja,0,b)},vf:function(a,b){if(null==a)return null;var c=Object.assign({},
|
|
416
|
+
a);null==c.iv&&(c.iv=Bj(new Uint8Array(12),new Uint8Array([b>>24&255,b>>16&255,b>>8&255,b&255])));return c},Ik:function(a){var b=a.S;a=b[0].startTime;b=b[b.length-1].endTime;return{Zb:a,ye:b,duration:b-a}},Ek:function(a){var b=Infinity,c=Infinity;_.Y.Gi(a).forEach(function(d){d=_.Y.Ik(d);b=Math.min(b,d.Zb);c=Math.min(c,d.duration)});return{Zb:b,duration:c}},oh:function(a){return a.type===_.bd||a.type===_.Fg},gk:function(a){return a.filter(_.Y.oh)},Dk:function(a){return a.map(function(b){return _.Y.Ek(b).duration}).reduce(function(b,
|
|
417
|
+
c){return b+c},0)},vk:function(a,b){return a&&b?_.To(a.drmInfos,b.drmInfos)?_.So(a.drmInfos,b.drmInfos):null:a?a.drmInfos:b?b.drmInfos:null},Zj:function(a,b){return(b?b.Vb():"")+" - "+(a?a.Vb():"")},Mg:function(a){return(a.video?a.video.Kb:"")+" - "+(a.audio?a.audio.Kb:"")},km:function(a,b,c,d){if(b===_.oc)return{delay:0,yc:0};b=_.Y.Pa(a,Ra);if(c&&b)return c=Number(_.$i(b,"PART-TARGET")),null!=d?{delay:d,yc:c}:{delay:_.Y.Th(a,{ai:!0}).Uh,yc:c};a=_.Y.hh(a,Xa);a=Number(a.value);return null!=d?{delay:d,
|
|
418
|
+
yc:a}:{delay:3*a,yc:a}},Ck:function(a){var b=[];_.Y.wh(a,function(c){b.push(c.el)});return{delay:Math.max.apply(Math,_.ah(b.map(function(c){return c.delay}))),yc:Math.min.apply(Math,_.ah(b.map(function(c){return c.yc})))}},Sm:function(a){var b=new Map;a.forEach(function(c){var d=c.Ak();b.has(d)?(d=b.get(d),d.includes(c)||d.push(c)):b.set(d,[c])});return b},eh:function(a){return _.dj(a||_.vg)},em:function(a){var b=new Map;a=_.t(a);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=_.Zi(c,_.tb);
|
|
419
|
+
d=_.Y.eh(d);var e=_.$i(c,_.eb);c=_.$i(c,"INSTREAM-ID");b.has(e)||b.set(e,new Map);b.get(e).set(c,d)}return b},ck:function(a){a=_.t(a.audio.concat(a.video));for(var b=a.next();!b.done;b=a.next()){b=b.value;var c=b.uk().filter(function(d){return"mp4a.40.34"!==d});b.Fm(c)}},pm:function(a){if(null==a.getAttribute("FRAME-RATE")&&null==a.getAttribute(_.Sb))return null;var b=_.Zi(a,"FRAME-RATE");a=_.Zi(a,_.Sb);var c=_.t(a?a.split("x"):[null,null]);a=c.next().value;c=c.next().value;return{frameRate:gj(b),
|
|
420
|
+
width:gj(a),height:gj(c)}},al:function(a){return"EXT-X-MEDIA"!==a.name?!0:_.Zi(a,_.dc)===_.Vb},fm:function(a,b){var c=_.Zi(a,"ID"),d=_.Zi(a,"START-DATE");if(null===c||null===d)return _.Y.g.warn("Invalid EXT-X-DATERANGE missing mandatory ID or START-DATE attribute, ignoring the EXT-X-DATERANGE tag.",a),null;var e=new Date(d);d=e.getTime()/1E3-b;c={id:c,startTime:d,startDate:e};var f=gj(_.Zi(a,_.Fa));void 0!==f&&0<=f&&(c.duration=f);var g=gj(_.Zi(a,"PLANNED-DURATION"));void 0!==g&&0<=g&&(c.plannedDuration=
|
|
421
|
+
g);var h=_.Zi(a,"CLASS");null!==h&&(c.schemeIdUri=h);var l=_.Zi(a,"END-DATE");l=l?new Date(l):null;null!==l&&l.getTime()>=e.getTime()&&(c.endDate=l);e=_.Y.dm(a)||{};if(h===Qd){h=_.Y.jm(a);if(null===h)return _.Y.g.warn("Invalid interstitial attributes, ignoring the EXT-X-DATERANGE tag.",a),null;e=Object.assign(e,h)}_.O.Hd(e)&&(c.Wa=e);c.endTime=l?l.getTime()/1E3:f?d+f:g?d+g:d;c.type=Su;return c},dm:function(a){var b=a.attributes;if(null==b)return null;a={};b=_.t(b);for(var c=b.next();!c.done;c=b.next())c=
|
|
422
|
+
c.value,c.name.startsWith("X-")&&(a[c.name]=c.value);return _.O.Hd(a)?a:null},jm:function(a){var b=a.attributes;if(null==b)return null;a={};b=_.t(b);for(var c=b.next();!c.done;c=b.next())switch(c=c.value,c.name){case uc:a[uc]=c.value;break;case tc:a[tc]=c.value;break;case wc:a[wc]=gj(c.value);break;case vc:a[vc]=gj(c.value);break;case "X-SNAP":a["X-SNAP"]=c.value.split(",");break;case "X-RESTRICT":a["X-SNAP"]=c.value.split(",")}return a[uc]&&a[tc]||!a[uc]&&!a[tc]?(_.Y.g.warn("Invalid EXT-X-DATERANGE Interstitial attributes X-ASSET-URI, X-ASSET-LIST"),
|
|
423
|
+
null):_.O.Hd(a)?a:null},Vg:function(a,b){if(!a)return null;var c=a.Kb;return b.find(function(d){return d.Vb()===c})||null}};_.Y.g=new _.K("clpp.hls.Utils");_.Tu=new Set([_.La,Ma,"EXT-X-I-FRAMES-ONLY",_.Qa,Ra,Sa,Va,Xa]);_.Uu=new Set(["EXTINF",Ia,_.Ka,_.Na,_.Oa,_.Ua]);_.Vu=new Set(["EXT-X-PART",_.Ta]);_.Wu=new Set([_.Ja]);var Fj=[403,401];_.H("clpp.net.DEFAULT_FATAL_STATUS_CODES",Fj);_.H("clpp.net.makeRequest",_.Jj);_.Ij=6;_.H("clpp.net.RequestType",{MANIFEST:1,SEGMENT:2,LICENSE:3,APP:4,TIMING:5,OTHER:_.Ij});_.Oj.prototype.resolve=function(){};_.Oj.prototype.reject=function(){};_.Pj.prototype.abort=function(){this.a=!0;return this.A()};_.Pj.prototype.le=function(a,b){function c(){e.reject(new _.P(_.Q,7,7001));return d.abort()}var d=this,e=new _.Oj;this.P.then(function(f){d.a?e.reject(new _.P(_.Q,7,7001)):a?c=Rj(a,f,e):e.resolve(f)},function(f){b?c=Rj(b,f,e):e.reject(f)});return new _.Pj(e,function(){return c()})};_.Pj.aborted=function(){var a=Promise.reject(new _.P(_.Q,7,7001));a["catch"](function(){});return new _.Pj(a,function(){return Promise.resolve()})};
|
|
424
|
+
_.Pj.prototype.chain=_.Pj.prototype.le;_.Sj.prototype.destroy=function(){for(var a=[],b=_.t(this.a),c=b.next();!c.done;c=b.next())c=c.value,c.P["catch"](function(){}),a.push(c.abort());this.a=[];return Promise.all(a)};_.r=_.ck.prototype;_.r.Km=function(a){0<a?_.J("Rate limit set to "+a+"bps"):_.J("Rate limit disabled");this.j=a};_.r.release=function(){return this.l.destroy()};_.r.destroy=function(){this.o=!0;this.f=[];this.h=[];return this.l.destroy()};_.r.lg=function(a){this.f.push(a)};_.r.ld=function(a){this.h.push(a)};_.r.Yh=function(a){this.f=this.f.filter(function(b){return b!==a})};_.r.Ie=function(a){this.h=this.h.filter(function(b){return b!==a})};
|
|
425
|
+
_.r.fetch=function(a){var b=this;if(this.o)return new Pt(Promise.reject(new _.P(1,1,7001,{url:a.uris[a.uriIndex],request:a})));this.j&&0<this.j&&(a.rateLimitBps=this.j);for(var c=[],d=_.t(this.f),e=d.next();!e.done;e=d.next())c.push(e.value);if(a.requestModifiers)for(d=_.t(a.requestModifiers),e=d.next();!e.done;e=d.next())c.push(e.value);a.requestModifiers=c;c=[];d=_.t(this.h);for(e=d.next();!e.done;e=d.next())c.push(e.value);if(a.responseModifiers)for(d=_.t(a.responseModifiers),e=d.next();!e.done;e=
|
|
426
|
+
d.next())c.push(e.value);a.responseModifiers=c;d=c=new _.Oj;try{var f={},g=_.t(a.requestModifiers);for(e=g.next();!e.done;f={Ue:f.Ue},e=g.next())f.Ue=e.value,d=d.then(function(m){return function(n){if(h.a)throw new _.P(_.Q,1,7001,n?{url:n.uris[n.uriIndex],request:n}:null);return m.Ue(n)||n}}(f))["catch"](function(m){if(m instanceof _.P)throw m;throw new _.P(_.Q,1,1006,null,m);});d=d.then(function(m){var n=new _.Ei(m.uris[m.uriIndex]),p=n.gb;p||(p=location.protocol,p=p.slice(0,-1),Fi(n,p),m.uris[m.uriIndex]=
|
|
427
|
+
n.toString());p=b.a[p];if(!p)throw new _.P(_.Q,1,1E3,{url:n.toString()});return{request:m,plugin:p}});var h=new Pt(d);g={};var l=_.t(a.responseModifiers);for(e=l.next();!e.done;g={de:g.de},e=l.next())g.de=e.value,h.then(function(m){return function(n){function p(){if(h.a)throw new _.P(_.Q,1,7001,n?{url:n.request.uris[n.request.uriIndex],request:n.request}:null);}p();var q=m.de(n)||n;p();return q}}(g))["catch"](function(m){return function(n){if(n instanceof _.P&&n.data&&n.data.response){var p=m.de(n.data.response);
|
|
428
|
+
if(p&&p.then)return p.then(function(){return Promise.reject(n)})}return Promise.reject(n)}}(g))["catch"](function(m){if(m instanceof _.P)throw m;throw new _.P(_.Q,1,1007,null,m);});_.Tj(this.l,h);c.resolve(a);return h}catch(m){return new Pt(Promise.reject(m))}};_.H("clpp.net.NetworkEngine",_.ck);_.ck.prototype.fetch=_.ck.prototype.fetch;_.ck.prototype.removeResponseModifier=_.ck.prototype.Ie;_.ck.prototype.removeRequestModifier=_.ck.prototype.Yh;_.ck.prototype.addResponseModifier=_.ck.prototype.ld;
|
|
429
|
+
_.ck.prototype.addRequestModifier=_.ck.prototype.lg;_.ck.prototype.setRateLimit=_.ck.prototype.Km;var kk;_.gk.prototype.ka=function(a){return this.type===a.type&&this.channelsCount===a.channelsCount&&this.frameRate===a.frameRate&&this.trickPlay===a.trickPlay&&this.kind===a.kind&&this.label===a.label&&this.language===a.language&&this.mimeType===a.mimeType&&ji(this.roles,a.roles)&&ji(this.accessibility,a.accessibility,ok)};_.gk.prototype.toString=function(){return"Track type: "+this.type+" id: "+this.id+"\n renditions size: "+this.renditions.length};_.H("clpp.Track",_.gk);
|
|
430
|
+
_.gk.prototype.toString=_.gk.prototype.toString;_.H("clpp.Rendition",_.pk);_.mk=1;_.jk=_.Fg;_.ik=_.bd;_.T="text";kk=_.Qe;_.Xu={VIDEO:_.jk,AUDIO:_.ik,TEXT:_.T,METADATA:kk};_.gk.Type=_.Xu;_.H("clpp.utils.url.queryString",_.sk);vk.prototype.h=function(a,b){var c=this,d,e,f,g,h,l,m;return _.E(function(n){switch(n.a){case 1:return d=null,_.A(n,2),_.x(n,Bk(c,a),4);case 4:d=n.f;_.oh(n,3);break;case 2:return e=_.C(n),c.g.warn("Failed to fetch playlist in order metadata from HLS playlist.",e.message),n["return"](Promise.resolve({}));case 3:f={};_.A(n,5);if(!b.enableHlsVideoTrackInfo){n.F(7);break}return _.x(n,yk(c,d,a),8);case 8:g=n.f,f.renditions=g.renditions,f.mimeType=g.mimeType;case 7:_.oh(n,6);break;case 5:h=_.C(n),c.g.warn("Failed to parse video metadata from HLS playlist.",
|
|
431
|
+
h.message);case 6:return _.A(n,9),_.x(n,Ak(d),11);case 11:l=n.f;f.$c=l;_.oh(n,10);break;case 9:m=_.C(n),c.g.warn("Failed to parse metadata from HLS playlist.",m.message);case 10:return n["return"](f)}})};_.Hk=[];_.r=_.U.prototype;_.r.gf=function(){return!0};_.r.mk=function(a){return this.getVideoTracks().find(function(b){return _.O.ka(b,a,a&&Object.keys(a))})};_.r.ik=function(a){return this.getAudioTracks().find(function(b){return _.O.ka(b,a,a&&Object.keys(a))})};_.r.kk=function(a){return this.ha().find(function(b){return _.O.ka(b,a,a&&Object.keys(a))})};_.r.lk=function(a){return this.getVideoTracks().flatMap(function(b){return b.renditions}).find(function(b){return _.O.ka(b,a,a&&Object.keys(a))})};
|
|
432
|
+
_.r.hk=function(a){return this.getAudioTracks().flatMap(function(b){return b.renditions}).find(function(b){return _.O.ka(b,a,a&&Object.keys(a))})};_.r.jk=function(a){return this.ha().flatMap(function(b){return b.renditions}).find(function(b){return _.O.ka(b,a,a&&Object.keys(a))})};_.H("clpp.TrackManager",_.U);_.U.prototype.isAbrEnabled=_.U.prototype.pa;_.U.prototype.addTextTrack=_.U.prototype.addTextTrack;_.U.prototype.findTextRendition=_.U.prototype.jk;_.U.prototype.findAudioRendition=_.U.prototype.hk;
|
|
433
|
+
_.U.prototype.findVideoRendition=_.U.prototype.lk;_.U.prototype.findTextTrack=_.U.prototype.kk;_.U.prototype.findAudioTrack=_.U.prototype.ik;_.U.prototype.findVideoTrack=_.U.prototype.mk;_.U.prototype.setTextRendition=_.U.prototype.ib;_.U.prototype.setAudioRendition=_.U.prototype.hb;_.U.prototype.setVideoRendition=_.U.prototype.Ya;_.U.prototype.setTextTrack=_.U.prototype.Ja;_.U.prototype.setAudioTrack=_.U.prototype.xa;_.U.prototype.setVideoTrack=_.U.prototype.jb;_.U.prototype.getTextTrack=_.U.prototype.ta;
|
|
434
|
+
_.U.prototype.getAudioTrack=_.U.prototype.la;_.U.prototype.getVideoTrack=_.U.prototype.Ha;_.U.prototype.getLoadingTextRendition=_.U.prototype.nb;_.U.prototype.getLoadingAudioRendition=_.U.prototype.mb;_.U.prototype.getLoadingVideoRendition=_.U.prototype.cb;_.U.prototype.getTextRendition=_.U.prototype.Ga;_.U.prototype.getAudioRendition=_.U.prototype.Oa;_.U.prototype.getVideoRendition=_.U.prototype.ma;_.U.prototype.getTextTracks=_.U.prototype.ha;_.U.prototype.getAudioTracks=_.U.prototype.getAudioTracks;
|
|
435
|
+
_.U.prototype.getVideoTracks=_.U.prototype.getVideoTracks;_.U.prototype.canSelectVideoTracks=_.U.prototype.gf;var Lk=new Map,Kk=1,Pk=2,Ok=3,Nk=4;_.Yu=(new Map).set(_.Md,_.Md).set("frameRate","framerate").set("bandwidth","bitrate").set(_.Ug,_.Ug).set(_.ve,_.ve).set("channelsCount","channels");_.Tk.prototype.da=function(a){return Uk(this,a,!1)};_.Tk.prototype.kb=function(a){return Uk(this,a,!0)};_.Tk.prototype.stop=function(){this.a&&(this.a(),this.a=null)};_.Vk.prototype.dg=function(){this.stop();this.f();return this};_.Vk.prototype.da=function(a){var b=this;this.stop();this.a=(new _.Tk(function(){b.f()})).da(a);return this};_.Vk.prototype.kb=function(a){var b=this;this.stop();this.a=(new _.Tk(function(){b.f()})).kb(a);return this};_.Vk.prototype.stop=function(){this.a&&(this.a.stop(),this.a=null)};_.H("clpp.utils.Timer",_.Vk);_.Vk.prototype.stop=_.Vk.prototype.stop;_.Vk.prototype.tickEvery=_.Vk.prototype.kb;_.Vk.prototype.tickAfter=_.Vk.prototype.da;
|
|
436
|
+
_.Vk.prototype.tickNow=_.Vk.prototype.dg;_.H(Ld,Wk);Wk.getInfo=_.Zj;
|
|
437
|
+
var gl=null,fl=null,il=new _.K(Ld),pl="android",ol="ios",ul="linux",ql="osx",rl="windows",sl="tizen",tl="webos",nl=wg,xl=wg,wl={windows:{os_version:/windows\s+?nt\s([\d.]+)/i,ie:/windows\s+?nt.+?trident\/[\d.]+.*rv:([\d.]+)/i,edge:/windows\s+?nt.+?edge?\/([\d.]+)/i,chrome:/windows\s+?nt.+?chrome\/([\d.]+)/i,firefox:/windows\s+?nt.+?firefox\/([\d.]+)/i,opera:/windows\s+?nt.+?opr\/([\d.]+)/i},osx:{os_version:/macintosh.+?([\d._]+)/i,safari:/macintosh.+?version\/([\d._]+).+?safari/i,edge:/macintosh.+?edge?\/([\d._]+)/i,
|
|
426
438
|
chrome:/macintosh.+?chrome\/([\d._]+)/i,firefox:/macintosh.+?firefox\/([\d._]+)/i,opera:/macintosh.+?opr\/([\d._]+)/i},unknown:{ie:/.+?trident\/([\d.]+)/i,edge:/.+?edge?\/([\d.]+)/i,safari:/.+?version\/([\d._]+).+?safari/i,chrome:/.+?chrome\/([\d._]+)/i,firefox:/.+?firefox\/([\d._]+)/i,opera:/.+?opr\/([\d._]+)/i},android:{os_version:/android.+?([\d._]+)/i,chrome:/android.+?chrome\/([\d._]+)/i,firefox:/android.+?firefox\/([\d._]+)/i,opera:/android.+?opr\/([\d._]+)/i},ios:{os_version:/(?:iPad|iPhone).+?([\d._]+)/i,
|
|
427
439
|
chrome:/.+?CriOS\/([\d._]+)/i,firefox:/.+?FxiOS\/([\d._]+)/i,safari:/.+?version\/([\d._]+).+?safari/i,opera:/.+?opr\/([\d._]+)/i},linux:{os_version:/linux.+?([\d._]+)/i,safari:/linux.+?version\/([\d._]+).+?safari/i,chrome:/linux.+?chrome\/([\d._]+)/i,firefox:/linux.+?firefox\/([\d._]+)/i,opera:/linux.+?opr\/([\d._]+)/i},tizen:{os_version:/tizen.+?([\d._]+)/i,safari:/linux.+?version\/([\d._]+).+?safari/i,chrome:/linux.+?chrome\/([\d._]+)/i,firefox:/linux.+?firefox\/([\d._]+)/i,opera:/linux.+?opr\/([\d._]+)/i},
|
|
428
|
-
webos:{os_version:/linux.+?([\d._]+)/i,safari:/linux.+?version\/([\d._]+).+?safari/i,chrome:/linux.+?chrome\/([\d._]+)/i,firefox:/linux.+?firefox\/([\d._]+)/i,opera:/linux.+?opr\/([\d._]+)/i}};_.w(
|
|
429
|
-
_.r.
|
|
430
|
-
n.kind&&"captions"===n.kind&&(n.mimeType=_.
|
|
431
|
-
|
|
432
|
-
_.r.
|
|
433
|
-
_.r.
|
|
434
|
-
_.r.load=function(){this.A=!1;var a=
|
|
435
|
-
_.r.getVideoTracks=function(){return
|
|
436
|
-
_.r.mb=function(){return
|
|
437
|
-
_.r.addTextTrack=function(a){var b=this,c;return _.E(function(d){return a.mimeType.match(/text\/vtt/)?(c="External_"+b.B++,b.o[c]=a,
|
|
438
|
-
_.r.
|
|
439
|
-
|
|
440
|
-
|
|
440
|
+
webos:{os_version:/linux.+?([\d._]+)/i,safari:/linux.+?version\/([\d._]+).+?safari/i,chrome:/linux.+?chrome\/([\d._]+)/i,firefox:/linux.+?firefox\/([\d._]+)/i,opera:/linux.+?opr\/([\d._]+)/i}};_.w(yl,_.U);_.r=yl.prototype;_.r.gf=function(){return!_.bl()};
|
|
441
|
+
_.r.Mf=function(a,b){var c=this,d,e,f,g,h,l,m,n,p,q,u,v,z,B,I,F,D,G;return _.E(function(M){if(1==M.a){if(!b)return c.g.warn(Bb),M["return"]();d=b.track;if(!d)return c.g.warn(Eb),M["return"]();e=a===_.ik;f=a===_.jk;g=a===_.T;h=e||f;l=b.target;if(m=c.h.find(function(N){return Ml(N,d,a)}))return c.g.warn("Track from event already exists",d,m),M["return"]();n=nk(a,d);p=Ql(d);if(g){if(d.kind===_.Qe)return M["return"]();void 0!==d.id?q=c.o[d.id]:(u=Object.values(c.o),q=u.find(function(N){return Ml(n,N,
|
|
442
|
+
a)}));n.kind&&"captions"===n.kind&&(n.mimeType=_.Tc);q&&(n.src=q.url,n.mimeType=q.mimeType)}else if(m=c.h.find(function(N){return N.type===a&&_.O.ka(N,n,["kind","label","language"])}))return m.id=d.id,p&&(c.g.debug(Zb+a+" track active"),c.a.set(a,m)),c.g.debug("Track from event seems to already exists, flipped native track to",d),M["return"]();_.A(M,2);v=new _.pk(n.id,n);n.renditions.push(v);c.h.push(n);z=c.m.getConfiguration().safari;return Cl(c,a,z)?_.x(M,Fl(c,n,z),5):Dl(c,a,z)?_.x(M,Gl(c,n,z),
|
|
443
|
+
5):M.F(5)}if(2!=M.a)return c.g.debug(a+" Track added",n),c.m.trigger(new _.L(_.Zu)),B=Jl(c,a).length,I=!(!l||!l.length),F=l&&l.length||0,D=function(){c.g.debug(Zb+a+" track active. Native track active: "+(p+". Number of tracks: ")+B,d);c.a.set(a,n)},p?D():1===B&&h&&(f?D():I&&1!==F||D()),_.oh(M,0);G=_.C(M);c.g.error("Error while converting track data",G);_.y(M)})};
|
|
444
|
+
_.r.Of=function(a,b){if(b){var c=b.track;if(!c)this.g.warn(Eb);else if(a===_.T&&c.kind!==_.Qe){var d=this.h.find(function(e){return Ml(e,c,a)});d&&(this.h.splice(this.h.indexOf(d),1),(this.a.get(a)||null)===d&&(this.a.set(a,null),Sl(this)),this.g.debug(a+" Track removed, id: ",d.id))}}else this.g.warn(Bb)};
|
|
445
|
+
_.r.Nf=function(a,b){this.g.debug(a+" Track changed",b);a===_.T&&Sl(this);var c=Il(this,a);if(c)for(var d={Ec:0};d.Ec<c.length;d={Ec:d.Ec},++d.Ec)if(Ql(c[d.Ec])){if(d=this.h.find(function(e){return function(f){return Ml(f,c[e.Ec],a)}}(d)))this.a.set(a,d),this.g.debug("Track change detected, id:",d.id),d===this.l.get(a)&&this.l.set(a,null),a===_.ik?this.m.trigger(new _.L(_.Nl)):a===_.T&&this.m.trigger(new _.L(_.Ol));break}};_.r.initialize=function(a){this.m=a;this.j=new vk(a.getNetworkEngine())};
|
|
446
|
+
_.r.load=function(){this.A=!1;var a=Hl(this,_.T);a&&(this.f.on(a,_.Nc,this.J),this.f.on(a,Pf,this.L),this.f.on(a,wd,this.K));if(a=Hl(this,_.ik))this.f.on(a,_.Nc,this.G),this.f.on(a,Pf,this.I),this.f.on(a,wd,this.H);if(a=Hl(this,_.jk))this.f.on(a,_.Nc,this.N),this.f.on(a,Pf,this.V),this.f.on(a,wd,this.T);this.f.one(this.m,od,this.Cj.bind(this))};_.r.release=function(){this.A=!0;this.h=[];this.o={};this.a.clear();this.l.clear();this.f.release()};_.r.destroy=function(){this.release();this.m=null};
|
|
447
|
+
_.r.getVideoTracks=function(){return Jl(this,_.jk)};_.r.getAudioTracks=function(){return Jl(this,_.ik)};_.r.ha=function(){return Jl(this,_.T)};_.r.ma=function(){var a=this,b=this.a.get(_.jk)||null;if(!b)return null;if(this.w){var c=b.renditions.find(function(d){return d.width===a.w.width&&d.height===a.w.height});if(c)return c}return b.renditions[0]||null};_.r.Oa=function(){return Kl(this,_.ik)};_.r.Ga=function(){return Kl(this,_.T)};_.r.cb=function(){return Ll(this,_.jk)};
|
|
448
|
+
_.r.mb=function(){return Ll(this,_.ik)};_.r.nb=function(){return Ll(this,_.T)};_.r.Ha=function(){return this.a.get(_.jk)||null};_.r.la=function(){return this.a.get(_.ik)||null};_.r.ta=function(){return this.a.get(_.T)||null};_.r.jb=function(a){Pl(this,_.jk,a)};_.r.xa=function(a){Pl(this,_.ik,a)};_.r.Ja=function(a){Pl(this,_.T,a)};_.r.Ya=function(a){Pl(this,_.jk,a&&a.track)};_.r.hb=function(a){Pl(this,_.ik,a&&a.track)};_.r.ib=function(a){Pl(this,_.T,a&&a.track)};
|
|
449
|
+
_.r.addTextTrack=function(a){var b=this,c;return _.E(function(d){return a.mimeType.match(/text\/vtt/)?(c="External_"+b.B++,b.o[c]=a,zl(b,a,c),d.F(0)):_.x(d,Al(b,a),0)})};_.r.pa=function(){return 1>=this.getVideoTracks().flatMap(function(a){return a.renditions}).length};
|
|
450
|
+
_.r.Cj=function(){var a=this,b,c,d;return _.E(function(e){if(1==e.a){b=a.m.getConfiguration();Rl(a,_.ik,b.preferredAudioLanguage);c=Il(a,_.T);if(c.some(function(f){return Ql(f)}))return e.F(2);d=Hl(a,_.T);return _.x(e,new Promise(function(f){a.f.one(d,wd,f);(new _.Vk(f)).da(1)}),2)}if(a.A)return e["return"]();Rl(a,_.T,b.preferredTextLanguage);_.y(e)})};yl.prototype.isAbrEnabled=yl.prototype.pa;yl.prototype.addTextTrack=yl.prototype.addTextTrack;yl.prototype.setTextRendition=yl.prototype.ib;
|
|
451
|
+
yl.prototype.setAudioRendition=yl.prototype.hb;yl.prototype.setVideoRendition=yl.prototype.Ya;yl.prototype.setTextTrack=yl.prototype.Ja;yl.prototype.setAudioTrack=yl.prototype.xa;yl.prototype.setVideoTrack=yl.prototype.jb;yl.prototype.getTextTrack=yl.prototype.ta;yl.prototype.getAudioTrack=yl.prototype.la;yl.prototype.getVideoTrack=yl.prototype.Ha;yl.prototype.getLoadingTextRendition=yl.prototype.nb;yl.prototype.getLoadingAudioRendition=yl.prototype.mb;yl.prototype.getLoadingVideoRendition=yl.prototype.cb;
|
|
452
|
+
yl.prototype.getTextRendition=yl.prototype.Ga;yl.prototype.getAudioRendition=yl.prototype.Oa;yl.prototype.getVideoRendition=yl.prototype.ma;yl.prototype.getTextTracks=yl.prototype.ha;yl.prototype.getAudioTracks=yl.prototype.getAudioTracks;yl.prototype.getVideoTracks=yl.prototype.getVideoTracks;yl.prototype.canSelectVideoTracks=yl.prototype.gf;_.r=_.Tl.prototype;_.r.start=function(a){if(this.f)return this.f.start(a);if(a<this.a.length)return this.a[a].start;throw Error(ec);};_.r.end=function(a){if(this.f)return this.f.end(a);if(a<this.a.length)return this.a[a].end;throw Error(ec);};_.r.xb=function(){return!this.length||1===this.length&&1E-6>this.end(0)-this.start(0)?null:1===this.length&&0>this.start(0)?0:this.start(0)};_.r.Ea=function(){return!this.length||1===this.length&&1E-6>this.end(0)-this.start(0)?null:this.end(this.length-1)};
|
|
441
453
|
_.r.qc=function(a,b,c){b=void 0===b?!0:b;c=void 0===c?0:c;if(!this.length||1===this.length&&1E-6>this.end(0)-this.start(0)||a>this.end(this.length-1))return!1;if(b)return c+a>=this.start(0)&&a<=this.end(this.length-1);for(b=0;b<this.length;b++)if(c+a>=this.start(b)&&a<=this.end(b))return!0;return!1};
|
|
442
|
-
_.r.
|
|
443
|
-
_.
|
|
444
|
-
_.r.trigger=function(a){this.xd.trigger(a);for(var b=_.
|
|
445
|
-
_.H("clpp.events.RELEASING",_.
|
|
446
|
-
_.H("clpp.events.AUTOPLAY_NOT_ALLOWED",_.
|
|
447
|
-
_.H("clpp.events.AD_FIRST_QUARTILE",_.
|
|
448
|
-
_.H("clpp.events.CASTING_STARTED",_.
|
|
449
|
-
_.H("clpp.events.MPD_TYPE_CHANGED",_.
|
|
450
|
-
_.r.destroy=function(){this.
|
|
451
|
-
_.r.play=function(){var a=this;if(!this.
|
|
452
|
-
_.r.pause=function(){var a=this;return this.
|
|
453
|
-
_.r.setDrmCustomDataModifier=function(a){this.
|
|
454
|
-
_.r.seek=function(a){var b=this,c=this.
|
|
455
|
-
q=.1>=Math.abs(a-p),
|
|
456
|
-
d.currentTime=a)}function m(){b.trigger(new _.L(_.
|
|
457
|
-
_.r.getVolume=function(){var a=this.
|
|
458
|
-
_.r.setMuted=function(a){var b=this.
|
|
459
|
-
_.r.getLoadedSource=function(){return this.
|
|
460
|
-
_.r.
|
|
461
|
-
this.getBufferInfo().
|
|
454
|
+
_.r.La=function(a,b){b=void 0===b?!1:b;if(!this.length||1===this.length&&1E-6>this.end(0)-this.start(0))return 0;var c=0;if(b){var d=this.Ea();null!=d&&(c=Math.max(0,d-a))}else for(d=this.length-1;0<=d&&this.end(d)>a;--d)c+=this.end(d)-Math.max(this.start(d),a);return c};_.r.toString=function(){for(var a="",b=0;b<this.length;b++)0<b&&(a+=" "),a+=this.start(b).toFixed(3)+"-"+this.end(b).toFixed(3);return a};_.H("clpp.BufferInfo",_.Tl);_.Tl.prototype.bufferedAheadOf=_.Tl.prototype.La;
|
|
455
|
+
_.Tl.prototype.isBuffered=_.Tl.prototype.qc;_.Tl.prototype.bufferEnd=_.Tl.prototype.Ea;_.Tl.prototype.bufferStart=_.Tl.prototype.xb;_.Tl.prototype.end=_.Tl.prototype.end;_.Tl.prototype.start=_.Tl.prototype.start;_.r=_.Ul.prototype;_.r.addEventListener=function(a,b){this.on(a,b)};_.r.removeEventListener=function(a,b){this.off(a,b)};_.r.on=function(a,b,c){return this.xd.on(a,b,c)};_.r.one=function(a,b,c){return this.xd.one(a,b,c)};_.r.off=function(a,b){return this.xd.off(a,b)};_.r.forwardEventsTo=function(a){a&&(0<=this.ud.indexOf(a)||this.ud.push(a))};_.r.dispatchEvent=function(a){this.trigger(a);return a.defaultPrevented};
|
|
456
|
+
_.r.stopForwardingEventsTo=function(a){a&&(a=this.ud.indexOf(a),0<=a&&this.ud.splice(a,1))};_.r.trigger=function(a){this.xd.trigger(a);for(var b=_.t(this.ud),c=b.next();!c.done;c=b.next())c.value.dispatchEvent(a)};_.Ul.prototype.off=_.Ul.prototype.off;_.Ul.prototype.one=_.Ul.prototype.one;_.Ul.prototype.on=_.Ul.prototype.on;_.Ul.prototype.removeEventListener=_.Ul.prototype.removeEventListener;_.Ul.prototype.addEventListener=_.Ul.prototype.addEventListener;_.H("clpp.events.ERROR",_.re);_.H("clpp.events.LOADEDMETADATA",_.Ke);_.H("clpp.events.BUFFERING_ENDED",_.ld);_.H("clpp.events.BUFFERING_STARTED",_.md);_.H("clpp.events.STATE_CHANGED",_.eg);_.Nl="audiotrackchanged";_.H("clpp.events.AUDIO_TRACK_CHANGED",_.Nl);_.Ol="texttrackchanged";_.H("clpp.events.TEXT_TRACK_CHANGED",_.Ol);_.H("clpp.events.VIDEO_TRACK_CHANGED",_.Jg);_.H("clpp.events.BITRATE_CHANGED",_.jd);_.Zu="tracksadded";_.H("clpp.events.TRACKS_ADDED",_.Zu);_.H("clpp.events.LOAD_START",Le);
|
|
457
|
+
_.H("clpp.events.RELEASING",_.Of);_.H("clpp.events.RELEASED",Nf);_.H("clpp.events.DESTROYING","destroying");_.H("clpp.events.DESTROYED","destroyed");_.H("clpp.events.VIDEO_BUFFER_CHANGED",_.Ig);_.H("clpp.events.AUDIO_BUFFER_CHANGED",_.hd);_.H("clpp.events.DOWNLOAD_TRACE","downloadtrace");_.H("clpp.events.DRM_SESSION_UPDATE",_.ke);_.H("clpp.events.DRM_SESSION_PERSISTED",_.je);_.H("clpp.events.DRM_RENEWAL_STARTED",ie);_.H("clpp.events.DRM_EXPIRATION_UPDATE",_.he);
|
|
458
|
+
_.H("clpp.events.AUTOPLAY_NOT_ALLOWED",_.id);_.H("clpp.events.PLAY",_.lf);_.H("clpp.events.SEEKING",_.Yf);_.H("clpp.events.SEEKED",_.Xf);_.H("clpp.events.USER_SEEKING",_.Bg);_.H("clpp.events.USER_SEEKED",_.Ag);_.rp={SEEKING:1,NO_DATA:2};_.H("clpp.events.BufferingReasons",_.rp);_.H("clpp.events.ADS_TIMELINE_CHANGED",_.Oc);_.H("clpp.events.AD_LOADED",_.Ec);_.H("clpp.events.AD_BREAK_STARTED",_.xc);_.H("clpp.events.AD_STARTED",_.Kc);_.H("clpp.events.AD_BUFFERING",_.zc);_.H("clpp.events.AD_PROGRESS",_.Hc);
|
|
459
|
+
_.H("clpp.events.AD_FIRST_QUARTILE",_.Cc);_.H("clpp.events.AD_MIDPOINT",_.Fc);_.H("clpp.events.AD_THIRD_QUARTILE",_.Mc);_.H("clpp.events.AD_PAUSED",_.Gc);_.H("clpp.events.AD_RESUMED",_.Ic);_.H("clpp.events.AD_SKIPPED",_.Jc);_.H("clpp.events.AD_CLICKED",_.Ac);_.H("clpp.events.AD_IMPRESSION",_.Dc);_.H("clpp.events.AD_COMPLETED",_.Bc);_.H("clpp.events.AD_STOPPED",_.Lc);_.H("clpp.events.AD_BREAK_STOPPED",_.yc);_.H("clpp.events.SIMID_CREATIVE_STARTED",_.$f);_.H("clpp.events.SIMID_CREATIVE_STOPPED",_.ag);
|
|
460
|
+
_.H("clpp.events.CASTING_STARTED",_.qd);_.H("clpp.events.CASTING_ENDED","castingended");_.H("clpp.events.CAST_STATUS_CHANGED",_.rd);_.H("clpp.events.AIRPLAY_STATUS_CHANGED",_.Rc);_.H("clpp.events.AIRPLAY_CASTING_STARTED",_.Qc);_.H("clpp.events.AIRPLAY_CASTING_ENDED",_.Pc);_.ci="timeline-cue-added";_.H("clpp.events.TIMELINE_CUE_ADDED",_.ci);_.ei="timeline-cue-enter";_.H("clpp.events.TIMELINE_CUE_ENTER",_.ei);_.fi="timeline-cue-exit";_.H("clpp.events.TIMELINE_CUE_EXIT",_.fi);
|
|
461
|
+
_.H("clpp.events.MPD_TYPE_CHANGED",_.Ue);_.H("clpp.events.LIVE_TURNED_STATIC",_.Ie);_.H("clpp.events.VIMOND_RESPONSE",_.Kg);_.H("clpp.events.PLAYLIST_ITEM_CHANGED",_.Af);_.H("clpp.events.PLAYLIST_MODIFIED",_.Bf);_.H("clpp.events.SC_PLAYLIST_TIMELINE_CHANGED",_.Wf);_.H("clpp.events.SC_PLAYLIST_ITEM_CHANGED",_.Uf);_.H("clpp.events.SC_PLAYLIST_ENDED",_.Tf);_.H("clpp.events.SC_PLAYLIST_LIVE_TURNED_STATIC",_.Vf);_.H("clpp.events.CDN_SWITCH_SUCCESS",_.sd);_.H("clpp.events.ONLINE_STATUS_CHANGED",cf);var Vl=["play() failed because the user didn't interact","The play method is not allowed by the user agent","The request is not allowed by the user agent or the platform"];var Su;_.H("clpp.version",_.ia);_.H("clpp.name",_.va);_.El="application/x-mpegurl";_.H("clpp.Type",{DASH:_.Uc,HLS:_.El,SMOOTH_STREAMING:_.$c,MP4:_.Hg});_.bi="scte35";Su="hls-daterange";_.$h=wg;_.H("clpp.TimelineCueType",{SCTE35:_.bi,DASH_CALLBACK:_.Ve,HLS_DATERANGE:Su,UNKNOWN:_.$h});_.H("clpp.SpeedUpMode",{DECODER:_.Yd,SEEK:"seek"});_.H("clpp.utils.PlayerConfiguration",Xl);Xl.create=_.bm;var $u=["abort",nd,od,me,"emptied",oe,_.qe,_.re,"interruptbegin","interruptend",_.Je,_.Ke,Le,"mozaudioavailable",_.gf,_.lf,_.zf,_.Kf,_.Mf,_.Xf,_.Yf,cg,"suspend",_.rg,"volumechange",_.Ng,_.Og,_.Rf,Tg,Sg,Qg,Rg];_.w(_.dm,_.Ul);_.r=_.dm.prototype;_.r.init=function(a,b){this.configuration=this.Ic=b;this.D=a;this.log.info("Initializing Player surface");var c=this.D.getMedia();this.log.info("Attaching media element listeners");for(var d=_.t($u),e=d.next();!e.done;e=d.next())e=e.value,this.N.on(c,e,this.ni,e!==_.re);this.wd||(this.wd=this.Ng());this.wd.initialize(this);this.D.showMediaElement()};_.r.release=function(){this.ba&&(this.ba.destroy(),this.ba=null);return Promise.resolve()};
|
|
462
|
+
_.r.destroy=function(){this.N.release();return this.Sf.release()};_.r.canPlay=function(a,b){return _.Kh[this.namespace()].canPlay(a,b)};_.r.getTimeline=function(){return null};_.r.setupPlaylist=function(){return Promise.reject(_.Gb)};_.r.appendLoad=function(){return Promise.reject(_.Gb)};_.r.seekWith=function(){return Promise.reject(_.Gb)};
|
|
463
|
+
_.r.play=function(){var a=this;if(!this.Z)return Promise.reject("No sources specified yet. You need to load content before calling play.");var b=this.D.getMedia().play();return Promise.resolve(b)["catch"](function(c){a.log.info("Caught play promise exception",c);var d={name:c.name||"",message:c.message||"",stack:c.stack||""};Wl(d)?(a.trigger(new _.L(_.id)),a.log.warn(_.ma)):d.name===Hb&&a.log.warn('Unrecognized "NotAllowedError" on play(). '+(c.name+": "+c.message));throw c;})};
|
|
464
|
+
_.r.pause=function(){var a=this;return this.Z?new Promise(function(b,c){var d=a.getState();if(d!==_.op&&d!==_.qp&&d!==_.xp&&d!==_.wp)c();else if(a.D.getMedia().pause(),a.getState()===_.xp)a.N.one(a,_.eg,function(){b()});else b()}):Promise.reject("No sources specified yet. You need to load content before calling pause.")};_.r.isPaused=function(){return this.D.getMedia().paused};_.r.isEnded=function(){return this.D.getMedia().ended};_.r.getConfiguration=function(){return this.configuration};
|
|
465
|
+
_.r.setDrmCustomDataModifier=function(a){this.Tc=a};_.r.setCdnErrorCallback=function(a){this.Hc=a};_.r.Vc=function(){return this.Tc};_.r.getSurface=function(){return this.D};_.r.getBufferInfo=function(a){var b=this.getSurface().getMedia();return new _.Tl(b?b.buffered:void 0,a)};_.r.getPosition=function(){return this.getMediaPosition()};_.r.getMediaPosition=function(){var a=this.D.getMedia();if(a)return a.currentTime;this.log.warn("No media element available, can not report current time!");return 0};
|
|
466
|
+
_.r.seek=function(a){var b=this,c=this.getMediaPosition();if(void 0===a||null===a||typeof a!==_.k||a===c)return Promise.resolve();var d=this.D.getMedia();if(!d)return this.log.warn("No media element available, can not set current time!"),Promise.reject();var e=a-c;return.1>=Math.abs(e)?(this.log.info("Skip seek. Delta "+Math.abs(e)+" \x3c 0.1"),Promise.resolve()):new Promise(function(f,g){function h(){if(d.readyState>HTMLMediaElement.HAVE_NOTHING)m();else b.N.one(d,_.Ke,m)}function l(n){var p=b.getMediaPosition(),
|
|
467
|
+
q=.1>=Math.abs(a-p),u=.25<p-a,v=d.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA,z=n.type===_.Xf,B=n.type===_.Kf,I=n.type===_.rg,F=B&&v;u=z||q&&F||I&&u;b.log.debug("Checking seeking state after "+n.type+" event. Seek completed:",u,"Current Time:",p,"Target Time:",a,"Native Event:",z,"Time reached",q,"Timeupdate:",I,"Progress:",B,"ReadyState:",v,"Progress Ready:",F);u?(b.Uf=!1,b.Od=!1,b.N.off(d,_.Xf,l),b.N.off(d,_.rg,l),b.N.off(d,_.Kf,l),b.Oh(),b.trigger(new _.L(_.Ag)),f()):B&&c===p&&(b.log.debug("Seek seemed to have been ignored. Trying again"),
|
|
468
|
+
d.currentTime=a)}function m(){b.trigger(new _.L(_.Bg));b.N.on(d,_.Xf,l);b.N.on(d,_.rg,l);b.N.on(d,_.Kf,l);b.log.info("Seeking to "+a+". Delta "+e);b.Uf=!0;b.Od=!0;d.currentTime=a}b.getState()===_.jp?(b.log.debug("Player is in IDLE state. Postpone seek."),b.N.one(b,_.eg,function(){switch(b.getState()){case _.op:case _.xp:case _.wp:b.log.debug("Valid seek state reached.");h();break;default:b.log.warn("Invalid seek target state. Aborting seek"),g()}})):h()})};
|
|
469
|
+
_.r.getVolume=function(){var a=this.D.getMedia();if(a)return a.volume;this.log.warn("No media element available, can not report volume!");return null};_.r.setVolume=function(a){var b=this.D.getMedia();b?_.O.qa(a)?0>a||1<a?this.log.warn(ta+a+".\n Value must be between 0 and 1."):b.volume=a:this.log.warn(ta+a+". Volume must be a number"):this.log.warn("No media element available, can not set volume !")};_.r.isMuted=function(){return this.D.getMedia().muted};
|
|
470
|
+
_.r.setMuted=function(a){var b=this.D.getMedia();typeof a===_.kd&&(b.muted=a)};_.r.getDuration=function(){return this.getMediaDuration()};_.r.getMediaDuration=function(){return this.Z?this.D.getMedia().duration:-1};_.r.getTrackManager=function(){return this.wd};_.r.getPlaybackRate=function(){var a=this.D.getMedia();return a&&a.playbackRate||1};_.r.setPlaybackRate=function(a){var b=this.D.getMedia();void 0!==a&&b&&(b.playbackRate=a)};_.r.setSourceIndex=function(a){this.we=a};_.r.getSourceIndex=function(){return this.we};
|
|
471
|
+
_.r.getLoadedSource=function(){return this.Z&&-1!==this.we?this.Z[this.we]:null};_.r.getPeriods=function(){return[]};_.r.getNetworkEngine=function(){return this.Sf};_.r.setNetworkEngine=function(a){this.Sf=a};_.r.getTextDisplayer=function(){return this.ba};_.r.getTimelineCues=function(){return[]};_.r.resetAbr=function(){};
|
|
472
|
+
_.r.xm=function(a){var b=this.getSurface().getMedia(),c=this.getPosition(),d="Received Video Element Event: '"+a.type+"' with playhead at: "+c;if(a.type===_.rg||a.type===_.Kf)this.kg.debug(d);else{var e="";switch(a.type){case _.Mf:e="Rate: "+this.getPlaybackRate();break;case me:e="Duration: "+this.getDuration();break;case "volumechange":e="Volume: "+this.getVolume()+" Muted: "+this.isMuted();break;case _.lf:case _.zf:case "suspend":case _.Ng:case cg:case _.Yf:case _.Xf:case _.rg:case _.Kf:case nd:case od:b=
|
|
473
|
+
this.getBufferInfo().La(c);e="State "+this.getSurface().getMedia().readyState+" Buffer: "+b;break;case _.Rf:null!=b&&(e="Size: "+b.videoWidth+"x"+b.videoHeight)}e&&(d+=". "+e);this.kg.info(d)}a.type!==_.re&&this.trigger(new _.L(a.type,{detail:a}))};_.r.Oh=function(){};_.dm.prototype.getTextDisplayer=_.dm.prototype.getTextDisplayer;_.dm.prototype.setNetworkEngine=_.dm.prototype.setNetworkEngine;_.dm.prototype.getNetworkEngine=_.dm.prototype.getNetworkEngine;var gm;gm=new _.K("clpp.Components");_.em=new Map;_.H("clpp.install",function(a){om(a)});_.H("clpp.uninstall",function(a){pm(a)});qm.prototype.release=function(){this.a=this.f=null};_.H("clpp.drm.WidevineRobustnessLevel",{SW_SECURE_CRYPTO:_.Wb,SW_SECURE_DECODE:_.Xb,HW_SECURE_CRYPTO:gb,HW_SECURE_DECODE:hb,HW_SECURE_ALL:fb});_.H("clpp.drm.PlayreadyRobustnessLevel",{SL150:"150",SL2000:"2000",SL3000:"3000"});_.H("clpp.drm.KeySystem",{NONE:_.We,CLEAR_KEY:_.ef,WIDEVINE:_.Td,PLAYREADY:_.Rd,FAIRPLAY:_.Pd,PRIMETIME:_.Od});_.um={};_.H("clpp.drm.registerDrmEnvironment",_.vm);var ym={V1_STAGING:[10,191,2,8,3,18,16,40,112,52,84,192,8,246,54,24,173,231,68,61,182,196,200,24,139,231,249,144,5,34,142,2,48,130,1,10,2,130,1,1,0,181,33,18,184,208,93,2,63,204,93,149,226,194,81,193,198,73,180,23,124,216,210,190,239,53,91,176,103,67,222,102,30,61,42,188,49,130,183,153,70,213,95,220,8,223,233,84,7,129,94,154,98,116,179,34,162,199,245,224,103,187,95,10,192,122,137,212,90,234,148,178,81,111,7,91,102,239,129,29,13,38,225,185,166,184,148,242,185,133,121,98,170,23,28,79,102,99,13,62,76,
|
|
462
474
|
96,39,24,137,127,94,30,249,182,170,245,173,77,186,42,126,20,23,109,241,52,161,211,24,91,90,33,138,192,90,76,65,240,129,239,255,128,163,160,64,197,11,9,187,199,64,238,220,216,241,77,103,90,145,152,15,146,202,125,220,100,106,6,173,173,81,1,247,74,14,73,140,192,31,0,83,43,172,33,120,80,189,144,94,144,146,54,86,183,223,239,239,66,72,103,103,243,62,246,40,61,79,66,84,171,114,88,147,144,190,229,88,8,241,214,104,8,13,69,216,147,194,188,162,247,77,96,160,192,208,160,153,60,239,1,96,71,3,51,76,54,56,19,148,
|
|
463
475
|
134,188,157,175,36,253,103,160,127,154,217,67,2,3,1,0,1,58,18,115,116,97,103,105,110,103,46,103,111,111,103,108,101,46,99,111,109,18,128,3,152,62,48,53,38,117,244,11,167,21,252,36,155,218,229,212,172,114,73,162,102,101,33,228,54,85,115,149,41,114,31,248,128,224,170,239,197,226,123,201,128,218,234,218,191,63,195,134,208,132,160,44,130,83,120,72,204,117,63,244,151,176,17,167,218,151,120,138,0,226,170,107,132,205,125,113,192,122,72,235,246,22,2,204,165,163,243,32,48,167,41,92,48,218,145,91,145,220,24,
|
|
464
476
|
185,188,149,147,184,222,139,181,15,13,237,193,41,56,184,233,224,57,205,222,24,250,130,232,27,176,50,99,15,233,85,216,90,86,108,225,84,48,11,246,212,193,189,18,105,102,53,107,40,125,101,123,24,206,99,208,239,212,95,197,38,158,151,234,177,28,181,99,229,86,67,178,111,244,159,16,156,33,1,175,202,243,91,131,47,40,143,13,157,69,150,14,37,158,133,251,93,36,219,210,207,130,118,76,93,217,191,114,126,251,233,200,97,248,105,50,31,106,222,24,144,95,77,146,249,166,218,101,54,219,132,117,135,29,22,142,135,11,178,
|
|
@@ -472,96 +484,105 @@ this.getBufferInfo().Na(c);e="State "+this.getSurface().getMedia().readyState+"
|
|
|
472
484
|
21,58,231,13,118,215,58,166,74,44,51,103,50,120,198,197,213,64,34,105,66,115,72,235,88,51,28,238,54,93,147,140,187,28,173,50,109,5,234,155,141,29,52,234,135,38,55,103,111,116,98,171,210,13,211,129,249,70,57,64,155,151,38,8,225,188,229,3,247,234,26,46,91,211,250,252,38,87,111,205,37,108,74,168,112,74,116,191,73,170,243,167,54,36,20,23,72,67,35,181,159,241,102,250,221,22,18,92,161,54,236,172,183,214,18,160,199,92,46,171,180,211,90,64,62,144,121,201,77,74,211,17,244,49,124,244,120,116,148,234,184,79,
|
|
473
485
|
136,12,176,34,231,39,149,87,28,219,2,3,1,0,1,58,12,99,97,115,116,108,97,98,115,46,99,111,109,64,1,18,128,3,50,97,151,165,120,63,210,172,84,187,10,36,166,202,149,32,118,107,37,251,186,217,170,254,4,95,20,85,66,157,43,154,24,66,136,147,101,223,78,204,173,228,175,111,100,168,97,164,222,84,160,51,79,233,227,223,105,252,85,11,242,129,199,206,11,9,236,118,163,118,204,179,159,69,108,223,229,114,176,8,26,36,9,23,103,233,62,55,162,154,209,96,98,102,80,173,114,233,213,36,56,135,65,188,245,176,95,70,189,199,
|
|
474
486
|
143,81,72,182,124,207,225,238,28,172,144,110,89,44,12,137,51,52,239,130,117,119,15,207,200,229,142,166,8,80,79,111,255,191,70,47,189,108,75,234,184,241,119,21,255,98,167,124,132,30,239,102,113,7,132,96,39,134,123,220,209,255,110,222,35,147,0,77,125,253,129,139,66,158,126,221,13,117,113,163,143,235,9,130,180,3,133,94,152,45,199,69,168,182,95,122,82,25,203,10,99,191,186,193,238,225,224,140,156,142,171,110,26,214,32,240,6,218,138,10,47,114,133,17,1,151,43,213,223,198,210,186,81,18,50,221,84,177,180,
|
|
475
|
-
26,58,164,235,113,177,235,207,22,230,8,119,76,167,166,176,173,209,214,53,116,116,231,227,221,238,174,87,249,19,166,195,81,47,210,172,15,75,251,202,192,80,85,213,23,17,178,104,181,193,115,239,91,72,230,167,55,143,10,250,26,54,8,60,13,213,206,235,3,215,179,205,232,1,144,158,35,48,196,149,117,219,63,196,130,117,40,165,193,65,215,122,44,201,218,67,216,6,131,178,5,168,229,21,137,112,215,254,127,48,160,181,68,49,255,64,46,247,236,85,155,146,208,5,219,252,37,174,31,218,136,135,55,119,112]};_
|
|
476
|
-
_.r.
|
|
477
|
-
has64BitSize:g})}else a=Math.min(d+e-b.getPosition(),b.
|
|
478
|
-
for(var
|
|
479
|
-
43E3:"General Fairplay error",44E3:"General OMA error",44001:"OMA Device registration failed",45E3:"General CDRM error",45001:"CDRM Device registration failed",6E4:"CSL",60001:"CSL - INVALID",60100:"CSL - Denied by Stream Limiting",7E4:"General Output Protection",70001:"All keys filtered by EOP settings",8E4:"TAKE DOWN",80001:"TAKE DOWN - Denied by Take Down",9E4:"General GBL error",90001:"License delivery prohibited in your region"},
|
|
480
|
-
"2000","150"],audio:["2000","150"]},
|
|
481
|
-
certificateUrl:
|
|
482
|
-
_.r.
|
|
483
|
-
_.r.
|
|
484
|
-
b.a.keySystem.startsWith(_.
|
|
485
|
-
_.
|
|
486
|
-
_.r.unload=function(){var a=this,b;return _.E(function(c){if(!a.
|
|
487
|
-
_.r.release=function(){var a=this;return _.
|
|
488
|
-
_.r.destroy=function(){var a=this;if(this.
|
|
489
|
-
_.r.detach=function(){};_.r.getTrackManager=function(){return this.
|
|
490
|
-
_.r.load=function(a){var b=this,c,d,e,f,g;return _.E(function(h){switch(h.a){case 1:if(b.
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
_.r.getPresentationStartTime=function(){if(this.a&&this.a.getStartDate&&this.isLive()){var a=this.a.getStartDate();return isNaN(a.getTime())?(this.log.warn("EXT-X-PROGRAM-DATETIME required to get presentation start time as Date!"),null):a.getTime()/1E3}return null};_.r.getSeekRange=function(){var a=this.getSurface().getMedia();if(a&&a.src){a=a.seekable;if(a.length)return this.
|
|
487
|
+
26,58,164,235,113,177,235,207,22,230,8,119,76,167,166,176,173,209,214,53,116,116,231,227,221,238,174,87,249,19,166,195,81,47,210,172,15,75,251,202,192,80,85,213,23,17,178,104,181,193,115,239,91,72,230,167,55,143,10,250,26,54,8,60,13,213,206,235,3,215,179,205,232,1,144,158,35,48,196,149,117,219,63,196,130,117,40,165,193,65,215,122,44,201,218,67,216,6,131,178,5,168,229,21,137,112,215,254,127,48,160,181,68,49,255,64,46,247,236,85,155,146,208,5,219,252,37,174,31,218,136,135,55,119,112]};_.Am.prototype.Sa=function(a,b){this.f[a]=b};_.H("clpp.drm.DrmEnvironment",_.Am);_.Am.prototype.setDrmSystem=_.Am.prototype.Sa;_.Bm.prototype.getPosition=function(){return this.a};_.Bm.prototype.Fa=function(){return this.f.byteLength};_.Bm.prototype.seek=function(a){(0>a||a>=this.f.byteLength)&&_.Cm();this.a=a};_.Em.prototype.getPosition=function(){return this.a};_.Em.prototype.Fa=function(){return this.f.byteLength};_.Em.prototype.skip=function(a){this.a+a>this.f.byteLength&&_.Gm();this.a+=a};_.Em.prototype.seek=function(a){if(0>a||a>=this.f.byteLength)throw _.Gm();this.a=a};_.H("clpp.utils.dataview.DataViewReader",_.Em);_.r=_.Pm.prototype;_.r.M=function(a,b){var c=Tm(a);this.h[c]=av;this.f[c]=b;return this};_.r.Y=function(a,b){var c=Tm(a);this.h[c]=bv;this.f[c]=b;return this};_.r.stop=function(){this.a=!0};_.r.parse=function(a,b){var c=_.lj(a);c=new _.Em(new DataView(c.buffer,c.byteOffset,c.byteLength),!1);for(this.a=!1;_.Fm(c)&&!this.a;)this.Ge(0,c,b)};
|
|
488
|
+
_.r.Ge=function(a,b,c){var d=b.getPosition(),e=_.W(b),f=_.W(b),g=!1;this.g.debug("Parsing MP4 box",_.Um(f));switch(e){case 0:e=b.Fa()-d;break;case 1:e=_.Km(b),g=!0}var h=this.f[f];if(h){var l=null,m=null;this.h[f]===bv&&(m=_.W(b),l=m>>>24,m&=16777215);f=b.getPosition()-d;var n=d+e;c&&n>b.Fa()&&(n=b.Fa());n-=b.getPosition();b=0<n?_.Mm(b,n):new Uint8Array(0);b=new _.Em(new DataView(b.buffer,b.byteOffset,b.byteLength),!1);h({parser:this,partialOkay:c||!1,version:l,flags:m,reader:b,size:e,start:d+a,headerSize:f,
|
|
489
|
+
has64BitSize:g})}else a=Math.min(d+e-b.getPosition(),b.Fa()-b.getPosition()),b.skip(a)};_.H("clpp.utils.Mp4Parser",_.Pm);_.Pm.typeToString=_.Um;_.Pm.allData=_.Sm;_.Pm.sampleDescription=_.Rm;_.Pm.children=_.Qm;_.Pm.prototype.parseNext=_.Pm.prototype.Ge;_.Pm.prototype.parse=_.Pm.prototype.parse;_.Pm.prototype.stop=_.Pm.prototype.stop;_.Pm.prototype.fullBox=_.Pm.prototype.Y;_.Pm.prototype.box=_.Pm.prototype.M;_.Pm.headerSize=_.Vm;var av=0,bv=1;_.H("clpp.utils.FairplayUtils",Wm);Wm.parseFairPlayResponse=_.bn;Wm.formatFairPlayRequest=_.an;Wm.createFairplayPayload=$m;Wm.extractContentId=_.Ym;Wm.extractExtXKeyUri=Xm;var nn=new _.K("clpp.drm.DrmToday"),dn="PRODUCTION",en="STAGING",fn="TEST",cv={PRODUCTION:dn,STAGING:en,TEST:fn};_.H("clpp.drm.DrmToday.Environment",cv);_.H("clpp.drm.DrmToday.WidevineCertificates",{V1_PROD:"V1_PROD",V1_STAGING:"V1_STAGING",V2:"V2"});
|
|
490
|
+
for(var hn="/license-proxy-widevine/cenc/",jn="/license-proxy-headerauth/drmtoday/RightsManager.asmx",kn="/license-server-fairplay/",wn={"00000":"Success","01000":"General Internal Error","02000":"General Request Error","03000":"General Request Authentication Error",3E4:"General DRM error",4E4:"General Widevine Modular error",40001:"Widevine Device Certificate Revocation (wv 127)",40002:"Widevine Device Certificate Revocation - Permanently (wv 175)",41E3:"General Widevine Classic error",42E3:"General Playready error",
|
|
491
|
+
43E3:"General Fairplay error",44E3:"General OMA error",44001:"OMA Device registration failed",45E3:"General CDRM error",45001:"CDRM Device registration failed",6E4:"CSL",60001:"CSL - INVALID",60100:"CSL - Denied by Stream Limiting",7E4:"General Output Protection",70001:"All keys filtered by EOP settings",8E4:"TAKE DOWN",80001:"TAKE DOWN - Denied by Take Down",9E4:"General GBL error",90001:"License delivery prohibited in your region"},dv={video:[fb,hb,gb,_.Xb,_.Wb],audio:[_.Xb,_.Wb]},ev={video:["3000",
|
|
492
|
+
"2000","150"],audio:["2000","150"]},fv=_.t(Object.keys(cv)),gv=fv.next();!gv.done;gv=fv.next()){var cn=gv.value,hv=Da;cn!==dn&&(hv+="_"+cn);var iv=new _.Am(hv),jv=null;switch(cn){case dn:jv=zm("V1_PROD");break;case en:jv=zm("V2");break;case fn:jv=null}iv.Sa(_.Td,{licenseUrl:ln(_.Td),videoRobustness:dv.video,audioRobustness:dv.audio,persistentStateRequired:!1,distinctiveIdentifierRequired:!1,serverCertificate:jv,modifiers:{licenseRequest:_.qn,licenseResponse:_.vn}});iv.Sa(_.Pd,{licenseUrl:ln(_.Pd),
|
|
493
|
+
certificateUrl:gn()+"/license-server-fairplay/cert/",modifiers:{licenseRequest:_.sn,licenseResponse:_.tn,extractContentId:_.on,certificateRequest:_.un}});iv.Sa(_.Rd,{licenseUrl:ln(_.Rd),videoRobustness:ev.video,audioRobustness:ev.audio,modifiers:{licenseRequest:rn}});_.vm(iv)};_.H("clpp.drm.eme.EmeFactory",yn);var zn=[];yn.Apis={STANDARD:Ub,APPLE:"APPLE",WEBKIT:"WEBKIT",NOP:"NOP"};var In;_.Vn=[154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149];In=[237,239,139,169,121,214,74,206,163,200,39,220,213,29,33,237];_.w(Hn,Gn);_.w(_.Rn,Gn);var Xn=!!(performance&&performance.mark&&performance.measure);$n.prototype.j=function(a){if(1<a.version)_.J("Unrecognized PSSH version found!");else{var b=_.zj(_.Mm(a.reader,16)),c=[];if(0<a.version)for(var d=_.W(a.reader),e=0;e<d;++e){var f=_.zj(_.Mm(a.reader,16));c.push(f)}d=_.W(a.reader);a.reader.skip(d);this.h.push.apply(this.h,c);this.f.push(b);this.a.push({start:a.start,end:a.start+a.size-1});a.reader.getPosition()!==a.reader.Fa()&&_.J("Mismatch between box size and data size!")}};_.r=_.eo.prototype;_.r.destroy=function(){var a=this;return _.E(function(b){if(1==b.a){if(a.j)return _.x(b,a.Ca,0);a.j=!0;return _.x(b,go(a),4)}a.Ca.resolve();return b.F(0)})};_.r.keySystem=function(){return this.a?_.Go(this.a.keySystem):""};_.r.getDrmInfo=function(){return this.a};
|
|
494
|
+
_.r.Nh=function(a){var b=this,c,d,e;return _.E(function(f){if(1==f.a){if(b.G&&b.K===ho)return f["return"]();c=Math.floor(a.timeStamp);d="drm.msg."+c+ha;e="drm.msg."+c+".end";_.Yn(d);return!b.h.delayLicenseRequestUntilPlayed||b.B&&!b.B.paused||b.Ka?_.x(f,Ro(b,a),2):(b.ea.push(a),f.F(2))}_.Yn(e);_.Zn("drm.sess.msg."+c,d,e);_.y(f)})};
|
|
495
|
+
_.r.Ih=function(a){var b=this,c=a.target;this.g.info("Key status changed for session",c.sessionId);var d=this.f.get(c),e=!1;c.keyStatuses.forEach(function(g,h){if(typeof h===_.hg){var l=h;h=g;g=l}if(No(b.a.keySystem)&&16===h.byteLength&&_.Xk()){l=_.sj(h);var m=l.getUint32(0,!0),n=l.getUint16(4,!0),p=l.getUint16(6,!0);l.setUint32(0,m,!1);l.setUint16(4,n,!1);l.setUint16(6,p,!1)}d&&g!==fg&&(d.loaded=!0);d&&d.Ia&&d.Ia.resolve();"expired"===g&&(e=!0);l=_.lj(h);var q=_.zj(l);"00"===q&&d&&d.keyId?q=d.keyId:
|
|
496
|
+
b.a.keySystem.startsWith(_.Pd)&&16!==l.byteLength&&(q=_.R.fromCharCode(l));(l=q||"")?b.g.info(sb+q+"': "+g):b.g.info("Key status global keys: "+g);b.l.set(l,g);d&&!d.keyId&&b.f.forEach(function(u,v){v===c||u.keyId!==q||u.loaded||(u.loaded=!0)})});d&&d.loaded&&d.ab.forEach(function(g){b.l.get(g)===fg&&(b.g.warn(sb+g+ea),b.l.set(g,_.ff))});for(a=0;a<this.a.initData.length;a++){var f=this.a.initData[a];f.keyId&&this.l.get(f.keyId)===fg&&_.Aj(f.initData,d.initData)&&(this.g.warn(sb+f.keyId+ea),this.l.set(f.keyId,
|
|
497
|
+
_.ff))}a=c.expiration-Date.now();(0>a||e&&1E3>a)&&d&&!d.vb&&(this.g.debug("Session has expired",c.sessionId),(a=this.f.get(c))&&a.Qc&&a.Qc.stop(),this.f["delete"](c),c.close()["catch"](function(){}));Io(this)&&(this.H.resolve(),1!==this.f.size||e?this.ba.da(.5):bo(this))};var ho=0,ao=3;_.Vo=new Map;_.Wo=new _.K("clpp.text");_.ep.prototype.getStats=function(){return{width:this.w,height:this.h,streamBandwidth:this.o,decodedFrames:this.j,droppedFrames:this.l,corruptedFrames:this.D,estimatedBandwidth:this.f,loadLatency:this.A,playTime:ap(this.a,_.xp),pauseTime:ap(this.a,_.wp),bufferingTime:ap(this.a,_.op),stateHistory:bp(this.a),switchHistory:dp(this.B)}};_.gp.prototype.value=function(){void 0===this.a&&(this.a=this.f());return this.a};var hp=new _.gp(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,_.Ke],[HTMLMediaElement.HAVE_CURRENT_DATA,_.Je],[HTMLMediaElement.HAVE_FUTURE_DATA,nd],[HTMLMediaElement.HAVE_ENOUGH_DATA,od]])});mp.prototype.dc=function(a,b){this.m&&this.m.trigger(new _.L(a,{detail:b}))};mp.prototype.getState=function(){return pp(this,"")};mp.prototype.U=function(a){(a=a&&a.detail)&&a.severity&&a.severity===_.Q&&tp(this,_.up)};mp.prototype.destroy=function(){this.g.debug("Stop watching for video events for "+this.m.namespace());this.a.release()};_.H("clpp.utils.media.detectType",zp);var Cp=new _.K("clpp.sources");_.w(Dp,_.dm);_.r=Dp.prototype;_.r.init=function(a,b){_.dm.prototype.init.call(this,a,b);this.j=new mp(this);tp(this.j,_.jp)};_.r.namespace=function(){return Jd};
|
|
498
|
+
_.r.unload=function(){var a=this,b;return _.E(function(c){if(!a.Z)return c.F(0);a.log.debug("Releasing player with source",a.Z);a.B&&(a.B.stop(),a.B=null);(b=a.getTrackManager())&&b.release();a.A&&(a.A.destroy(),a.A=null);a.ba&&(a.ba.destroy(),a.ba=null);a.l&&a.l.release();a.o&&(a.o.destroy(),a.o=null);_.Vh(a.h);a.f&&(a.f=new _.ep);a.G=null;a.Z=null;a.H=!1;a.a&&(a.a.removeAttribute("src"),a.a.load());return _.x(c,Hp(a),0)})};
|
|
499
|
+
_.r.release=function(){var a=this;return _.dm.prototype.release.call(this).then(function(){return a.unload()}).then(function(){a.j&&tp(a.j,_.jp)})};
|
|
500
|
+
_.r.destroy=function(){var a=this;if(this.w)return this.log.warn("Player is already destroyed!"),Promise.resolve();this.w=!0;return _.dm.prototype.destroy.call(this).then(function(){return a.release()}).then(function(){a.log.debug(Ga);var b=a.getTrackManager();b&&b.destroy();a.l&&(a.l.destroy()["catch"](function(c){a.log.warn("Error while disposing metadata handler",c)}),a.l=null);a.j&&(a.j.destroy(),a.j=null);a.f=null})};_.r.getDrmInfo=function(){return this.o?this.o.getDrmInfo():null};
|
|
501
|
+
_.r.detach=function(){};_.r.getTrackManager=function(){return this.wd};
|
|
502
|
+
_.r.load=function(a){var b=this,c,d,e,f,g;return _.E(function(h){switch(h.a){case 1:if(b.w)return h["return"](Ep());if(!b.getSurface()||!b.getSurface().getMedia())return h["return"](Promise.reject("No surface or no media element in surface"));c=_.O;d=b.D.getMedia();b.I=Date.now()/1E3;b.f=new _.ep;b.h.on(b,_.eg,function(){b.f&&_.$o(b.f.a,b.getState())});tp(b.j,_.vp);b.Z=_.Bp(a);b.configuration=_.bm(b.Ic,a);b.log.debug(_.wb,b.configuration);b.log.debug(_.Mb,b.Z);e=_.Yo(b.configuration,[_.xe,"native"]);
|
|
503
|
+
b.ba=e.create(b);b.ba.setTextVisibility(!0);b.configuration.enableHtmlCue&&_.fm(_.lg)&&!_.el()&&(b.A=new vi(b),b.A.start(d));b.l?b.l.release():b.l=new Xh(b);Zh(b.l,d);f=b.getTrackManager();f.load();d.loop=!!b.configuration.loop;c.R(b.configuration.volume)||b.setVolume(b.configuration.volume);c.R(b.configuration.muted)||b.setMuted(b.configuration.muted);b.h.one(d,nd,function(){b.trigger(new _.L(_.Zu))});null==b.configuration.startTime&&Mp(b,d);_.bl()&&Np(b,d);_.A(h,2);return _.x(h,Gp(b,d),4);case 4:return _.x(h,
|
|
504
|
+
Jp(b),5);case 5:return _.x(h,Lp(b).P,6);case 6:_.oh(h,0);break;case 2:g=_.C(h),b.H=!1,b.onError(g),_.y(h)}})};_.r.onError=function(a){this.H||(a.severity===_.Q&&null!==this.j&&tp(this.j,_.up),this.trigger(new _.L(_.re,{detail:a})))};_.r.Ng=function(){return new yl};_.r.getState=function(){return null!==this.j?this.j.getState().currentState:_.kp};
|
|
505
|
+
_.r.getPresentationStartTime=function(){if(this.a&&this.a.getStartDate&&this.isLive()){var a=this.a.getStartDate();return isNaN(a.getTime())?(this.log.warn("EXT-X-PROGRAM-DATETIME required to get presentation start time as Date!"),null):a.getTime()/1E3}return null};_.r.getSeekRange=function(){var a=this.getSurface().getMedia();if(a&&a.src){a=a.seekable;if(a.length)return this.G=a={start:a.start(0),end:a.end(a.length-1)};if(this.G)return this.G}return{start:0,end:0}};
|
|
494
506
|
_.r.isLive=function(){return this.a&&this.a.src?Infinity===this.a.duration:!1};
|
|
495
|
-
_.r.getStats=function(){if(!this.f||!this.a)return _.
|
|
496
|
-
_.r.getTimelineCues=function(){return this.l?this.l.getTimelineCues():[]};
|
|
497
|
-
_.r.showMediaElement=function(){var a=this.getMedia();a?a.classList.remove(
|
|
498
|
-
_.r.removeElementFromContainer=function(a){var b=this.getContainer();if(!b)throw Error("No container is available. Unable to remove element");b.removeChild(a)};_.r.hide=function(a){_.
|
|
499
|
-
|
|
500
|
-
_.r.getDrmInfo=function(){return this.a?this.a.getDrmInfo():null};_.r.
|
|
501
|
-
_.r.destroy=function(){var a=this;if(this.
|
|
502
|
-
_.r.load=function(a){var b=this,c;return _.E(function(
|
|
503
|
-
_.r.preload=function(a){var b=this,c;return _.E(function(d){if(1==d.a)return _.x(d,_.
|
|
504
|
-
_.r.remove=function(a){return(this.getState()<=_.
|
|
505
|
-
_.r.getBufferInfo=function(a){return this.a?this.a.getBufferInfo(a):new _.
|
|
506
|
-
_.r.seek=function(a){return this.getState()===_.
|
|
507
|
-
_.r.getDuration=function(){return this.a?this.a.getDuration():-1};_.r.getAdsManager=function(){return this.j};_.r.namespace=function(){return this.a&&this.a.namespace()||"Undefined"};_.r.
|
|
508
|
-
_.r.
|
|
509
|
-
_.r.
|
|
510
|
-
X.prototype.
|
|
511
|
-
X.prototype.
|
|
512
|
-
X.prototype.
|
|
513
|
-
X.prototype.
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
_.r.
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
_.r.
|
|
524
|
-
_.r.
|
|
525
|
-
|
|
526
|
-
_.r.
|
|
527
|
-
a+")");case 3:_.
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
_.r.
|
|
531
|
-
_.
|
|
532
|
-
|
|
533
|
-
_.r.
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
_.r.
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
_.r.
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
507
|
+
_.r.getStats=function(){if(!this.f||!this.a)return _.fp();this.f&&_.$o(this.f.a,this.getState());var a=this.a,b=this.f,c=a.videoHeight;b.w=a.videoWidth;b.h=c;a.getVideoPlaybackQuality&&(a=a.getVideoPlaybackQuality(),b=this.f,c=Number(a.totalVideoFrames),b.l=Number(a.droppedVideoFrames),b.j=c,this.f.D=Number(a.corruptedVideoFrames));if(a=this.getTrackManager())if(a=a.ma())a.bandwidth&&(this.f.o=a.bandwidth),a.nd&&(this.f.f=a.nd);return this.f.getStats()};
|
|
508
|
+
_.r.getTimelineCues=function(){return this.l?this.l.getTimelineCues():[]};Op.prototype.a=function(){return Jd};Op.prototype.canPlay=function(a,b){var c=a.type||"",d=c===_.Uc,e=c===_.$c,f=c===_.El;return _.al()||d||e||f&&!_.bl()?0:""!==hl().canPlayType(c)?f&&_.bl()&&(window.ManagedMediaSource||window.MediaSource&&MediaSource.isTypeSupported)&&!b.streaming.preferNativeHlsOnSafari?1:2:0};Op.prototype.f=function(a){return a===_.pa};Op.prototype.create=function(){return new Dp};_.Nh(new Op);_.H("clpp.ads.PodType",{PREROLL:0,MIDROLL:1,POSTROLL:2});_.H("clpp.ads.Technology",{CLIENT_SIDE:0,SERVER_SIDE:1});_.H("clpp.ads.ErrorType",{LOAD:0,PLAY:1,OTHER:2});var Qp=new _.K("clpp.ads"),Pp=[];_.H("clpp.utils.dom.createHTMLElement",_.Xp);Yp.prototype.set=function(a){this.h.clear();this.f&&(this.f.disconnect(),this.f=null);if(this.a=a)this.f=$p(this,a)};Yp.prototype.get=function(){return this.a};_.r=dq.prototype;_.r.getMedia=function(){return this.f.get()};_.r.getContainer=function(){return this.a.get()};_.r.getSafeContainer=function(){return this.a};_.r.getId=function(){return this.l};_.r.getUniqueCssClass=function(){return this.o};_.r.getCastElement=function(){return this.h};_.r.isFullscreen=function(){return!!document.fullscreenElement};_.r.hideMediaElement=function(){var a=this.getMedia();a?_.Vp(a,Ad):this.g.debug("No media element available that could be hidden")};
|
|
509
|
+
_.r.showMediaElement=function(){var a=this.getMedia();a?a.classList.remove(Ad):this.g.debug("No media element available that could be shown")};_.r.addElementToContainer=function(a,b,c){b=void 0===b?!1:b;c=void 0===c?!1:c;var d=this.getContainer();if(!d)throw Error("No container is available. Unable to add element");b&&_.Vp(a,_.yd);c?d.insertBefore(a,d.firstElementChild):d.appendChild(a)};
|
|
510
|
+
_.r.removeElementFromContainer=function(a){var b=this.getContainer();if(!b)throw Error("No container is available. Unable to remove element");b.removeChild(a)};_.r.hide=function(a){_.Vp(a,Ad)};_.r.show=function(a){a.classList.remove(Ad)};_.r.release=function(){this.j.release()};dq.prototype.removeElementFromContainer=dq.prototype.removeElementFromContainer;dq.prototype.addElementToContainer=dq.prototype.addElementToContainer;dq.prototype.getCastElement=dq.prototype.getCastElement;
|
|
511
|
+
dq.prototype.getContainer=dq.prototype.getContainer;dq.prototype.getMedia=dq.prototype.getMedia;var aq={disableContainer:!1,webOSStartupPatch:!0,crossorigin:"anonymous",containerEl:null},bq=1;fq.prototype.release=function(){this.a.release();jq(this);this.m=null};_.H("clpp.polyfill.installAll",mq);var lq=[];_.H("clpp.polyfill.register",_.nq);pq.prototype.verify=function(a,b){var c=_.R.Ua,d={kty:"RSA",n:a.n,e:a.e},e=this.h+"."+this.f,f=this.j;return new Promise(function(g,h){try{var l=window&&window.crypto&&window.crypto.subtle}catch(n){}if(l){var m={name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}};l.importKey("jwk",d,m,!1,["verify"]).then(function(n){var p=c(e),q=_.xj(f);return l.verify(m,n,q.buffer,p.buffer)}).then(function(n){n?g():h(ac)})["catch"](h)}else b?h("Web Crypto API is not supported"):g()})};var kv={n:"vXdoJIQCz6sZ9pbduNukEHOR0H2dHlwuuBUAR5Ot7WLEYvav5mn63yxr6F6TIl8RHTFw2siXQhHblZH2Y89o8vhcZRFkYXo6h0igEVafu-n0w52UEcH8Cqzlb8Q7x03Qb8OcKLngSzDkwe5Y2Aix6I66RRVNLLssqyjp2n5tXs4JQmYdqY6hhpGhmBN84naeCTdcPpAYhCw8jqbTSNrJp5hjU4GVvOiUtoYCvdESV9xrOR7fPCFXhWfLtC3i1k1zVoIM7YW5qD0F676jhqkF-GmDuCHpRY2I2Cxui-ytYEVIM6_pylSIlmYLjARmv2jXz9aV_WvHLh6B8Yx0slNGCQ",e:"AQAB"},Yl="eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJ1cmxzIjpbIjovL2Nhc3RsYWJzLmNvbSJdLCJ0eXBlIjoiV2ViIiwia2lkIjoxOTUwLCJpbHYiOmZhbHNlfQ.jzGGRcbFr_2QET-4tbMcpR5pSaj7eV7X2d1HWw_VKQpPg3zCwSZSDuqw225dIYyAYwLSiElbozbZPSArkBXOsoUm-KZRUPF4m7WG0T7Uza5G-QaQw57BbbfcSsooSpatC997kHKLMTjO71By9Olcu5ykN164nZpGQtZNzQjYag-bnUaMVI5vvhzjlvDihORQ9V_qRlEh0-mpoz6W0-36HGAbWIXWq0kxPh6inbovby-ZmFpqGrVjWOEFa55EARZXPNW9ERupW5xrrYHZdwwTpdRTY5IwEnobS85yTrLhK8Y2MV4jlQLTtQp372fKDsuU6q6_4XvmNq1SgAoKoaf41g";qq.prototype.verify=function(){var a=this;return(new Promise(function(b,c){try{var d=rq(a);b(d)}catch(e){c()}})).then(function(b){return b.verify(kv)})["catch"](function(b){if(b&&b!==ac){var c=window.location.href;var d=new _.Ei(c);c=d.gb||d.Na?d:new _.Ei("//"+c);if(/(^127\.)|(^10\.)|(^172\.1[6-9]\.)|(^172\.2[0-9]\.)|(^172\.3[0-1]\.)|(^192\.168\.)|(^localhost)/.test(c.Na))return Promise.resolve()}throw b;})};var Cq="vod",Bq="live";_.w(X,_.Ul);_.r=X.prototype;_.r.on=function(a,b,c){return _.Ul.prototype.on.call(this,a,b,c)};_.r.one=function(a,b,c){return _.Ul.prototype.one.call(this,a,b,c)};_.r.off=function(a,b){return _.Ul.prototype.off.call(this,a,b)};_.r.onError=function(a){if(null!==this.a)this.a.onError(a);else this.trigger(new _.L(_.re,{detail:a}))};_.r.mc=function(a){a=this.I[a];void 0===a&&(a=null);return a};_.r.getSurface=function(){return this.h};_.r.getConfiguration=function(){return _.O.Ma(this.f)};
|
|
512
|
+
_.r.getDrmInfo=function(){return this.a?this.a.getDrmInfo():null};_.r.detach=function(){return this.a?this.a.detach():Promise.resolve()};_.r.release=function(){var a=this;if(null!=this.l)return this.g.info("Player release already in progress"),this.l;this.g.debug("Releasing player");this.l=Jq(this);return this.l["finally"](function(){a.g.debug("Player released");a.l=null})};
|
|
513
|
+
_.r.destroy=function(){var a=this;if(this.L)return this.g.debug("The player is already destroyed. No-op"),new Promise(function(b){return b()});this.L=!0;return this.release().then(function(){a.g.debug(Ga);a.trigger(new _.L("destroying"));return a.vc(_.$e)}).then(function(){a.a&&a.a.stopForwardingEventsTo(a);a.xd.clear();a.ia.release();if(a.a)return a.a.destroy()}).then(function(){return a.G.destroy()}).then(function(){nm();a.a=null;a.trigger(new _.L("destroyed"))})};
|
|
514
|
+
_.r.load=function(a){var b=this,c,d,e;return _.E(function(f){switch(f.a){case 1:return _.A(f,2),_.Yn(wf),b.K=_.pa,b.ba=!0,c=_.Bp(a),d=cm(a)?a:{},_.x(f,_.Rq(b,d,c),4);case 4:return _.x(f,_.Sq(b),5);case 5:return _.x(f,_.Oq(b),6);case 6:_.Yn(vf);_.Zn("player.load",wf,vf);_.oh(f,0);break;case 2:e=_.C(f);if(b.l)throw b.g.info(vb),new _.P(_.Q,7,7E3);throw e;}})};
|
|
515
|
+
_.r.preload=function(a){var b=this,c;return _.E(function(d){if(1==d.a)return _.x(d,_.Rq(b,a),2);if(!b.a)return b.g.warn(Lb),d["return"]();c=b.a;return c.preload?_.x(d,c.preload(b.f),0):(b.g.warn(Qb),d["return"]())})};_.r.vc=function(a,b){for(var c=[],d=1;d<arguments.length;++d)c[d-1]=arguments[d];if(!this.ba)return Promise.resolve();var e=this;d=this.$.map(function(f){var g=f[a];return g.call.apply(g,[f,e].concat(_.ah(c)))}).filter(function(f){return f instanceof Promise});return Promise.all(d)};
|
|
516
|
+
_.r.use=function(a){(a=om(a))&&a.o(this)};_.r.remove=function(a){return(this.getState()<=_.jp||this.N)&&null!==im(a)?(pm(a),this.T=!0):!1};_.r.play=function(){return this.a?this.j&&this.a.namespace()!==_.Fd?this.j.start(this.a):this.a.play():Promise.reject("No player initialized. You need to load content before calling play.")};_.r.pause=function(){return this.a?this.a.pause():Promise.reject("No player initialized. You need to load content before calling pause.")};
|
|
517
|
+
_.r.getTrackManager=function(){return this.a&&this.a.getTrackManager()};_.r.getBufferInfo=function(a){return this.a?this.a.getBufferInfo(a):new _.Tl};_.r.getState=function(){return this.a?this.a.getState():_.jp};_.r.getPeriods=function(){return this.a?this.a.getPeriods():[]};_.r.isEnded=function(){return this.a&&this.a.isEnded()||!1};_.r.isPaused=function(){return this.a&&this.a.isPaused()||!1};_.r.getPosition=function(){return this.a?this.a.getPosition():0};
|
|
518
|
+
_.r.seek=function(a){return this.getState()===_.up?Promise.reject("Cannot seek in current state."):this.a?this.a.seek(a):Promise.reject("delegate does not exist")};_.r.getPresentationStartTime=function(){return this.a?this.a.getPresentationStartTime():null};_.r.getSeekRange=function(){return this.a?this.a.getSeekRange():{start:0,end:0}};_.r.nc=function(){var a=this.a;return a&&a.nc?a.nc():null};_.r.getVolume=function(){return this.a?this.a.getVolume():null};_.r.setVolume=function(a){this.a&&this.a.setVolume(a)};
|
|
519
|
+
_.r.getDuration=function(){return this.a?this.a.getDuration():-1};_.r.getAdsManager=function(){return this.j};_.r.namespace=function(){return this.a&&this.a.namespace()||"Undefined"};_.r.getPlaybackRate=function(){return this.a?this.a.getPlaybackRate():1};_.r.setPlaybackRate=function(a,b){this.a&&this.a.setPlaybackRate(a,b)};_.r.isMuted=function(){return this.a&&this.a.isMuted()||!1};_.r.setMuted=function(a){this.a&&this.a.setMuted(a)};_.r.getNetworkEngine=function(){return this.G};
|
|
520
|
+
_.r.setNetworkEngine=function(a){this.G=a};_.r.getTextDisplayer=function(){return this.a&&this.a.getTextDisplayer()};_.r.isLive=function(){return!!this.a&&this.a.isLive()};_.r.getStats=function(){return this.a?this.a.getStats():null};_.r.ih=function(){return Object.freeze(this.fa)};_.r.getLoadedSource=function(){return this.a&&this.a.getLoadedSource()};_.r.getTimelineCues=function(){return this.a?this.a.getTimelineCues():[]};_.r.re=function(){return this.a?this.a.re():null};
|
|
521
|
+
_.r.resetAbr=function(){this.a&&this.a.resetAbr()};_.r.setDrmCustomDataModifier=function(a){this.Tc=a;Qq(this)};_.r.setCdnErrorCallback=function(a){this.J=a;this.a&&this.a.setCdnErrorCallback(this.J)};_.r.Ch=function(){this.nf=!0};_.H("clpp.Player",X);X.registerPlugin=_.Vq;X.prototype.setCdnErrorCallback=X.prototype.setCdnErrorCallback;X.prototype.setDrmCustomDataModifier=X.prototype.setDrmCustomDataModifier;X.prototype.resetAbr=X.prototype.resetAbr;X.prototype.getTimelineCues=X.prototype.getTimelineCues;
|
|
522
|
+
X.prototype.getLoadedSource=X.prototype.getLoadedSource;X.prototype.getSources=X.prototype.ih;X.prototype.getStats=X.prototype.getStats;X.prototype.isLive=X.prototype.isLive;X.prototype.getTextDisplayer=X.prototype.getTextDisplayer;X.prototype.setNetworkEngine=X.prototype.setNetworkEngine;X.prototype.getNetworkEngine=X.prototype.getNetworkEngine;X.prototype.isMuted=X.prototype.isMuted;X.prototype.setPlaybackRate=X.prototype.setPlaybackRate;X.prototype.getPlaybackRate=X.prototype.getPlaybackRate;
|
|
523
|
+
X.prototype.namespace=X.prototype.namespace;X.prototype.getAdsManager=X.prototype.getAdsManager;X.prototype.getDuration=X.prototype.getDuration;X.prototype.setVolume=X.prototype.setVolume;X.prototype.getVolume=X.prototype.getVolume;X.prototype.getTimelineOffset=X.prototype.nc;X.prototype.getSeekRange=X.prototype.getSeekRange;X.prototype.getPresentationStartTime=X.prototype.getPresentationStartTime;X.prototype.seek=X.prototype.seek;X.prototype.getPosition=X.prototype.getPosition;
|
|
524
|
+
X.prototype.isPaused=X.prototype.isPaused;X.prototype.isEnded=X.prototype.isEnded;X.prototype.getState=X.prototype.getState;X.prototype.getBufferInfo=X.prototype.getBufferInfo;X.prototype.getTrackManager=X.prototype.getTrackManager;X.prototype.pause=X.prototype.pause;X.prototype.play=X.prototype.play;X.prototype.remove=X.prototype.remove;X.prototype.use=X.prototype.use;X.prototype.load=X.prototype.load;X.prototype.destroy=X.prototype.destroy;X.prototype.release=X.prototype.release;
|
|
525
|
+
X.prototype.getDrmInfo=X.prototype.getDrmInfo;X.prototype.getConfiguration=X.prototype.getConfiguration;X.prototype.getSurface=X.prototype.getSurface;X.prototype.getPlugin=X.prototype.mc;X.prototype.off=X.prototype.off;X.prototype.one=X.prototype.one;X.prototype.on=X.prototype.on;_.jp=0;_.vp=1;_.op=2;_.xp=3;_.wp=4;_.qp=5;_.up=6;_.kp=7;_.sp={IDLE:_.jp,PREPARING:_.vp,BUFFERING:_.op,PLAYING:_.xp,PAUSED:_.wp,ENDED:_.qp,ERROR:_.up,UNSET:_.kp};X.State=_.sp;var Fq=[];_.w(Wq,X);_.r=Wq.prototype;
|
|
526
|
+
_.r.open=function(a,b){var c=this,d,e,f,g,h,l,m;return _.E(function(n){if(1==n.a){if(c.w)throw new _.P(_.Q,7,7008,"Cannot call open() while "+c.w+fa);if(0!==a)throw new _.P(_.Q,7,7007,"The index parameter only supports the value of 0.");if(0===b.length)throw new _.P(_.Q,7,7003,Db);if(b.some(function(p){return!p.id||!p.source}))throw new _.P(_.Q,7,7100,"Some config is missing required properties `id` or `source`!");d=new Set(b.map(function(p){return p.id}));if(d.size!==b.length)throw new _.P(_.Q,7,
|
|
527
|
+
7100,"Some config contains a non-unique property `id`!");if(e=b[0].playlist){f=e.timeline;g=["flat","basic"];if(f&&!g.includes(f))throw new _.P(_.Q,7,7100,"Unsupported `playlist.timeline` config value!");h=e.startTime;if(null!=h&&(typeof h!==_.k||0>h))throw new _.P(_.Q,7,7100,"Invalid `playlist.startTime` config value!");l=e.endTime;if(null!=l&&(typeof l!==_.k||0>l||null!=h&&l<=h))throw new _.P(_.Q,7,7100,"Invalid `playlist.endTime` config value!");m=e.content;if("DVR"===m&&!l)throw new _.P(_.Q,7,
|
|
528
|
+
7100,"`playlist.endTime` config value is required for DVR content!");}nh(n);Xq(c);c.w="open";return _.x(n,ar(c,b),4)}2!=n.a&&(c.B=0,c.o=b,c.V=!0,Yq(c,b[0].playlist||{}));_.ph(n);c.w=null;return _.qh(n,0)})};
|
|
529
|
+
_.r.Ai=function(a){var b=this,c;return _.E(function(d){if(1==d.a){if(b.w)throw new _.P(_.Q,7,7008,"Cannot call addItem() while "+b.w+fa);if(!b.V)throw new _.P(_.Q,7,7008,"open() must be called before addItem()!");if(!a.id||!a.source)throw new _.P(_.Q,7,7100,"The config is missing required properties `id` or `source`!");c=new Set(b.o.map(function(e){return e.id}));if(c.has(a.id))throw new _.P(_.Q,7,7100,"A config with this `id` already exists in the playlist!");nh(d);b.w="addItem";b.o.push(a);return _.x(d,
|
|
530
|
+
br(b,a),2)}_.ph(d);b.w=null;return _.qh(d,0)})};_.r.getCurrentItem=function(){return this.o[this.B]||null};_.r.getCurrentItemIndex=function(){return this.B};_.r.Fk=function(){return _.ah(this.o).concat()};_.r.Ed=function(){return this.o.length};_.r.getTimeline=function(){return this.a?this.a.getTimeline():null};_.r.seekWith=function(a){return this.a?this.a.seekWith(a):Promise.resolve()};_.r.release=function(){this.o=[];this.B=0;this.V=!1;return X.prototype.release.call(this)};
|
|
531
|
+
_.r.destroy=function(){Xq(this);return X.prototype.destroy.call(this)};_.r.setCdnErrorCallback=function(){throw new _.P(1,7,7009,"CDN switching is not supported!");};_.H("clpp.plist.ScPlaylist",Wq);Wq.prototype.setCdnErrorCallback=Wq.prototype.setCdnErrorCallback;Wq.prototype.destroy=Wq.prototype.destroy;Wq.prototype.release=Wq.prototype.release;Wq.prototype.seekWith=Wq.prototype.seekWith;Wq.prototype.getTimeline=Wq.prototype.getTimeline;Wq.prototype.getSize=Wq.prototype.Ed;
|
|
532
|
+
Wq.prototype.getPlaylist=Wq.prototype.Fk;Wq.prototype.getCurrentItemIndex=Wq.prototype.getCurrentItemIndex;Wq.prototype.getCurrentItem=Wq.prototype.getCurrentItem;Wq.prototype.addItem=Wq.prototype.Ai;Wq.prototype.open=Wq.prototype.open;cr.prototype.has=function(){return this.a.some(function(a){return a.he})};cr.prototype.get=function(){var a=this,b;return _.E(function(c){if(1==c.a){b=a.a.find(function(d){return d.he});if(!b)throw Error("No available players in the pool");b.he=!1;return _.x(c,b.ready,2)}return c["return"](b.player)})};
|
|
533
|
+
cr.prototype.release=function(a){var b=this,c=this.a.find(function(d){return d.player===a});if(!c)return Promise.resolve();c.he=!0;c.ready=new Promise(function(d){a.release()["catch"](function(e){b.g.error("Failed to unload player",e)}).then(d)});return c.ready};cr.prototype.destroy=function(){var a=this;return _.E(function(b){return _.x(b,Promise.all(a.a.map(function(c){return c.player.destroy()})),0)})};_.w(fr,_.Ul);_.r=fr.prototype;_.r.Dd=function(){return this.f};_.r.Ab=function(){return this.f?this.f.player:null};_.r.dh=function(){return this.l.get(this.a+1)||null};_.r.fh=function(){return this.l.get(this.a-1)||null};_.r.wf=function(){return[this.fh(),this.dh()].filter(Boolean)};_.r.Hm=function(a){if(0<this.h.length)throw Error("Cannot re-set items in the playlist");this.g.info("Set items",a);this.h=a.map(function(b,c){return{config:b,index:c,preloadPromise:Promise.resolve(),disposers:[]}})};
|
|
534
|
+
_.r.Gm=function(a){if(0===this.h.length)throw Error(Cb);if(0>a||a>this.h.length-1)throw Error("Index out of bounds");this.a=a};_.r.Xc=function(){return this.a<this.h.length-1};_.r.kh=function(){return 0<this.a};
|
|
535
|
+
_.r.rm=function(){var a=this,b,c;return _.E(function(d){switch(d.a){case 1:if(a.j)return a.g.warn("Cannot play first item while busy"),d["return"]();if(0===a.h.length)return a.g.warn(Cb),d["return"]();a.j=!0;a.g.info("First (index: "+a.a+")");b=a.h[a.a];_.A(d,2,3);a.g.info("First loading (index: "+a.a+")");return _.x(d,nr(a,b),5);case 5:a.g.info("First playing (index: "+a.a+")");case 3:_.ph(d);a.j=!1;sr(a);_.qh(d,0);break;case 2:throw c=_.C(d),a.g.error("First failed (index: "+a.a+")"),c;}})};
|
|
536
|
+
_.r.Vh=function(){var a=this,b,c,d;return _.E(function(e){switch(e.a){case 1:if(a.j)return a.g.warn("Cannot play next item while busy"),e["return"]();if(!a.Xc())return a.g.warn("There are no more items in the playlist"),e["return"]();a.j=!0;a.a+=1;a.g.info("Next (index: "+a.a+")");b=a.f;a.o.transition===_.gf&&b.player.pause();gr(a,a.a+-2);a.l["delete"](a.a);c=a.h[a.a];_.A(e,2,3);a.g.info("Next loading (index: "+a.a+")");return _.x(e,or(a,c),5);case 5:a.g.info("Next playing (index: "+a.a+")");case 3:_.ph(e);
|
|
537
|
+
a.j=!1;b&&kr(a,b);sr(a);_.qh(e,0);break;case 2:throw d=_.C(e),a.g.error("Next failed (index: "+a.a+")"),d;}})};
|
|
538
|
+
_.r.sm=function(){var a=this,b,c,d;return _.E(function(e){switch(e.a){case 1:if(a.j)return a.g.warn("Cannot play previous item while busy"),e["return"]();if(!a.kh())return a.g.warn("There are no more previous items in the playlist"),e["return"]();a.j=!0;--a.a;a.g.info("Previous (index: "+a.a+")");b=a.f;a.o.transition===_.gf&&b.player.pause();gr(a,a.a+2);a.l["delete"](a.a);c=a.h[a.a];_.A(e,2,3);a.g.info("Previous loading (index: "+a.a+")");return _.x(e,or(a,c),5);case 5:a.g.info("Previous playing (index: "+
|
|
539
|
+
a.a+")");case 3:_.ph(e);a.j=!1;b&&kr(a,b);sr(a);_.qh(e,0);break;case 2:throw d=_.C(e),a.g.error("Previous failed (index: "+a.a+")"),d;}})};_.r.destroy=function(){var a=this;return _.E(function(b){return 1==b.a?(a.g.info("Destroy"),_.x(b,Promise.all([hr(a),a.f?kr(a,a.f):Promise.resolve()]),2)):_.x(b,tr(a),0)})};_.H(Kd,fr);fr.prototype.destroy=fr.prototype.destroy;fr.prototype.playPrev=fr.prototype.sm;fr.prototype.playNext=fr.prototype.Vh;fr.prototype.playFirst=fr.prototype.rm;
|
|
540
|
+
fr.prototype.hasPrev=fr.prototype.kh;fr.prototype.hasNext=fr.prototype.Xc;fr.prototype.setIndex=fr.prototype.Gm;fr.prototype.setItems=fr.prototype.Hm;fr.prototype.getPreloading=fr.prototype.wf;fr.prototype.getPrev=fr.prototype.fh;fr.prototype.getNext=fr.prototype.dh;fr.prototype.getCurrentPlayer=fr.prototype.Ab;fr.prototype.getCurrent=fr.prototype.Dd;var jr="preload",lr=_.Me;var ur=new Map;_.r=wr.prototype;_.r.destroy=function(){this.a.dispose();this.a=null};_.r.reset=function(){this.a=new muxjs.mp4.Transmuxer(this.f)};_.r.isSupported=function(a,b){var c="mp2t"===a.toLowerCase().split(";")[0].split("/")[1],d=a.toLowerCase().split(";")[0]===_.cd;if(!window.muxjs||!c&&!d)return!1;if(d)return _.vr(gd);if(b)return _.vr(xr(b,a));c=xr(_.bd,a);d=xr(_.Fg,a);return _.vr(c)||_.vr(d)};_.r.isMuxed=function(a,b){return 1<this.demuxMimeTypes(a,b).size};
|
|
541
|
+
_.r.demuxMimeTypes=function(a,b){var c=new Map;c.set(a,b);try{var d=b.split(";")[0],e=Sk(b).split(","),f=new Map,g=Si(_.bd,e),h=Si(_.Fg,e);g&&f.set(_.bd,this.convertCodecs(_.bd,_.Rk(d,g)));h&&f.set(_.Fg,this.convertCodecs(_.Fg,_.Rk(d,h)));return f}catch(l){return c}};_.r.convertCodecs=function(a,b){return b.toLowerCase().split(";")[0]===_.cd?gd:"mp2t"===b.toLowerCase().split(";")[0].split("/")[1]?xr(a,b):b};_.r.getOriginalMimeType=function(){return this.h};
|
|
542
|
+
_.r.transmux=function(a){function b(){g={video:Bj.apply(uj,_.ah(d)),captions:f,audio:Bj.apply(uj,_.ah(e))}}function c(h){f=h.captions;var l=new Uint8Array(h.data.byteLength+h.initSegment.byteLength);l.set(h.initSegment,0);l.set(h.data,h.initSegment.byteLength);h.type===lv?d.push(l):h.type===mv&&e.push(l)}var d=[],e=[],f=[],g=null;a=_.lj(a);this.a.on("data",c);this.a.on("done",b);this.a.push(a);this.a.flush();this.a.off("data",c);this.a.off("done",b);if(!g)throw new _.P(_.Q,3,3018);return g};
|
|
543
|
+
Mk(_.cd,function(){return new wr(_.cd)});Mk(_.Gg,function(){return new wr(_.Gg)});var mv=_.bd,lv=_.Fg;_.w(Ar,_.Ul);_.r=Ar.prototype;_.r.getCurrentItem=function(){return this.a};_.r.Ab=function(){return this.a?this.a.player:null};_.r.wf=function(){return Array.from(this.f.values())};_.r.ge=function(a){this.g.info("Add items",a);this.j=this.j.concat(a.map(function(b){return Object.assign({},b,{state:"idle",disposers:[],preloadPromise:Promise.resolve(),Td:Promise.resolve()})}))};
|
|
544
|
+
_.r.removeItems=function(a){this.g.info("Remove items",a);a?this.j=this.j.filter(function(b){return!a.includes(b.id)}):this.j=[]};_.r.Xc=function(){return 0<this.f.size};
|
|
545
|
+
_.r.play=function(a){var b=this,c,d,e,f;return _.E(function(g){switch(g.a){case 1:if(b.h)return b.g.warn("Cannot play item while busy (ID: "+a+")"),g["return"]();c=b.getItem(a);if(!c)return b.g.warn(rb+a+")"),g["return"]();b.g.info("Play item (ID: "+a+")");b.h=!0;(d=b.a)&&d.player.pause();(e=b.f.has(a))&&b.f["delete"](a);_.A(g,2,3);b.g.info(qb+a+")");return e?_.x(g,Nr(b,c),6):_.x(g,Lr(b,c),6);case 6:c.uc&&c.uc(),b.trigger(new _.L(Ae,{detail:c})),Dr(b,c),b.g.info("Item playing (ID: "+a+")");case 3:_.ph(g);
|
|
546
|
+
b.h=!1;d&&Jr(b,d);Er(b);Fr(b,c.next);_.qh(g,0);break;case 2:throw f=_.C(g),b.g.error(pb+a+")"),f;}})};
|
|
547
|
+
_.r.load=function(a){var b=this,c,d,e,f;return _.E(function(g){switch(g.a){case 1:if(b.h)return b.g.warn("Cannot load item while busy (ID: "+a+")"),g["return"]();c=b.getItem(a);if(!c)return b.g.warn(rb+a+")"),g["return"]();b.g.info("Load item (ID: "+a+")");b.h=!0;(d=b.a)&&d.player.pause();(e=b.f.has(a))&&b.f["delete"](a);_.A(g,2,3);b.g.info(qb+a+")");if(e){b.g.error("Loading preloaded items is not supported");g.F(5);break}return _.x(g,Kr(b,c),5);case 5:b.trigger(new _.L(Ae,{detail:c})),Dr(b,c),b.g.info("Item loaded (ID: "+
|
|
548
|
+
a+")");case 3:_.ph(g);b.h=!1;d&&Jr(b,d);Er(b);Fr(b,c.next);_.qh(g,0);break;case 2:throw f=_.C(g),b.g.error(pb+a+")"),f;}})};_.r.getItem=function(a){return this.j.find(function(b){return b.id===a})||null};_.r.release=function(){var a=this;return _.E(function(b){if(1==b.a)return _.x(b,Promise.all([Er(a),a.a?Jr(a,a.a):Promise.resolve()]),2);a.a=null;a.h=!1;a.removeItems();Cr(a,!0);_.y(b)})};
|
|
549
|
+
_.r.destroy=function(){var a=this;return _.E(function(b){return 1==b.a?(a.g.info("Destroy"),_.x(b,a.release(),2)):_.x(b,Pr(a),0)})};Ar.prototype.destroy=Ar.prototype.destroy;Ar.prototype.release=Ar.prototype.release;Ar.prototype.getItem=Ar.prototype.getItem;Ar.prototype.load=Ar.prototype.load;Ar.prototype.play=Ar.prototype.play;Ar.prototype.hasNext=Ar.prototype.Xc;Ar.prototype.removeItems=Ar.prototype.removeItems;Ar.prototype.addItems=Ar.prototype.ge;Ar.prototype.getPreloading=Ar.prototype.wf;
|
|
550
|
+
Ar.prototype.getCurrentPlayer=Ar.prototype.Ab;Ar.prototype.getCurrentItem=Ar.prototype.getCurrentItem;var Ir="preload",Mr=_.Me;_.w(Ur,_.Ul);_.r=Ur.prototype;_.r.load=function(a){var b=this,c;return _.E(function(d){if(1==d.a)return _.x(d,Wr(b,a,!1),2);b.trigger(new _.L(nv));c=b.a.getCurrentItem();c.primary&&b.trigger(new _.L(vs));_.y(d)})};_.r.Cd=function(){var a=this.l;return a?this.j.map(function(b){return{cueId:b.cueId,startTime:b.startTime,endTime:b.endTime,primaryDuration:a}}):[]};_.r.gl=function(a){var b=this;return _.E(function(c){return _.x(c,Wr(b,a,!0),0)})};
|
|
551
|
+
_.r.unload=function(){var a=this;return _.E(function(b){if(1==b.a)return _.x(b,a.a.release(),2);a.j=[];_.y(b)})};_.r.destroy=function(){var a=this;return _.E(function(b){return _.x(b,a.a.destroy(),0)})};_.r.Wm=function(){var a=this,b;return _.E(function(c){if(1==c.a)return _.x(c,Br(a.a),2);a.trigger(new _.L(nv));b=a.a.getCurrentItem();b.primary&&a.trigger(new _.L(vs));_.y(c)})};_.r.getPosition=function(){var a=this.a.Ab();return a?a.getPosition():null};_.r.Ab=function(){return this.a.Ab()};
|
|
552
|
+
_.r.getCurrentItem=function(){return this.a.getCurrentItem()};_.H(Id,Ur);Ur.prototype.getCurrentItem=Ur.prototype.getCurrentItem;Ur.prototype.getCurrentPlayer=Ur.prototype.Ab;Ur.prototype.getPosition=Ur.prototype.getPosition;Ur.prototype.unpause=Ur.prototype.Wm;Ur.prototype.destroy=Ur.prototype.destroy;Ur.prototype.unload=Ur.prototype.unload;Ur.prototype.loadPaused=Ur.prototype.gl;Ur.prototype.getCues=Ur.prototype.Cd;Ur.prototype.load=Ur.prototype.load;
|
|
553
|
+
var bs="new",hs="preparing",js="ready",us="completed",ks="failed",is="interstitial-preload-started",ls="x-asset-list-request-started",ns="x-asset-list-request-ended",qs="interstitial-scheduled",ss="interstitial-started",ts="interstitial-ended",rs="interstitial-item-started",Tr="primary-player-changed",Qr="item-changed",nv="playback-started",vs="primary-started",fs="primary-ended",as="cues-changed";_.r=xs.prototype;_.r.yb=function(){};_.r.zb=function(){};_.r.Fb=function(){};_.r.getId=function(){};_.r.getCreativeId=function(){};_.r.getApiFramework=function(){};_.r.getAdSystem=function(){};_.r.getAdvertiserName=function(){};_.r.getTitle=function(){};_.r.getDuration=function(){};_.r.getSkipTimeOffset=function(){};_.r.rc=function(){};_.r.Sb=function(){};_.r.getMediaUrl=function(){};_.r.Cb=function(){};_.r.Bb=function(){};_.r.ob=function(){};_.r.eb=function(){};_.r.getPodIndex=function(){};
|
|
554
|
+
_.r.Tb=function(){};_.r.Ub=function(){};_.r.Eb=function(){};_.r.getWrapperAdIds=function(){};_.r.getWrapperAdSystems=function(){};_.r.getWrapperCreativeIds=function(){};_.H("clpp.ads.IAd",xs);xs.prototype.getWrapperCreativeIds=xs.prototype.getWrapperCreativeIds;xs.prototype.getWrapperAdSystems=xs.prototype.getWrapperAdSystems;xs.prototype.getWrapperAdIds=xs.prototype.getWrapperAdIds;xs.prototype.getSequenceLength=xs.prototype.Eb;xs.prototype.getPositionInSequence=xs.prototype.Ub;
|
|
555
|
+
xs.prototype.getPodTimeOffset=xs.prototype.Tb;xs.prototype.getPodIndex=xs.prototype.getPodIndex;xs.prototype.getPodType=xs.prototype.eb;xs.prototype.getMediaBitrate=xs.prototype.ob;xs.prototype.getMediaHeight=xs.prototype.Bb;xs.prototype.getMediaWidth=xs.prototype.Cb;xs.prototype.getMediaUrl=xs.prototype.getMediaUrl;xs.prototype.getClickThroughUrl=xs.prototype.Sb;xs.prototype.isBumper=xs.prototype.rc;xs.prototype.getSkipTimeOffset=xs.prototype.getSkipTimeOffset;xs.prototype.getDuration=xs.prototype.getDuration;
|
|
556
|
+
xs.prototype.getTitle=xs.prototype.getTitle;xs.prototype.getAdvertiserName=xs.prototype.getAdvertiserName;xs.prototype.getAdSystem=xs.prototype.getAdSystem;xs.prototype.getApiFramework=xs.prototype.getApiFramework;xs.prototype.getCreativeId=xs.prototype.getCreativeId;xs.prototype.getId=xs.prototype.getId;xs.prototype.getTechnology=xs.prototype.Fb;xs.prototype.getAdManagerVersion=xs.prototype.zb;xs.prototype.getAdManagerName=xs.prototype.yb;ys.prototype.name=function(){};ys.prototype.isSupported=function(){};ys.prototype.create=function(){};_.H("clpp.ads.IAdsManagerFactory",ys);ys.prototype.create=ys.prototype.create;ys.prototype.isSupported=ys.prototype.isSupported;ys.prototype.name=ys.prototype.name;_.r=zs.prototype;_.r.load=function(){};_.r.start=function(){};_.r.resume=function(){};_.r.pause=function(){};_.r.skip=function(){};_.r.getVolume=function(){};_.r.setVolume=function(){};_.r.getPosition=function(){};_.r.dispose=function(){};_.H("clpp.ads.IAdsManager",zs);zs.prototype.getPosition=zs.prototype.getPosition;zs.prototype.setVolume=zs.prototype.setVolume;zs.prototype.getVolume=zs.prototype.getVolume;zs.prototype.skip=zs.prototype.skip;zs.prototype.pause=zs.prototype.pause;
|
|
557
|
+
zs.prototype.resume=zs.prototype.resume;_.r=As.prototype;_.r.load=function(){return Promise.resolve()};_.r.start=function(a){return a.play()};_.r.resume=function(){};_.r.pause=function(){};_.r.skip=function(){};_.r.getVolume=function(){return 1};_.r.setVolume=function(){};_.r.getPosition=function(){return-1};_.r.dispose=function(){return _.E(function(a){_.y(a)})};As.prototype.dispose=As.prototype.dispose;As.prototype.getPosition=As.prototype.getPosition;As.prototype.setVolume=As.prototype.setVolume;As.prototype.getVolume=As.prototype.getVolume;
|
|
558
|
+
As.prototype.skip=As.prototype.skip;As.prototype.pause=As.prototype.pause;As.prototype.resume=As.prototype.resume;As.prototype.start=As.prototype.start;As.prototype.load=As.prototype.load;Sp.prototype.name=function(){return"clpp.ads.NopAdsManagerFactory"};Sp.prototype.isSupported=function(){return!0};Sp.prototype.create=function(){return new As};Sp.prototype.create=Sp.prototype.create;Sp.prototype.isSupported=Sp.prototype.isSupported;Sp.prototype.name=Sp.prototype.name;Bs.prototype.getCuePoints=function(){};Bs.prototype.Wb=function(){};Bs.prototype.qb=function(){};_.H("clpp.ads.IAdsTimeline",Bs);Bs.prototype.hasPostroll=Bs.prototype.qb;Bs.prototype.hasPreroll=Bs.prototype.Wb;Bs.prototype.getCuePoints=Bs.prototype.getCuePoints;_.Cs.prototype.f=function(){};_.Cs.prototype.a=function(){};_.Cs.prototype.h=function(){};_.Cs.prototype.o=function(){};_.r=Ds.prototype;_.r.ne=function(a){this.a=a};_.r.qd=function(a){return this.a?this.a.setMediaKeys(a):Promise.reject(zb)};_.r.te=function(){return this.a&&this.a.mediaKeys};_.r.ic=function(a,b){this.g.debug("Requesting media key system access for",a,b.map(function(c){return Object.assign({},c,{drmInfos:c.drmInfos.map(function(){return"_anonymous_"})})}));return navigator.requestMediaKeySystemAccess(a,b)["catch"](function(c){c.message&&(c=Error(c.message+" (keySystem: "+a+")"));return Promise.reject(c)})};
|
|
559
|
+
_.r.pd=function(){return Ub};Es.prototype.a=function(){return Ub};Es.prototype.isSupported=function(){return!!(window.MediaKeys&&navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)};Es.prototype.create=function(){return new Ds};An(new Es,1E3);_.r=Fs.prototype;_.r.getStatus=function(){return this.a};_.r.forEach=function(a){this.a&&a(this.a,ov.value())};_.r.get=function(a){if(this.has(a))return this.a};_.r.has=function(a){var b=ov.value();return this.a&&nj(a,b)?!0:!1};_.r.entries=function(){};_.r.keys=function(){};_.r.values=function(){};var ov=new _.gp(function(){return tj(new Uint8Array([0]))});_.r=Hs.prototype;_.r.ne=function(){};_.r.qd=function(a){_.Hh("NopEmeManager.setMediaKeys");return null===a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))};_.r.te=function(){return null};_.r.ic=function(){_.Hh("NopEmeManager.requestMediaKeySystemAccess");return Promise.reject(Error("The key system specified is not supported."))};_.r.pd=function(){return"NOP"};Is.prototype.a=function(){return"NOP"};Is.prototype.isSupported=function(){return!0};Is.prototype.create=function(){return new Hs};
|
|
560
|
+
An(new Is,-1);_.r=Js.prototype;_.r.ne=function(a){this.f=a};_.r.qd=function(a){var b=this.a;b&&b!==a&&Ms(b,null);return(this.a=a)?Ms(a,this.f):Promise.resolve()};_.r.te=function(){return this.a};_.r.ic=function(a,b){_.Hh("AppleEmeManager.requestMediaKeySystemAccess");try{var c=new Ks(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}};_.r.pd=function(){return"APPLE"};Ks.prototype.createMediaKeys=function(){var a=new Ls(this.keySystem);return Promise.resolve(a)};
|
|
561
|
+
Ks.prototype.getConfiguration=function(){_.Hh("AppleEmeManager.MediaKeySystemAccess.getConfiguration");return this.a};Ls.prototype.createSession=function(a){a=void 0===a?mg:a;this.g.debug("Creating Apple MediaKeys Session");if(a!==mg)throw new TypeError("Session type "+a+ca);return new Ns(this.h,"__session_"+this.j++)};Ls.prototype.setServerCertificate=function(){this.g.debug("AppleEmeManager.MediaKeys.setServerCertificate");return Promise.resolve(!1)};_.w(Ns,_.Ul);_.r=Ns.prototype;
|
|
562
|
+
_.r.generateRequest=function(a,b){var c=this;if(this.l)return Promise.reject(Yb);this.g.debug("generateRequest");this.h=new _.Oj;try{var d=this.o.createSession(_.Hg,_.lj(b));this.a=d;this.sessionId=d.sessionId||this.sessionId||"";this.j.on(d,Sg,function(e){var f=c.keyStatuses.getStatus();c.g.debug("Received Key Message in "+c.sessionId);c.h&&(c.h.resolve(),c.h=null);e=new _.L(_.Pe,{messageType:void 0===f||f===fg?Fe:De,message:tj(e.message.buffer)});c.dispatchEvent(e)});this.j.on(d,Qg,function(e){c.g.debug("onWebkitKeyAdded_",
|
|
563
|
+
e);c.f&&(Os(c,"usable"),c.f.resolve(),c.f=null)});this.j.on(d,Rg,function(){var e=c.keyStatuses.getStatus();if(c.a&&c.a&&c.a.error&&c.a.error.code===WebKitMediaKeyError.MEDIA_KEYERR_DOMAIN&&e===fg)c.g.warn("Ignoring webkit key error for session "+c.sessionId);else if(c.g.error("Received key error in session "+c.sessionId+" with code "+(c.a.error.code+". Session Status ")+(e+".")),e=Error("EME AppleEmeManager key error"),e.errorCode=c.a.error,null!==c.h)c.h.reject(e),c.h=null;else if(null!==c.f)c.f.reject(e),
|
|
564
|
+
c.f=null;else switch(c.a.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:Os(c,"output-not-allowed");break;default:Os(c,_.ze)}});Os(this,fg)}catch(e){this.h.reject(e)}return this.h};_.r.load=function(){this.g.debug("load");return Promise.reject(Error("MediaKeySession.load not yet supported"))};_.r.update=function(a){if(this.l)return Promise.reject(Yb);this.g.debug(xg);this.f=new _.Oj;try{this.a.update(_.lj(a))}catch(b){this.f.reject(b)}return this.f};
|
|
565
|
+
_.r.close=function(){if(this.l)return this.closed;this.g.info("Closing Key Session "+this.sessionId);this.l=!0;try{this.a.close(),this.closed.resolve(),_.Vh(this.j)}catch(a){this.closed.reject(a)}return this.closed};_.r.remove=function(){this.g.debug("remove");return Promise.reject(Error("MediaKeySession is only applicable for persistent licenses, which are not supported on this platform"))};Ps.prototype.a=function(){return"APPLE"};Ps.prototype.isSupported=function(){return!!window.WebKitMediaKeys};
|
|
566
|
+
Ps.prototype.create=function(){return new Js};An(new Ps,1100);_.r=Qs.prototype;_.r.ne=function(a){this.a=a};_.r.qd=function(a){_.Hh("WebkitEmeManager.setMediaKeys");if(!this.a)return Promise.reject(zb);var b=this.f;b&&b!==a&&Vs(b,null);(this.f=a)&&Vs(a,this.a);return Promise.resolve()};_.r.te=function(){return this.f};_.r.ic=function(a,b){_.Hh("WebkitEmeManager.requestMediaKeySystemAccess");try{if(this.a)var c=this.a;else{var d=document.getElementsByTagName(_.Fg);c=d.length?d[0]:document.createElement(_.Fg)}var e=new Rs(this.h,c,a,b);return Promise.resolve(e)}catch(f){return Promise.reject(f)}};
|
|
567
|
+
_.r.pd=function(){return"WEBKIT"};Rs.prototype.createMediaKeys=function(){return Promise.resolve(new Ss(this.h,this.a))};Rs.prototype.getConfiguration=function(){return this.f};Ss.prototype.createSession=function(a){a=void 0===a?mg:a;if(a!==mg&&a!==_.jf)throw new TypeError("Session type "+a+ca);if(!this.a)throw a=Error("Media element is missing."),a.name=ob,a.code=DOMException.INVALID_STATE_ERR,a;this.a.src||(this.a.src="about:blank");a=new Ws(this.h,this.a,this.o,a);this.j.push(a);return a};
|
|
568
|
+
Ss.prototype.setServerCertificate=function(){return Promise.resolve(!1)};_.w(Ws,_.Ul);_.r=Ws.prototype;_.r.ready=function(){_.Hh("WebkitEmeManager.MediaKeySession.ready");Us(this,"usable");this.a&&this.a.resolve();this.a=null};_.r.generateRequest=function(a,b){_.Hh("WebkitEmeManager.MediaKeySession.generateRequest");return Ys(this,b,null)};_.r.load=function(a){_.Hh(qc);return this.l===_.jf?Ys(this,null,a):Promise.reject(Error(Fb))};_.r.update=function(a){_.Hh(qc);var b=new _.Oj;Zs(this,b,a);return b};
|
|
569
|
+
_.r.close=function(){_.Hh("WebkitEmeManager.MediaKeySession.close");if(this.l!==_.jf){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=Xs(this,"cancelKeyRequest");try{this.j[a](this.h,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};_.r.remove=function(){_.Hh("WebkitEmeManager.MediaKeySession.remove");return this.l!==_.jf?Promise.reject(Error(Fb)):this.close()};$s.prototype.a=function(){return"WEBKIT"};
|
|
570
|
+
$s.prototype.isSupported=function(){return!(!HTMLMediaElement.prototype.webkitGenerateKeyRequest&&!HTMLMediaElement.prototype.generateKeyRequest)};$s.prototype.create=function(){return new Qs};An(new $s);_.w(at,_.Am);at.prototype.Vd=function(a,b){for(var c=a.drm.customData.headers||{},d=_.t(Object.keys(c)),e=d.next();!e.done;e=d.next())e=e.value,b.headers[e]=c[e]};at.prototype.Tg=function(a,b){var c=Xm(b);switch(this.o){case pv:return c;case qv:return(new _.qk(c)).a;default:throw Error("Unknown content ID strategy");}};at.prototype.Gh=function(a,b){b.headers[xa]=ad;this.Vd(a,b);var c={spc:_.vj(b.body)};b.body=_.R.gd(_.sk(c,!0))};
|
|
571
|
+
at.prototype.Hh=function(a,b){var c=_.R.aa(b.data).trim(),d="\x3c/ckc\x3e"===c.substr(-6);"\x3cckc\x3e"===c.substr(0,5)&&d&&(c=c.slice(5,-6));b.data=_.xj(c).buffer};_.H(Gd,at);at.prototype.onFairPlayLicenseResponse=at.prototype.Hh;at.prototype.onFairPlayLicenseRequest=at.prototype.Gh;at.prototype.extractFairPlayContentId=at.prototype.Tg;at.prototype.onLicenseRequest=at.prototype.Vd;at.prototype.constructor=at.prototype.constructor;at.NAME=ib;var qv="hostname",pv="full-skd";
|
|
572
|
+
at.FairPlayContentIdStrategy={HOSTNAME:qv,FULL_SKD:pv};_.w(bt,_.Cs);bt.prototype.h=function(a){a=a.getConfiguration();if(a.drm&&a.drm&&a.drm.env===ib){a=a.drm.customData;if(!a)throw new _.P(_.Q,7,7100,_.Ud);a=new at(a.widevineLicenseUrl,a.playReadyLicenseUrl,a.fairPlayLicenseUrl,a.fairPlayCertificateUrl,a.fairPlayContentIdStrategy||pv);_.vm(a)}};bt.prototype.a=function(){delete _.um.HeaderDrm};bt.prototype.id=function(){return"headerdrm"};_.H("clpp.drm.HeaderDrmComponent",bt);_.nq(function(){ArrayBuffer.prototype.slice||(ArrayBuffer.prototype.slice=function(a,b){b=void 0!==b?b:this.byteLength;a=Math.floor(a);b=Math.floor(b);0>a&&(a+=this.byteLength);0>b&&(b+=this.byteLength);a=Math.min(Math.max(0,a),this.byteLength);b=Math.min(Math.max(0,b),this.byteLength);if(0>=b-a)return new ArrayBuffer(0);var c=new ArrayBuffer(b-a),d=_.lj(c),e=new Uint8Array(this,a,b-a);d.set(e);return c})});_.nq(function(){_.Hh("mathRound.install")});_.nq(function(){if(window.Document){var a=Element.prototype;a.requestFullscreen=a.requestFullscreen||a.mozRequestFullScreen||a.msRequestFullscreen||a.webkitRequestFullscreen;a=Document.prototype;a.exitFullscreen=a.exitFullscreen||a.mozCancelFullScreen||a.msExitFullscreen||a.webkitExitFullscreen;te in document||(Object.defineProperty(document,te,{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitFullscreenElement}}),Object.defineProperty(document,"fullscreenEnabled",
|
|
573
|
+
{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitSupportsFullscreen||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",ct);document.addEventListener("webkitfullscreenerror",ct);document.addEventListener("mozfullscreenchange",ct);document.addEventListener("mozfullscreenerror",ct);document.addEventListener("MSFullscreenChange",ct);document.addEventListener("MSFullscreenError",ct)}});_.nq(function(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(_.Hh("PiPWebkit.install"),document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=et,document.exitPictureInPicture=ft,document.addEventListener("webkitpresentationmodechanged",dt,!0))}});_.nq(function(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&"webkitDroppedFrameCount"in a&&(a.getVideoPlaybackQuality=gt)}});_.nq(function(){if(window.VTTCue)_.Gh("Using native VTTCue.");else if(window.TextTrackCue){var a=TextTrackCue.length;if(3===a)_.Gh(mc),window.VTTCue=ht;else if(6===a)_.Gh("Using VTTCue polyfill from 6 argument TextTrackCue."),window.VTTCue=it;else{try{var b=!!ht(1,2,"")}catch(c){b=!1}b&&(_.Gh(mc),window.VTTCue=ht)}}else _.Ih("VTTCue not available.")});var jt;_.nq(function(){_.Hh("InputEvent.install");_.Yk("Trident/")&&HTMLInputElement.prototype.addEventListener!==lt&&(_.Gh("Patching input event support on IE."),jt=HTMLInputElement.prototype.addEventListener,HTMLInputElement.prototype.addEventListener=lt)});_.nq(function(){navigator.languages||Object.defineProperty(navigator,"languages",{get:function(){return navigator.language?[navigator.language]:["en"]}})});_.nq(function(){_.Hh("VideoPlayPromise.install");if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b["catch"](function(){});return b}}});_.tt.prototype.start=function(){var a=this;this.a=new ResizeObserver(function(b){b=b[0];a.j(b.contentRect.width,b.contentRect.height,a.h.isFullscreen())});this.f&&this.a.observe(this.f)};_.tt.prototype.stop=function(){this.a&&(this.a.disconnect(),this.a=null)};_.vt.prototype.canPlay=function(a){function b(f){e.stop();d.resolve(f)}var c=document.createElement(_.Fg);c.setAttribute("playsinline","playsinline");a&&(c.muted=!0,c.setAttribute("muted","muted"));c.src=URL.createObjectURL(this.a);var d=new _.Oj;c=c.play();var e=(new _.Vk(function(){b(a)})).da(.25);void 0!==c?c.then(function(){return b(!0)})["catch"](function(f){f&&f.message&&f.message===Ib?b(!0):b(!1)}):b(!0);return d};
|
|
574
|
+
var ut=new Uint8Array([0,0,0,28,102,116,121,112,105,115,111,109,0,0,2,0,105,115,111,109,105,115,111,50,109,112,52,49,0,0,0,8,102,114,101,101,0,0,2,239,109,100,97,116,33,16,5,32,164,27,255,192,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
|
554
575
|
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,55,167,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,112,33,16,5,32,164,27,255,192,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
|
|
555
576
|
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,55,167,128,0,0,0,0,
|
|
556
577
|
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,112,0,0,2,194,109,111,111,118,0,0,0,108,109,118,104,100,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,232,0,0,0,47,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,0,0,1,236,116,114,97,107,0,0,0,92,116,107,104,100,0,0,0,3,0,0,0,0,
|
|
557
578
|
0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,47,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,36,101,100,116,115,0,0,0,28,101,108,115,116,0,0,0,0,0,0,0,1,0,0,0,47,0,0,0,0,0,1,0,0,0,0,1,100,109,100,105,97,0,0,0,32,109,100,104,100,0,0,0,0,0,0,0,0,0,0,0,0,0,0,172,68,0,0,8,0,85,196,0,0,0,0,0,45,104,100,108,114,0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0,0,0,1,15,109,105,110,102,
|
|
558
579
|
0,0,0,16,115,109,104,100,0,0,0,0,0,0,0,0,0,0,0,36,100,105,110,102,0,0,0,28,100,114,101,102,0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1,0,0,0,211,115,116,98,108,0,0,0,103,115,116,115,100,0,0,0,0,0,0,0,1,0,0,0,87,109,112,52,97,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,2,0,16,0,0,0,0,172,68,0,0,0,0,0,51,101,115,100,115,0,0,0,0,3,128,128,128,34,0,2,0,4,128,128,128,20,64,21,0,0,0,0,1,244,0,0,1,243,249,5,128,128,128,2,18,16,6,128,128,128,1,2,0,0,0,24,115,116,116,115,0,0,0,0,0,0,0,1,0,0,0,2,0,0,4,0,0,0,0,28,
|
|
559
|
-
115,116,115,99,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,2,0,0,0,1,0,0,0,28,115,116,115,122,0,0,0,0,0,0,0,0,0,0,0,2,0,0,1,115,0,0,1,116,0,0,0,20,115,116,99,111,0,0,0,0,0,0,0,1,0,0,0,44,0,0,0,98,117,100,116,97,0,0,0,90,109,101,116,97,0,0,0,0,0,0,0,33,104,100,108,114,0,0,0,0,0,0,0,0,109,100,105,114,97,112,112,108,0,0,0,0,0,0,0,0,0,0,0,0,45,105,108,115,116,0,0,0,37,169,116,111,111,0,0,0,29,100,97,116,97,0,0,0,1,0,0,0,0,76,97,118,102,53,54,46,52,48,46,49,48,49]);_.
|
|
560
|
-
_.r.getFontSizePercent=function(){return null===this.B?
|
|
561
|
-
_.
|
|
562
|
-
_.
|
|
563
|
-
|
|
564
|
-
_.r.
|
|
580
|
+
115,116,115,99,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,2,0,0,0,1,0,0,0,28,115,116,115,122,0,0,0,0,0,0,0,0,0,0,0,2,0,0,1,115,0,0,1,116,0,0,0,20,115,116,99,111,0,0,0,0,0,0,0,1,0,0,0,44,0,0,0,98,117,100,116,97,0,0,0,90,109,101,116,97,0,0,0,0,0,0,0,33,104,100,108,114,0,0,0,0,0,0,0,0,109,100,105,114,97,112,112,108,0,0,0,0,0,0,0,0,0,0,0,0,45,105,108,115,116,0,0,0,37,169,116,111,111,0,0,0,29,100,97,116,97,0,0,0,1,0,0,0,0,76,97,118,102,53,54,46,52,48,46,49,48,49]);_.r=_.wt.prototype;_.r.getDuration=function(){return this.a};_.r.getId=function(){return this.id};_.r.pb=function(){return this.f};_.r.Md=function(){return this.h};_.r.ka=function(a){return this.getId()===a.getId()&&this.pb()===a.pb()&&this.getDuration()===a.getDuration()&&this.Md()===a.Md()};_.H("clpp.media.TimelineWindow",_.wt);_.wt.prototype.isDynamic=_.wt.prototype.Md;_.wt.prototype.getStart=_.wt.prototype.pb;_.wt.prototype.getId=_.wt.prototype.getId;_.wt.prototype.getDuration=_.wt.prototype.getDuration;_.rv=new _.K("clpp.media.TimestampParser");_.r=_.xt.prototype;_.r.Kk=function(a){return this.a[a]||null};_.r.Lk=function(){return this.a.length};_.r.Mk=function(){return this.a};_.r.$g=function(){return this.a[this.f]||null};_.r.wk=function(){return this.f};_.H("clpp.media.Timeline",_.xt);_.xt.prototype.getCurrentWindowIndex=_.xt.prototype.wk;_.xt.prototype.getCurrentWindow=_.xt.prototype.$g;_.xt.prototype.getWindows=_.xt.prototype.Mk;_.xt.prototype.getWindowCount=_.xt.prototype.Lk;_.xt.prototype.getWindow=_.xt.prototype.Kk;_.At={};_.Ct={};var Ht=window.XMLHttpRequest;_.w(Pt,_.Pj);Pt.prototype.then=function(a,b){this.P=this.P.then(a,b);return this};Pt.prototype["catch"]=function(a){this.P=this.P["catch"](a);return this};Pt.prototype.abort=function(){var a=this;if(this.a)return Promise.resolve();this.a=!0;return this.h.then(function(b){a.o&&clearTimeout(a.o);a.l&&a.l();return b.abort()})["catch"](function(){})};_.au.prototype.enabled=function(){return this.a};_.au.prototype.bh=function(){return this.a&&this.f&&this.f.has(sv)?1E3*this.f.get(sv):null};_.au.prototype.release=function(){this.f=null;this.a=!1;this.h.Ie(this.j)};_.au.prototype.getEstimatedThroughput=_.au.prototype.bh;var sv="etp",ju={gn:sv},ku=new _.K("clpp.net.CmsdManager");var ou=window.fetch,mu=window.AbortController,lu=window.Headers;_.qu={};_.r=_.uu.prototype;_.r.getBackgroundColor=function(){return this.K};_.r.setBackgroundColor=function(a){this.K=a;this.wb()};_.r.getWindowColor=function(){return this.V};_.r.setWindowColor=function(a){this.V=a;this.wb()};_.r.getFontFamily=function(){return this.T};_.r.setFontFamily=function(a){this.T=a;this.wb()};_.r.getFontColor=function(){return this.N};_.r.setFontColor=function(a){this.N=a;this.wb()};_.r.getFontSize=function(){return this.I};_.r.setFontSize=function(a){this.I=a;this.wb()};
|
|
581
|
+
_.r.getFontSizePercent=function(){return null===this.B?uv:this.B};_.r.setFontSizePercent=function(a){this.B=a;this.wb()};_.r.getEdgeColor=function(){return this.H};_.r.setEdgeColor=function(a){this.H=a;this.wb()};_.r.getEdgeType=function(){return this.o};_.r.setEdgeType=function(a){this.o=a;this.wb()};_.uu.prototype.setEdgeType=_.uu.prototype.setEdgeType;_.uu.prototype.getEdgeType=_.uu.prototype.getEdgeType;_.uu.prototype.setEdgeColor=_.uu.prototype.setEdgeColor;_.uu.prototype.getEdgeColor=_.uu.prototype.getEdgeColor;
|
|
582
|
+
_.uu.prototype.setFontSizePercent=_.uu.prototype.setFontSizePercent;_.uu.prototype.getFontSizePercent=_.uu.prototype.getFontSizePercent;_.uu.prototype.setFontSize=_.uu.prototype.setFontSize;_.uu.prototype.getFontSize=_.uu.prototype.getFontSize;_.uu.prototype.setFontColor=_.uu.prototype.setFontColor;_.uu.prototype.getFontColor=_.uu.prototype.getFontColor;_.uu.prototype.setFontFamily=_.uu.prototype.setFontFamily;_.uu.prototype.getFontFamily=_.uu.prototype.getFontFamily;
|
|
583
|
+
_.uu.prototype.setWindowColor=_.uu.prototype.setWindowColor;_.uu.prototype.getWindowColor=_.uu.prototype.getWindowColor;_.uu.prototype.setBackgroundColor=_.uu.prototype.setBackgroundColor;_.uu.prototype.getBackgroundColor=_.uu.prototype.getBackgroundColor;var uv=1/15;var vu="raised",wu="depressed",yu="dropshadow",xu="uniform";_.H("clpp.text.EdgeType",{NONE:_.We,RAISED:vu,DEPRESSED:wu,DROP_SHADOW:yu,UNIFORM:xu});Au.prototype.parseInit=function(a){try{var b=_.su(_.Xc);if(b){var c=new b(this.f);c.parseInit(a)}else this.g.warn("The clpp.ttml.Mp4TtmlParser class is not available. Please register the ttml component first.")}catch(e){c=null}if(c)this.a=c;else{try{var d=_.su(_.Yc);d?(c=new d(this.f),c.parseInit(a)):this.g.warn("The clpp.vtt.Mp4VttParser class is not available. Please register the vtt component first.")}catch(e){c=null}if(c)this.a=c;else throw new _.P(_.Q,2,2011);}};
|
|
584
|
+
Au.prototype.parseMedia=function(a,b){if(!this.a)throw new _.P(_.Q,2,2011);return this.a.parseMedia(a,b)};_.ru(Wc,Au);_.w(_.Cu,_.uu);_.r=_.Cu.prototype;_.r.append=function(){};_.r.remove=function(){return!0};_.r.isTextVisible=function(){return this.w};_.r.setTextVisibility=function(a){this.w=a};
|
|
585
|
+
_.r.wb=function(){if(!this.j){var a={"background-color":this.getBackgroundColor(),color:this.getFontColor(),"font-family":this.getFontFamily(),"font-size":this.getFontSize(),"text-shadow":_.zu(this)},b=Object.keys(a).map(function(c){return null!==a[c]?c+":"+a[c]+";":""}).join("");this.h.textContent="."+this.f+"::cue {"+b+"}"}};_.r.destroy=function(){this.l.classList.remove(this.f);document.head.removeChild(this.h);this.j=!0;return Promise.resolve()};var Bu=0;Du.prototype.isSupported=function(){return!0};Du.prototype.create=function(a){return new _.Cu(a)};_.Xo("native",new Du);_.Eu.prototype.onContentWillLoad=function(){return Promise.resolve()};_.Eu.prototype.onContentLoaded=function(a,b){for(var c=1;c<arguments.length;++c);return Promise.resolve()};_.Eu.prototype.onPlayerWillDestroy=function(){};_.Eu.prototype.onPlayerWillRelease=function(){};}.call(g,this));
|
|
565
586
|
g.clpp._ = _;
|
|
566
587
|
if (typeof(module)!="undefined"&&module.exports) {module.exports=g.clpp;}
|
|
567
588
|
else if (typeof(define)!="undefined" && define.amd) {define(function(){return g.clpp;});}
|