@das-fed/upf-ui 6.4.0-dev.216 → 6.4.0-dev.218

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.
Files changed (100) hide show
  1. package/package.json +5 -5
  2. package/packages/business-components/ai-panel/{index-BgyMyjJo.js → index-BybM3Q9u.js} +700 -711
  3. package/packages/business-components/ai-panel/index-BybM3Q9u.js.gz +0 -0
  4. package/packages/business-components/ai-panel/index-CgWRv2Ge.js +142 -0
  5. package/packages/business-components/ai-panel/index-CgWRv2Ge.js.gz +0 -0
  6. package/packages/business-components/ai-panel/{index-Bw7rNZmA.js → index-CwdJKHy0.js} +9 -9
  7. package/packages/business-components/ai-panel/index-CwdJKHy0.js.gz +0 -0
  8. package/packages/business-components/ai-panel/index.js +1 -1
  9. package/packages/business-components/device-panel/index.js +8773 -8873
  10. package/packages/business-components/device-panel/index.js.gz +0 -0
  11. package/packages/business-components/echarts/index.js +2049 -2056
  12. package/packages/business-components/echarts/index.js.gz +0 -0
  13. package/packages/business-components/process-configuration/index.js +50 -50
  14. package/packages/business-components/process-configuration/index.js.gz +0 -0
  15. package/packages/business-components/process-form/index.js +149 -149
  16. package/packages/business-components/process-form/index.js.gz +0 -0
  17. package/packages/business-components/process-search-form/index.js +60 -60
  18. package/packages/business-components/process-search-form/index.js.gz +0 -0
  19. package/packages/business-components/process-table/index.js +128 -130
  20. package/packages/business-components/process-table/index.js.gz +0 -0
  21. package/packages/business-components/urgent-panel/index.js +896 -904
  22. package/packages/business-components/urgent-panel/index.js.gz +0 -0
  23. package/packages/business-components/user-org-dialog/index.js +246 -249
  24. package/packages/business-components/user-org-dialog/index.js.gz +0 -0
  25. package/packages/business-components/video-dialog/index.js +0 -1
  26. package/packages/business-components/video-dialog/index.js.gz +0 -0
  27. package/packages/components/autocomplete/index.js +6 -12
  28. package/packages/components/autocomplete/index.js.gz +0 -0
  29. package/packages/components/calendar/index.js +104 -104
  30. package/packages/components/calendar/index.js.gz +0 -0
  31. package/packages/components/cascader/index.js +27 -27
  32. package/packages/components/cascader/index.js.gz +0 -0
  33. package/packages/components/checkbox/index.js +54 -54
  34. package/packages/components/checkbox/index.js.gz +0 -0
  35. package/packages/components/date-picker/index.js +459 -459
  36. package/packages/components/date-picker/index.js.gz +0 -0
  37. package/packages/components/dimple-layout/index.js +61 -63
  38. package/packages/components/dimple-layout/index.js.gz +0 -0
  39. package/packages/components/dropdown/index.js +22 -23
  40. package/packages/components/dropdown/index.js.gz +0 -0
  41. package/packages/components/edit-table/index.js +223 -224
  42. package/packages/components/edit-table/index.js.gz +0 -0
  43. package/packages/components/error-overlay-model/index.js +42 -44
  44. package/packages/components/error-overlay-model/index.js.gz +0 -0
  45. package/packages/components/form-item/index.js +63 -67
  46. package/packages/components/form-item/index.js.gz +0 -0
  47. package/packages/components/image-viewer/index.js +32 -32
  48. package/packages/components/image-viewer/index.js.gz +0 -0
  49. package/packages/components/input/index.d.ts +4264 -0
  50. package/packages/components/input/index.js +51 -51
  51. package/packages/components/input/index.js.gz +0 -0
  52. package/packages/components/input/src/index.vue.d.ts +1432 -0
  53. package/packages/components/input-number/index.js +44 -44
  54. package/packages/components/input-number/index.js.gz +0 -0
  55. package/packages/components/live-player/index.js +832 -834
  56. package/packages/components/live-player/index.js.gz +0 -0
  57. package/packages/components/map/index.js +431 -437
  58. package/packages/components/map/index.js.gz +0 -0
  59. package/packages/components/menu-aside/index.js +1 -1
  60. package/packages/components/menu-aside/index.js.gz +0 -0
  61. package/packages/components/message/index.js +6 -6
  62. package/packages/components/message/index.js.gz +0 -0
  63. package/packages/components/radio-tabs/index.js +33 -33
  64. package/packages/components/radio-tabs/index.js.gz +0 -0
  65. package/packages/components/rich-editor/index.js +4556 -4586
  66. package/packages/components/rich-editor/index.js.gz +0 -0
  67. package/packages/components/scrollbar/index.js +135 -135
  68. package/packages/components/scrollbar/index.js.gz +0 -0
  69. package/packages/components/search/index.js +2 -2
  70. package/packages/components/search/index.js.gz +0 -0
  71. package/packages/components/select/index.js +92 -92
  72. package/packages/components/select/index.js.gz +0 -0
  73. package/packages/components/select-list/index.js +6 -10
  74. package/packages/components/select-list/index.js.gz +0 -0
  75. package/packages/components/special-range-picker-month/index.js +14 -16
  76. package/packages/components/special-range-picker-month/index.js.gz +0 -0
  77. package/packages/components/special-range-picker-year/index.js +51 -53
  78. package/packages/components/special-range-picker-year/index.js.gz +0 -0
  79. package/packages/components/spin/index.js +35 -35
  80. package/packages/components/spin/index.js.gz +0 -0
  81. package/packages/components/split-panel/index.js +101 -102
  82. package/packages/components/split-panel/index.js.gz +0 -0
  83. package/packages/components/table/index.js +599 -604
  84. package/packages/components/table/index.js.gz +0 -0
  85. package/packages/components/time-line/index.js +1 -1
  86. package/packages/components/time-line/index.js.gz +0 -0
  87. package/packages/components/tree/index.js +173 -182
  88. package/packages/components/tree/index.js.gz +0 -0
  89. package/packages/components/tree-select/index.js +81 -81
  90. package/packages/components/tree-select/index.js.gz +0 -0
  91. package/packages/components/tree-table/index.js +2 -2
  92. package/packages/components/tree-table/index.js.gz +0 -0
  93. package/packages/components/tree-v2/index.js +1208 -1240
  94. package/packages/components/tree-v2/index.js.gz +0 -0
  95. package/packages/components/virtual-tree/src/App.vue.d.ts +3974 -0
  96. package/packages/components/virtual-tree/src/type.d.ts +43 -0
  97. package/packages/business-components/ai-panel/index-B4pMosXu.js +0 -143
  98. package/packages/business-components/ai-panel/index-B4pMosXu.js.gz +0 -0
  99. package/packages/business-components/ai-panel/index-BgyMyjJo.js.gz +0 -0
  100. package/packages/business-components/ai-panel/index-Bw7rNZmA.js.gz +0 -0
@@ -1,6 +1,6 @@
1
1
  import '@das-fed/upf-ui/packages/components/live-player/style.css';
2
- import { defineComponent as Yt, useCssVars as Jt, toRefs as Zt, computed as ot, ref as Xe, onMounted as $t, onBeforeUnmount as Qt, withDirectives as ei, openBlock as dt, createElementBlock as ut, unref as We, normalizeStyle as ti, renderSlot as ii, createTextVNode as ri, toDisplayString as ai } from "vue";
3
- import { withInstall as ni } from "@das-fed/upf-utils/with-install/index";
2
+ import { defineComponent as Yt, useCssVars as Jt, toRefs as Zt, computed as ot, ref as Xe, onMounted as $t, onBeforeUnmount as Qt, withDirectives as ei, openBlock as dt, createElementBlock as ut, unref as We, normalizeStyle as ti, renderSlot as ii, createTextVNode as ri, toDisplayString as ni } from "vue";
3
+ import { withInstall as ai } from "@das-fed/upf-utils/with-install/index";
4
4
  import { ElLoadingDirective as si } from "element-plus/es";
5
5
  import "element-plus/es/components/base/style/css";
6
6
  import "element-plus/es/components/loading/style/css";
@@ -15,56 +15,56 @@ var Tt = { exports: {} };
15
15
  })(window, function() {
16
16
  return function(fe) {
17
17
  var Z = {};
18
- function O(x) {
19
- if (Z[x]) return Z[x].exports;
20
- var B = Z[x] = { i: x, l: !1, exports: {} };
21
- return fe[x].call(B.exports, B, B.exports, O), B.l = !0, B.exports;
18
+ function O(U) {
19
+ if (Z[U]) return Z[U].exports;
20
+ var B = Z[U] = { i: U, l: !1, exports: {} };
21
+ return fe[U].call(B.exports, B, B.exports, O), B.l = !0, B.exports;
22
22
  }
23
- return O.m = fe, O.c = Z, O.d = function(x, B, m) {
24
- O.o(x, B) || Object.defineProperty(x, B, { enumerable: !0, get: m });
25
- }, O.r = function(x) {
26
- typeof Symbol < "u" && Symbol.toStringTag && Object.defineProperty(x, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(x, "__esModule", { value: !0 });
27
- }, O.t = function(x, B) {
28
- if (1 & B && (x = O(x)), 8 & B || 4 & B && typeof x == "object" && x && x.__esModule) return x;
23
+ return O.m = fe, O.c = Z, O.d = function(U, B, m) {
24
+ O.o(U, B) || Object.defineProperty(U, B, { enumerable: !0, get: m });
25
+ }, O.r = function(U) {
26
+ typeof Symbol < "u" && Symbol.toStringTag && Object.defineProperty(U, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(U, "__esModule", { value: !0 });
27
+ }, O.t = function(U, B) {
28
+ if (1 & B && (U = O(U)), 8 & B || 4 & B && typeof U == "object" && U && U.__esModule) return U;
29
29
  var m = /* @__PURE__ */ Object.create(null);
30
- if (O.r(m), Object.defineProperty(m, "default", { enumerable: !0, value: x }), 2 & B && typeof x != "string") for (var b in x) O.d(m, b, (function(y) {
31
- return x[y];
30
+ if (O.r(m), Object.defineProperty(m, "default", { enumerable: !0, value: U }), 2 & B && typeof U != "string") for (var b in U) O.d(m, b, (function(y) {
31
+ return U[y];
32
32
  }).bind(null, b));
33
33
  return m;
34
- }, O.n = function(x) {
35
- var B = x && x.__esModule ? function() {
36
- return x.default;
34
+ }, O.n = function(U) {
35
+ var B = U && U.__esModule ? function() {
36
+ return U.default;
37
37
  } : function() {
38
- return x;
38
+ return U;
39
39
  };
40
40
  return O.d(B, "a", B), B;
41
- }, O.o = function(x, B) {
42
- return Object.prototype.hasOwnProperty.call(x, B);
41
+ }, O.o = function(U, B) {
42
+ return Object.prototype.hasOwnProperty.call(U, B);
43
43
  }, O.p = "", O(O.s = 14);
44
44
  }([function(fe, Z, O) {
45
- var x = O(6), B = O.n(x), m = function() {
45
+ var U = O(6), B = O.n(U), m = function() {
46
46
  function b() {
47
47
  }
48
48
  return b.e = function(y, f) {
49
49
  y && !b.FORCE_GLOBAL_TAG || (y = b.GLOBAL_TAG);
50
- var k = "[" + y + "] > " + f;
51
- b.ENABLE_CALLBACK && b.emitter.emit("log", "error", k), b.ENABLE_ERROR && (console.error ? console.error(k) : console.warn ? console.warn(k) : console.log(k));
50
+ var L = "[" + y + "] > " + f;
51
+ b.ENABLE_CALLBACK && b.emitter.emit("log", "error", L), b.ENABLE_ERROR;
52
52
  }, b.i = function(y, f) {
53
53
  y && !b.FORCE_GLOBAL_TAG || (y = b.GLOBAL_TAG);
54
- var k = "[" + y + "] > " + f;
55
- b.ENABLE_CALLBACK && b.emitter.emit("log", "info", k), b.ENABLE_INFO && (console.info ? console.info(k) : console.log(k));
54
+ var L = "[" + y + "] > " + f;
55
+ b.ENABLE_CALLBACK && b.emitter.emit("log", "info", L), b.ENABLE_INFO;
56
56
  }, b.w = function(y, f) {
57
57
  y && !b.FORCE_GLOBAL_TAG || (y = b.GLOBAL_TAG);
58
- var k = "[" + y + "] > " + f;
59
- b.ENABLE_CALLBACK && b.emitter.emit("log", "warn", k), b.ENABLE_WARN && (console.warn ? console.warn(k) : console.log(k));
58
+ var L = "[" + y + "] > " + f;
59
+ b.ENABLE_CALLBACK && b.emitter.emit("log", "warn", L), b.ENABLE_WARN;
60
60
  }, b.d = function(y, f) {
61
61
  y && !b.FORCE_GLOBAL_TAG || (y = b.GLOBAL_TAG);
62
- var k = "[" + y + "] > " + f;
63
- b.ENABLE_CALLBACK && b.emitter.emit("log", "debug", k), b.ENABLE_DEBUG && (console.debug ? console.debug(k) : console.log(k));
62
+ var L = "[" + y + "] > " + f;
63
+ b.ENABLE_CALLBACK && b.emitter.emit("log", "debug", L), b.ENABLE_DEBUG;
64
64
  }, b.v = function(y, f) {
65
65
  y && !b.FORCE_GLOBAL_TAG || (y = b.GLOBAL_TAG);
66
- var k = "[" + y + "] > " + f;
67
- b.ENABLE_CALLBACK && b.emitter.emit("log", "verbose", k), b.ENABLE_VERBOSE && console.log(k);
66
+ var L = "[" + y + "] > " + f;
67
+ b.ENABLE_CALLBACK && b.emitter.emit("log", "verbose", L), b.ENABLE_VERBOSE;
68
68
  }, b;
69
69
  }();
70
70
  m.GLOBAL_TAG = "mpegts.js", m.FORCE_GLOBAL_TAG = !1, m.ENABLE_ERROR = !0, m.ENABLE_INFO = !0, m.ENABLE_WARN = !0, m.ENABLE_DEBUG = !0, m.ENABLE_VERBOSE = !0, m.ENABLE_CALLBACK = !1, m.emitter = new B.a(), Z.a = m;
@@ -78,7 +78,7 @@ var Tt = { exports: {} };
78
78
  }), O.d(Z, "a", function() {
79
79
  return b;
80
80
  });
81
- var x = O(3), B = { kIdle: 0, kConnecting: 1, kBuffering: 2, kError: 3, kComplete: 4 }, m = { OK: "OK", EXCEPTION: "Exception", HTTP_STATUS_CODE_INVALID: "HttpStatusCodeInvalid", CONNECTING_TIMEOUT: "ConnectingTimeout", EARLY_EOF: "EarlyEof", UNRECOVERABLE_EARLY_EOF: "UnrecoverableEarlyEof" }, b = function() {
81
+ var U = O(3), B = { kIdle: 0, kConnecting: 1, kBuffering: 2, kError: 3, kComplete: 4 }, m = { OK: "OK", EXCEPTION: "Exception", HTTP_STATUS_CODE_INVALID: "HttpStatusCodeInvalid", CONNECTING_TIMEOUT: "ConnectingTimeout", EARLY_EOF: "EarlyEof", UNRECOVERABLE_EARLY_EOF: "UnrecoverableEarlyEof" }, b = function() {
82
82
  function y(f) {
83
83
  this._type = f || "undefined", this._status = B.kIdle, this._needStash = !1, this._onContentLengthKnown = null, this._onURLRedirect = null, this._onDataArrival = null, this._onError = null, this._onComplete = null;
84
84
  }
@@ -112,10 +112,10 @@ var Tt = { exports: {} };
112
112
  return this._onComplete;
113
113
  }, set: function(f) {
114
114
  this._onComplete = f;
115
- }, enumerable: !1, configurable: !0 }), y.prototype.open = function(f, k) {
116
- throw new x.c("Unimplemented abstract function!");
115
+ }, enumerable: !1, configurable: !0 }), y.prototype.open = function(f, L) {
116
+ throw new U.c("Unimplemented abstract function!");
117
117
  }, y.prototype.abort = function() {
118
- throw new x.c("Unimplemented abstract function!");
118
+ throw new U.c("Unimplemented abstract function!");
119
119
  }, y;
120
120
  }();
121
121
  }, function(fe, Z, O) {
@@ -128,70 +128,70 @@ var Tt = { exports: {} };
128
128
  }), O.d(Z, "c", function() {
129
129
  return f;
130
130
  });
131
- var x, B = (x = function(k, U) {
132
- return (x = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(C, V) {
131
+ var U, B = (U = function(L, x) {
132
+ return (U = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(C, V) {
133
133
  C.__proto__ = V;
134
134
  } || function(C, V) {
135
135
  for (var H in V) V.hasOwnProperty(H) && (C[H] = V[H]);
136
- })(k, U);
137
- }, function(k, U) {
136
+ })(L, x);
137
+ }, function(L, x) {
138
138
  function C() {
139
- this.constructor = k;
139
+ this.constructor = L;
140
140
  }
141
- x(k, U), k.prototype = U === null ? Object.create(U) : (C.prototype = U.prototype, new C());
141
+ U(L, x), L.prototype = x === null ? Object.create(x) : (C.prototype = x.prototype, new C());
142
142
  }), m = function() {
143
- function k(U) {
144
- this._message = U;
143
+ function L(x) {
144
+ this._message = x;
145
145
  }
146
- return Object.defineProperty(k.prototype, "name", { get: function() {
146
+ return Object.defineProperty(L.prototype, "name", { get: function() {
147
147
  return "RuntimeException";
148
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "message", { get: function() {
148
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "message", { get: function() {
149
149
  return this._message;
150
- }, enumerable: !1, configurable: !0 }), k.prototype.toString = function() {
150
+ }, enumerable: !1, configurable: !0 }), L.prototype.toString = function() {
151
151
  return this.name + ": " + this.message;
152
- }, k;
153
- }(), b = function(k) {
154
- function U(C) {
155
- return k.call(this, C) || this;
152
+ }, L;
153
+ }(), b = function(L) {
154
+ function x(C) {
155
+ return L.call(this, C) || this;
156
156
  }
157
- return B(U, k), Object.defineProperty(U.prototype, "name", { get: function() {
157
+ return B(x, L), Object.defineProperty(x.prototype, "name", { get: function() {
158
158
  return "IllegalStateException";
159
- }, enumerable: !1, configurable: !0 }), U;
160
- }(m), y = function(k) {
161
- function U(C) {
162
- return k.call(this, C) || this;
159
+ }, enumerable: !1, configurable: !0 }), x;
160
+ }(m), y = function(L) {
161
+ function x(C) {
162
+ return L.call(this, C) || this;
163
163
  }
164
- return B(U, k), Object.defineProperty(U.prototype, "name", { get: function() {
164
+ return B(x, L), Object.defineProperty(x.prototype, "name", { get: function() {
165
165
  return "InvalidArgumentException";
166
- }, enumerable: !1, configurable: !0 }), U;
167
- }(m), f = function(k) {
168
- function U(C) {
169
- return k.call(this, C) || this;
166
+ }, enumerable: !1, configurable: !0 }), x;
167
+ }(m), f = function(L) {
168
+ function x(C) {
169
+ return L.call(this, C) || this;
170
170
  }
171
- return B(U, k), Object.defineProperty(U.prototype, "name", { get: function() {
171
+ return B(x, L), Object.defineProperty(x.prototype, "name", { get: function() {
172
172
  return "NotImplementedException";
173
- }, enumerable: !1, configurable: !0 }), U;
173
+ }, enumerable: !1, configurable: !0 }), x;
174
174
  }(m);
175
175
  }, function(fe, Z, O) {
176
- var x = {};
176
+ var U = {};
177
177
  (function() {
178
178
  var B = self.navigator.userAgent.toLowerCase(), m = /(edge)\/([\w.]+)/.exec(B) || /(opr)[\/]([\w.]+)/.exec(B) || /(chrome)[ \/]([\w.]+)/.exec(B) || /(iemobile)[\/]([\w.]+)/.exec(B) || /(version)(applewebkit)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(B) || /(webkit)[ \/]([\w.]+).*(version)[ \/]([\w.]+).*(safari)[ \/]([\w.]+)/.exec(B) || /(webkit)[ \/]([\w.]+)/.exec(B) || /(opera)(?:.*version|)[ \/]([\w.]+)/.exec(B) || /(msie) ([\w.]+)/.exec(B) || B.indexOf("trident") >= 0 && /(rv)(?::| )([\w.]+)/.exec(B) || B.indexOf("compatible") < 0 && /(firefox)[ \/]([\w.]+)/.exec(B) || [], b = /(ipad)/.exec(B) || /(ipod)/.exec(B) || /(windows phone)/.exec(B) || /(iphone)/.exec(B) || /(kindle)/.exec(B) || /(android)/.exec(B) || /(windows)/.exec(B) || /(mac)/.exec(B) || /(linux)/.exec(B) || /(cros)/.exec(B) || [], y = { browser: m[5] || m[3] || m[1] || "", version: m[2] || m[4] || "0", majorVersion: m[4] || m[2] || "0", platform: b[0] || "" }, f = {};
179
179
  if (y.browser) {
180
180
  f[y.browser] = !0;
181
- var k = y.majorVersion.split(".");
182
- f.version = { major: parseInt(y.majorVersion, 10), string: y.version }, k.length > 1 && (f.version.minor = parseInt(k[1], 10)), k.length > 2 && (f.version.build = parseInt(k[2], 10));
181
+ var L = y.majorVersion.split(".");
182
+ f.version = { major: parseInt(y.majorVersion, 10), string: y.version }, L.length > 1 && (f.version.minor = parseInt(L[1], 10)), L.length > 2 && (f.version.build = parseInt(L[2], 10));
183
183
  }
184
184
  y.platform && (f[y.platform] = !0), (f.chrome || f.opr || f.safari) && (f.webkit = !0), (f.rv || f.iemobile) && (f.rv && delete f.rv, y.browser = "msie", f.msie = !0), f.edge && (delete f.edge, y.browser = "msedge", f.msedge = !0), f.opr && (y.browser = "opera", f.opera = !0), f.safari && f.android && (y.browser = "android", f.android = !0);
185
- for (var U in f.name = y.browser, f.platform = y.platform, x) x.hasOwnProperty(U) && delete x[U];
186
- Object.assign(x, f);
187
- })(), Z.a = x;
185
+ for (var x in f.name = y.browser, f.platform = y.platform, U) U.hasOwnProperty(x) && delete U[x];
186
+ Object.assign(U, f);
187
+ })(), Z.a = U;
188
188
  }, function(fe, Z, O) {
189
189
  Z.a = { OK: "OK", FORMAT_ERROR: "FormatError", FORMAT_UNSUPPORTED: "FormatUnsupported", CODEC_UNSUPPORTED: "CodecUnsupported" };
190
190
  }, function(fe, Z, O) {
191
- var x, B = typeof Reflect == "object" ? Reflect : null, m = B && typeof B.apply == "function" ? B.apply : function(v, G, T) {
191
+ var U, B = typeof Reflect == "object" ? Reflect : null, m = B && typeof B.apply == "function" ? B.apply : function(v, G, T) {
192
192
  return Function.prototype.apply.call(v, G, T);
193
193
  };
194
- x = B && typeof B.ownKeys == "function" ? B.ownKeys : Object.getOwnPropertySymbols ? function(v) {
194
+ U = B && typeof B.ownKeys == "function" ? B.ownKeys : Object.getOwnPropertySymbols ? function(v) {
195
195
  return Object.getOwnPropertyNames(v).concat(Object.getOwnPropertySymbols(v));
196
196
  } : function(v) {
197
197
  return Object.getOwnPropertyNames(v);
@@ -210,25 +210,25 @@ var Tt = { exports: {} };
210
210
  function _() {
211
211
  typeof v.removeListener == "function" && v.removeListener("error", u), T([].slice.call(arguments));
212
212
  }
213
- ae(v, G, _, { once: !0 }), G !== "error" && function(c, P, D) {
214
- typeof c.on == "function" && ae(c, "error", P, D);
213
+ ne(v, G, _, { once: !0 }), G !== "error" && function(c, P, D) {
214
+ typeof c.on == "function" && ne(c, "error", P, D);
215
215
  }(v, u, { once: !0 });
216
216
  });
217
217
  }, y.EventEmitter = y, y.prototype._events = void 0, y.prototype._eventsCount = 0, y.prototype._maxListeners = void 0;
218
218
  var f = 10;
219
- function k(v) {
219
+ function L(v) {
220
220
  if (typeof v != "function") throw new TypeError('The "listener" argument must be of type Function. Received type ' + typeof v);
221
221
  }
222
- function U(v) {
222
+ function x(v) {
223
223
  return v._maxListeners === void 0 ? y.defaultMaxListeners : v._maxListeners;
224
224
  }
225
225
  function C(v, G, T, l) {
226
226
  var u, _, c, P;
227
- if (k(T), (_ = v._events) === void 0 ? (_ = v._events = /* @__PURE__ */ Object.create(null), v._eventsCount = 0) : (_.newListener !== void 0 && (v.emit("newListener", G, T.listener ? T.listener : T), _ = v._events), c = _[G]), c === void 0) c = _[G] = T, ++v._eventsCount;
228
- else if (typeof c == "function" ? c = _[G] = l ? [T, c] : [c, T] : l ? c.unshift(T) : c.push(T), (u = U(v)) > 0 && c.length > u && !c.warned) {
227
+ if (L(T), (_ = v._events) === void 0 ? (_ = v._events = /* @__PURE__ */ Object.create(null), v._eventsCount = 0) : (_.newListener !== void 0 && (v.emit("newListener", G, T.listener ? T.listener : T), _ = v._events), c = _[G]), c === void 0) c = _[G] = T, ++v._eventsCount;
228
+ else if (typeof c == "function" ? c = _[G] = l ? [T, c] : [c, T] : l ? c.unshift(T) : c.push(T), (u = x(v)) > 0 && c.length > u && !c.warned) {
229
229
  c.warned = !0;
230
230
  var D = new Error("Possible EventEmitter memory leak detected. " + c.length + " " + String(G) + " listeners added. Use emitter.setMaxListeners() to increase limit");
231
- D.name = "MaxListenersExceededWarning", D.emitter = v, D.type = G, D.count = c.length, P = D, console && console.warn && console.warn(P);
231
+ D.name = "MaxListenersExceededWarning", D.emitter = v, D.type = G, D.count = c.length, P = D;
232
232
  }
233
233
  return v;
234
234
  }
@@ -261,7 +261,7 @@ var Tt = { exports: {} };
261
261
  for (var T = new Array(G), l = 0; l < G; ++l) T[l] = v[l];
262
262
  return T;
263
263
  }
264
- function ae(v, G, T, l) {
264
+ function ne(v, G, T, l) {
265
265
  if (typeof v.on == "function") l.once ? v.once(G, T) : v.on(G, T);
266
266
  else {
267
267
  if (typeof v.addEventListener != "function") throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof v);
@@ -281,7 +281,7 @@ var Tt = { exports: {} };
281
281
  if (typeof v != "number" || v < 0 || b(v)) throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + v + ".");
282
282
  return this._maxListeners = v, this;
283
283
  }, y.prototype.getMaxListeners = function() {
284
- return U(this);
284
+ return x(this);
285
285
  }, y.prototype.emit = function(v) {
286
286
  for (var G = [], T = 1; T < arguments.length; T++) G.push(arguments[T]);
287
287
  var l = v === "error", u = this._events;
@@ -306,12 +306,12 @@ var Tt = { exports: {} };
306
306
  }, y.prototype.on = y.prototype.addListener, y.prototype.prependListener = function(v, G) {
307
307
  return C(this, v, G, !0);
308
308
  }, y.prototype.once = function(v, G) {
309
- return k(G), this.on(v, H(this, v, G)), this;
309
+ return L(G), this.on(v, H(this, v, G)), this;
310
310
  }, y.prototype.prependOnceListener = function(v, G) {
311
- return k(G), this.prependListener(v, H(this, v, G)), this;
311
+ return L(G), this.prependListener(v, H(this, v, G)), this;
312
312
  }, y.prototype.removeListener = function(v, G) {
313
313
  var T, l, u, _, c;
314
- if (k(G), (l = this._events) === void 0) return this;
314
+ if (L(G), (l = this._events) === void 0) return this;
315
315
  if ((T = l[v]) === void 0) return this;
316
316
  if (T === G || T.listener === G) --this._eventsCount == 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete l[v], l.removeListener && this.emit("removeListener", v, T.listener || G));
317
317
  else if (typeof T != "function") {
@@ -345,11 +345,11 @@ var Tt = { exports: {} };
345
345
  }, y.listenerCount = function(v, G) {
346
346
  return typeof v.listenerCount == "function" ? v.listenerCount(G) : se.call(v, G);
347
347
  }, y.prototype.listenerCount = se, y.prototype.eventNames = function() {
348
- return this._eventsCount > 0 ? x(this._events) : [];
348
+ return this._eventsCount > 0 ? U(this._events) : [];
349
349
  };
350
350
  }, function(fe, Z, O) {
351
351
  O.d(Z, "d", function() {
352
- return x;
352
+ return U;
353
353
  }), O.d(Z, "b", function() {
354
354
  return B;
355
355
  }), O.d(Z, "a", function() {
@@ -357,8 +357,8 @@ var Tt = { exports: {} };
357
357
  }), O.d(Z, "c", function() {
358
358
  return b;
359
359
  });
360
- var x = function(y, f, k, U, C) {
361
- this.dts = y, this.pts = f, this.duration = k, this.originalDts = U, this.isSyncPoint = C, this.fileposition = null;
360
+ var U = function(y, f, L, x, C) {
361
+ this.dts = y, this.pts = f, this.duration = L, this.originalDts = x, this.isSyncPoint = C, this.fileposition = null;
362
362
  }, B = function() {
363
363
  function y() {
364
364
  this.beginDts = 0, this.endDts = 0, this.beginPts = 0, this.endPts = 0, this.originalBeginDts = 0, this.originalEndDts = 0, this.syncPoints = [], this.firstSample = null, this.lastSample = null;
@@ -373,19 +373,19 @@ var Tt = { exports: {} };
373
373
  return y.prototype.clear = function() {
374
374
  this._list = [];
375
375
  }, y.prototype.appendArray = function(f) {
376
- var k = this._list;
377
- f.length !== 0 && (k.length > 0 && f[0].originalDts < k[k.length - 1].originalDts && this.clear(), Array.prototype.push.apply(k, f));
376
+ var L = this._list;
377
+ f.length !== 0 && (L.length > 0 && f[0].originalDts < L[L.length - 1].originalDts && this.clear(), Array.prototype.push.apply(L, f));
378
378
  }, y.prototype.getLastSyncPointBeforeDts = function(f) {
379
379
  if (this._list.length == 0) return null;
380
- var k = this._list, U = 0, C = k.length - 1, V = 0, H = 0, ue = C;
381
- for (f < k[0].dts && (U = 0, H = ue + 1); H <= ue; ) {
382
- if ((V = H + Math.floor((ue - H) / 2)) === C || f >= k[V].dts && f < k[V + 1].dts) {
383
- U = V;
380
+ var L = this._list, x = 0, C = L.length - 1, V = 0, H = 0, ue = C;
381
+ for (f < L[0].dts && (x = 0, H = ue + 1); H <= ue; ) {
382
+ if ((V = H + Math.floor((ue - H) / 2)) === C || f >= L[V].dts && f < L[V + 1].dts) {
383
+ x = V;
384
384
  break;
385
385
  }
386
- k[V].dts < f ? H = V + 1 : ue = V - 1;
386
+ L[V].dts < f ? H = V + 1 : ue = V - 1;
387
387
  }
388
- return this._list[U];
388
+ return this._list[x];
389
389
  }, y;
390
390
  }(), b = function() {
391
391
  function y(f) {
@@ -400,36 +400,36 @@ var Tt = { exports: {} };
400
400
  }, y.prototype.clear = function() {
401
401
  this._list = [], this._lastAppendLocation = -1;
402
402
  }, y.prototype._searchNearestSegmentBefore = function(f) {
403
- var k = this._list;
404
- if (k.length === 0) return -2;
405
- var U = k.length - 1, C = 0, V = 0, H = U, ue = 0;
406
- if (f < k[0].originalBeginDts) return ue = -1;
403
+ var L = this._list;
404
+ if (L.length === 0) return -2;
405
+ var x = L.length - 1, C = 0, V = 0, H = x, ue = 0;
406
+ if (f < L[0].originalBeginDts) return ue = -1;
407
407
  for (; V <= H; ) {
408
- if ((C = V + Math.floor((H - V) / 2)) === U || f > k[C].lastSample.originalDts && f < k[C + 1].originalBeginDts) {
408
+ if ((C = V + Math.floor((H - V) / 2)) === x || f > L[C].lastSample.originalDts && f < L[C + 1].originalBeginDts) {
409
409
  ue = C;
410
410
  break;
411
411
  }
412
- k[C].originalBeginDts < f ? V = C + 1 : H = C - 1;
412
+ L[C].originalBeginDts < f ? V = C + 1 : H = C - 1;
413
413
  }
414
414
  return ue;
415
415
  }, y.prototype._searchNearestSegmentAfter = function(f) {
416
416
  return this._searchNearestSegmentBefore(f) + 1;
417
417
  }, y.prototype.append = function(f) {
418
- var k = this._list, U = f, C = this._lastAppendLocation, V = 0;
419
- C !== -1 && C < k.length && U.originalBeginDts >= k[C].lastSample.originalDts && (C === k.length - 1 || C < k.length - 1 && U.originalBeginDts < k[C + 1].originalBeginDts) ? V = C + 1 : k.length > 0 && (V = this._searchNearestSegmentBefore(U.originalBeginDts) + 1), this._lastAppendLocation = V, this._list.splice(V, 0, U);
418
+ var L = this._list, x = f, C = this._lastAppendLocation, V = 0;
419
+ C !== -1 && C < L.length && x.originalBeginDts >= L[C].lastSample.originalDts && (C === L.length - 1 || C < L.length - 1 && x.originalBeginDts < L[C + 1].originalBeginDts) ? V = C + 1 : L.length > 0 && (V = this._searchNearestSegmentBefore(x.originalBeginDts) + 1), this._lastAppendLocation = V, this._list.splice(V, 0, x);
420
420
  }, y.prototype.getLastSegmentBefore = function(f) {
421
- var k = this._searchNearestSegmentBefore(f);
422
- return k >= 0 ? this._list[k] : null;
421
+ var L = this._searchNearestSegmentBefore(f);
422
+ return L >= 0 ? this._list[L] : null;
423
423
  }, y.prototype.getLastSampleBefore = function(f) {
424
- var k = this.getLastSegmentBefore(f);
425
- return k != null ? k.lastSample : null;
424
+ var L = this.getLastSegmentBefore(f);
425
+ return L != null ? L.lastSample : null;
426
426
  }, y.prototype.getLastSyncPointBefore = function(f) {
427
- for (var k = this._searchNearestSegmentBefore(f), U = this._list[k].syncPoints; U.length === 0 && k > 0; ) k--, U = this._list[k].syncPoints;
428
- return U.length > 0 ? U[U.length - 1] : null;
427
+ for (var L = this._searchNearestSegmentBefore(f), x = this._list[L].syncPoints; x.length === 0 && L > 0; ) L--, x = this._list[L].syncPoints;
428
+ return x.length > 0 ? x[x.length - 1] : null;
429
429
  }, y;
430
430
  }();
431
431
  }, function(fe, Z, O) {
432
- var x = function() {
432
+ var U = function() {
433
433
  function B() {
434
434
  this.mimeType = null, this.duration = null, this.hasAudio = null, this.hasVideo = null, this.audioCodec = null, this.videoCodec = null, this.audioDataRate = null, this.videoDataRate = null, this.audioSampleRate = null, this.audioChannelCount = null, this.width = null, this.height = null, this.fps = null, this.profile = null, this.level = null, this.refFrames = null, this.chromaFormat = null, this.sarNum = null, this.sarDen = null, this.metadata = null, this.segments = null, this.segmentCount = null, this.hasKeyframesIndex = null, this.keyframesIndex = null;
435
435
  }
@@ -443,20 +443,20 @@ var Tt = { exports: {} };
443
443
  var b = this.keyframesIndex, y = this._search(b.times, m);
444
444
  return { index: y, milliseconds: b.times[y], fileposition: b.filepositions[y] };
445
445
  }, B.prototype._search = function(m, b) {
446
- var y = 0, f = m.length - 1, k = 0, U = 0, C = f;
447
- for (b < m[0] && (y = 0, U = C + 1); U <= C; ) {
448
- if ((k = U + Math.floor((C - U) / 2)) === f || b >= m[k] && b < m[k + 1]) {
449
- y = k;
446
+ var y = 0, f = m.length - 1, L = 0, x = 0, C = f;
447
+ for (b < m[0] && (y = 0, x = C + 1); x <= C; ) {
448
+ if ((L = x + Math.floor((C - x) / 2)) === f || b >= m[L] && b < m[L + 1]) {
449
+ y = L;
450
450
  break;
451
451
  }
452
- m[k] < b ? U = k + 1 : C = k - 1;
452
+ m[L] < b ? x = L + 1 : C = L - 1;
453
453
  }
454
454
  return y;
455
455
  }, B;
456
456
  }();
457
- Z.a = x;
457
+ Z.a = U;
458
458
  }, function(fe, Z, O) {
459
- var x = O(6), B = O.n(x), m = O(0), b = function() {
459
+ var U = O(6), B = O.n(U), m = O(0), b = function() {
460
460
  function y() {
461
461
  }
462
462
  return Object.defineProperty(y, "forceGlobalTag", { get: function() {
@@ -498,8 +498,8 @@ var Tt = { exports: {} };
498
498
  }, y._notifyChange = function() {
499
499
  var f = y.emitter;
500
500
  if (f.listenerCount("change") > 0) {
501
- var k = y.getConfig();
502
- f.emit("change", k);
501
+ var L = y.getConfig();
502
+ f.emit("change", L);
503
503
  }
504
504
  }, y.registerListener = function(f) {
505
505
  y.emitter.addListener("change", f);
@@ -513,7 +513,7 @@ var Tt = { exports: {} };
513
513
  }();
514
514
  b.emitter = new B.a(), Z.a = b;
515
515
  }, function(fe, Z, O) {
516
- var x = O(6), B = O.n(x), m = O(0), b = O(4), y = O(8);
516
+ var U = O(6), B = O.n(U), m = O(0), b = O(4), y = O(8);
517
517
  function f(r, t, i) {
518
518
  var e = r;
519
519
  if (t + i < e.length) {
@@ -522,8 +522,8 @@ var Tt = { exports: {} };
522
522
  }
523
523
  return !1;
524
524
  }
525
- var k, U = function(r) {
526
- for (var t = [], i = r, e = 0, a = r.length; e < a; ) if (i[e] < 128) t.push(String.fromCharCode(i[e])), ++e;
525
+ var L, x = function(r) {
526
+ for (var t = [], i = r, e = 0, n = r.length; e < n; ) if (i[e] < 128) t.push(String.fromCharCode(i[e])), ++e;
527
527
  else {
528
528
  if (!(i[e] < 192)) {
529
529
  if (i[e] < 224) {
@@ -547,96 +547,96 @@ var Tt = { exports: {} };
547
547
  t.push("�"), ++e;
548
548
  }
549
549
  return t.join("");
550
- }, C = O(3), V = (k = new ArrayBuffer(2), new DataView(k).setInt16(0, 256, !0), new Int16Array(k)[0] === 256), H = function() {
550
+ }, C = O(3), V = (L = new ArrayBuffer(2), new DataView(L).setInt16(0, 256, !0), new Int16Array(L)[0] === 256), H = function() {
551
551
  function r() {
552
552
  }
553
553
  return r.parseScriptData = function(t, i, e) {
554
- var a = {};
554
+ var n = {};
555
555
  try {
556
- var s = r.parseValue(t, i, e), n = r.parseValue(t, i + s.size, e - s.size);
557
- a[s.data] = n.data;
556
+ var s = r.parseValue(t, i, e), a = r.parseValue(t, i + s.size, e - s.size);
557
+ n[s.data] = a.data;
558
558
  } catch (o) {
559
559
  m.a.e("AMF", o.toString());
560
560
  }
561
- return a;
561
+ return n;
562
562
  }, r.parseObject = function(t, i, e) {
563
563
  if (e < 3) throw new C.a("Data not enough when parse ScriptDataObject");
564
- var a = r.parseString(t, i, e), s = r.parseValue(t, i + a.size, e - a.size), n = s.objectEnd;
565
- return { data: { name: a.data, value: s.data }, size: a.size + s.size, objectEnd: n };
564
+ var n = r.parseString(t, i, e), s = r.parseValue(t, i + n.size, e - n.size), a = s.objectEnd;
565
+ return { data: { name: n.data, value: s.data }, size: n.size + s.size, objectEnd: a };
566
566
  }, r.parseVariable = function(t, i, e) {
567
567
  return r.parseObject(t, i, e);
568
568
  }, r.parseString = function(t, i, e) {
569
569
  if (e < 2) throw new C.a("Data not enough when parse String");
570
- var a = new DataView(t, i, e).getUint16(0, !V);
571
- return { data: a > 0 ? U(new Uint8Array(t, i + 2, a)) : "", size: 2 + a };
570
+ var n = new DataView(t, i, e).getUint16(0, !V);
571
+ return { data: n > 0 ? x(new Uint8Array(t, i + 2, n)) : "", size: 2 + n };
572
572
  }, r.parseLongString = function(t, i, e) {
573
573
  if (e < 4) throw new C.a("Data not enough when parse LongString");
574
- var a = new DataView(t, i, e).getUint32(0, !V);
575
- return { data: a > 0 ? U(new Uint8Array(t, i + 4, a)) : "", size: 4 + a };
574
+ var n = new DataView(t, i, e).getUint32(0, !V);
575
+ return { data: n > 0 ? x(new Uint8Array(t, i + 4, n)) : "", size: 4 + n };
576
576
  }, r.parseDate = function(t, i, e) {
577
577
  if (e < 10) throw new C.a("Data size invalid when parse Date");
578
- var a = new DataView(t, i, e), s = a.getFloat64(0, !V), n = a.getInt16(8, !V);
579
- return { data: new Date(s += 60 * n * 1e3), size: 10 };
578
+ var n = new DataView(t, i, e), s = n.getFloat64(0, !V), a = n.getInt16(8, !V);
579
+ return { data: new Date(s += 60 * a * 1e3), size: 10 };
580
580
  }, r.parseValue = function(t, i, e) {
581
581
  if (e < 1) throw new C.a("Data not enough when parse Value");
582
- var a, s = new DataView(t, i, e), n = 1, o = s.getUint8(0), p = !1;
582
+ var n, s = new DataView(t, i, e), a = 1, o = s.getUint8(0), p = !1;
583
583
  try {
584
584
  switch (o) {
585
585
  case 0:
586
- a = s.getFloat64(1, !V), n += 8;
586
+ n = s.getFloat64(1, !V), a += 8;
587
587
  break;
588
588
  case 1:
589
- a = !!s.getUint8(1), n += 1;
589
+ n = !!s.getUint8(1), a += 1;
590
590
  break;
591
591
  case 2:
592
592
  var g = r.parseString(t, i + 1, e - 1);
593
- a = g.data, n += g.size;
593
+ n = g.data, a += g.size;
594
594
  break;
595
595
  case 3:
596
- a = {};
596
+ n = {};
597
597
  var E = 0;
598
- for ((16777215 & s.getUint32(e - 4, !V)) == 9 && (E = 3); n < e - 4; ) {
599
- var A = r.parseObject(t, i + n, e - n - E);
598
+ for ((16777215 & s.getUint32(e - 4, !V)) == 9 && (E = 3); a < e - 4; ) {
599
+ var A = r.parseObject(t, i + a, e - a - E);
600
600
  if (A.objectEnd) break;
601
- a[A.data.name] = A.data.value, n += A.size;
601
+ n[A.data.name] = A.data.value, a += A.size;
602
602
  }
603
- n <= e - 3 && (16777215 & s.getUint32(n - 1, !V)) === 9 && (n += 3);
603
+ a <= e - 3 && (16777215 & s.getUint32(a - 1, !V)) === 9 && (a += 3);
604
604
  break;
605
605
  case 8:
606
- for (a = {}, n += 4, E = 0, (16777215 & s.getUint32(e - 4, !V)) == 9 && (E = 3); n < e - 8; ) {
607
- var S = r.parseVariable(t, i + n, e - n - E);
606
+ for (n = {}, a += 4, E = 0, (16777215 & s.getUint32(e - 4, !V)) == 9 && (E = 3); a < e - 8; ) {
607
+ var S = r.parseVariable(t, i + a, e - a - E);
608
608
  if (S.objectEnd) break;
609
- a[S.data.name] = S.data.value, n += S.size;
609
+ n[S.data.name] = S.data.value, a += S.size;
610
610
  }
611
- n <= e - 3 && (16777215 & s.getUint32(n - 1, !V)) === 9 && (n += 3);
611
+ a <= e - 3 && (16777215 & s.getUint32(a - 1, !V)) === 9 && (a += 3);
612
612
  break;
613
613
  case 9:
614
- a = void 0, n = 1, p = !0;
614
+ n = void 0, a = 1, p = !0;
615
615
  break;
616
616
  case 10:
617
- a = [];
617
+ n = [];
618
618
  var w = s.getUint32(1, !V);
619
- n += 4;
619
+ a += 4;
620
620
  for (var I = 0; I < w; I++) {
621
- var z = r.parseValue(t, i + n, e - n);
622
- a.push(z.data), n += z.size;
621
+ var z = r.parseValue(t, i + a, e - a);
622
+ n.push(z.data), a += z.size;
623
623
  }
624
624
  break;
625
625
  case 11:
626
626
  var N = r.parseDate(t, i + 1, e - 1);
627
- a = N.data, n += N.size;
627
+ n = N.data, a += N.size;
628
628
  break;
629
629
  case 12:
630
630
  var J = r.parseString(t, i + 1, e - 1);
631
- a = J.data, n += J.size;
631
+ n = J.data, a += J.size;
632
632
  break;
633
633
  default:
634
- n = e, m.a.w("AMF", "Unsupported AMF value type " + o);
634
+ a = e, m.a.w("AMF", "Unsupported AMF value type " + o);
635
635
  }
636
636
  } catch (W) {
637
637
  m.a.e("AMF", W.toString());
638
638
  }
639
- return { data: a, size: n, objectEnd: p };
639
+ return { data: n, size: a, objectEnd: p };
640
640
  }, r;
641
641
  }(), ue = function() {
642
642
  function r(t) {
@@ -657,10 +657,10 @@ var Tt = { exports: {} };
657
657
  }
658
658
  var e = this._current_word_bits_left ? this._current_word : 0;
659
659
  e >>>= 32 - this._current_word_bits_left;
660
- var a = t - this._current_word_bits_left;
660
+ var n = t - this._current_word_bits_left;
661
661
  this._fillCurrentWord();
662
- var s = Math.min(a, this._current_word_bits_left), n = this._current_word >>> 32 - s;
663
- return this._current_word <<= s, this._current_word_bits_left -= s, e = e << s | n;
662
+ var s = Math.min(n, this._current_word_bits_left), a = this._current_word >>> 32 - s;
663
+ return this._current_word <<= s, this._current_word_bits_left -= s, e = e << s | a;
664
664
  }, r.prototype.readBool = function() {
665
665
  return this.readBits(1) === 1;
666
666
  }, r.prototype.readByte = function() {
@@ -680,14 +680,14 @@ var Tt = { exports: {} };
680
680
  function r() {
681
681
  }
682
682
  return r._ebsp2rbsp = function(t) {
683
- for (var i = t, e = i.byteLength, a = new Uint8Array(e), s = 0, n = 0; n < e; n++) n >= 2 && i[n] === 3 && i[n - 1] === 0 && i[n - 2] === 0 || (a[s] = i[n], s++);
684
- return new Uint8Array(a.buffer, 0, s);
683
+ for (var i = t, e = i.byteLength, n = new Uint8Array(e), s = 0, a = 0; a < e; a++) a >= 2 && i[a] === 3 && i[a - 1] === 0 && i[a - 2] === 0 || (n[s] = i[a], s++);
684
+ return new Uint8Array(n.buffer, 0, s);
685
685
  }, r.parseSPS = function(t) {
686
- for (var i = t.subarray(1, 4), e = "avc1.", a = 0; a < 3; a++) {
687
- var s = i[a].toString(16);
686
+ for (var i = t.subarray(1, 4), e = "avc1.", n = 0; n < 3; n++) {
687
+ var s = i[n].toString(16);
688
688
  s.length < 2 && (s = "0" + s), e += s;
689
689
  }
690
- var n = r._ebsp2rbsp(t), o = new ue(n);
690
+ var a = r._ebsp2rbsp(t), o = new ue(a);
691
691
  o.readByte();
692
692
  var p = o.readByte();
693
693
  o.readByte();
@@ -707,8 +707,8 @@ var Tt = { exports: {} };
707
707
  o.readBits(1);
708
708
  var he = o.readUEG(), K = o.readUEG(), Q = o.readBits(1);
709
709
  Q === 0 && o.readBits(1), o.readBits(1);
710
- var _e = 0, te = 0, ne = 0, be = 0;
711
- o.readBool() && (_e = o.readUEG(), te = o.readUEG(), ne = o.readUEG(), be = o.readUEG());
710
+ var _e = 0, te = 0, ae = 0, be = 0;
711
+ o.readBool() && (_e = o.readUEG(), te = o.readUEG(), ae = o.readUEG(), be = o.readUEG());
712
712
  var Ae = 1, le = 1, ve = 0, Re = !0, ke = 0, Ne = 0;
713
713
  if (o.readBool()) {
714
714
  if (o.readBool()) {
@@ -725,11 +725,11 @@ var Tt = { exports: {} };
725
725
  var Ce = 0, ge = 0;
726
726
  S === 0 ? (Ce = 1, ge = 2 - Q) : (Ce = S === 3 ? 1 : 2, ge = (S === 1 ? 2 : 1) * (2 - Q));
727
727
  var xe = 16 * (he + 1), Ue = 16 * (K + 1) * (2 - Q);
728
- xe -= (_e + te) * Ce, Ue -= (ne + be) * ge;
728
+ xe -= (_e + te) * Ce, Ue -= (ae + be) * ge;
729
729
  var Je = Math.ceil(xe * Fe);
730
730
  return o.destroy(), o = null, { codec_mimetype: e, profile_idc: p, level_idc: g, profile_string: E, level_string: A, chroma_format_idc: S, bit_depth: I, bit_depth_luma: I, bit_depth_chroma: z, ref_frames: de, chroma_format: w, chroma_format_string: r.getChromaFormatString(w), frame_rate: { fixed: Re, fps: ve, fps_den: Ne, fps_num: ke }, sar_ratio: { width: Ae, height: le }, codec_size: { width: xe, height: Ue }, present_size: { width: Je, height: Ue } };
731
731
  }, r._skipScalingList = function(t, i) {
732
- for (var e = 8, a = 8, s = 0; s < i; s++) a !== 0 && (a = (e + t.readSEG() + 256) % 256), e = a === 0 ? e : a;
732
+ for (var e = 8, n = 8, s = 0; s < i; s++) n !== 0 && (n = (e + t.readSEG() + 256) % 256), e = n === 0 ? e : n;
733
733
  }, r.getProfileString = function(t) {
734
734
  switch (t) {
735
735
  case 66:
@@ -763,26 +763,26 @@ var Tt = { exports: {} };
763
763
  return "Unknown";
764
764
  }
765
765
  }, r;
766
- }(), Y = O(5), ae = function() {
766
+ }(), Y = O(5), ne = function() {
767
767
  function r() {
768
768
  }
769
769
  return r._ebsp2rbsp = function(t) {
770
- for (var i = t, e = i.byteLength, a = new Uint8Array(e), s = 0, n = 0; n < e; n++) n >= 2 && i[n] === 3 && i[n - 1] === 0 && i[n - 2] === 0 || (a[s] = i[n], s++);
771
- return new Uint8Array(a.buffer, 0, s);
770
+ for (var i = t, e = i.byteLength, n = new Uint8Array(e), s = 0, a = 0; a < e; a++) a >= 2 && i[a] === 3 && i[a - 1] === 0 && i[a - 2] === 0 || (n[s] = i[a], s++);
771
+ return new Uint8Array(n.buffer, 0, s);
772
772
  }, r.parseVPS = function(t) {
773
773
  var i = r._ebsp2rbsp(t), e = new ue(i);
774
774
  return e.readByte(), e.readByte(), e.readBits(4), e.readBits(2), e.readBits(6), { num_temporal_layers: e.readBits(3) + 1, temporal_id_nested: e.readBool() };
775
775
  }, r.parseSPS = function(t) {
776
776
  var i = r._ebsp2rbsp(t), e = new ue(i);
777
777
  e.readByte(), e.readByte();
778
- for (var a = 0, s = 0, n = 0, o = 0, p = (e.readBits(4), e.readBits(3)), g = (e.readBool(), e.readBits(2)), E = e.readBool(), A = e.readBits(5), S = e.readByte(), w = e.readByte(), I = e.readByte(), z = e.readByte(), N = e.readByte(), J = e.readByte(), W = e.readByte(), q = e.readByte(), de = e.readByte(), he = e.readByte(), K = e.readByte(), Q = [], _e = [], te = 0; te < p; te++) Q.push(e.readBool()), _e.push(e.readBool());
778
+ for (var n = 0, s = 0, a = 0, o = 0, p = (e.readBits(4), e.readBits(3)), g = (e.readBool(), e.readBits(2)), E = e.readBool(), A = e.readBits(5), S = e.readByte(), w = e.readByte(), I = e.readByte(), z = e.readByte(), N = e.readByte(), J = e.readByte(), W = e.readByte(), q = e.readByte(), de = e.readByte(), he = e.readByte(), K = e.readByte(), Q = [], _e = [], te = 0; te < p; te++) Q.push(e.readBool()), _e.push(e.readBool());
779
779
  if (p > 0) for (te = p; te < 8; te++) e.readBits(2);
780
780
  for (te = 0; te < p; te++) Q[te] && (e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte(), e.readByte()), _e[te] && e.readByte();
781
781
  e.readUEG();
782
- var ne = e.readUEG();
783
- ne == 3 && e.readBits(1);
782
+ var ae = e.readUEG();
783
+ ae == 3 && e.readBits(1);
784
784
  var be = e.readUEG(), Ae = e.readUEG();
785
- e.readBool() && (a += e.readUEG(), s += e.readUEG(), n += e.readUEG(), o += e.readUEG());
785
+ e.readBool() && (n += e.readUEG(), s += e.readUEG(), a += e.readUEG(), o += e.readUEG());
786
786
  var le = e.readUEG(), ve = e.readUEG(), Re = e.readUEG();
787
787
  for (te = e.readBool() ? 0 : p; te <= p; te++) e.readUEG(), e.readUEG(), e.readUEG();
788
788
  if (e.readUEG(), e.readUEG(), e.readUEG(), e.readUEG(), e.readUEG(), e.readUEG(), e.readBool() && e.readBool()) for (var ke = 0; ke < 4; ke++) for (var Ne = 0; Ne < (ke === 3 ? 2 : 6); Ne++)
@@ -821,27 +821,27 @@ var Tt = { exports: {} };
821
821
  Ke > 0 && Ke <= 16 ? (He = [1, 12, 10, 16, 40, 24, 20, 32, 80, 18, 15, 64, 160, 4, 3, 2][Ke - 1], qe = [1, 11, 11, 11, 33, 11, 11, 11, 33, 11, 11, 33, 99, 3, 2, 1][Ke - 1]) : Ke === 255 && (He = e.readBits(16), qe = e.readBits(16));
822
822
  }
823
823
  if (e.readBool() && e.readBool(), e.readBool() && (e.readBits(3), e.readBool(), e.readBool() && (e.readByte(), e.readByte(), e.readByte())), e.readBool() && (e.readUEG(), e.readUEG()), e.readBool(), e.readBool(), e.readBool(), e.readBool() && (e.readUEG(), e.readUEG(), e.readUEG(), e.readUEG()), e.readBool() && (it = e.readBits(32), rt = e.readBits(32), e.readBool() && (e.readUEG(), e.readBool()))) {
824
- var at = !1, nt = !1, Ze = !1;
825
- for (at = e.readBool(), nt = e.readBool(), (at || nt) && ((Ze = e.readBool()) && (e.readByte(), e.readBits(5), e.readBool(), e.readBits(5)), e.readBits(4), e.readBits(4), Ze && e.readBits(4), e.readBits(5), e.readBits(5), e.readBits(5)), te = 0; te <= p; te++) {
824
+ var nt = !1, at = !1, Ze = !1;
825
+ for (nt = e.readBool(), at = e.readBool(), (nt || at) && ((Ze = e.readBool()) && (e.readByte(), e.readBits(5), e.readBool(), e.readBits(5)), e.readBits(4), e.readBits(4), Ze && e.readBits(4), e.readBits(5), e.readBits(5), e.readBits(5)), te = 0; te <= p; te++) {
826
826
  var gt = e.readBool();
827
827
  mt = gt;
828
828
  var yt = !1, st = 1;
829
829
  gt || (yt = e.readBool());
830
830
  var vt = !1;
831
- if (yt ? e.readSEG() : vt = e.readBool(), vt || (st = e.readUEG() + 1), at) for (ge = 0; ge < st; ge++) e.readUEG(), e.readUEG(), Ze && (e.readUEG(), e.readUEG());
832
- if (nt) for (ge = 0; ge < st; ge++) e.readUEG(), e.readUEG(), Ze && (e.readUEG(), e.readUEG());
831
+ if (yt ? e.readSEG() : vt = e.readBool(), vt || (st = e.readUEG() + 1), nt) for (ge = 0; ge < st; ge++) e.readUEG(), e.readUEG(), Ze && (e.readUEG(), e.readUEG());
832
+ if (at) for (ge = 0; ge < st; ge++) e.readUEG(), e.readUEG(), Ze && (e.readUEG(), e.readUEG());
833
833
  }
834
834
  }
835
835
  e.readBool() && (e.readBool(), e.readBool(), e.readBool(), pt = e.readUEG(), e.readUEG(), e.readUEG(), e.readUEG(), e.readUEG());
836
836
  }
837
837
  e.readBool();
838
- var Xt = "hvc1." + A + ".1.L" + K + ".B0", bt = be - (a + s) * (ne === 1 || ne === 2 ? 2 : 1), St = Ae - (n + o) * (ne === 1 ? 2 : 1), Et = 1;
839
- return He !== 1 && qe !== 1 && (Et = He / qe), e.destroy(), e = null, { codec_mimetype: Xt, level_string: r.getLevelString(K), profile_idc: A, bit_depth: le + 8, ref_frames: 1, chroma_format: ne, chroma_format_string: r.getChromaFormatString(ne), general_level_idc: K, general_profile_space: g, general_tier_flag: E, general_profile_idc: A, general_profile_compatibility_flags_1: S, general_profile_compatibility_flags_2: w, general_profile_compatibility_flags_3: I, general_profile_compatibility_flags_4: z, general_constraint_indicator_flags_1: N, general_constraint_indicator_flags_2: J, general_constraint_indicator_flags_3: W, general_constraint_indicator_flags_4: q, general_constraint_indicator_flags_5: de, general_constraint_indicator_flags_6: he, min_spatial_segmentation_idc: pt, constant_frame_rate: 0, chroma_format_idc: ne, bit_depth_luma_minus8: le, bit_depth_chroma_minus8: ve, frame_rate: { fixed: mt, fps: rt / it, fps_den: it, fps_num: rt }, sar_ratio: { width: He, height: qe }, codec_size: { width: bt, height: St }, present_size: { width: bt * Et, height: St } };
838
+ var Xt = "hvc1." + A + ".1.L" + K + ".B0", bt = be - (n + s) * (ae === 1 || ae === 2 ? 2 : 1), St = Ae - (a + o) * (ae === 1 ? 2 : 1), Et = 1;
839
+ return He !== 1 && qe !== 1 && (Et = He / qe), e.destroy(), e = null, { codec_mimetype: Xt, level_string: r.getLevelString(K), profile_idc: A, bit_depth: le + 8, ref_frames: 1, chroma_format: ae, chroma_format_string: r.getChromaFormatString(ae), general_level_idc: K, general_profile_space: g, general_tier_flag: E, general_profile_idc: A, general_profile_compatibility_flags_1: S, general_profile_compatibility_flags_2: w, general_profile_compatibility_flags_3: I, general_profile_compatibility_flags_4: z, general_constraint_indicator_flags_1: N, general_constraint_indicator_flags_2: J, general_constraint_indicator_flags_3: W, general_constraint_indicator_flags_4: q, general_constraint_indicator_flags_5: de, general_constraint_indicator_flags_6: he, min_spatial_segmentation_idc: pt, constant_frame_rate: 0, chroma_format_idc: ae, bit_depth_luma_minus8: le, bit_depth_chroma_minus8: ve, frame_rate: { fixed: mt, fps: rt / it, fps_den: it, fps_num: rt }, sar_ratio: { width: He, height: qe }, codec_size: { width: bt, height: St }, present_size: { width: bt * Et, height: St } };
840
840
  }, r.parsePPS = function(t) {
841
841
  var i = r._ebsp2rbsp(t), e = new ue(i);
842
842
  e.readByte(), e.readByte(), e.readUEG(), e.readUEG(), e.readBool(), e.readBool(), e.readBits(3), e.readBool(), e.readBool(), e.readUEG(), e.readUEG(), e.readSEG(), e.readBool(), e.readBool(), e.readBool() && e.readUEG(), e.readSEG(), e.readSEG(), e.readBool(), e.readBool(), e.readBool(), e.readBool();
843
- var a = e.readBool(), s = e.readBool(), n = 1;
844
- return s && a ? n = 0 : s ? n = 3 : a && (n = 2), { parallelismType: n };
843
+ var n = e.readBool(), s = e.readBool(), a = 1;
844
+ return s && n ? a = 0 : s ? a = 3 : n && (a = 2), { parallelismType: a };
845
845
  }, r.getChromaFormatString = function(t) {
846
846
  switch (t) {
847
847
  case 0:
@@ -906,8 +906,8 @@ var Tt = { exports: {} };
906
906
  if (i.byteLength < 9) return { needMoreData: !0 };
907
907
  var e = { match: !1 };
908
908
  if (i[0] !== 70 || i[1] !== 76 || i[2] !== 86 || i[3] !== 1) return e;
909
- var a, s, n = (4 & i[4]) >>> 2 != 0, o = (1 & i[4]) != 0, p = (a = i)[s = 5] << 24 | a[s + 1] << 16 | a[s + 2] << 8 | a[s + 3];
910
- return p < 9 ? e : { match: !0, consumed: p, dataOffset: p, hasAudioTrack: n, hasVideoTrack: o };
909
+ var n, s, a = (4 & i[4]) >>> 2 != 0, o = (1 & i[4]) != 0, p = (n = i)[s = 5] << 24 | n[s + 1] << 16 | n[s + 2] << 8 | n[s + 3];
910
+ return p < 9 ? e : { match: !0, consumed: p, dataOffset: p, hasAudioTrack: a, hasVideoTrack: o };
911
911
  }, r.prototype.bindDataSource = function(t) {
912
912
  return t.onDataArrival = this.parseChunks.bind(this), this;
913
913
  }, Object.defineProperty(r.prototype, "onTrackMetadata", { get: function() {
@@ -952,22 +952,22 @@ var Tt = { exports: {} };
952
952
  return this._hasAudio && this._hasVideo ? this._audioInitialMetadataDispatched && this._videoInitialMetadataDispatched : this._hasAudio && !this._hasVideo ? this._audioInitialMetadataDispatched : !(this._hasAudio || !this._hasVideo) && this._videoInitialMetadataDispatched;
953
953
  }, r.prototype.parseChunks = function(t, i) {
954
954
  if (!(this._onError && this._onMediaInfo && this._onTrackMetadata && this._onDataAvailable)) throw new C.a("Flv: onError & onMediaInfo & onTrackMetadata & onDataAvailable callback must be specified");
955
- var e = 0, a = this._littleEndian;
955
+ var e = 0, n = this._littleEndian;
956
956
  if (i === 0) {
957
957
  if (!(t.byteLength > 13)) return 0;
958
958
  e = r.probe(t).dataOffset;
959
959
  }
960
- for (this._firstParse && (this._firstParse = !1, i + e !== this._dataOffset && m.a.w(this.TAG, "First time parsing but chunk byteStart invalid!"), (s = new DataView(t, e)).getUint32(0, !a) !== 0 && m.a.w(this.TAG, "PrevTagSize0 !== 0 !!!"), e += 4); e < t.byteLength; ) {
960
+ for (this._firstParse && (this._firstParse = !1, i + e !== this._dataOffset && m.a.w(this.TAG, "First time parsing but chunk byteStart invalid!"), (s = new DataView(t, e)).getUint32(0, !n) !== 0 && m.a.w(this.TAG, "PrevTagSize0 !== 0 !!!"), e += 4); e < t.byteLength; ) {
961
961
  this._dispatch = !0;
962
962
  var s = new DataView(t, e);
963
963
  if (e + 11 + 4 > t.byteLength) break;
964
- var n = s.getUint8(0), o = 16777215 & s.getUint32(0, !a);
964
+ var a = s.getUint8(0), o = 16777215 & s.getUint32(0, !n);
965
965
  if (e + 11 + o + 4 > t.byteLength) break;
966
- if (n === 8 || n === 9 || n === 18) {
966
+ if (a === 8 || a === 9 || a === 18) {
967
967
  var p = s.getUint8(4), g = s.getUint8(5), E = s.getUint8(6) | g << 8 | p << 16 | s.getUint8(7) << 24;
968
- 16777215 & s.getUint32(7, !a) && m.a.w(this.TAG, "Meet tag which has StreamID != 0!");
968
+ 16777215 & s.getUint32(7, !n) && m.a.w(this.TAG, "Meet tag which has StreamID != 0!");
969
969
  var A = e + 11;
970
- switch (n) {
970
+ switch (a) {
971
971
  case 8:
972
972
  this._parseAudioData(t, A, o, E);
973
973
  break;
@@ -977,21 +977,21 @@ var Tt = { exports: {} };
977
977
  case 18:
978
978
  this._parseScriptData(t, A, o);
979
979
  }
980
- var S = s.getUint32(11 + o, !a);
980
+ var S = s.getUint32(11 + o, !n);
981
981
  S !== 11 + o && m.a.w(this.TAG, "Invalid PrevTagSize " + S), e += 11 + o + 4;
982
- } else m.a.w(this.TAG, "Unsupported tag type " + n + ", skipped"), e += 11 + o + 4;
982
+ } else m.a.w(this.TAG, "Unsupported tag type " + a + ", skipped"), e += 11 + o + 4;
983
983
  }
984
984
  return this._isInitialMetadataDispatched() && this._dispatch && (this._audioTrack.length || this._videoTrack.length) && this._onDataAvailable(this._audioTrack, this._videoTrack), e;
985
985
  }, r.prototype._parseScriptData = function(t, i, e) {
986
- var a = H.parseScriptData(t, i, e);
987
- if (a.hasOwnProperty("onMetaData")) {
988
- if (a.onMetaData == null || typeof a.onMetaData != "object") return void m.a.w(this.TAG, "Invalid onMetaData structure!");
989
- this._metadata && m.a.w(this.TAG, "Found another onMetaData tag!"), this._metadata = a;
986
+ var n = H.parseScriptData(t, i, e);
987
+ if (n.hasOwnProperty("onMetaData")) {
988
+ if (n.onMetaData == null || typeof n.onMetaData != "object") return void m.a.w(this.TAG, "Invalid onMetaData structure!");
989
+ this._metadata && m.a.w(this.TAG, "Found another onMetaData tag!"), this._metadata = n;
990
990
  var s = this._metadata.onMetaData;
991
991
  if (this._onMetaDataArrived && this._onMetaDataArrived(Object.assign({}, s)), typeof s.hasAudio == "boolean" && this._hasAudioFlagOverrided === !1 && (this._hasAudio = s.hasAudio, this._mediaInfo.hasAudio = this._hasAudio), typeof s.hasVideo == "boolean" && this._hasVideoFlagOverrided === !1 && (this._hasVideo = s.hasVideo, this._mediaInfo.hasVideo = this._hasVideo), typeof s.audiodatarate == "number" && (this._mediaInfo.audioDataRate = s.audiodatarate), typeof s.videodatarate == "number" && (this._mediaInfo.videoDataRate = s.videodatarate), typeof s.width == "number" && (this._mediaInfo.width = s.width), typeof s.height == "number" && (this._mediaInfo.height = s.height), typeof s.duration == "number") {
992
992
  if (!this._durationOverrided) {
993
- var n = Math.floor(s.duration * this._timescale);
994
- this._duration = n, this._mediaInfo.duration = n;
993
+ var a = Math.floor(s.duration * this._timescale);
994
+ this._duration = a, this._mediaInfo.duration = a;
995
995
  }
996
996
  } else this._mediaInfo.duration = 0;
997
997
  if (typeof s.framerate == "number") {
@@ -1008,24 +1008,24 @@ var Tt = { exports: {} };
1008
1008
  } else this._mediaInfo.hasKeyframesIndex = !1;
1009
1009
  this._dispatch = !1, this._mediaInfo.metadata = s, m.a.v(this.TAG, "Parsed onMetaData"), this._mediaInfo.isComplete() && this._onMediaInfo(this._mediaInfo);
1010
1010
  }
1011
- Object.keys(a).length > 0 && this._onScriptDataArrived && this._onScriptDataArrived(Object.assign({}, a));
1011
+ Object.keys(n).length > 0 && this._onScriptDataArrived && this._onScriptDataArrived(Object.assign({}, n));
1012
1012
  }, r.prototype._parseKeyframesIndex = function(t) {
1013
- for (var i = [], e = [], a = 1; a < t.times.length; a++) {
1014
- var s = this._timestampBase + Math.floor(1e3 * t.times[a]);
1015
- i.push(s), e.push(t.filepositions[a]);
1013
+ for (var i = [], e = [], n = 1; n < t.times.length; n++) {
1014
+ var s = this._timestampBase + Math.floor(1e3 * t.times[n]);
1015
+ i.push(s), e.push(t.filepositions[n]);
1016
1016
  }
1017
1017
  return { times: i, filepositions: e };
1018
- }, r.prototype._parseAudioData = function(t, i, e, a) {
1018
+ }, r.prototype._parseAudioData = function(t, i, e, n) {
1019
1019
  if (e <= 1) m.a.w(this.TAG, "Flv: Invalid audio packet, missing SoundData payload!");
1020
1020
  else if (this._hasAudioFlagOverrided !== !0 || this._hasAudio !== !1) {
1021
1021
  this._littleEndian;
1022
- var s = new DataView(t, i, e).getUint8(0), n = s >>> 4;
1023
- if (n === 2 || n === 10) {
1022
+ var s = new DataView(t, i, e).getUint8(0), a = s >>> 4;
1023
+ if (a === 2 || a === 10) {
1024
1024
  var o = 0, p = (12 & s) >>> 2;
1025
1025
  if (p >= 0 && p <= 4) {
1026
1026
  o = this._flvSoundRateTable[p];
1027
1027
  var g = 1 & s, E = this._audioMetadata, A = this._audioTrack;
1028
- if (E || (this._hasAudio === !1 && this._hasAudioFlagOverrided === !1 && (this._hasAudio = !0, this._mediaInfo.hasAudio = !0), (E = this._audioMetadata = {}).type = "audio", E.id = A.id, E.timescale = this._timescale, E.duration = this._duration, E.audioSampleRate = o, E.channelCount = g === 0 ? 1 : 2), n === 10) {
1028
+ if (E || (this._hasAudio === !1 && this._hasAudioFlagOverrided === !1 && (this._hasAudio = !0, this._mediaInfo.hasAudio = !0), (E = this._audioMetadata = {}).type = "audio", E.id = A.id, E.timescale = this._timescale, E.duration = this._duration, E.audioSampleRate = o, E.channelCount = g === 0 ? 1 : 2), a === 10) {
1029
1029
  var S = this._parseAACAudioData(t, i + 1, e - 1);
1030
1030
  if (S == null) return;
1031
1031
  if (S.packetType === 0) {
@@ -1036,10 +1036,10 @@ var Tt = { exports: {} };
1036
1036
  var w = S.data;
1037
1037
  E.audioSampleRate = w.samplingRate, E.channelCount = w.channelCount, E.codec = w.codec, E.originalCodec = w.originalCodec, E.config = w.config, E.refSampleDuration = 1024 / E.audioSampleRate * E.timescale, m.a.v(this.TAG, "Parsed AudioSpecificConfig"), this._isInitialMetadataDispatched() ? this._dispatch && (this._audioTrack.length || this._videoTrack.length) && this._onDataAvailable(this._audioTrack, this._videoTrack) : this._audioInitialMetadataDispatched = !0, this._dispatch = !1, this._onTrackMetadata("audio", E), (N = this._mediaInfo).audioCodec = E.originalCodec, N.audioSampleRate = E.audioSampleRate, N.audioChannelCount = E.channelCount, N.hasVideo ? N.videoCodec != null && (N.mimeType = 'video/x-flv; codecs="' + N.videoCodec + "," + N.audioCodec + '"') : N.mimeType = 'video/x-flv; codecs="' + N.audioCodec + '"', N.isComplete() && this._onMediaInfo(N);
1038
1038
  } else if (S.packetType === 1) {
1039
- var I = this._timestampBase + a, z = { unit: S.data, length: S.data.byteLength, dts: I, pts: I };
1039
+ var I = this._timestampBase + n, z = { unit: S.data, length: S.data.byteLength, dts: I, pts: I };
1040
1040
  A.samples.push(z), A.length += S.data.length;
1041
1041
  } else m.a.e(this.TAG, "Flv: Unsupported AAC data type " + S.packetType);
1042
- } else if (n === 2) {
1042
+ } else if (a === 2) {
1043
1043
  if (!E.codec) {
1044
1044
  var N;
1045
1045
  if ((w = this._parseMP3AudioData(t, i + 1, e - 1, !0)) == null) return;
@@ -1047,36 +1047,36 @@ var Tt = { exports: {} };
1047
1047
  }
1048
1048
  var J = this._parseMP3AudioData(t, i + 1, e - 1, !1);
1049
1049
  if (J == null) return;
1050
- I = this._timestampBase + a;
1050
+ I = this._timestampBase + n;
1051
1051
  var W = { unit: J, length: J.byteLength, dts: I, pts: I };
1052
1052
  A.samples.push(W), A.length += J.length;
1053
1053
  }
1054
1054
  } else this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid audio sample rate idx: " + p);
1055
- } else this._onError(Y.a.CODEC_UNSUPPORTED, "Flv: Unsupported audio codec idx: " + n);
1055
+ } else this._onError(Y.a.CODEC_UNSUPPORTED, "Flv: Unsupported audio codec idx: " + a);
1056
1056
  }
1057
1057
  }, r.prototype._parseAACAudioData = function(t, i, e) {
1058
1058
  if (!(e <= 1)) {
1059
- var a = {}, s = new Uint8Array(t, i, e);
1060
- return a.packetType = s[0], s[0] === 0 ? a.data = this._parseAACAudioSpecificConfig(t, i + 1, e - 1) : a.data = s.subarray(1), a;
1059
+ var n = {}, s = new Uint8Array(t, i, e);
1060
+ return n.packetType = s[0], s[0] === 0 ? n.data = this._parseAACAudioSpecificConfig(t, i + 1, e - 1) : n.data = s.subarray(1), n;
1061
1061
  }
1062
1062
  m.a.w(this.TAG, "Flv: Invalid AAC packet, missing AACPacketType or/and Data!");
1063
1063
  }, r.prototype._parseAACAudioSpecificConfig = function(t, i, e) {
1064
- var a, s, n = new Uint8Array(t, i, e), o = null, p = 0, g = null;
1065
- if (p = a = n[0] >>> 3, (s = (7 & n[0]) << 1 | n[1] >>> 7) < 0 || s >= this._mpegSamplingRates.length) this._onError(Y.a.FORMAT_ERROR, "Flv: AAC invalid sampling frequency index!");
1064
+ var n, s, a = new Uint8Array(t, i, e), o = null, p = 0, g = null;
1065
+ if (p = n = a[0] >>> 3, (s = (7 & a[0]) << 1 | a[1] >>> 7) < 0 || s >= this._mpegSamplingRates.length) this._onError(Y.a.FORMAT_ERROR, "Flv: AAC invalid sampling frequency index!");
1066
1066
  else {
1067
- var E = this._mpegSamplingRates[s], A = (120 & n[1]) >>> 3;
1067
+ var E = this._mpegSamplingRates[s], A = (120 & a[1]) >>> 3;
1068
1068
  if (!(A < 0 || A >= 8)) {
1069
- p === 5 && (g = (7 & n[1]) << 1 | n[2] >>> 7, (124 & n[2]) >>> 2);
1069
+ p === 5 && (g = (7 & a[1]) << 1 | a[2] >>> 7, (124 & a[2]) >>> 2);
1070
1070
  var S = self.navigator.userAgent.toLowerCase();
1071
- return S.indexOf("firefox") !== -1 ? s >= 6 ? (p = 5, o = new Array(4), g = s - 3) : (p = 2, o = new Array(2), g = s) : S.indexOf("android") !== -1 ? (p = 2, o = new Array(2), g = s) : (p = 5, g = s, o = new Array(4), s >= 6 ? g = s - 3 : A === 1 && (p = 2, o = new Array(2), g = s)), o[0] = p << 3, o[0] |= (15 & s) >>> 1, o[1] = (15 & s) << 7, o[1] |= (15 & A) << 3, p === 5 && (o[1] |= (15 & g) >>> 1, o[2] = (1 & g) << 7, o[2] |= 8, o[3] = 0), { config: o, samplingRate: E, channelCount: A, codec: "mp4a.40." + p, originalCodec: "mp4a.40." + a };
1071
+ return S.indexOf("firefox") !== -1 ? s >= 6 ? (p = 5, o = new Array(4), g = s - 3) : (p = 2, o = new Array(2), g = s) : S.indexOf("android") !== -1 ? (p = 2, o = new Array(2), g = s) : (p = 5, g = s, o = new Array(4), s >= 6 ? g = s - 3 : A === 1 && (p = 2, o = new Array(2), g = s)), o[0] = p << 3, o[0] |= (15 & s) >>> 1, o[1] = (15 & s) << 7, o[1] |= (15 & A) << 3, p === 5 && (o[1] |= (15 & g) >>> 1, o[2] = (1 & g) << 7, o[2] |= 8, o[3] = 0), { config: o, samplingRate: E, channelCount: A, codec: "mp4a.40." + p, originalCodec: "mp4a.40." + n };
1072
1072
  }
1073
1073
  this._onError(Y.a.FORMAT_ERROR, "Flv: AAC invalid channel configuration");
1074
1074
  }
1075
- }, r.prototype._parseMP3AudioData = function(t, i, e, a) {
1075
+ }, r.prototype._parseMP3AudioData = function(t, i, e, n) {
1076
1076
  if (!(e < 4)) {
1077
1077
  this._littleEndian;
1078
- var s = new Uint8Array(t, i, e), n = null;
1079
- if (a) {
1078
+ var s = new Uint8Array(t, i, e), a = null;
1079
+ if (n) {
1080
1080
  if (s[0] !== 255) return;
1081
1081
  var o = s[1] >>> 3 & 3, p = (6 & s[1]) >> 1, g = (240 & s[2]) >>> 4, E = (12 & s[2]) >>> 2, A = (s[3] >>> 6 & 3) !== 3 ? 2 : 1, S = 0, w = 0;
1082
1082
  switch (o) {
@@ -1099,96 +1099,96 @@ var Tt = { exports: {} };
1099
1099
  case 3:
1100
1100
  g < this._mpegAudioL1BitRateTable.length && (w = this._mpegAudioL1BitRateTable[g]);
1101
1101
  }
1102
- n = { bitRate: w, samplingRate: S, channelCount: A, codec: "mp3", originalCodec: "mp3" };
1103
- } else n = s;
1104
- return n;
1102
+ a = { bitRate: w, samplingRate: S, channelCount: A, codec: "mp3", originalCodec: "mp3" };
1103
+ } else a = s;
1104
+ return a;
1105
1105
  }
1106
1106
  m.a.w(this.TAG, "Flv: Invalid MP3 packet, header missing!");
1107
- }, r.prototype._parseVideoData = function(t, i, e, a, s) {
1107
+ }, r.prototype._parseVideoData = function(t, i, e, n, s) {
1108
1108
  if (e <= 1) m.a.w(this.TAG, "Flv: Invalid video packet, missing VideoData payload!");
1109
1109
  else if (this._hasVideoFlagOverrided !== !0 || this._hasVideo !== !1) {
1110
- var n = new Uint8Array(t, i, e)[0], o = (112 & n) >>> 4;
1111
- if (128 & n) {
1112
- var p = 15 & n, g = String.fromCharCode.apply(String, new Uint8Array(t, i, e).slice(1, 5));
1110
+ var a = new Uint8Array(t, i, e)[0], o = (112 & a) >>> 4;
1111
+ if (128 & a) {
1112
+ var p = 15 & a, g = String.fromCharCode.apply(String, new Uint8Array(t, i, e).slice(1, 5));
1113
1113
  if (g !== "hvc1") return void this._onError(Y.a.CODEC_UNSUPPORTED, "Flv: Unsupported codec in video frame: " + g);
1114
- this._parseEnhancedHEVCVideoPacket(t, i + 5, e - 5, a, s, o, p);
1114
+ this._parseEnhancedHEVCVideoPacket(t, i + 5, e - 5, n, s, o, p);
1115
1115
  } else {
1116
- var E = 15 & n;
1117
- if (E === 7) this._parseAVCVideoPacket(t, i + 1, e - 1, a, s, o);
1116
+ var E = 15 & a;
1117
+ if (E === 7) this._parseAVCVideoPacket(t, i + 1, e - 1, n, s, o);
1118
1118
  else {
1119
1119
  if (E !== 12) return void this._onError(Y.a.CODEC_UNSUPPORTED, "Flv: Unsupported codec in video frame: " + E);
1120
- this._parseHEVCVideoPacket(t, i + 1, e - 1, a, s, o);
1120
+ this._parseHEVCVideoPacket(t, i + 1, e - 1, n, s, o);
1121
1121
  }
1122
1122
  }
1123
1123
  }
1124
- }, r.prototype._parseAVCVideoPacket = function(t, i, e, a, s, n) {
1124
+ }, r.prototype._parseAVCVideoPacket = function(t, i, e, n, s, a) {
1125
1125
  if (e < 4) m.a.w(this.TAG, "Flv: Invalid AVC packet, missing AVCPacketType or/and CompositionTime");
1126
1126
  else {
1127
1127
  var o = this._littleEndian, p = new DataView(t, i, e), g = p.getUint8(0), E = (16777215 & p.getUint32(0, !o)) << 8 >> 8;
1128
1128
  if (g === 0) this._parseAVCDecoderConfigurationRecord(t, i + 4, e - 4);
1129
- else if (g === 1) this._parseAVCVideoData(t, i + 4, e - 4, a, s, n, E);
1129
+ else if (g === 1) this._parseAVCVideoData(t, i + 4, e - 4, n, s, a, E);
1130
1130
  else if (g !== 2) return void this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid video packet type " + g);
1131
1131
  }
1132
- }, r.prototype._parseHEVCVideoPacket = function(t, i, e, a, s, n) {
1132
+ }, r.prototype._parseHEVCVideoPacket = function(t, i, e, n, s, a) {
1133
1133
  if (e < 4) m.a.w(this.TAG, "Flv: Invalid HEVC packet, missing HEVCPacketType or/and CompositionTime");
1134
1134
  else {
1135
1135
  var o = this._littleEndian, p = new DataView(t, i, e), g = p.getUint8(0), E = (16777215 & p.getUint32(0, !o)) << 8 >> 8;
1136
1136
  if (g === 0) this._parseHEVCDecoderConfigurationRecord(t, i + 4, e - 4);
1137
- else if (g === 1) this._parseHEVCVideoData(t, i + 4, e - 4, a, s, n, E);
1137
+ else if (g === 1) this._parseHEVCVideoData(t, i + 4, e - 4, n, s, a, E);
1138
1138
  else if (g !== 2) return void this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid video packet type " + g);
1139
1139
  }
1140
- }, r.prototype._parseEnhancedHEVCVideoPacket = function(t, i, e, a, s, n, o) {
1140
+ }, r.prototype._parseEnhancedHEVCVideoPacket = function(t, i, e, n, s, a, o) {
1141
1141
  if (e < 4) m.a.w(this.TAG, "Flv: Invalid HEVC packet, missing HEVCPacketType or/and CompositionTime");
1142
1142
  else {
1143
1143
  var p = this._littleEndian, g = new DataView(t, i, e);
1144
1144
  if (o === 0) this._parseHEVCDecoderConfigurationRecord(t, i, e);
1145
1145
  else if (o === 1) {
1146
1146
  var E = (4294967040 & g.getUint32(0, !p)) >> 8;
1147
- this._parseHEVCVideoData(t, i + 3, e - 3, a, s, n, E);
1148
- } else if (o === 3) this._parseHEVCVideoData(t, i, e, a, s, n, 0);
1147
+ this._parseHEVCVideoData(t, i + 3, e - 3, n, s, a, E);
1148
+ } else if (o === 3) this._parseHEVCVideoData(t, i, e, n, s, a, 0);
1149
1149
  else if (o !== 2) return void this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid video packet type " + o);
1150
1150
  }
1151
1151
  }, r.prototype._parseAVCDecoderConfigurationRecord = function(t, i, e) {
1152
1152
  if (e < 7) m.a.w(this.TAG, "Flv: Invalid AVCDecoderConfigurationRecord, lack of data!");
1153
1153
  else {
1154
- var a = this._videoMetadata, s = this._videoTrack, n = this._littleEndian, o = new DataView(t, i, e);
1155
- if (a) {
1156
- if (a.avcc !== void 0) {
1154
+ var n = this._videoMetadata, s = this._videoTrack, a = this._littleEndian, o = new DataView(t, i, e);
1155
+ if (n) {
1156
+ if (n.avcc !== void 0) {
1157
1157
  var p = new Uint8Array(t, i, e);
1158
- if (l(p, a.avcc)) return;
1158
+ if (l(p, n.avcc)) return;
1159
1159
  m.a.w(this.TAG, "AVCDecoderConfigurationRecord has been changed, re-generate initialization segment");
1160
1160
  }
1161
- } else this._hasVideo === !1 && this._hasVideoFlagOverrided === !1 && (this._hasVideo = !0, this._mediaInfo.hasVideo = !0), (a = this._videoMetadata = {}).type = "video", a.id = s.id, a.timescale = this._timescale, a.duration = this._duration;
1161
+ } else this._hasVideo === !1 && this._hasVideoFlagOverrided === !1 && (this._hasVideo = !0, this._mediaInfo.hasVideo = !0), (n = this._videoMetadata = {}).type = "video", n.id = s.id, n.timescale = this._timescale, n.duration = this._duration;
1162
1162
  var g = o.getUint8(0), E = o.getUint8(1);
1163
1163
  if (o.getUint8(2), o.getUint8(3), g === 1 && E !== 0) if (this._naluLengthSize = 1 + (3 & o.getUint8(4)), this._naluLengthSize === 3 || this._naluLengthSize === 4) {
1164
1164
  var A = 31 & o.getUint8(5);
1165
1165
  if (A !== 0) {
1166
1166
  A > 1 && m.a.w(this.TAG, "Flv: Strange AVCDecoderConfigurationRecord: SPS Count = " + A);
1167
1167
  for (var S = 6, w = 0; w < A; w++) {
1168
- var I = o.getUint16(S, !n);
1168
+ var I = o.getUint16(S, !a);
1169
1169
  if (S += 2, I !== 0) {
1170
1170
  var z = new Uint8Array(t, i + S, I);
1171
1171
  S += I;
1172
1172
  var N = se.parseSPS(z);
1173
1173
  if (w === 0) {
1174
- a.codecWidth = N.codec_size.width, a.codecHeight = N.codec_size.height, a.presentWidth = N.present_size.width, a.presentHeight = N.present_size.height, a.profile = N.profile_string, a.level = N.level_string, a.bitDepth = N.bit_depth, a.chromaFormat = N.chroma_format, a.sarRatio = N.sar_ratio, a.frameRate = N.frame_rate, N.frame_rate.fixed !== !1 && N.frame_rate.fps_num !== 0 && N.frame_rate.fps_den !== 0 || (a.frameRate = this._referenceFrameRate);
1175
- var J = a.frameRate.fps_den, W = a.frameRate.fps_num;
1176
- a.refSampleDuration = a.timescale * (J / W);
1174
+ n.codecWidth = N.codec_size.width, n.codecHeight = N.codec_size.height, n.presentWidth = N.present_size.width, n.presentHeight = N.present_size.height, n.profile = N.profile_string, n.level = N.level_string, n.bitDepth = N.bit_depth, n.chromaFormat = N.chroma_format, n.sarRatio = N.sar_ratio, n.frameRate = N.frame_rate, N.frame_rate.fixed !== !1 && N.frame_rate.fps_num !== 0 && N.frame_rate.fps_den !== 0 || (n.frameRate = this._referenceFrameRate);
1175
+ var J = n.frameRate.fps_den, W = n.frameRate.fps_num;
1176
+ n.refSampleDuration = n.timescale * (J / W);
1177
1177
  for (var q = z.subarray(1, 4), de = "avc1.", he = 0; he < 3; he++) {
1178
1178
  var K = q[he].toString(16);
1179
1179
  K.length < 2 && (K = "0" + K), de += K;
1180
1180
  }
1181
- a.codec = de;
1181
+ n.codec = de;
1182
1182
  var Q = this._mediaInfo;
1183
- Q.width = a.codecWidth, Q.height = a.codecHeight, Q.fps = a.frameRate.fps, Q.profile = a.profile, Q.level = a.level, Q.refFrames = N.ref_frames, Q.chromaFormat = N.chroma_format_string, Q.sarNum = a.sarRatio.width, Q.sarDen = a.sarRatio.height, Q.videoCodec = de, Q.hasAudio ? Q.audioCodec != null && (Q.mimeType = 'video/x-flv; codecs="' + Q.videoCodec + "," + Q.audioCodec + '"') : Q.mimeType = 'video/x-flv; codecs="' + Q.videoCodec + '"', Q.isComplete() && this._onMediaInfo(Q);
1183
+ Q.width = n.codecWidth, Q.height = n.codecHeight, Q.fps = n.frameRate.fps, Q.profile = n.profile, Q.level = n.level, Q.refFrames = N.ref_frames, Q.chromaFormat = N.chroma_format_string, Q.sarNum = n.sarRatio.width, Q.sarDen = n.sarRatio.height, Q.videoCodec = de, Q.hasAudio ? Q.audioCodec != null && (Q.mimeType = 'video/x-flv; codecs="' + Q.videoCodec + "," + Q.audioCodec + '"') : Q.mimeType = 'video/x-flv; codecs="' + Q.videoCodec + '"', Q.isComplete() && this._onMediaInfo(Q);
1184
1184
  }
1185
1185
  }
1186
1186
  }
1187
1187
  var _e = o.getUint8(S);
1188
1188
  if (_e !== 0) {
1189
1189
  for (_e > 1 && m.a.w(this.TAG, "Flv: Strange AVCDecoderConfigurationRecord: PPS Count = " + _e), S++, w = 0; w < _e; w++)
1190
- I = o.getUint16(S, !n), S += 2, I !== 0 && (S += I);
1191
- a.avcc = new Uint8Array(e), a.avcc.set(new Uint8Array(t, i, e), 0), m.a.v(this.TAG, "Parsed AVCDecoderConfigurationRecord"), this._isInitialMetadataDispatched() ? this._dispatch && (this._audioTrack.length || this._videoTrack.length) && this._onDataAvailable(this._audioTrack, this._videoTrack) : this._videoInitialMetadataDispatched = !0, this._dispatch = !1, this._onTrackMetadata("video", a);
1190
+ I = o.getUint16(S, !a), S += 2, I !== 0 && (S += I);
1191
+ n.avcc = new Uint8Array(e), n.avcc.set(new Uint8Array(t, i, e), 0), m.a.v(this.TAG, "Parsed AVCDecoderConfigurationRecord"), this._isInitialMetadataDispatched() ? this._dispatch && (this._audioTrack.length || this._videoTrack.length) && this._onDataAvailable(this._audioTrack, this._videoTrack) : this._videoInitialMetadataDispatched = !0, this._dispatch = !1, this._onTrackMetadata("video", n);
1192
1192
  } else this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid AVCDecoderConfigurationRecord: No PPS");
1193
1193
  } else this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid AVCDecoderConfigurationRecord: No SPS");
1194
1194
  } else this._onError(Y.a.FORMAT_ERROR, "Flv: Strange NaluLengthSizeMinusOne: " + (this._naluLengthSize - 1));
@@ -1197,39 +1197,39 @@ var Tt = { exports: {} };
1197
1197
  }, r.prototype._parseHEVCDecoderConfigurationRecord = function(t, i, e) {
1198
1198
  if (e < 22) m.a.w(this.TAG, "Flv: Invalid HEVCDecoderConfigurationRecord, lack of data!");
1199
1199
  else {
1200
- var a = this._videoMetadata, s = this._videoTrack, n = this._littleEndian, o = new DataView(t, i, e);
1201
- if (a) {
1202
- if (a.hvcc !== void 0) {
1200
+ var n = this._videoMetadata, s = this._videoTrack, a = this._littleEndian, o = new DataView(t, i, e);
1201
+ if (n) {
1202
+ if (n.hvcc !== void 0) {
1203
1203
  var p = new Uint8Array(t, i, e);
1204
- if (l(p, a.hvcc)) return;
1204
+ if (l(p, n.hvcc)) return;
1205
1205
  m.a.w(this.TAG, "HEVCDecoderConfigurationRecord has been changed, re-generate initialization segment");
1206
1206
  }
1207
- } else this._hasVideo === !1 && this._hasVideoFlagOverrided === !1 && (this._hasVideo = !0, this._mediaInfo.hasVideo = !0), (a = this._videoMetadata = {}).type = "video", a.id = s.id, a.timescale = this._timescale, a.duration = this._duration;
1207
+ } else this._hasVideo === !1 && this._hasVideoFlagOverrided === !1 && (this._hasVideo = !0, this._mediaInfo.hasVideo = !0), (n = this._videoMetadata = {}).type = "video", n.id = s.id, n.timescale = this._timescale, n.duration = this._duration;
1208
1208
  var g = o.getUint8(0), E = 31 & o.getUint8(1);
1209
1209
  if (g === 1 && E !== 0) if (this._naluLengthSize = 1 + (3 & o.getUint8(21)), this._naluLengthSize === 3 || this._naluLengthSize === 4) {
1210
1210
  for (var A = o.getUint8(22), S = 0, w = 23; S < A; S++) {
1211
- var I = 63 & o.getUint8(w + 0), z = o.getUint16(w + 1, !n);
1211
+ var I = 63 & o.getUint8(w + 0), z = o.getUint16(w + 1, !a);
1212
1212
  w += 3;
1213
1213
  for (var N = 0; N < z; N++) {
1214
- var J = o.getUint16(w + 0, !n);
1214
+ var J = o.getUint16(w + 0, !a);
1215
1215
  if (N === 0) if (I === 33) {
1216
1216
  w += 2;
1217
- var W = new Uint8Array(t, i + w, J), q = ae.parseSPS(W);
1218
- a.codecWidth = q.codec_size.width, a.codecHeight = q.codec_size.height, a.presentWidth = q.present_size.width, a.presentHeight = q.present_size.height, a.profile = q.profile_string, a.level = q.level_string, a.bitDepth = q.bit_depth, a.chromaFormat = q.chroma_format, a.sarRatio = q.sar_ratio, a.frameRate = q.frame_rate, q.frame_rate.fixed !== !1 && q.frame_rate.fps_num !== 0 && q.frame_rate.fps_den !== 0 || (a.frameRate = this._referenceFrameRate);
1219
- var de = a.frameRate.fps_den, he = a.frameRate.fps_num;
1220
- a.refSampleDuration = a.timescale * (de / he), a.codec = q.codec_mimetype;
1217
+ var W = new Uint8Array(t, i + w, J), q = ne.parseSPS(W);
1218
+ n.codecWidth = q.codec_size.width, n.codecHeight = q.codec_size.height, n.presentWidth = q.present_size.width, n.presentHeight = q.present_size.height, n.profile = q.profile_string, n.level = q.level_string, n.bitDepth = q.bit_depth, n.chromaFormat = q.chroma_format, n.sarRatio = q.sar_ratio, n.frameRate = q.frame_rate, q.frame_rate.fixed !== !1 && q.frame_rate.fps_num !== 0 && q.frame_rate.fps_den !== 0 || (n.frameRate = this._referenceFrameRate);
1219
+ var de = n.frameRate.fps_den, he = n.frameRate.fps_num;
1220
+ n.refSampleDuration = n.timescale * (de / he), n.codec = q.codec_mimetype;
1221
1221
  var K = this._mediaInfo;
1222
- K.width = a.codecWidth, K.height = a.codecHeight, K.fps = a.frameRate.fps, K.profile = a.profile, K.level = a.level, K.refFrames = q.ref_frames, K.chromaFormat = q.chroma_format_string, K.sarNum = a.sarRatio.width, K.sarDen = a.sarRatio.height, K.videoCodec = q.codec_mimetype, K.hasAudio ? K.audioCodec != null && (K.mimeType = 'video/x-flv; codecs="' + K.videoCodec + "," + K.audioCodec + '"') : K.mimeType = 'video/x-flv; codecs="' + K.videoCodec + '"', K.isComplete() && this._onMediaInfo(K), w += J;
1222
+ K.width = n.codecWidth, K.height = n.codecHeight, K.fps = n.frameRate.fps, K.profile = n.profile, K.level = n.level, K.refFrames = q.ref_frames, K.chromaFormat = q.chroma_format_string, K.sarNum = n.sarRatio.width, K.sarDen = n.sarRatio.height, K.videoCodec = q.codec_mimetype, K.hasAudio ? K.audioCodec != null && (K.mimeType = 'video/x-flv; codecs="' + K.videoCodec + "," + K.audioCodec + '"') : K.mimeType = 'video/x-flv; codecs="' + K.videoCodec + '"', K.isComplete() && this._onMediaInfo(K), w += J;
1223
1223
  } else w += 2 + J;
1224
1224
  else w += 2 + J;
1225
1225
  }
1226
1226
  }
1227
- a.hvcc = new Uint8Array(e), a.hvcc.set(new Uint8Array(t, i, e), 0), m.a.v(this.TAG, "Parsed HEVCDecoderConfigurationRecord"), this._isInitialMetadataDispatched() ? this._dispatch && (this._audioTrack.length || this._videoTrack.length) && this._onDataAvailable(this._audioTrack, this._videoTrack) : this._videoInitialMetadataDispatched = !0, this._dispatch = !1, this._onTrackMetadata("video", a);
1227
+ n.hvcc = new Uint8Array(e), n.hvcc.set(new Uint8Array(t, i, e), 0), m.a.v(this.TAG, "Parsed HEVCDecoderConfigurationRecord"), this._isInitialMetadataDispatched() ? this._dispatch && (this._audioTrack.length || this._videoTrack.length) && this._onDataAvailable(this._audioTrack, this._videoTrack) : this._videoInitialMetadataDispatched = !0, this._dispatch = !1, this._onTrackMetadata("video", n);
1228
1228
  } else this._onError(Y.a.FORMAT_ERROR, "Flv: Strange NaluLengthSizeMinusOne: " + (this._naluLengthSize - 1));
1229
1229
  else this._onError(Y.a.FORMAT_ERROR, "Flv: Invalid HEVCDecoderConfigurationRecord");
1230
1230
  }
1231
- }, r.prototype._parseAVCVideoData = function(t, i, e, a, s, n, o) {
1232
- for (var p = this._littleEndian, g = new DataView(t, i, e), E = [], A = 0, S = 0, w = this._naluLengthSize, I = this._timestampBase + a, z = n === 1; S < e; ) {
1231
+ }, r.prototype._parseAVCVideoData = function(t, i, e, n, s, a, o) {
1232
+ for (var p = this._littleEndian, g = new DataView(t, i, e), E = [], A = 0, S = 0, w = this._naluLengthSize, I = this._timestampBase + n, z = a === 1; S < e; ) {
1233
1233
  if (S + 4 >= e) {
1234
1234
  m.a.w(this.TAG, "Malformed Nalu near timestamp " + I + ", offset = " + S + ", dataSize = " + e);
1235
1235
  break;
@@ -1245,8 +1245,8 @@ var Tt = { exports: {} };
1245
1245
  var de = this._videoTrack, he = { units: E, length: A, isKeyframe: z, dts: I, cts: o, pts: I + o };
1246
1246
  z && (he.fileposition = s), de.samples.push(he), de.length += A;
1247
1247
  }
1248
- }, r.prototype._parseHEVCVideoData = function(t, i, e, a, s, n, o) {
1249
- for (var p = this._littleEndian, g = new DataView(t, i, e), E = [], A = 0, S = 0, w = this._naluLengthSize, I = this._timestampBase + a, z = n === 1; S < e; ) {
1248
+ }, r.prototype._parseHEVCVideoData = function(t, i, e, n, s, a, o) {
1249
+ for (var p = this._littleEndian, g = new DataView(t, i, e), E = [], A = 0, S = 0, w = this._naluLengthSize, I = this._timestampBase + n, z = a === 1; S < e; ) {
1250
1250
  if (S + 4 >= e) {
1251
1251
  m.a.w(this.TAG, "Malformed Nalu near timestamp " + I + ", offset = " + S + ", dataSize = " + e);
1252
1252
  break;
@@ -1285,7 +1285,7 @@ var Tt = { exports: {} };
1285
1285
  (function(r) {
1286
1286
  r[r.kUnspecified = 0] = "kUnspecified", r[r.kSliceNonIDR = 1] = "kSliceNonIDR", r[r.kSliceDPA = 2] = "kSliceDPA", r[r.kSliceDPB = 3] = "kSliceDPB", r[r.kSliceDPC = 4] = "kSliceDPC", r[r.kSliceIDR = 5] = "kSliceIDR", r[r.kSliceSEI = 6] = "kSliceSEI", r[r.kSliceSPS = 7] = "kSliceSPS", r[r.kSlicePPS = 8] = "kSlicePPS", r[r.kSliceAUD = 9] = "kSliceAUD", r[r.kEndOfSequence = 10] = "kEndOfSequence", r[r.kEndOfStream = 11] = "kEndOfStream", r[r.kFiller = 12] = "kFiller", r[r.kSPSExt = 13] = "kSPSExt", r[r.kReserved0 = 14] = "kReserved0";
1287
1287
  })(D || (D = {}));
1288
- var L, d, h = function() {
1288
+ var k, d, h = function() {
1289
1289
  }, R = function(r) {
1290
1290
  var t = r.data.byteLength;
1291
1291
  this.type = r.type, this.data = new Uint8Array(4 + t), new DataView(this.data.buffer).setUint32(0, t), this.data.set(r.data, 4);
@@ -1296,32 +1296,32 @@ var Tt = { exports: {} };
1296
1296
  return r.prototype.findNextStartCodeOffset = function(t) {
1297
1297
  for (var i = t, e = this.data_; ; ) {
1298
1298
  if (i + 3 >= e.byteLength) return this.eof_flag_ = !0, e.byteLength;
1299
- var a = e[i + 0] << 24 | e[i + 1] << 16 | e[i + 2] << 8 | e[i + 3], s = e[i + 0] << 16 | e[i + 1] << 8 | e[i + 2];
1300
- if (a === 1 || s === 1) return i;
1299
+ var n = e[i + 0] << 24 | e[i + 1] << 16 | e[i + 2] << 8 | e[i + 3], s = e[i + 0] << 16 | e[i + 1] << 8 | e[i + 2];
1300
+ if (n === 1 || s === 1) return i;
1301
1301
  i++;
1302
1302
  }
1303
1303
  }, r.prototype.readNextNaluPayload = function() {
1304
1304
  for (var t = this.data_, i = null; i == null && !this.eof_flag_; ) {
1305
- var e = this.current_startcode_offset_, a = 31 & t[e += (t[e] << 24 | t[e + 1] << 16 | t[e + 2] << 8 | t[e + 3]) === 1 ? 4 : 3], s = (128 & t[e]) >>> 7, n = this.findNextStartCodeOffset(e);
1306
- if (this.current_startcode_offset_ = n, !(a >= D.kReserved0) && s === 0) {
1307
- var o = t.subarray(e, n);
1308
- (i = new h()).type = a, i.data = o;
1305
+ var e = this.current_startcode_offset_, n = 31 & t[e += (t[e] << 24 | t[e + 1] << 16 | t[e + 2] << 8 | t[e + 3]) === 1 ? 4 : 3], s = (128 & t[e]) >>> 7, a = this.findNextStartCodeOffset(e);
1306
+ if (this.current_startcode_offset_ = a, !(n >= D.kReserved0) && s === 0) {
1307
+ var o = t.subarray(e, a);
1308
+ (i = new h()).type = n, i.data = o;
1309
1309
  }
1310
1310
  }
1311
1311
  return i;
1312
1312
  }, r;
1313
1313
  }(), oe = function() {
1314
1314
  function r(t, i, e) {
1315
- var a = 8 + t.byteLength + 1 + 2 + i.byteLength, s = !1;
1316
- t[3] !== 66 && t[3] !== 77 && t[3] !== 88 && (s = !0, a += 4);
1317
- var n = this.data = new Uint8Array(a);
1318
- n[0] = 1, n[1] = t[1], n[2] = t[2], n[3] = t[3], n[4] = 255, n[5] = 225;
1315
+ var n = 8 + t.byteLength + 1 + 2 + i.byteLength, s = !1;
1316
+ t[3] !== 66 && t[3] !== 77 && t[3] !== 88 && (s = !0, n += 4);
1317
+ var a = this.data = new Uint8Array(n);
1318
+ a[0] = 1, a[1] = t[1], a[2] = t[2], a[3] = t[3], a[4] = 255, a[5] = 225;
1319
1319
  var o = t.byteLength;
1320
- n[6] = o >>> 8, n[7] = 255 & o;
1320
+ a[6] = o >>> 8, a[7] = 255 & o;
1321
1321
  var p = 8;
1322
- n.set(t, 8), n[p += o] = 1;
1322
+ a.set(t, 8), a[p += o] = 1;
1323
1323
  var g = i.byteLength;
1324
- n[p + 1] = g >>> 8, n[p + 2] = 255 & g, n.set(i, p + 3), p += 3 + g, s && (n[p] = 252 | e.chroma_format_idc, n[p + 1] = 248 | e.bit_depth_luma - 8, n[p + 2] = 248 | e.bit_depth_chroma - 8, n[p + 3] = 0, p += 4);
1324
+ a[p + 1] = g >>> 8, a[p + 2] = 255 & g, a.set(i, p + 3), p += 3 + g, s && (a[p] = 252 | e.chroma_format_idc, a[p + 1] = 248 | e.bit_depth_luma - 8, a[p + 2] = 248 | e.bit_depth_chroma - 8, a[p + 3] = 0, p += 4);
1325
1325
  }
1326
1326
  return r.prototype.getData = function() {
1327
1327
  return this.data;
@@ -1329,14 +1329,14 @@ var Tt = { exports: {} };
1329
1329
  }();
1330
1330
  (function(r) {
1331
1331
  r[r.kNull = 0] = "kNull", r[r.kAACMain = 1] = "kAACMain", r[r.kAAC_LC = 2] = "kAAC_LC", r[r.kAAC_SSR = 3] = "kAAC_SSR", r[r.kAAC_LTP = 4] = "kAAC_LTP", r[r.kAAC_SBR = 5] = "kAAC_SBR", r[r.kAAC_Scalable = 6] = "kAAC_Scalable", r[r.kLayer1 = 32] = "kLayer1", r[r.kLayer2 = 33] = "kLayer2", r[r.kLayer3 = 34] = "kLayer3";
1332
- })(L || (L = {})), function(r) {
1332
+ })(k || (k = {})), function(r) {
1333
1333
  r[r.k96000Hz = 0] = "k96000Hz", r[r.k88200Hz = 1] = "k88200Hz", r[r.k64000Hz = 2] = "k64000Hz", r[r.k48000Hz = 3] = "k48000Hz", r[r.k44100Hz = 4] = "k44100Hz", r[r.k32000Hz = 5] = "k32000Hz", r[r.k24000Hz = 6] = "k24000Hz", r[r.k22050Hz = 7] = "k22050Hz", r[r.k16000Hz = 8] = "k16000Hz", r[r.k12000Hz = 9] = "k12000Hz", r[r.k11025Hz = 10] = "k11025Hz", r[r.k8000Hz = 11] = "k8000Hz", r[r.k7350Hz = 12] = "k7350Hz";
1334
1334
  }(d || (d = {}));
1335
1335
  var me, Se, De = [96e3, 88200, 64e3, 48e3, 44100, 32e3, 24e3, 22050, 16e3, 12e3, 11025, 8e3, 7350], Te = (me = function(r, t) {
1336
1336
  return (me = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(i, e) {
1337
1337
  i.__proto__ = e;
1338
1338
  } || function(i, e) {
1339
- for (var a in e) e.hasOwnProperty(a) && (i[a] = e[a]);
1339
+ for (var n in e) e.hasOwnProperty(n) && (i[n] = e[n]);
1340
1340
  })(r, t);
1341
1341
  }, function(r, t) {
1342
1342
  function i() {
@@ -1361,15 +1361,15 @@ var Tt = { exports: {} };
1361
1361
  }
1362
1362
  }, r.prototype.readNextAACFrame = function() {
1363
1363
  for (var t = this.data_, i = null; i == null && !this.eof_flag_; ) {
1364
- var e = this.current_syncword_offset_, a = (8 & t[e + 1]) >>> 3, s = (6 & t[e + 1]) >>> 1, n = 1 & t[e + 1], o = (192 & t[e + 2]) >>> 6, p = (60 & t[e + 2]) >>> 2, g = (1 & t[e + 2]) << 2 | (192 & t[e + 3]) >>> 6, E = (3 & t[e + 3]) << 11 | t[e + 4] << 3 | (224 & t[e + 5]) >>> 5;
1364
+ var e = this.current_syncword_offset_, n = (8 & t[e + 1]) >>> 3, s = (6 & t[e + 1]) >>> 1, a = 1 & t[e + 1], o = (192 & t[e + 2]) >>> 6, p = (60 & t[e + 2]) >>> 2, g = (1 & t[e + 2]) << 2 | (192 & t[e + 3]) >>> 6, E = (3 & t[e + 3]) << 11 | t[e + 4] << 3 | (224 & t[e + 5]) >>> 5;
1365
1365
  if (t[e + 6], e + E > this.data_.byteLength) {
1366
1366
  this.eof_flag_ = !0, this.has_last_incomplete_data = !0;
1367
1367
  break;
1368
1368
  }
1369
- var A = n === 1 ? 7 : 9, S = E - A;
1369
+ var A = a === 1 ? 7 : 9, S = E - A;
1370
1370
  e += A;
1371
1371
  var w = this.findNextSyncwordOffset(e + S);
1372
- if (this.current_syncword_offset_ = w, (a === 0 || a === 1) && s === 0) {
1372
+ if (this.current_syncword_offset_ = w, (n === 0 || n === 1) && s === 0) {
1373
1373
  var I = t.subarray(e, e + S);
1374
1374
  (i = new M()).audio_object_type = o + 1, i.sampling_freq_index = p, i.sampling_frequency = De[p], i.channel_config = g, i.data = I;
1375
1375
  }
@@ -1391,74 +1391,72 @@ var Tt = { exports: {} };
1391
1391
  i++;
1392
1392
  }
1393
1393
  }, r.prototype.getLATMValue = function(t) {
1394
- for (var i = t.readBits(2), e = 0, a = 0; a <= i; a++) e <<= 8, e |= t.readByte();
1394
+ for (var i = t.readBits(2), e = 0, n = 0; n <= i; n++) e <<= 8, e |= t.readByte();
1395
1395
  return e;
1396
1396
  }, r.prototype.readNextAACFrame = function(t) {
1397
1397
  for (var i = this.data_, e = null; e == null && !this.eof_flag_; ) {
1398
- var a = this.current_syncword_offset_, s = (31 & i[a + 1]) << 8 | i[a + 2];
1399
- if (a + 3 + s >= this.data_.byteLength) {
1398
+ var n = this.current_syncword_offset_, s = (31 & i[n + 1]) << 8 | i[n + 2];
1399
+ if (n + 3 + s >= this.data_.byteLength) {
1400
1400
  this.eof_flag_ = !0, this.has_last_incomplete_data = !0;
1401
1401
  break;
1402
1402
  }
1403
- var n = new ue(i.subarray(a + 3, a + 3 + s)), o = null;
1404
- if (n.readBool()) {
1403
+ var a = new ue(i.subarray(n + 3, n + 3 + s)), o = null;
1404
+ if (a.readBool()) {
1405
1405
  if (t == null) {
1406
- m.a.w(this.TAG, "StreamMuxConfig Missing"), this.current_syncword_offset_ = this.findNextSyncwordOffset(a + 3 + s), n.destroy();
1406
+ m.a.w(this.TAG, "StreamMuxConfig Missing"), this.current_syncword_offset_ = this.findNextSyncwordOffset(n + 3 + s), a.destroy();
1407
1407
  continue;
1408
1408
  }
1409
1409
  o = t;
1410
1410
  } else {
1411
- var p = n.readBool();
1412
- if (p && n.readBool()) {
1413
- m.a.e(this.TAG, "audioMuxVersionA is Not Supported"), n.destroy();
1411
+ var p = a.readBool();
1412
+ if (p && a.readBool()) {
1413
+ m.a.e(this.TAG, "audioMuxVersionA is Not Supported"), a.destroy();
1414
1414
  break;
1415
1415
  }
1416
- if (p && this.getLATMValue(n), !n.readBool()) {
1417
- m.a.e(this.TAG, "allStreamsSameTimeFraming zero is Not Supported"), n.destroy();
1416
+ if (p && this.getLATMValue(a), !a.readBool()) {
1417
+ m.a.e(this.TAG, "allStreamsSameTimeFraming zero is Not Supported"), a.destroy();
1418
1418
  break;
1419
1419
  }
1420
- if (n.readBits(6) !== 0) {
1421
- m.a.e(this.TAG, "more than 2 numSubFrames Not Supported"), n.destroy();
1420
+ if (a.readBits(6) !== 0) {
1421
+ m.a.e(this.TAG, "more than 2 numSubFrames Not Supported"), a.destroy();
1422
1422
  break;
1423
1423
  }
1424
- if (n.readBits(4) !== 0) {
1425
- m.a.e(this.TAG, "more than 2 numProgram Not Supported"), n.destroy();
1424
+ if (a.readBits(4) !== 0) {
1425
+ m.a.e(this.TAG, "more than 2 numProgram Not Supported"), a.destroy();
1426
1426
  break;
1427
1427
  }
1428
- if (n.readBits(3) !== 0) {
1429
- m.a.e(this.TAG, "more than 2 numLayer Not Supported"), n.destroy();
1428
+ if (a.readBits(3) !== 0) {
1429
+ m.a.e(this.TAG, "more than 2 numLayer Not Supported"), a.destroy();
1430
1430
  break;
1431
1431
  }
1432
- var g = p ? this.getLATMValue(n) : 0, E = n.readBits(5);
1432
+ var g = p ? this.getLATMValue(a) : 0, E = a.readBits(5);
1433
1433
  g -= 5;
1434
- var A = n.readBits(4);
1434
+ var A = a.readBits(4);
1435
1435
  g -= 4;
1436
- var S = n.readBits(4);
1437
- g -= 4, n.readBits(3), (g -= 3) > 0 && n.readBits(g);
1438
- var w = n.readBits(3);
1436
+ var S = a.readBits(4);
1437
+ g -= 4, a.readBits(3), (g -= 3) > 0 && a.readBits(g);
1438
+ var w = a.readBits(3);
1439
1439
  if (w !== 0) {
1440
- m.a.e(this.TAG, "frameLengthType = " + w + ". Only frameLengthType = 0 Supported"), n.destroy();
1440
+ m.a.e(this.TAG, "frameLengthType = " + w + ". Only frameLengthType = 0 Supported"), a.destroy();
1441
1441
  break;
1442
1442
  }
1443
- n.readByte();
1444
- var I = n.readBool();
1445
- if (I) if (p) this.getLATMValue(n);
1446
- else {
1443
+ a.readByte();
1444
+ var I = a.readBool();
1445
+ if (I) if (p) this.getLATMValue(a);
1446
+ else
1447
1447
  for (var z = 0; ; ) {
1448
1448
  z <<= 8;
1449
- var N = n.readBool();
1450
- if (z += n.readByte(), !N) break;
1449
+ var N = a.readBool();
1450
+ if (z += a.readByte(), !N) break;
1451
1451
  }
1452
- console.log(z);
1453
- }
1454
- n.readBool() && n.readByte(), (o = new j()).audio_object_type = E, o.sampling_freq_index = A, o.sampling_frequency = De[o.sampling_freq_index], o.channel_config = S, o.other_data_present = I;
1452
+ a.readBool() && a.readByte(), (o = new j()).audio_object_type = E, o.sampling_freq_index = A, o.sampling_frequency = De[o.sampling_freq_index], o.channel_config = S, o.other_data_present = I;
1455
1453
  }
1456
1454
  for (var J = 0; ; ) {
1457
- var W = n.readByte();
1455
+ var W = a.readByte();
1458
1456
  if (J += W, W !== 255) break;
1459
1457
  }
1460
- for (var q = new Uint8Array(J), de = 0; de < J; de++) q[de] = n.readByte();
1461
- (e = new j()).audio_object_type = o.audio_object_type, e.sampling_freq_index = o.sampling_freq_index, e.sampling_frequency = De[o.sampling_freq_index], e.channel_config = o.channel_config, e.other_data_present = o.other_data_present, e.data = q, this.current_syncword_offset_ = this.findNextSyncwordOffset(a + 3 + s);
1458
+ for (var q = new Uint8Array(J), de = 0; de < J; de++) q[de] = a.readByte();
1459
+ (e = new j()).audio_object_type = o.audio_object_type, e.sampling_freq_index = o.sampling_freq_index, e.sampling_frequency = De[o.sampling_freq_index], e.channel_config = o.channel_config, e.other_data_present = o.other_data_present, e.data = q, this.current_syncword_offset_ = this.findNextSyncwordOffset(n + 3 + s);
1462
1460
  }
1463
1461
  return e;
1464
1462
  }, r.prototype.hasIncompleteData = function() {
@@ -1467,8 +1465,8 @@ var Tt = { exports: {} };
1467
1465
  return this.has_last_incomplete_data ? this.data_.subarray(this.current_syncword_offset_) : null;
1468
1466
  }, r;
1469
1467
  }(), re = function(r) {
1470
- var t = null, i = r.audio_object_type, e = r.audio_object_type, a = r.sampling_freq_index, s = r.channel_config, n = 0, o = navigator.userAgent.toLowerCase();
1471
- o.indexOf("firefox") !== -1 ? a >= 6 ? (e = 5, t = new Array(4), n = a - 3) : (e = 2, t = new Array(2), n = a) : o.indexOf("android") !== -1 ? (e = 2, t = new Array(2), n = a) : (e = 5, n = a, t = new Array(4), a >= 6 ? n = a - 3 : s === 1 && (e = 2, t = new Array(2), n = a)), t[0] = e << 3, t[0] |= (15 & a) >>> 1, t[1] = (15 & a) << 7, t[1] |= (15 & s) << 3, e === 5 && (t[1] |= (15 & n) >>> 1, t[2] = (1 & n) << 7, t[2] |= 8, t[3] = 0), this.config = t, this.sampling_rate = De[a], this.channel_count = s, this.codec_mimetype = "mp4a.40." + e, this.original_codec_mimetype = "mp4a.40." + i;
1468
+ var t = null, i = r.audio_object_type, e = r.audio_object_type, n = r.sampling_freq_index, s = r.channel_config, a = 0, o = navigator.userAgent.toLowerCase();
1469
+ o.indexOf("firefox") !== -1 ? n >= 6 ? (e = 5, t = new Array(4), a = n - 3) : (e = 2, t = new Array(2), a = n) : o.indexOf("android") !== -1 ? (e = 2, t = new Array(2), a = n) : (e = 5, a = n, t = new Array(4), n >= 6 ? a = n - 3 : s === 1 && (e = 2, t = new Array(2), a = n)), t[0] = e << 3, t[0] |= (15 & n) >>> 1, t[1] = (15 & n) << 7, t[1] |= (15 & s) << 3, e === 5 && (t[1] |= (15 & a) >>> 1, t[2] = (1 & a) << 7, t[2] |= 8, t[3] = 0), this.config = t, this.sampling_rate = De[n], this.channel_count = s, this.codec_mimetype = "mp4a.40." + e, this.original_codec_mimetype = "mp4a.40." + i;
1472
1470
  }, ce = function() {
1473
1471
  }, we = function() {
1474
1472
  };
@@ -1494,67 +1492,67 @@ var Tt = { exports: {} };
1494
1492
  if (e.out_of_network_indicator = r.readBool(), e.program_splice_flag = r.readBool(), e.duration_flag = r.readBool(), r.readBits(5), e.program_splice_flag) e.utc_splice_time = r.readBits(32);
1495
1493
  else {
1496
1494
  e.component_count = r.readBits(8), e.components = [];
1497
- for (var a = 0; a < e.component_count; a++) e.components.push(Qe(r));
1495
+ for (var n = 0; n < e.component_count; n++) e.components.push(Qe(r));
1498
1496
  }
1499
1497
  return e.duration_flag && (e.break_duration = Be(r)), e.unique_program_id = r.readBits(16), e.avail_num = r.readBits(8), e.avails_expected = r.readBits(8), e;
1500
1498
  }, tt = function(r, t, i, e) {
1501
1499
  return { descriptor_tag: r, descriptor_length: t, identifier: i, provider_avail_id: e.readBits(32) };
1502
1500
  }, wt = function(r, t, i, e) {
1503
- var a = e.readBits(8), s = e.readBits(3);
1501
+ var n = e.readBits(8), s = e.readBits(3);
1504
1502
  e.readBits(5);
1505
- for (var n = "", o = 0; o < s; o++) n += String.fromCharCode(e.readBits(8));
1506
- return { descriptor_tag: r, descriptor_length: t, identifier: i, preroll: a, dtmf_count: s, DTMF_char: n };
1503
+ for (var a = "", o = 0; o < s; o++) a += String.fromCharCode(e.readBits(8));
1504
+ return { descriptor_tag: r, descriptor_length: t, identifier: i, preroll: n, dtmf_count: s, DTMF_char: a };
1507
1505
  }, kt = function(r) {
1508
1506
  var t = r.readBits(8);
1509
1507
  return r.readBits(7), { component_tag: t, pts_offset: 4 * r.readBits(31) + r.readBits(2) };
1510
1508
  }, Lt = function(r, t, i, e) {
1511
- var a = e.readBits(32), s = e.readBool();
1509
+ var n = e.readBits(32), s = e.readBool();
1512
1510
  e.readBits(7);
1513
- var n = { descriptor_tag: r, descriptor_length: t, identifier: i, segmentation_event_id: a, segmentation_event_cancel_indicator: s };
1514
- if (s) return n;
1515
- if (n.program_segmentation_flag = e.readBool(), n.segmentation_duration_flag = e.readBool(), n.delivery_not_restricted_flag = e.readBool(), n.delivery_not_restricted_flag ? e.readBits(5) : (n.web_delivery_allowed_flag = e.readBool(), n.no_regional_blackout_flag = e.readBool(), n.archive_allowed_flag = e.readBool(), n.device_restrictions = e.readBits(2)), !n.program_segmentation_flag) {
1516
- n.component_count = e.readBits(8), n.components = [];
1517
- for (var o = 0; o < n.component_count; o++) n.components.push(kt(e));
1511
+ var a = { descriptor_tag: r, descriptor_length: t, identifier: i, segmentation_event_id: n, segmentation_event_cancel_indicator: s };
1512
+ if (s) return a;
1513
+ if (a.program_segmentation_flag = e.readBool(), a.segmentation_duration_flag = e.readBool(), a.delivery_not_restricted_flag = e.readBool(), a.delivery_not_restricted_flag ? e.readBits(5) : (a.web_delivery_allowed_flag = e.readBool(), a.no_regional_blackout_flag = e.readBool(), a.archive_allowed_flag = e.readBool(), a.device_restrictions = e.readBits(2)), !a.program_segmentation_flag) {
1514
+ a.component_count = e.readBits(8), a.components = [];
1515
+ for (var o = 0; o < a.component_count; o++) a.components.push(kt(e));
1518
1516
  }
1519
- n.segmentation_duration_flag && (n.segmentation_duration = e.readBits(40)), n.segmentation_upid_type = e.readBits(8), n.segmentation_upid_length = e.readBits(8);
1520
- var p = new Uint8Array(n.segmentation_upid_length);
1521
- for (o = 0; o < n.segmentation_upid_length; o++) p[o] = e.readBits(8);
1522
- return n.segmentation_upid = p.buffer, n.segmentation_type_id = e.readBits(8), n.segment_num = e.readBits(8), n.segments_expected = e.readBits(8), n.segmentation_type_id !== 52 && n.segmentation_type_id !== 54 && n.segmentation_type_id !== 56 && n.segmentation_type_id !== 58 || (n.sub_segment_num = e.readBits(8), n.sub_segments_expected = e.readBits(8)), n;
1517
+ a.segmentation_duration_flag && (a.segmentation_duration = e.readBits(40)), a.segmentation_upid_type = e.readBits(8), a.segmentation_upid_length = e.readBits(8);
1518
+ var p = new Uint8Array(a.segmentation_upid_length);
1519
+ for (o = 0; o < a.segmentation_upid_length; o++) p[o] = e.readBits(8);
1520
+ return a.segmentation_upid = p.buffer, a.segmentation_type_id = e.readBits(8), a.segment_num = e.readBits(8), a.segments_expected = e.readBits(8), a.segmentation_type_id !== 52 && a.segmentation_type_id !== 54 && a.segmentation_type_id !== 56 && a.segmentation_type_id !== 58 || (a.sub_segment_num = e.readBits(8), a.sub_segments_expected = e.readBits(8)), a;
1523
1521
  }, Dt = function(r, t, i, e) {
1524
1522
  return { descriptor_tag: r, descriptor_length: t, identifier: i, TAI_seconds: e.readBits(48), TAI_ns: e.readBits(32), UTC_offset: e.readBits(16) };
1525
1523
  }, Ct = function(r) {
1526
1524
  return { component_tag: r.readBits(8), ISO_code: String.fromCharCode(r.readBits(8), r.readBits(8), r.readBits(8)), Bit_Stream_Mode: r.readBits(3), Num_Channels: r.readBits(4), Full_Srvc_Audio: r.readBool() };
1527
1525
  }, Bt = function(r, t, i, e) {
1528
- for (var a = e.readBits(4), s = [], n = 0; n < a; n++) s.push(Ct(e));
1529
- return { descriptor_tag: r, descriptor_length: t, identifier: i, audio_count: a, components: s };
1526
+ for (var n = e.readBits(4), s = [], a = 0; a < n; a++) s.push(Ct(e));
1527
+ return { descriptor_tag: r, descriptor_length: t, identifier: i, audio_count: n, components: s };
1530
1528
  }, It = function(r) {
1531
- var t = new ue(r), i = t.readBits(8), e = t.readBool(), a = t.readBool();
1529
+ var t = new ue(r), i = t.readBits(8), e = t.readBool(), n = t.readBool();
1532
1530
  t.readBits(2);
1533
- var s = t.readBits(12), n = t.readBits(8), o = t.readBool(), p = t.readBits(6), g = 4 * t.readBits(31) + t.readBits(2), E = t.readBits(8), A = t.readBits(12), S = t.readBits(12), w = t.readBits(8), I = null;
1534
- w === Se.kSpliceNull ? I = {} : w === Se.kSpliceSchedule ? I = function(ne) {
1535
- for (var be = ne.readBits(8), Ae = [], le = 0; le < be; le++) Ae.push(et(ne));
1531
+ var s = t.readBits(12), a = t.readBits(8), o = t.readBool(), p = t.readBits(6), g = 4 * t.readBits(31) + t.readBits(2), E = t.readBits(8), A = t.readBits(12), S = t.readBits(12), w = t.readBits(8), I = null;
1532
+ w === Se.kSpliceNull ? I = {} : w === Se.kSpliceSchedule ? I = function(ae) {
1533
+ for (var be = ae.readBits(8), Ae = [], le = 0; le < be; le++) Ae.push(et(ae));
1536
1534
  return { splice_count: be, events: Ae };
1537
- }(t) : w === Se.kSpliceInsert ? I = function(ne) {
1538
- var be = ne.readBits(32), Ae = ne.readBool();
1539
- ne.readBits(7);
1535
+ }(t) : w === Se.kSpliceInsert ? I = function(ae) {
1536
+ var be = ae.readBits(32), Ae = ae.readBool();
1537
+ ae.readBits(7);
1540
1538
  var le = { splice_event_id: be, splice_event_cancel_indicator: Ae };
1541
1539
  if (Ae) return le;
1542
- if (le.out_of_network_indicator = ne.readBool(), le.program_splice_flag = ne.readBool(), le.duration_flag = ne.readBool(), le.splice_immediate_flag = ne.readBool(), ne.readBits(4), le.program_splice_flag && !le.splice_immediate_flag && (le.splice_time = Oe(ne)), !le.program_splice_flag) {
1543
- le.component_count = ne.readBits(8), le.components = [];
1544
- for (var ve = 0; ve < le.component_count; ve++) le.components.push($e(le.splice_immediate_flag, ne));
1545
- }
1546
- return le.duration_flag && (le.break_duration = Be(ne)), le.unique_program_id = ne.readBits(16), le.avail_num = ne.readBits(8), le.avails_expected = ne.readBits(8), le;
1547
- }(t) : w === Se.kTimeSignal ? I = function(ne) {
1548
- return { splice_time: Oe(ne) };
1549
- }(t) : w === Se.kBandwidthReservation ? I = {} : w === Se.kPrivateCommand ? I = function(ne, be) {
1550
- for (var Ae = String.fromCharCode(be.readBits(8), be.readBits(8), be.readBits(8), be.readBits(8)), le = new Uint8Array(ne - 4), ve = 0; ve < ne - 4; ve++) le[ve] = be.readBits(8);
1540
+ if (le.out_of_network_indicator = ae.readBool(), le.program_splice_flag = ae.readBool(), le.duration_flag = ae.readBool(), le.splice_immediate_flag = ae.readBool(), ae.readBits(4), le.program_splice_flag && !le.splice_immediate_flag && (le.splice_time = Oe(ae)), !le.program_splice_flag) {
1541
+ le.component_count = ae.readBits(8), le.components = [];
1542
+ for (var ve = 0; ve < le.component_count; ve++) le.components.push($e(le.splice_immediate_flag, ae));
1543
+ }
1544
+ return le.duration_flag && (le.break_duration = Be(ae)), le.unique_program_id = ae.readBits(16), le.avail_num = ae.readBits(8), le.avails_expected = ae.readBits(8), le;
1545
+ }(t) : w === Se.kTimeSignal ? I = function(ae) {
1546
+ return { splice_time: Oe(ae) };
1547
+ }(t) : w === Se.kBandwidthReservation ? I = {} : w === Se.kPrivateCommand ? I = function(ae, be) {
1548
+ for (var Ae = String.fromCharCode(be.readBits(8), be.readBits(8), be.readBits(8), be.readBits(8)), le = new Uint8Array(ae - 4), ve = 0; ve < ae - 4; ve++) le[ve] = be.readBits(8);
1551
1549
  return { identifier: Ae, private_data: le.buffer };
1552
1550
  }(S, t) : t.readBits(8 * S);
1553
1551
  for (var z = [], N = t.readBits(16), J = 0; J < N; ) {
1554
1552
  var W = t.readBits(8), q = t.readBits(8), de = String.fromCharCode(t.readBits(8), t.readBits(8), t.readBits(8), t.readBits(8));
1555
1553
  W === 0 ? z.push(tt(W, q, de, t)) : W === 1 ? z.push(wt(W, q, de, t)) : W === 2 ? z.push(Lt(W, q, de, t)) : W === 3 ? z.push(Dt(W, q, de, t)) : W === 4 ? z.push(Bt(W, q, de, t)) : t.readBits(8 * (q - 4)), J += 2 + q;
1556
1554
  }
1557
- var he = { table_id: i, section_syntax_indicator: e, private_indicator: a, section_length: s, protocol_version: n, encrypted_packet: o, encryption_algorithm: p, pts_adjustment: g, cw_index: E, tier: A, splice_command_length: S, splice_command_type: w, splice_command: I, descriptor_loop_length: N, splice_descriptors: z, E_CRC32: o ? t.readBits(32) : void 0, CRC32: t.readBits(32) };
1555
+ var he = { table_id: i, section_syntax_indicator: e, private_indicator: n, section_length: s, protocol_version: a, encrypted_packet: o, encryption_algorithm: p, pts_adjustment: g, cw_index: E, tier: A, splice_command_length: S, splice_command_type: w, splice_command: I, descriptor_loop_length: N, splice_descriptors: z, E_CRC32: o ? t.readBits(32) : void 0, CRC32: t.readBits(32) };
1558
1556
  if (w === Se.kSpliceInsert) {
1559
1557
  var K = I;
1560
1558
  if (K.splice_event_cancel_indicator) return { splice_command_type: w, detail: he, data: r };
@@ -1584,24 +1582,24 @@ var Tt = { exports: {} };
1584
1582
  return r.prototype.findNextStartCodeOffset = function(t) {
1585
1583
  for (var i = t, e = this.data_; ; ) {
1586
1584
  if (i + 3 >= e.byteLength) return this.eof_flag_ = !0, e.byteLength;
1587
- var a = e[i + 0] << 24 | e[i + 1] << 16 | e[i + 2] << 8 | e[i + 3], s = e[i + 0] << 16 | e[i + 1] << 8 | e[i + 2];
1588
- if (a === 1 || s === 1) return i;
1585
+ var n = e[i + 0] << 24 | e[i + 1] << 16 | e[i + 2] << 8 | e[i + 3], s = e[i + 0] << 16 | e[i + 1] << 8 | e[i + 2];
1586
+ if (n === 1 || s === 1) return i;
1589
1587
  i++;
1590
1588
  }
1591
1589
  }, r.prototype.readNextNaluPayload = function() {
1592
1590
  for (var t = this.data_, i = null; i == null && !this.eof_flag_; ) {
1593
- var e = this.current_startcode_offset_, a = t[e += (t[e] << 24 | t[e + 1] << 16 | t[e + 2] << 8 | t[e + 3]) === 1 ? 4 : 3] >> 1 & 63, s = (128 & t[e]) >>> 7, n = this.findNextStartCodeOffset(e);
1594
- if (this.current_startcode_offset_ = n, s === 0) {
1595
- var o = t.subarray(e, n);
1596
- (i = new Ot()).type = a, i.data = o;
1591
+ var e = this.current_startcode_offset_, n = t[e += (t[e] << 24 | t[e + 1] << 16 | t[e + 2] << 8 | t[e + 3]) === 1 ? 4 : 3] >> 1 & 63, s = (128 & t[e]) >>> 7, a = this.findNextStartCodeOffset(e);
1592
+ if (this.current_startcode_offset_ = a, s === 0) {
1593
+ var o = t.subarray(e, a);
1594
+ (i = new Ot()).type = n, i.data = o;
1597
1595
  }
1598
1596
  }
1599
1597
  return i;
1600
1598
  }, r;
1601
1599
  }(), xt = function() {
1602
- function r(t, i, e, a) {
1603
- var s = 23 + (5 + t.byteLength) + (5 + i.byteLength) + (5 + e.byteLength), n = this.data = new Uint8Array(s);
1604
- n[0] = 1, n[1] = (3 & a.general_profile_space) << 6 | (a.general_tier_flag ? 1 : 0) << 5 | 31 & a.general_profile_idc, n[2] = a.general_profile_compatibility_flags_1, n[3] = a.general_profile_compatibility_flags_2, n[4] = a.general_profile_compatibility_flags_3, n[5] = a.general_profile_compatibility_flags_4, n[6] = a.general_constraint_indicator_flags_1, n[7] = a.general_constraint_indicator_flags_2, n[8] = a.general_constraint_indicator_flags_3, n[9] = a.general_constraint_indicator_flags_4, n[10] = a.general_constraint_indicator_flags_5, n[11] = a.general_constraint_indicator_flags_6, n[12] = a.general_level_idc, n[13] = 240 | (3840 & a.min_spatial_segmentation_idc) >> 8, n[14] = 255 & a.min_spatial_segmentation_idc, n[15] = 252 | 3 & a.parallelismType, n[16] = 252 | 3 & a.chroma_format_idc, n[17] = 248 | 7 & a.bit_depth_luma_minus8, n[18] = 248 | 7 & a.bit_depth_chroma_minus8, n[19] = 0, n[20] = 0, n[21] = (3 & a.constant_frame_rate) << 6 | (7 & a.num_temporal_layers) << 3 | (a.temporal_id_nested ? 1 : 0) << 2 | 3, n[22] = 3, n[23] = 128 | Ee.kSliceVPS, n[24] = 0, n[25] = 1, n[26] = (65280 & t.byteLength) >> 8, n[27] = (255 & t.byteLength) >> 0, n.set(t, 28), n[23 + (5 + t.byteLength) + 0] = 128 | Ee.kSliceSPS, n[23 + (5 + t.byteLength) + 1] = 0, n[23 + (5 + t.byteLength) + 2] = 1, n[23 + (5 + t.byteLength) + 3] = (65280 & i.byteLength) >> 8, n[23 + (5 + t.byteLength) + 4] = (255 & i.byteLength) >> 0, n.set(i, 23 + (5 + t.byteLength) + 5), n[23 + (5 + t.byteLength + 5 + i.byteLength) + 0] = 128 | Ee.kSlicePPS, n[23 + (5 + t.byteLength + 5 + i.byteLength) + 1] = 0, n[23 + (5 + t.byteLength + 5 + i.byteLength) + 2] = 1, n[23 + (5 + t.byteLength + 5 + i.byteLength) + 3] = (65280 & e.byteLength) >> 8, n[23 + (5 + t.byteLength + 5 + i.byteLength) + 4] = (255 & e.byteLength) >> 0, n.set(e, 23 + (5 + t.byteLength + 5 + i.byteLength) + 5);
1600
+ function r(t, i, e, n) {
1601
+ var s = 23 + (5 + t.byteLength) + (5 + i.byteLength) + (5 + e.byteLength), a = this.data = new Uint8Array(s);
1602
+ a[0] = 1, a[1] = (3 & n.general_profile_space) << 6 | (n.general_tier_flag ? 1 : 0) << 5 | 31 & n.general_profile_idc, a[2] = n.general_profile_compatibility_flags_1, a[3] = n.general_profile_compatibility_flags_2, a[4] = n.general_profile_compatibility_flags_3, a[5] = n.general_profile_compatibility_flags_4, a[6] = n.general_constraint_indicator_flags_1, a[7] = n.general_constraint_indicator_flags_2, a[8] = n.general_constraint_indicator_flags_3, a[9] = n.general_constraint_indicator_flags_4, a[10] = n.general_constraint_indicator_flags_5, a[11] = n.general_constraint_indicator_flags_6, a[12] = n.general_level_idc, a[13] = 240 | (3840 & n.min_spatial_segmentation_idc) >> 8, a[14] = 255 & n.min_spatial_segmentation_idc, a[15] = 252 | 3 & n.parallelismType, a[16] = 252 | 3 & n.chroma_format_idc, a[17] = 248 | 7 & n.bit_depth_luma_minus8, a[18] = 248 | 7 & n.bit_depth_chroma_minus8, a[19] = 0, a[20] = 0, a[21] = (3 & n.constant_frame_rate) << 6 | (7 & n.num_temporal_layers) << 3 | (n.temporal_id_nested ? 1 : 0) << 2 | 3, a[22] = 3, a[23] = 128 | Ee.kSliceVPS, a[24] = 0, a[25] = 1, a[26] = (65280 & t.byteLength) >> 8, a[27] = (255 & t.byteLength) >> 0, a.set(t, 28), a[23 + (5 + t.byteLength) + 0] = 128 | Ee.kSliceSPS, a[23 + (5 + t.byteLength) + 1] = 0, a[23 + (5 + t.byteLength) + 2] = 1, a[23 + (5 + t.byteLength) + 3] = (65280 & i.byteLength) >> 8, a[23 + (5 + t.byteLength) + 4] = (255 & i.byteLength) >> 0, a.set(i, 23 + (5 + t.byteLength) + 5), a[23 + (5 + t.byteLength + 5 + i.byteLength) + 0] = 128 | Ee.kSlicePPS, a[23 + (5 + t.byteLength + 5 + i.byteLength) + 1] = 0, a[23 + (5 + t.byteLength + 5 + i.byteLength) + 2] = 1, a[23 + (5 + t.byteLength + 5 + i.byteLength) + 3] = (65280 & e.byteLength) >> 8, a[23 + (5 + t.byteLength + 5 + i.byteLength) + 4] = (255 & e.byteLength) >> 0, a.set(e, 23 + (5 + t.byteLength + 5 + i.byteLength) + 5);
1605
1603
  }
1606
1604
  return r.prototype.getData = function() {
1607
1605
  return this.data;
@@ -1621,7 +1619,7 @@ var Tt = { exports: {} };
1621
1619
  }
1622
1620
  }, r.prototype.readNextAC3Frame = function() {
1623
1621
  for (var t = this.data_, i = null; i == null && !this.eof_flag_; ) {
1624
- var e = this.current_syncword_offset_, a = t[e + 4] >> 6, s = [48e3, 44200, 33e3][a], n = 63 & t[e + 4], o = 2 * Ft[a][n];
1622
+ var e = this.current_syncword_offset_, n = t[e + 4] >> 6, s = [48e3, 44200, 33e3][n], a = 63 & t[e + 4], o = 2 * Ft[n][a];
1625
1623
  if (e + o > this.data_.byteLength) {
1626
1624
  this.eof_flag_ = !0, this.has_last_incomplete_data = !0;
1627
1625
  break;
@@ -1631,7 +1629,7 @@ var Tt = { exports: {} };
1631
1629
  var g = t[e + 5] >> 3, E = 7 & t[e + 5], A = t[e + 6] >> 5, S = 0;
1632
1630
  1 & A && A !== 1 && (S += 2), 4 & A && (S += 2), A === 2 && (S += 2);
1633
1631
  var w = (t[e + 6] << 8 | t[e + 7] << 0) >> 12 - S & 1, I = [2, 1, 2, 3, 3, 4, 4, 5][A] + w;
1634
- (i = new Gt()).sampling_frequency = s, i.channel_count = I, i.channel_mode = A, i.bit_stream_identification = g, i.low_frequency_effects_channel_on = w, i.bit_stream_mode = E, i.frame_size_code = n, i.data = t.subarray(e, e + o);
1632
+ (i = new Gt()).sampling_frequency = s, i.channel_count = I, i.channel_mode = A, i.bit_stream_identification = g, i.low_frequency_effects_channel_on = w, i.bit_stream_mode = E, i.frame_size_code = a, i.data = t.subarray(e, e + o);
1635
1633
  }
1636
1634
  return i;
1637
1635
  }, r.prototype.hasIncompleteData = function() {
@@ -1644,10 +1642,10 @@ var Tt = { exports: {} };
1644
1642
  t = [r.sampling_rate_code << 6 | r.bit_stream_identification << 1 | r.bit_stream_mode >> 2, (3 & r.bit_stream_mode) << 6 | r.channel_mode << 3 | r.low_frequency_effects_channel_on << 2 | r.frame_size_code >> 4, r.frame_size_code << 4 & 224], this.config = t, this.sampling_rate = r.sampling_frequency, this.bit_stream_identification = r.bit_stream_identification, this.bit_stream_mode = r.bit_stream_mode, this.low_frequency_effects_channel_on = r.low_frequency_effects_channel_on, this.channel_count = r.channel_count, this.channel_mode = r.channel_mode, this.codec_mimetype = "ac-3", this.original_codec_mimetype = "ac-3";
1645
1643
  }, zt = /* @__PURE__ */ function() {
1646
1644
  var r = function(t, i) {
1647
- return (r = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, a) {
1648
- e.__proto__ = a;
1649
- } || function(e, a) {
1650
- for (var s in a) a.hasOwnProperty(s) && (e[s] = a[s]);
1645
+ return (r = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, n) {
1646
+ e.__proto__ = n;
1647
+ } || function(e, n) {
1648
+ for (var s in n) n.hasOwnProperty(s) && (e[s] = n[s]);
1651
1649
  })(t, i);
1652
1650
  };
1653
1651
  return function(t, i) {
@@ -1658,89 +1656,89 @@ var Tt = { exports: {} };
1658
1656
  };
1659
1657
  }(), Ve = function() {
1660
1658
  return (Ve = Object.assign || function(r) {
1661
- for (var t, i = 1, e = arguments.length; i < e; i++) for (var a in t = arguments[i]) Object.prototype.hasOwnProperty.call(t, a) && (r[a] = t[a]);
1659
+ for (var t, i = 1, e = arguments.length; i < e; i++) for (var n in t = arguments[i]) Object.prototype.hasOwnProperty.call(t, n) && (r[n] = t[n]);
1662
1660
  return r;
1663
1661
  }).apply(this, arguments);
1664
1662
  }, lt = function(r) {
1665
1663
  function t(i, e) {
1666
- var a = r.call(this) || this;
1667
- return a.TAG = "TSDemuxer", a.first_parse_ = !0, a.media_info_ = new y.a(), a.timescale_ = 90, a.duration_ = 0, a.current_pmt_pid_ = -1, a.program_pmt_map_ = {}, a.pes_slice_queues_ = {}, a.section_slice_queues_ = {}, a.video_metadata_ = { vps: void 0, sps: void 0, pps: void 0, details: void 0 }, a.audio_metadata_ = { codec: void 0, audio_object_type: void 0, sampling_freq_index: void 0, sampling_frequency: void 0, channel_config: void 0 }, a.aac_last_sample_pts_ = void 0, a.aac_last_incomplete_data_ = null, a.has_video_ = !1, a.has_audio_ = !1, a.video_init_segment_dispatched_ = !1, a.audio_init_segment_dispatched_ = !1, a.video_metadata_changed_ = !1, a.audio_metadata_changed_ = !1, a.loas_previous_frame = null, a.video_track_ = { type: "video", id: 1, sequenceNumber: 0, samples: [], length: 0 }, a.audio_track_ = { type: "audio", id: 2, sequenceNumber: 0, samples: [], length: 0 }, a.ts_packet_size_ = i.ts_packet_size, a.sync_offset_ = i.sync_offset, a.config_ = e, a;
1664
+ var n = r.call(this) || this;
1665
+ return n.TAG = "TSDemuxer", n.first_parse_ = !0, n.media_info_ = new y.a(), n.timescale_ = 90, n.duration_ = 0, n.current_pmt_pid_ = -1, n.program_pmt_map_ = {}, n.pes_slice_queues_ = {}, n.section_slice_queues_ = {}, n.video_metadata_ = { vps: void 0, sps: void 0, pps: void 0, details: void 0 }, n.audio_metadata_ = { codec: void 0, audio_object_type: void 0, sampling_freq_index: void 0, sampling_frequency: void 0, channel_config: void 0 }, n.aac_last_sample_pts_ = void 0, n.aac_last_incomplete_data_ = null, n.has_video_ = !1, n.has_audio_ = !1, n.video_init_segment_dispatched_ = !1, n.audio_init_segment_dispatched_ = !1, n.video_metadata_changed_ = !1, n.audio_metadata_changed_ = !1, n.loas_previous_frame = null, n.video_track_ = { type: "video", id: 1, sequenceNumber: 0, samples: [], length: 0 }, n.audio_track_ = { type: "audio", id: 2, sequenceNumber: 0, samples: [], length: 0 }, n.ts_packet_size_ = i.ts_packet_size, n.sync_offset_ = i.sync_offset, n.config_ = e, n;
1668
1666
  }
1669
1667
  return zt(t, r), t.prototype.destroy = function() {
1670
1668
  this.media_info_ = null, this.pes_slice_queues_ = null, this.section_slice_queues_ = null, this.video_metadata_ = null, this.audio_metadata_ = null, this.aac_last_incomplete_data_ = null, this.video_track_ = null, this.audio_track_ = null, r.prototype.destroy.call(this);
1671
1669
  }, t.probe = function(i) {
1672
- var e = new Uint8Array(i), a = -1, s = 188;
1670
+ var e = new Uint8Array(i), n = -1, s = 188;
1673
1671
  if (e.byteLength <= 3 * s) return { needMoreData: !0 };
1674
- for (; a === -1; ) {
1675
- for (var n = Math.min(1e3, e.byteLength - 3 * s), o = 0; o < n; ) {
1672
+ for (; n === -1; ) {
1673
+ for (var a = Math.min(1e3, e.byteLength - 3 * s), o = 0; o < a; ) {
1676
1674
  if (e[o] === 71 && e[o + s] === 71 && e[o + 2 * s] === 71) {
1677
- a = o;
1675
+ n = o;
1678
1676
  break;
1679
1677
  }
1680
1678
  o++;
1681
1679
  }
1682
- if (a === -1) if (s === 188) s = 192;
1680
+ if (n === -1) if (s === 188) s = 192;
1683
1681
  else {
1684
1682
  if (s !== 192) break;
1685
1683
  s = 204;
1686
1684
  }
1687
1685
  }
1688
- return a === -1 ? { match: !1 } : (s === 192 && a >= 4 ? (m.a.v("TSDemuxer", "ts_packet_size = 192, m2ts mode"), a -= 4) : s === 204 && m.a.v("TSDemuxer", "ts_packet_size = 204, RS encoded MPEG2-TS stream"), { match: !0, consumed: 0, ts_packet_size: s, sync_offset: a });
1686
+ return n === -1 ? { match: !1 } : (s === 192 && n >= 4 ? (m.a.v("TSDemuxer", "ts_packet_size = 192, m2ts mode"), n -= 4) : s === 204 && m.a.v("TSDemuxer", "ts_packet_size = 204, RS encoded MPEG2-TS stream"), { match: !0, consumed: 0, ts_packet_size: s, sync_offset: n });
1689
1687
  }, t.prototype.bindDataSource = function(i) {
1690
1688
  return i.onDataArrival = this.parseChunks.bind(this), this;
1691
1689
  }, t.prototype.resetMediaInfo = function() {
1692
1690
  this.media_info_ = new y.a();
1693
1691
  }, t.prototype.parseChunks = function(i, e) {
1694
1692
  if (!(this.onError && this.onMediaInfo && this.onTrackMetadata && this.onDataAvailable)) throw new C.a("onError & onMediaInfo & onTrackMetadata & onDataAvailable callback must be specified");
1695
- var a = 0;
1696
- for (this.first_parse_ && (this.first_parse_ = !1, a = this.sync_offset_); a + this.ts_packet_size_ <= i.byteLength; ) {
1697
- var s = e + a;
1698
- this.ts_packet_size_ === 192 && (a += 4);
1699
- var n = new Uint8Array(i, a, 188), o = n[0];
1693
+ var n = 0;
1694
+ for (this.first_parse_ && (this.first_parse_ = !1, n = this.sync_offset_); n + this.ts_packet_size_ <= i.byteLength; ) {
1695
+ var s = e + n;
1696
+ this.ts_packet_size_ === 192 && (n += 4);
1697
+ var a = new Uint8Array(i, n, 188), o = a[0];
1700
1698
  if (o !== 71) {
1701
1699
  m.a.e(this.TAG, "sync_byte = " + o + ", not 0x47");
1702
1700
  break;
1703
1701
  }
1704
- var p = (64 & n[1]) >>> 6, g = (n[1], (31 & n[1]) << 8 | n[2]), E = (48 & n[3]) >>> 4, A = 15 & n[3], S = {}, w = 4;
1702
+ var p = (64 & a[1]) >>> 6, g = (a[1], (31 & a[1]) << 8 | a[2]), E = (48 & a[3]) >>> 4, A = 15 & a[3], S = {}, w = 4;
1705
1703
  if (E == 2 || E == 3) {
1706
- var I = n[4];
1704
+ var I = a[4];
1707
1705
  if (5 + I === 188) {
1708
- a += 188, this.ts_packet_size_ === 204 && (a += 16);
1706
+ n += 188, this.ts_packet_size_ === 204 && (n += 16);
1709
1707
  continue;
1710
1708
  }
1711
- I > 0 && (S = this.parseAdaptationField(i, a + 4, 1 + I)), w = 5 + I;
1709
+ I > 0 && (S = this.parseAdaptationField(i, n + 4, 1 + I)), w = 5 + I;
1712
1710
  }
1713
1711
  if (E == 1 || E == 3) {
1714
1712
  if (g === 0 || g === this.current_pmt_pid_ || this.pmt_ != null && this.pmt_.pid_stream_type[g] === u.kSCTE35) {
1715
1713
  var z = 188 - w;
1716
- this.handleSectionSlice(i, a + w, z, { pid: g, file_position: s, payload_unit_start_indicator: p, continuity_conunter: A, random_access_indicator: S.random_access_indicator });
1714
+ this.handleSectionSlice(i, n + w, z, { pid: g, file_position: s, payload_unit_start_indicator: p, continuity_conunter: A, random_access_indicator: S.random_access_indicator });
1717
1715
  } else if (this.pmt_ != null && this.pmt_.pid_stream_type[g] != null) {
1718
1716
  z = 188 - w;
1719
1717
  var N = this.pmt_.pid_stream_type[g];
1720
- g !== this.pmt_.common_pids.h264 && g !== this.pmt_.common_pids.h265 && g !== this.pmt_.common_pids.adts_aac && g !== this.pmt_.common_pids.loas_aac && g !== this.pmt_.common_pids.ac3 && g !== this.pmt_.common_pids.opus && g !== this.pmt_.common_pids.mp3 && this.pmt_.pes_private_data_pids[g] !== !0 && this.pmt_.timed_id3_pids[g] !== !0 || this.handlePESSlice(i, a + w, z, { pid: g, stream_type: N, file_position: s, payload_unit_start_indicator: p, continuity_conunter: A, random_access_indicator: S.random_access_indicator });
1718
+ g !== this.pmt_.common_pids.h264 && g !== this.pmt_.common_pids.h265 && g !== this.pmt_.common_pids.adts_aac && g !== this.pmt_.common_pids.loas_aac && g !== this.pmt_.common_pids.ac3 && g !== this.pmt_.common_pids.opus && g !== this.pmt_.common_pids.mp3 && this.pmt_.pes_private_data_pids[g] !== !0 && this.pmt_.timed_id3_pids[g] !== !0 || this.handlePESSlice(i, n + w, z, { pid: g, stream_type: N, file_position: s, payload_unit_start_indicator: p, continuity_conunter: A, random_access_indicator: S.random_access_indicator });
1721
1719
  }
1722
1720
  }
1723
- a += 188, this.ts_packet_size_ === 204 && (a += 16);
1724
- }
1725
- return this.dispatchAudioVideoMediaSegment(), a;
1726
- }, t.prototype.parseAdaptationField = function(i, e, a) {
1727
- var s = new Uint8Array(i, e, a), n = s[0];
1728
- return n > 0 ? n > 183 ? (m.a.w(this.TAG, "Illegal adaptation_field_length: " + n), {}) : { discontinuity_indicator: (128 & s[1]) >>> 7, random_access_indicator: (64 & s[1]) >>> 6, elementary_stream_priority_indicator: (32 & s[1]) >>> 5 } : {};
1729
- }, t.prototype.handleSectionSlice = function(i, e, a, s) {
1730
- var n = new Uint8Array(i, e, a), o = this.section_slice_queues_[s.pid];
1721
+ n += 188, this.ts_packet_size_ === 204 && (n += 16);
1722
+ }
1723
+ return this.dispatchAudioVideoMediaSegment(), n;
1724
+ }, t.prototype.parseAdaptationField = function(i, e, n) {
1725
+ var s = new Uint8Array(i, e, n), a = s[0];
1726
+ return a > 0 ? a > 183 ? (m.a.w(this.TAG, "Illegal adaptation_field_length: " + a), {}) : { discontinuity_indicator: (128 & s[1]) >>> 7, random_access_indicator: (64 & s[1]) >>> 6, elementary_stream_priority_indicator: (32 & s[1]) >>> 5 } : {};
1727
+ }, t.prototype.handleSectionSlice = function(i, e, n, s) {
1728
+ var a = new Uint8Array(i, e, n), o = this.section_slice_queues_[s.pid];
1731
1729
  if (s.payload_unit_start_indicator) {
1732
- var p = n[0];
1730
+ var p = a[0];
1733
1731
  if (o != null && o.total_length !== 0) {
1734
- var g = new Uint8Array(i, e + 1, Math.min(a, p));
1732
+ var g = new Uint8Array(i, e + 1, Math.min(n, p));
1735
1733
  o.slices.push(g), o.total_length += g.byteLength, o.total_length === o.expected_length ? this.emitSectionSlices(o, s) : this.clearSlices(o, s);
1736
1734
  }
1737
- for (var E = 1 + p; E < n.byteLength && n[E + 0] !== 255; ) {
1738
- var A = (15 & n[E + 1]) << 8 | n[E + 2];
1739
- this.section_slice_queues_[s.pid] = new ye(), (o = this.section_slice_queues_[s.pid]).expected_length = A + 3, o.file_position = s.file_position, o.random_access_indicator = s.random_access_indicator, g = new Uint8Array(i, e + E, Math.min(a - E, o.expected_length - o.total_length)), o.slices.push(g), o.total_length += g.byteLength, o.total_length === o.expected_length ? this.emitSectionSlices(o, s) : o.total_length >= o.expected_length && this.clearSlices(o, s), E += g.byteLength;
1735
+ for (var E = 1 + p; E < a.byteLength && a[E + 0] !== 255; ) {
1736
+ var A = (15 & a[E + 1]) << 8 | a[E + 2];
1737
+ this.section_slice_queues_[s.pid] = new ye(), (o = this.section_slice_queues_[s.pid]).expected_length = A + 3, o.file_position = s.file_position, o.random_access_indicator = s.random_access_indicator, g = new Uint8Array(i, e + E, Math.min(n - E, o.expected_length - o.total_length)), o.slices.push(g), o.total_length += g.byteLength, o.total_length === o.expected_length ? this.emitSectionSlices(o, s) : o.total_length >= o.expected_length && this.clearSlices(o, s), E += g.byteLength;
1740
1738
  }
1741
- } else o != null && o.total_length !== 0 && (g = new Uint8Array(i, e, Math.min(a, o.expected_length - o.total_length)), o.slices.push(g), o.total_length += g.byteLength, o.total_length === o.expected_length ? this.emitSectionSlices(o, s) : o.total_length >= o.expected_length && this.clearSlices(o, s));
1742
- }, t.prototype.handlePESSlice = function(i, e, a, s) {
1743
- var n = new Uint8Array(i, e, a), o = n[0] << 16 | n[1] << 8 | n[2], p = (n[3], n[4] << 8 | n[5]);
1739
+ } else o != null && o.total_length !== 0 && (g = new Uint8Array(i, e, Math.min(n, o.expected_length - o.total_length)), o.slices.push(g), o.total_length += g.byteLength, o.total_length === o.expected_length ? this.emitSectionSlices(o, s) : o.total_length >= o.expected_length && this.clearSlices(o, s));
1740
+ }, t.prototype.handlePESSlice = function(i, e, n, s) {
1741
+ var a = new Uint8Array(i, e, n), o = a[0] << 16 | a[1] << 8 | a[2], p = (a[3], a[4] << 8 | a[5]);
1744
1742
  if (s.payload_unit_start_indicator) {
1745
1743
  if (o !== 1) return void m.a.e(this.TAG, "handlePESSlice: packet_start_code_prefix should be 1 but with value " + o);
1746
1744
  var g = this.pes_slice_queues_[s.pid];
@@ -1748,40 +1746,40 @@ var Tt = { exports: {} };
1748
1746
  }
1749
1747
  if (this.pes_slice_queues_[s.pid] != null) {
1750
1748
  var E = this.pes_slice_queues_[s.pid];
1751
- E.slices.push(n), s.payload_unit_start_indicator && (E.expected_length = p === 0 ? 0 : p + 6), E.total_length += n.byteLength, E.expected_length > 0 && E.expected_length === E.total_length ? this.emitPESSlices(E, s) : E.expected_length > 0 && E.expected_length < E.total_length && this.clearSlices(E, s);
1749
+ E.slices.push(a), s.payload_unit_start_indicator && (E.expected_length = p === 0 ? 0 : p + 6), E.total_length += a.byteLength, E.expected_length > 0 && E.expected_length === E.total_length ? this.emitPESSlices(E, s) : E.expected_length > 0 && E.expected_length < E.total_length && this.clearSlices(E, s);
1752
1750
  }
1753
1751
  }, t.prototype.emitSectionSlices = function(i, e) {
1754
- for (var a = new Uint8Array(i.total_length), s = 0, n = 0; s < i.slices.length; s++) {
1752
+ for (var n = new Uint8Array(i.total_length), s = 0, a = 0; s < i.slices.length; s++) {
1755
1753
  var o = i.slices[s];
1756
- a.set(o, n), n += o.byteLength;
1754
+ n.set(o, a), a += o.byteLength;
1757
1755
  }
1758
1756
  i.slices = [], i.expected_length = -1, i.total_length = 0;
1759
1757
  var p = new pe();
1760
- p.pid = e.pid, p.data = a, p.file_position = i.file_position, p.random_access_indicator = i.random_access_indicator, this.parseSection(p);
1758
+ p.pid = e.pid, p.data = n, p.file_position = i.file_position, p.random_access_indicator = i.random_access_indicator, this.parseSection(p);
1761
1759
  }, t.prototype.emitPESSlices = function(i, e) {
1762
- for (var a = new Uint8Array(i.total_length), s = 0, n = 0; s < i.slices.length; s++) {
1760
+ for (var n = new Uint8Array(i.total_length), s = 0, a = 0; s < i.slices.length; s++) {
1763
1761
  var o = i.slices[s];
1764
- a.set(o, n), n += o.byteLength;
1762
+ n.set(o, a), a += o.byteLength;
1765
1763
  }
1766
1764
  i.slices = [], i.expected_length = -1, i.total_length = 0;
1767
1765
  var p = new ee();
1768
- p.pid = e.pid, p.data = a, p.stream_type = e.stream_type, p.file_position = i.file_position, p.random_access_indicator = i.random_access_indicator, this.parsePES(p);
1766
+ p.pid = e.pid, p.data = n, p.stream_type = e.stream_type, p.file_position = i.file_position, p.random_access_indicator = i.random_access_indicator, this.parsePES(p);
1769
1767
  }, t.prototype.clearSlices = function(i, e) {
1770
1768
  i.slices = [], i.expected_length = -1, i.total_length = 0;
1771
1769
  }, t.prototype.parseSection = function(i) {
1772
- var e = i.data, a = i.pid;
1773
- a === 0 ? this.parsePAT(e) : a === this.current_pmt_pid_ ? this.parsePMT(e) : this.pmt_ != null && this.pmt_.scte_35_pids[a] && this.parseSCTE35(e);
1770
+ var e = i.data, n = i.pid;
1771
+ n === 0 ? this.parsePAT(e) : n === this.current_pmt_pid_ ? this.parsePMT(e) : this.pmt_ != null && this.pmt_.scte_35_pids[n] && this.parseSCTE35(e);
1774
1772
  }, t.prototype.parsePES = function(i) {
1775
- var e = i.data, a = e[0] << 16 | e[1] << 8 | e[2], s = e[3], n = e[4] << 8 | e[5];
1776
- if (a === 1)
1773
+ var e = i.data, n = e[0] << 16 | e[1] << 8 | e[2], s = e[3], a = e[4] << 8 | e[5];
1774
+ if (n === 1)
1777
1775
  if (s !== 188 && s !== 190 && s !== 191 && s !== 240 && s !== 241 && s !== 255 && s !== 242 && s !== 248) {
1778
1776
  e[6];
1779
1777
  var o = (192 & e[7]) >>> 6, p = e[8], g = void 0, E = void 0;
1780
1778
  o !== 2 && o !== 3 || (g = 536870912 * (14 & e[9]) + 4194304 * (255 & e[10]) + 16384 * (254 & e[11]) + 128 * (255 & e[12]) + (254 & e[13]) / 2, E = o === 3 ? 536870912 * (14 & e[14]) + 4194304 * (255 & e[15]) + 16384 * (254 & e[16]) + 128 * (255 & e[17]) + (254 & e[18]) / 2 : g);
1781
1779
  var A = 9 + p, S = void 0;
1782
- if (n !== 0) {
1783
- if (n < 3 + p) return void m.a.v(this.TAG, "Malformed PES: PES_packet_length < 3 + PES_header_data_length");
1784
- S = n - 3 - p;
1780
+ if (a !== 0) {
1781
+ if (a < 3 + p) return void m.a.v(this.TAG, "Malformed PES: PES_packet_length < 3 + PES_header_data_length");
1782
+ S = a - 3 - p;
1785
1783
  } else S = e.byteLength - A;
1786
1784
  var w = e.subarray(A, A + S);
1787
1785
  switch (i.stream_type) {
@@ -1810,28 +1808,28 @@ var Tt = { exports: {} };
1810
1808
  case u.kH265:
1811
1809
  this.parseH265Payload(w, g, E, i.file_position, i.random_access_indicator);
1812
1810
  }
1813
- } else (s === 188 || s === 191 || s === 240 || s === 241 || s === 255 || s === 242 || s === 248) && i.stream_type === u.kPESPrivateData && (A = 6, S = void 0, S = n !== 0 ? n : e.byteLength - A, w = e.subarray(A, A + S), this.parsePESPrivateDataPayload(w, void 0, void 0, i.pid, s));
1814
- else m.a.e(this.TAG, "parsePES: packet_start_code_prefix should be 1 but with value " + a);
1811
+ } else (s === 188 || s === 191 || s === 240 || s === 241 || s === 255 || s === 242 || s === 248) && i.stream_type === u.kPESPrivateData && (A = 6, S = void 0, S = a !== 0 ? a : e.byteLength - A, w = e.subarray(A, A + S), this.parsePESPrivateDataPayload(w, void 0, void 0, i.pid, s));
1812
+ else m.a.e(this.TAG, "parsePES: packet_start_code_prefix should be 1 but with value " + n);
1815
1813
  }, t.prototype.parsePAT = function(i) {
1816
1814
  var e = i[0];
1817
1815
  if (e === 0) {
1818
- var a = (15 & i[1]) << 8 | i[2], s = (i[3], i[4], (62 & i[5]) >>> 1), n = 1 & i[5], o = i[6], p = (i[7], null);
1819
- if (n === 1 && o === 0) (p = new P()).version_number = s;
1816
+ var n = (15 & i[1]) << 8 | i[2], s = (i[3], i[4], (62 & i[5]) >>> 1), a = 1 & i[5], o = i[6], p = (i[7], null);
1817
+ if (a === 1 && o === 0) (p = new P()).version_number = s;
1820
1818
  else if ((p = this.pat_) == null) return;
1821
- for (var g = a - 5 - 4, E = -1, A = -1, S = 8; S < 8 + g; S += 4) {
1819
+ for (var g = n - 5 - 4, E = -1, A = -1, S = 8; S < 8 + g; S += 4) {
1822
1820
  var w = i[S] << 8 | i[S + 1], I = (31 & i[S + 2]) << 8 | i[S + 3];
1823
1821
  w === 0 ? p.network_pid = I : (p.program_pmt_pid[w] = I, E === -1 && (E = w), A === -1 && (A = I));
1824
1822
  }
1825
- n === 1 && o === 0 && (this.pat_ == null && m.a.v(this.TAG, "Parsed first PAT: " + JSON.stringify(p)), this.pat_ = p, this.current_program_ = E, this.current_pmt_pid_ = A);
1823
+ a === 1 && o === 0 && (this.pat_ == null && m.a.v(this.TAG, "Parsed first PAT: " + JSON.stringify(p)), this.pat_ = p, this.current_program_ = E, this.current_pmt_pid_ = A);
1826
1824
  } else m.a.e(this.TAG, "parsePAT: table_id " + e + " is not corresponded to PAT!");
1827
1825
  }, t.prototype.parsePMT = function(i) {
1828
1826
  var e = i[0];
1829
1827
  if (e === 2) {
1830
- var a = (15 & i[1]) << 8 | i[2], s = i[3] << 8 | i[4], n = (62 & i[5]) >>> 1, o = 1 & i[5], p = i[6], g = (i[7], null);
1831
- if (o === 1 && p === 0) (g = new F()).program_number = s, g.version_number = n, this.program_pmt_map_[s] = g;
1828
+ var n = (15 & i[1]) << 8 | i[2], s = i[3] << 8 | i[4], a = (62 & i[5]) >>> 1, o = 1 & i[5], p = i[6], g = (i[7], null);
1829
+ if (o === 1 && p === 0) (g = new F()).program_number = s, g.version_number = a, this.program_pmt_map_[s] = g;
1832
1830
  else if ((g = this.program_pmt_map_[s]) == null) return;
1833
1831
  i[8], i[9];
1834
- for (var E = (15 & i[10]) << 8 | i[11], A = 12 + E, S = a - 9 - E - 4, w = A; w < A + S; ) {
1832
+ for (var E = (15 & i[10]) << 8 | i[11], A = 12 + E, S = n - 9 - E - 4, w = A; w < A + S; ) {
1835
1833
  var I = i[w], z = (31 & i[w + 1]) << 8 | i[w + 2], N = (15 & i[w + 3]) << 8 | i[w + 4];
1836
1834
  g.pid_stream_type[z] = I;
1837
1835
  var J = g.common_pids.h264 || g.common_pids.h265, W = g.common_pids.adts_aac || g.common_pids.loas_aac || g.common_pids.ac3 || g.common_pids.opus || g.common_pids.mp3;
@@ -1853,8 +1851,8 @@ var Tt = { exports: {} };
1853
1851
  }
1854
1852
  q += 2 + he;
1855
1853
  }
1856
- var ne = i.subarray(w + 5, w + 5 + N);
1857
- this.dispatchPESPrivateDataDescriptor(z, I, ne);
1854
+ var ae = i.subarray(w + 5, w + 5 + N);
1855
+ this.dispatchPESPrivateDataDescriptor(z, I, ae);
1858
1856
  }
1859
1857
  } else I === u.kID3 ? g.timed_id3_pids[z] = !0 : I === u.kSCTE35 && (g.scte_35_pids[z] = !0);
1860
1858
  else g.common_pids.mp3 = z;
@@ -1870,36 +1868,36 @@ var Tt = { exports: {} };
1870
1868
  }, t.prototype.parseSCTE35 = function(i) {
1871
1869
  var e = It(i);
1872
1870
  if (e.pts != null) {
1873
- var a = Math.floor(e.pts / this.timescale_);
1874
- e.pts = a;
1871
+ var n = Math.floor(e.pts / this.timescale_);
1872
+ e.pts = n;
1875
1873
  } else e.nearest_pts = this.aac_last_sample_pts_;
1876
1874
  this.onSCTE35Metadata && this.onSCTE35Metadata(e);
1877
- }, t.prototype.parseH264Payload = function(i, e, a, s, n) {
1875
+ }, t.prototype.parseH264Payload = function(i, e, n, s, a) {
1878
1876
  for (var o = new X(i), p = null, g = [], E = 0, A = !1; (p = o.readNextNaluPayload()) != null; ) {
1879
1877
  var S = new R(p);
1880
1878
  if (S.type === D.kSliceSPS) {
1881
1879
  var w = se.parseSPS(p.data);
1882
1880
  this.video_init_segment_dispatched_ ? this.detectVideoMetadataChange(S, w) === !0 && (m.a.v(this.TAG, "H264: Critical h264 metadata has been changed, attempt to re-generate InitSegment"), this.video_metadata_changed_ = !0, this.video_metadata_ = { vps: void 0, sps: S, pps: void 0, details: w }) : (this.video_metadata_.sps = S, this.video_metadata_.details = w);
1883
- } else S.type === D.kSlicePPS ? this.video_init_segment_dispatched_ && !this.video_metadata_changed_ || (this.video_metadata_.pps = S, this.video_metadata_.sps && this.video_metadata_.pps && (this.video_metadata_changed_ && this.dispatchVideoMediaSegment(), this.dispatchVideoInitSegment())) : (S.type === D.kSliceIDR || S.type === D.kSliceNonIDR && n === 1) && (A = !0);
1881
+ } else S.type === D.kSlicePPS ? this.video_init_segment_dispatched_ && !this.video_metadata_changed_ || (this.video_metadata_.pps = S, this.video_metadata_.sps && this.video_metadata_.pps && (this.video_metadata_changed_ && this.dispatchVideoMediaSegment(), this.dispatchVideoInitSegment())) : (S.type === D.kSliceIDR || S.type === D.kSliceNonIDR && a === 1) && (A = !0);
1884
1882
  this.video_init_segment_dispatched_ && (g.push(S), E += S.data.byteLength);
1885
1883
  }
1886
- var I = Math.floor(e / this.timescale_), z = Math.floor(a / this.timescale_);
1884
+ var I = Math.floor(e / this.timescale_), z = Math.floor(n / this.timescale_);
1887
1885
  if (g.length) {
1888
1886
  var N = this.video_track_, J = { units: g, length: E, isKeyframe: A, dts: z, pts: I, cts: I - z, file_position: s };
1889
1887
  N.samples.push(J), N.length += E;
1890
1888
  }
1891
- }, t.prototype.parseH265Payload = function(i, e, a, s, n) {
1889
+ }, t.prototype.parseH265Payload = function(i, e, n, s, a) {
1892
1890
  for (var o = new Mt(i), p = null, g = [], E = 0, A = !1; (p = o.readNextNaluPayload()) != null; ) {
1893
1891
  var S = new Pt(p);
1894
1892
  if (S.type === Ee.kSliceVPS) {
1895
1893
  if (!this.video_init_segment_dispatched_) {
1896
- var w = ae.parseVPS(p.data);
1894
+ var w = ne.parseVPS(p.data);
1897
1895
  this.video_metadata_.vps = S, this.video_metadata_.details = Ve(Ve({}, this.video_metadata_.details), w);
1898
1896
  }
1899
- } else S.type === Ee.kSliceSPS ? (w = ae.parseSPS(p.data), this.video_init_segment_dispatched_ ? this.detectVideoMetadataChange(S, w) === !0 && (m.a.v(this.TAG, "H265: Critical h265 metadata has been changed, attempt to re-generate InitSegment"), this.video_metadata_changed_ = !0, this.video_metadata_ = { vps: void 0, sps: S, pps: void 0, details: w }) : (this.video_metadata_.sps = S, this.video_metadata_.details = Ve(Ve({}, this.video_metadata_.details), w))) : S.type === Ee.kSlicePPS ? (!this.video_init_segment_dispatched_ || this.video_metadata_changed_) && (w = ae.parsePPS(p.data), this.video_metadata_.pps = S, this.video_metadata_.details = Ve(Ve({}, this.video_metadata_.details), w), this.video_metadata_.vps && this.video_metadata_.sps && this.video_metadata_.pps && (this.video_metadata_changed_ && this.dispatchVideoMediaSegment(), this.dispatchVideoInitSegment())) : S.type !== Ee.kSliceIDR_W_RADL && S.type !== Ee.kSliceIDR_N_LP && S.type !== Ee.kSliceCRA_NUT || (A = !0);
1897
+ } else S.type === Ee.kSliceSPS ? (w = ne.parseSPS(p.data), this.video_init_segment_dispatched_ ? this.detectVideoMetadataChange(S, w) === !0 && (m.a.v(this.TAG, "H265: Critical h265 metadata has been changed, attempt to re-generate InitSegment"), this.video_metadata_changed_ = !0, this.video_metadata_ = { vps: void 0, sps: S, pps: void 0, details: w }) : (this.video_metadata_.sps = S, this.video_metadata_.details = Ve(Ve({}, this.video_metadata_.details), w))) : S.type === Ee.kSlicePPS ? (!this.video_init_segment_dispatched_ || this.video_metadata_changed_) && (w = ne.parsePPS(p.data), this.video_metadata_.pps = S, this.video_metadata_.details = Ve(Ve({}, this.video_metadata_.details), w), this.video_metadata_.vps && this.video_metadata_.sps && this.video_metadata_.pps && (this.video_metadata_changed_ && this.dispatchVideoMediaSegment(), this.dispatchVideoInitSegment())) : S.type !== Ee.kSliceIDR_W_RADL && S.type !== Ee.kSliceIDR_N_LP && S.type !== Ee.kSliceCRA_NUT || (A = !0);
1900
1898
  this.video_init_segment_dispatched_ && (g.push(S), E += S.data.byteLength);
1901
1899
  }
1902
- var I = Math.floor(e / this.timescale_), z = Math.floor(a / this.timescale_);
1900
+ var I = Math.floor(e / this.timescale_), z = Math.floor(n / this.timescale_);
1903
1901
  if (g.length) {
1904
1902
  var N = this.video_track_, J = { units: g, length: E, isKeyframe: A, dts: z, pts: I, cts: I - z, file_position: s };
1905
1903
  N.samples.push(J), N.length += E;
@@ -1907,8 +1905,8 @@ var Tt = { exports: {} };
1907
1905
  }, t.prototype.detectVideoMetadataChange = function(i, e) {
1908
1906
  if (e.codec_mimetype !== this.video_metadata_.details.codec_mimetype) return m.a.v(this.TAG, "Video: Codec mimeType changed from " + this.video_metadata_.details.codec_mimetype + " to " + e.codec_mimetype), !0;
1909
1907
  if (e.codec_size.width !== this.video_metadata_.details.codec_size.width || e.codec_size.height !== this.video_metadata_.details.codec_size.height) {
1910
- var a = this.video_metadata_.details.codec_size, s = e.codec_size;
1911
- return m.a.v(this.TAG, "Video: Coded Resolution changed from " + a.width + "x" + a.height + " to " + s.width + "x" + s.height), !0;
1908
+ var n = this.video_metadata_.details.codec_size, s = e.codec_size;
1909
+ return m.a.v(this.TAG, "Video: Coded Resolution changed from " + n.width + "x" + n.height + " to " + s.width + "x" + s.height), !0;
1912
1910
  }
1913
1911
  return e.present_size.width !== this.video_metadata_.details.present_size.width && (m.a.v(this.TAG, "Video: Present resolution width changed from " + this.video_metadata_.details.present_size.width + " to " + e.present_size.width), !0);
1914
1912
  }, t.prototype.isInitSegmentDispatched = function() {
@@ -1916,9 +1914,9 @@ var Tt = { exports: {} };
1916
1914
  }, t.prototype.dispatchVideoInitSegment = function() {
1917
1915
  var i = this.video_metadata_.details, e = { type: "video" };
1918
1916
  e.id = this.video_track_.id, e.timescale = 1e3, e.duration = this.duration_, e.codecWidth = i.codec_size.width, e.codecHeight = i.codec_size.height, e.presentWidth = i.present_size.width, e.presentHeight = i.present_size.height, e.profile = i.profile_string, e.level = i.level_string, e.bitDepth = i.bit_depth, e.chromaFormat = i.chroma_format, e.sarRatio = i.sar_ratio, e.frameRate = i.frame_rate;
1919
- var a = e.frameRate.fps_den, s = e.frameRate.fps_num;
1920
- if (e.refSampleDuration = a / s * 1e3, e.codec = i.codec_mimetype, this.video_metadata_.vps) {
1921
- var n = this.video_metadata_.vps.data.subarray(4), o = this.video_metadata_.sps.data.subarray(4), p = this.video_metadata_.pps.data.subarray(4), g = new xt(n, o, p, i);
1917
+ var n = e.frameRate.fps_den, s = e.frameRate.fps_num;
1918
+ if (e.refSampleDuration = n / s * 1e3, e.codec = i.codec_mimetype, this.video_metadata_.vps) {
1919
+ var a = this.video_metadata_.vps.data.subarray(4), o = this.video_metadata_.sps.data.subarray(4), p = this.video_metadata_.pps.data.subarray(4), g = new xt(a, o, p, i);
1922
1920
  e.hvcc = g.getData(), this.video_init_segment_dispatched_ == 0 && m.a.v(this.TAG, "Generated first HEVCDecoderConfigurationRecord for mimeType: " + e.codec);
1923
1921
  } else {
1924
1922
  o = this.video_metadata_.sps.data.subarray(4), p = this.video_metadata_.pps.data.subarray(4);
@@ -1937,20 +1935,20 @@ var Tt = { exports: {} };
1937
1935
  }, t.prototype.parseADTSAACPayload = function(i, e) {
1938
1936
  if (!this.has_video_ || this.video_init_segment_dispatched_) {
1939
1937
  if (this.aac_last_incomplete_data_) {
1940
- var a = new Uint8Array(i.byteLength + this.aac_last_incomplete_data_.byteLength);
1941
- a.set(this.aac_last_incomplete_data_, 0), a.set(i, this.aac_last_incomplete_data_.byteLength), i = a;
1938
+ var n = new Uint8Array(i.byteLength + this.aac_last_incomplete_data_.byteLength);
1939
+ n.set(this.aac_last_incomplete_data_, 0), n.set(i, this.aac_last_incomplete_data_.byteLength), i = n;
1942
1940
  }
1943
- var s, n;
1944
- if (e != null && (n = e / this.timescale_), this.audio_metadata_.codec === "aac") {
1945
- if (e == null && this.aac_last_sample_pts_ != null) s = 1024 / this.audio_metadata_.sampling_frequency * 1e3, n = this.aac_last_sample_pts_ + s;
1941
+ var s, a;
1942
+ if (e != null && (a = e / this.timescale_), this.audio_metadata_.codec === "aac") {
1943
+ if (e == null && this.aac_last_sample_pts_ != null) s = 1024 / this.audio_metadata_.sampling_frequency * 1e3, a = this.aac_last_sample_pts_ + s;
1946
1944
  else if (e == null) return void m.a.w(this.TAG, "AAC: Unknown pts");
1947
1945
  if (this.aac_last_incomplete_data_ && this.aac_last_sample_pts_) {
1948
1946
  s = 1024 / this.audio_metadata_.sampling_frequency * 1e3;
1949
1947
  var o = this.aac_last_sample_pts_ + s;
1950
- Math.abs(o - n) > 1 && (m.a.w(this.TAG, "AAC: Detected pts overlapped, expected: " + o + "ms, PES pts: " + n + "ms"), n = o);
1948
+ Math.abs(o - a) > 1 && (m.a.w(this.TAG, "AAC: Detected pts overlapped, expected: " + o + "ms, PES pts: " + a + "ms"), a = o);
1951
1949
  }
1952
1950
  }
1953
- for (var p, g = new $(i), E = null, A = n; (E = g.readNextAACFrame()) != null; ) {
1951
+ for (var p, g = new $(i), E = null, A = a; (E = g.readNextAACFrame()) != null; ) {
1954
1952
  s = 1024 / E.sampling_frequency * 1e3;
1955
1953
  var S = { codec: "aac", data: E };
1956
1954
  this.audio_init_segment_dispatched_ == 0 ? (this.audio_metadata_ = { codec: "aac", audio_object_type: E.audio_object_type, sampling_freq_index: E.sampling_freq_index, sampling_frequency: E.sampling_frequency, channel_config: E.channel_config }, this.dispatchAudioInitSegment(S)) : this.detectAudioMetadataChange(S) && (this.dispatchAudioMediaSegment(), this.dispatchAudioInitSegment(S)), p = A;
@@ -1960,66 +1958,66 @@ var Tt = { exports: {} };
1960
1958
  g.hasIncompleteData() && (this.aac_last_incomplete_data_ = g.getIncompleteData()), p && (this.aac_last_sample_pts_ = p);
1961
1959
  }
1962
1960
  }, t.prototype.parseLOASAACPayload = function(i, e) {
1963
- var a;
1961
+ var n;
1964
1962
  if (!this.has_video_ || this.video_init_segment_dispatched_) {
1965
1963
  if (this.aac_last_incomplete_data_) {
1966
1964
  var s = new Uint8Array(i.byteLength + this.aac_last_incomplete_data_.byteLength);
1967
1965
  s.set(this.aac_last_incomplete_data_, 0), s.set(i, this.aac_last_incomplete_data_.byteLength), i = s;
1968
1966
  }
1969
- var n, o;
1967
+ var a, o;
1970
1968
  if (e != null && (o = e / this.timescale_), this.audio_metadata_.codec === "aac") {
1971
- if (e == null && this.aac_last_sample_pts_ != null) n = 1024 / this.audio_metadata_.sampling_frequency * 1e3, o = this.aac_last_sample_pts_ + n;
1969
+ if (e == null && this.aac_last_sample_pts_ != null) a = 1024 / this.audio_metadata_.sampling_frequency * 1e3, o = this.aac_last_sample_pts_ + a;
1972
1970
  else if (e == null) return void m.a.w(this.TAG, "AAC: Unknown pts");
1973
1971
  if (this.aac_last_incomplete_data_ && this.aac_last_sample_pts_) {
1974
- n = 1024 / this.audio_metadata_.sampling_frequency * 1e3;
1975
- var p = this.aac_last_sample_pts_ + n;
1972
+ a = 1024 / this.audio_metadata_.sampling_frequency * 1e3;
1973
+ var p = this.aac_last_sample_pts_ + a;
1976
1974
  Math.abs(p - o) > 1 && (m.a.w(this.TAG, "AAC: Detected pts overlapped, expected: " + p + "ms, PES pts: " + o + "ms"), o = p);
1977
1975
  }
1978
1976
  }
1979
- for (var g, E = new ie(i), A = null, S = o; (A = E.readNextAACFrame((a = this.loas_previous_frame) !== null && a !== void 0 ? a : void 0)) != null; ) {
1980
- this.loas_previous_frame = A, n = 1024 / A.sampling_frequency * 1e3;
1977
+ for (var g, E = new ie(i), A = null, S = o; (A = E.readNextAACFrame((n = this.loas_previous_frame) !== null && n !== void 0 ? n : void 0)) != null; ) {
1978
+ this.loas_previous_frame = A, a = 1024 / A.sampling_frequency * 1e3;
1981
1979
  var w = { codec: "aac", data: A };
1982
1980
  this.audio_init_segment_dispatched_ == 0 ? (this.audio_metadata_ = { codec: "aac", audio_object_type: A.audio_object_type, sampling_freq_index: A.sampling_freq_index, sampling_frequency: A.sampling_frequency, channel_config: A.channel_config }, this.dispatchAudioInitSegment(w)) : this.detectAudioMetadataChange(w) && (this.dispatchAudioMediaSegment(), this.dispatchAudioInitSegment(w)), g = S;
1983
1981
  var I = Math.floor(S), z = { unit: A.data, length: A.data.byteLength, pts: I, dts: I };
1984
- this.audio_track_.samples.push(z), this.audio_track_.length += A.data.byteLength, S += n;
1982
+ this.audio_track_.samples.push(z), this.audio_track_.length += A.data.byteLength, S += a;
1985
1983
  }
1986
1984
  E.hasIncompleteData() && (this.aac_last_incomplete_data_ = E.getIncompleteData()), g && (this.aac_last_sample_pts_ = g);
1987
1985
  }
1988
1986
  }, t.prototype.parseAC3Payload = function(i, e) {
1989
1987
  if (!this.has_video_ || this.video_init_segment_dispatched_) {
1990
- var a, s;
1988
+ var n, s;
1991
1989
  if (e != null && (s = e / this.timescale_), this.audio_metadata_.codec === "ac-3") {
1992
- if (e == null && this.aac_last_sample_pts_ != null) a = 1536 / this.audio_metadata_.sampling_frequency * 1e3, s = this.aac_last_sample_pts_ + a;
1990
+ if (e == null && this.aac_last_sample_pts_ != null) n = 1536 / this.audio_metadata_.sampling_frequency * 1e3, s = this.aac_last_sample_pts_ + n;
1993
1991
  else if (e == null) return void m.a.w(this.TAG, "Opus: Unknown pts");
1994
1992
  }
1995
- for (var n, o = new Vt(i), p = null, g = s; (p = o.readNextAC3Frame()) != null; ) {
1996
- a = 1536 / p.sampling_frequency * 1e3;
1993
+ for (var a, o = new Vt(i), p = null, g = s; (p = o.readNextAC3Frame()) != null; ) {
1994
+ n = 1536 / p.sampling_frequency * 1e3;
1997
1995
  var E = { codec: "ac-3", data: p };
1998
- this.audio_init_segment_dispatched_ == 0 ? (this.audio_metadata_ = { codec: "ac-3", sampling_frequency: p.sampling_frequency, bit_stream_identification: p.bit_stream_identification, bit_stream_mode: p.bit_stream_mode, low_frequency_effects_channel_on: p.low_frequency_effects_channel_on, channel_mode: p.channel_mode }, console.log(JSON.stringify(this.audio_metadata_)), this.dispatchAudioInitSegment(E)) : this.detectAudioMetadataChange(E) && (this.dispatchAudioMediaSegment(), this.dispatchAudioInitSegment(E)), n = g;
1996
+ this.audio_init_segment_dispatched_ == 0 ? (this.audio_metadata_ = { codec: "ac-3", sampling_frequency: p.sampling_frequency, bit_stream_identification: p.bit_stream_identification, bit_stream_mode: p.bit_stream_mode, low_frequency_effects_channel_on: p.low_frequency_effects_channel_on, channel_mode: p.channel_mode }, this.dispatchAudioInitSegment(E)) : this.detectAudioMetadataChange(E) && (this.dispatchAudioMediaSegment(), this.dispatchAudioInitSegment(E)), a = g;
1999
1997
  var A = Math.floor(g), S = { unit: p.data, length: p.data.byteLength, pts: A, dts: A };
2000
- this.audio_track_.samples.push(S), this.audio_track_.length += p.data.byteLength, g += a;
1998
+ this.audio_track_.samples.push(S), this.audio_track_.length += p.data.byteLength, g += n;
2001
1999
  }
2002
- n && (this.aac_last_sample_pts_ = n);
2000
+ a && (this.aac_last_sample_pts_ = a);
2003
2001
  }
2004
2002
  }, t.prototype.parseOpusPayload = function(i, e) {
2005
2003
  if (!this.has_video_ || this.video_init_segment_dispatched_) {
2006
- var a, s;
2004
+ var n, s;
2007
2005
  if (e != null && (s = e / this.timescale_), this.audio_metadata_.codec === "opus") {
2008
- if (e == null && this.aac_last_sample_pts_ != null) a = 20, s = this.aac_last_sample_pts_ + a;
2006
+ if (e == null && this.aac_last_sample_pts_ != null) n = 20, s = this.aac_last_sample_pts_ + n;
2009
2007
  else if (e == null) return void m.a.w(this.TAG, "Opus: Unknown pts");
2010
2008
  }
2011
- for (var n, o = s, p = 0; p < i.length; ) {
2012
- a = 20;
2009
+ for (var a, o = s, p = 0; p < i.length; ) {
2010
+ n = 20;
2013
2011
  for (var g = (16 & i[p + 1]) != 0, E = (8 & i[p + 1]) != 0, A = p + 2, S = 0; i[A] === 255; ) S += 255, A += 1;
2014
- S += i[A], A += 1, A += g ? 2 : 0, A += E ? 2 : 0, n = o;
2012
+ S += i[A], A += 1, A += g ? 2 : 0, A += E ? 2 : 0, a = o;
2015
2013
  var w = Math.floor(o), I = i.slice(A, A + S), z = { unit: I, length: I.byteLength, pts: w, dts: w };
2016
- this.audio_track_.samples.push(z), this.audio_track_.length += I.byteLength, o += a, p = A + S;
2014
+ this.audio_track_.samples.push(z), this.audio_track_.length += I.byteLength, o += n, p = A + S;
2017
2015
  }
2018
- n && (this.aac_last_sample_pts_ = n);
2016
+ a && (this.aac_last_sample_pts_ = a);
2019
2017
  }
2020
2018
  }, t.prototype.parseMP3Payload = function(i, e) {
2021
2019
  if (!this.has_video_ || this.video_init_segment_dispatched_) {
2022
- var a = [0, 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, 416, 448, -1], s = [0, 32, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, -1], n = [0, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, -1], o = i[1] >>> 3 & 3, p = (6 & i[1]) >> 1, g = (240 & i[2]) >>> 4, E = (12 & i[2]) >>> 2, A = (i[3] >>> 6 & 3) !== 3 ? 2 : 1, S = 0, w = 34;
2020
+ var n = [0, 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, 416, 448, -1], s = [0, 32, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384, -1], a = [0, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, -1], o = i[1] >>> 3 & 3, p = (6 & i[1]) >> 1, g = (240 & i[2]) >>> 4, E = (12 & i[2]) >>> 2, A = (i[3] >>> 6 & 3) !== 3 ? 2 : 1, S = 0, w = 34;
2023
2021
  switch (o) {
2024
2022
  case 0:
2025
2023
  S = [11025, 12e3, 8e3, 0][E];
@@ -2032,13 +2030,13 @@ var Tt = { exports: {} };
2032
2030
  }
2033
2031
  switch (p) {
2034
2032
  case 1:
2035
- w = 34, g < n.length && n[g];
2033
+ w = 34, g < a.length && a[g];
2036
2034
  break;
2037
2035
  case 2:
2038
2036
  w = 33, g < s.length && s[g];
2039
2037
  break;
2040
2038
  case 3:
2041
- w = 32, g < a.length && a[g];
2039
+ w = 32, g < n.length && n[g];
2042
2040
  }
2043
2041
  var I = new Nt();
2044
2042
  I.object_type = w, I.sample_rate = S, I.channel_count = A, I.data = i;
@@ -2061,60 +2059,60 @@ var Tt = { exports: {} };
2061
2059
  if (e.channel_mode !== this.audio_metadata_.channel_mode) return m.a.v(this.TAG, "AC3: Channel Mode changed from " + this.audio_metadata_.channel_mode + " to " + e.channel_mode), !0;
2062
2060
  if (e.low_frequency_effects_channel_on !== this.audio_metadata_.low_frequency_effects_channel_on) return m.a.v(this.TAG, "AC3: Low Frequency Effects Channel On changed from " + this.audio_metadata_.low_frequency_effects_channel_on + " to " + e.low_frequency_effects_channel_on), !0;
2063
2061
  } else if (i.codec === "opus" && this.audio_metadata_.codec === "opus") {
2064
- if ((a = i.meta).sample_rate !== this.audio_metadata_.sample_rate) return m.a.v(this.TAG, "Opus: SamplingFrequencyIndex changed from " + this.audio_metadata_.sample_rate + " to " + a.sample_rate), !0;
2065
- if (a.channel_count !== this.audio_metadata_.channel_count) return m.a.v(this.TAG, "Opus: Channel count changed from " + this.audio_metadata_.channel_count + " to " + a.channel_count), !0;
2062
+ if ((n = i.meta).sample_rate !== this.audio_metadata_.sample_rate) return m.a.v(this.TAG, "Opus: SamplingFrequencyIndex changed from " + this.audio_metadata_.sample_rate + " to " + n.sample_rate), !0;
2063
+ if (n.channel_count !== this.audio_metadata_.channel_count) return m.a.v(this.TAG, "Opus: Channel count changed from " + this.audio_metadata_.channel_count + " to " + n.channel_count), !0;
2066
2064
  } else if (i.codec === "mp3" && this.audio_metadata_.codec === "mp3") {
2067
- var a;
2068
- if ((a = i.data).object_type !== this.audio_metadata_.object_type) return m.a.v(this.TAG, "MP3: AudioObjectType changed from " + this.audio_metadata_.object_type + " to " + a.object_type), !0;
2069
- if (a.sample_rate !== this.audio_metadata_.sample_rate) return m.a.v(this.TAG, "MP3: SamplingFrequencyIndex changed from " + this.audio_metadata_.sample_rate + " to " + a.sample_rate), !0;
2070
- if (a.channel_count !== this.audio_metadata_.channel_count) return m.a.v(this.TAG, "MP3: Channel count changed from " + this.audio_metadata_.channel_count + " to " + a.channel_count), !0;
2065
+ var n;
2066
+ if ((n = i.data).object_type !== this.audio_metadata_.object_type) return m.a.v(this.TAG, "MP3: AudioObjectType changed from " + this.audio_metadata_.object_type + " to " + n.object_type), !0;
2067
+ if (n.sample_rate !== this.audio_metadata_.sample_rate) return m.a.v(this.TAG, "MP3: SamplingFrequencyIndex changed from " + this.audio_metadata_.sample_rate + " to " + n.sample_rate), !0;
2068
+ if (n.channel_count !== this.audio_metadata_.channel_count) return m.a.v(this.TAG, "MP3: Channel count changed from " + this.audio_metadata_.channel_count + " to " + n.channel_count), !0;
2071
2069
  }
2072
2070
  return !1;
2073
2071
  }, t.prototype.dispatchAudioInitSegment = function(i) {
2074
2072
  var e = { type: "audio" };
2075
2073
  if (e.id = this.audio_track_.id, e.timescale = 1e3, e.duration = this.duration_, this.audio_metadata_.codec === "aac") {
2076
- var a = i.codec === "aac" ? i.data : null, s = new re(a);
2074
+ var n = i.codec === "aac" ? i.data : null, s = new re(n);
2077
2075
  e.audioSampleRate = s.sampling_rate, e.channelCount = s.channel_count, e.codec = s.codec_mimetype, e.originalCodec = s.original_codec_mimetype, e.config = s.config, e.refSampleDuration = 1024 / e.audioSampleRate * e.timescale;
2078
2076
  } else if (this.audio_metadata_.codec === "ac-3") {
2079
- var n = i.codec === "ac-3" ? i.data : null, o = new jt(n);
2077
+ var a = i.codec === "ac-3" ? i.data : null, o = new jt(a);
2080
2078
  e.audioSampleRate = o.sampling_rate, e.channelCount = o.channel_count, e.codec = o.codec_mimetype, e.originalCodec = o.original_codec_mimetype, e.config = o.config, e.refSampleDuration = 1536 / e.audioSampleRate * e.timescale;
2081
2079
  } else this.audio_metadata_.codec === "opus" ? (e.audioSampleRate = this.audio_metadata_.sample_rate, e.channelCount = this.audio_metadata_.channel_count, e.channelConfigCode = this.audio_metadata_.channel_config_code, e.codec = "opus", e.originalCodec = "opus", e.config = void 0, e.refSampleDuration = 20) : this.audio_metadata_.codec === "mp3" && (e.audioSampleRate = this.audio_metadata_.sample_rate, e.channelCount = this.audio_metadata_.channel_count, e.codec = "mp3", e.originalCodec = "mp3", e.config = void 0);
2082
2080
  this.audio_init_segment_dispatched_ == 0 && m.a.v(this.TAG, "Generated first AudioSpecificConfig for mimeType: " + e.codec), this.onTrackMetadata("audio", e), this.audio_init_segment_dispatched_ = !0, this.video_metadata_changed_ = !1;
2083
2081
  var p = this.media_info_;
2084
2082
  p.hasAudio = !0, p.audioCodec = e.originalCodec, p.audioSampleRate = e.audioSampleRate, p.audioChannelCount = e.channelCount, p.hasVideo && p.videoCodec ? p.mimeType = 'video/mp2t; codecs="' + p.videoCodec + "," + p.audioCodec + '"' : p.mimeType = 'video/mp2t; codecs="' + p.audioCodec + '"', p.isComplete() && this.onMediaInfo(p);
2085
- }, t.prototype.dispatchPESPrivateDataDescriptor = function(i, e, a) {
2083
+ }, t.prototype.dispatchPESPrivateDataDescriptor = function(i, e, n) {
2086
2084
  var s = new we();
2087
- s.pid = i, s.stream_type = e, s.descriptor = a, this.onPESPrivateDataDescriptor && this.onPESPrivateDataDescriptor(s);
2088
- }, t.prototype.parsePESPrivateDataPayload = function(i, e, a, s, n) {
2085
+ s.pid = i, s.stream_type = e, s.descriptor = n, this.onPESPrivateDataDescriptor && this.onPESPrivateDataDescriptor(s);
2086
+ }, t.prototype.parsePESPrivateDataPayload = function(i, e, n, s, a) {
2089
2087
  var o = new ce();
2090
- if (o.pid = s, o.stream_id = n, o.len = i.byteLength, o.data = i, e != null) {
2088
+ if (o.pid = s, o.stream_id = a, o.len = i.byteLength, o.data = i, e != null) {
2091
2089
  var p = Math.floor(e / this.timescale_);
2092
2090
  o.pts = p;
2093
2091
  } else o.nearest_pts = this.aac_last_sample_pts_;
2094
- if (a != null) {
2095
- var g = Math.floor(a / this.timescale_);
2092
+ if (n != null) {
2093
+ var g = Math.floor(n / this.timescale_);
2096
2094
  o.dts = g;
2097
2095
  }
2098
2096
  this.onPESPrivateData && this.onPESPrivateData(o);
2099
- }, t.prototype.parseTimedID3MetadataPayload = function(i, e, a, s, n) {
2097
+ }, t.prototype.parseTimedID3MetadataPayload = function(i, e, n, s, a) {
2100
2098
  var o = new ce();
2101
- if (o.pid = s, o.stream_id = n, o.len = i.byteLength, o.data = i, e != null) {
2099
+ if (o.pid = s, o.stream_id = a, o.len = i.byteLength, o.data = i, e != null) {
2102
2100
  var p = Math.floor(e / this.timescale_);
2103
2101
  o.pts = p;
2104
2102
  }
2105
- if (a != null) {
2106
- var g = Math.floor(a / this.timescale_);
2103
+ if (n != null) {
2104
+ var g = Math.floor(n / this.timescale_);
2107
2105
  o.dts = g;
2108
2106
  }
2109
2107
  this.onTimedID3Metadata && this.onTimedID3Metadata(o);
2110
- }, t.prototype.parseSMPTE2038MetadataPayload = function(i, e, a, s, n) {
2108
+ }, t.prototype.parseSMPTE2038MetadataPayload = function(i, e, n, s, a) {
2111
2109
  var o = new Ut();
2112
- if (o.pid = s, o.stream_id = n, o.len = i.byteLength, o.data = i, e != null) {
2110
+ if (o.pid = s, o.stream_id = a, o.len = i.byteLength, o.data = i, e != null) {
2113
2111
  var p = Math.floor(e / this.timescale_);
2114
2112
  o.pts = p;
2115
2113
  }
2116
- if (o.nearest_pts = this.aac_last_sample_pts_, a != null) {
2117
- var g = Math.floor(a / this.timescale_);
2114
+ if (o.nearest_pts = this.aac_last_sample_pts_, n != null) {
2115
+ var g = Math.floor(n / this.timescale_);
2118
2116
  o.dts = g;
2119
2117
  }
2120
2118
  o.ancillaries = function(E) {
@@ -2144,8 +2142,8 @@ var Tt = { exports: {} };
2144
2142
  }, t;
2145
2143
  }(c), Ht = function() {
2146
2144
  for (var r = 0, t = 0, i = arguments.length; t < i; t++) r += arguments[t].length;
2147
- var e = Array(r), a = 0;
2148
- for (t = 0; t < i; t++) for (var s = arguments[t], n = 0, o = s.length; n < o; n++, a++) e[a] = s[n];
2145
+ var e = Array(r), n = 0;
2146
+ for (t = 0; t < i; t++) for (var s = arguments[t], a = 0, o = s.length; a < o; a++, n++) e[n] = s[a];
2149
2147
  return e;
2150
2148
  }, _t = function() {
2151
2149
  function r() {
@@ -2155,24 +2153,24 @@ var Tt = { exports: {} };
2155
2153
  var i = r.constants = {};
2156
2154
  i.FTYP = new Uint8Array([105, 115, 111, 109, 0, 0, 0, 1, 105, 115, 111, 109, 97, 118, 99, 49]), i.STSD_PREFIX = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1]), i.STTS = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0]), i.STSC = i.STCO = i.STTS, i.STSZ = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]), i.HDLR_VIDEO = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 118, 105, 100, 101, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 86, 105, 100, 101, 111, 72, 97, 110, 100, 108, 101, 114, 0]), i.HDLR_AUDIO = new Uint8Array([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]), i.DREF = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 117, 114, 108, 32, 0, 0, 0, 1]), i.SMHD = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0]), i.VMHD = new Uint8Array([0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0]);
2157
2155
  }, r.box = function(t) {
2158
- for (var i = 8, e = null, a = Array.prototype.slice.call(arguments, 1), s = a.length, n = 0; n < s; n++) i += a[n].byteLength;
2156
+ for (var i = 8, e = null, n = Array.prototype.slice.call(arguments, 1), s = n.length, a = 0; a < s; a++) i += n[a].byteLength;
2159
2157
  (e = new Uint8Array(i))[0] = i >>> 24 & 255, e[1] = i >>> 16 & 255, e[2] = i >>> 8 & 255, e[3] = 255 & i, e.set(t, 4);
2160
2158
  var o = 8;
2161
- for (n = 0; n < s; n++) e.set(a[n], o), o += a[n].byteLength;
2159
+ for (a = 0; a < s; a++) e.set(n[a], o), o += n[a].byteLength;
2162
2160
  return e;
2163
2161
  }, r.generateInitSegment = function(t) {
2164
- var i = r.box(r.types.ftyp, r.constants.FTYP), e = r.moov(t), a = new Uint8Array(i.byteLength + e.byteLength);
2165
- return a.set(i, 0), a.set(e, i.byteLength), a;
2162
+ var i = r.box(r.types.ftyp, r.constants.FTYP), e = r.moov(t), n = new Uint8Array(i.byteLength + e.byteLength);
2163
+ return n.set(i, 0), n.set(e, i.byteLength), n;
2166
2164
  }, r.moov = function(t) {
2167
- var i = r.mvhd(t.timescale, t.duration), e = r.trak(t), a = r.mvex(t);
2168
- return r.box(r.types.moov, i, e, a);
2165
+ var i = r.mvhd(t.timescale, t.duration), e = r.trak(t), n = r.mvex(t);
2166
+ return r.box(r.types.moov, i, e, n);
2169
2167
  }, r.mvhd = function(t, i) {
2170
2168
  return r.box(r.types.mvhd, new Uint8Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, t >>> 24 & 255, t >>> 16 & 255, t >>> 8 & 255, 255 & t, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i, 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, 255, 255, 255, 255]));
2171
2169
  }, r.trak = function(t) {
2172
2170
  return r.box(r.types.trak, r.tkhd(t), r.mdia(t));
2173
2171
  }, r.tkhd = function(t) {
2174
- var i = t.id, e = t.duration, a = t.presentWidth, s = t.presentHeight;
2175
- return r.box(r.types.tkhd, new Uint8Array([0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i, 0, 0, 0, 0, e >>> 24 & 255, e >>> 16 & 255, e >>> 8 & 255, 255 & e, 0, 0, 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, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, a >>> 8 & 255, 255 & a, 0, 0, s >>> 8 & 255, 255 & s, 0, 0]));
2172
+ var i = t.id, e = t.duration, n = t.presentWidth, s = t.presentHeight;
2173
+ return r.box(r.types.tkhd, new Uint8Array([0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i, 0, 0, 0, 0, e >>> 24 & 255, e >>> 16 & 255, e >>> 8 & 255, 255 & e, 0, 0, 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, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, n >>> 8 & 255, 255 & n, 0, 0, s >>> 8 & 255, 255 & s, 0, 0]));
2176
2174
  }, r.mdia = function(t) {
2177
2175
  return r.box(r.types.mdia, r.mdhd(t), r.hdlr(t), r.minf(t));
2178
2176
  }, r.mdhd = function(t) {
@@ -2191,23 +2189,23 @@ var Tt = { exports: {} };
2191
2189
  }, r.stsd = function(t) {
2192
2190
  return t.type === "audio" ? t.codec === "mp3" ? r.box(r.types.stsd, r.constants.STSD_PREFIX, r.mp3(t)) : t.codec === "ac-3" ? r.box(r.types.stsd, r.constants.STSD_PREFIX, r.ac3(t)) : t.codec === "opus" ? r.box(r.types.stsd, r.constants.STSD_PREFIX, r.Opus(t)) : r.box(r.types.stsd, r.constants.STSD_PREFIX, r.mp4a(t)) : t.type === "video" && t.codec.startsWith("hvc1") ? r.box(r.types.stsd, r.constants.STSD_PREFIX, r.hvc1(t)) : r.box(r.types.stsd, r.constants.STSD_PREFIX, r.avc1(t));
2193
2191
  }, r.mp3 = function(t) {
2194
- var i = t.channelCount, e = t.audioSampleRate, a = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2195
- return r.box(r.types[".mp3"], a);
2192
+ var i = t.channelCount, e = t.audioSampleRate, n = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2193
+ return r.box(r.types[".mp3"], n);
2196
2194
  }, r.mp4a = function(t) {
2197
- var i = t.channelCount, e = t.audioSampleRate, a = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2198
- return r.box(r.types.mp4a, a, r.esds(t));
2195
+ var i = t.channelCount, e = t.audioSampleRate, n = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2196
+ return r.box(r.types.mp4a, n, r.esds(t));
2199
2197
  }, r.ac3 = function(t) {
2200
- var i = t.channelCount, e = t.audioSampleRate, a = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2201
- return r.box(r.types["ac-3"], a, r.box(r.types.dac3, new Uint8Array(t.config)));
2198
+ var i = t.channelCount, e = t.audioSampleRate, n = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2199
+ return r.box(r.types["ac-3"], n, r.box(r.types.dac3, new Uint8Array(t.config)));
2202
2200
  }, r.esds = function(t) {
2203
- var i = t.config || [], e = i.length, a = new Uint8Array([0, 0, 0, 0, 3, 23 + e, 0, 1, 0, 4, 15 + e, 64, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5].concat([e]).concat(i).concat([6, 1, 2]));
2204
- return r.box(r.types.esds, a);
2201
+ var i = t.config || [], e = i.length, n = new Uint8Array([0, 0, 0, 0, 3, 23 + e, 0, 1, 0, 4, 15 + e, 64, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5].concat([e]).concat(i).concat([6, 1, 2]));
2202
+ return r.box(r.types.esds, n);
2205
2203
  }, r.Opus = function(t) {
2206
- var i = t.channelCount, e = t.audioSampleRate, a = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2207
- return r.box(r.types.Opus, a, r.dOps(t));
2204
+ var i = t.channelCount, e = t.audioSampleRate, n = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, i, 0, 16, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, 0, 0]);
2205
+ return r.box(r.types.Opus, n, r.dOps(t));
2208
2206
  }, r.dOps = function(t) {
2209
- var i = t.channelCount, e = t.channelConfigCode, a = t.audioSampleRate;
2210
- if (t.config) return r.box(r.types.dOps, n);
2207
+ var i = t.channelCount, e = t.channelConfigCode, n = t.audioSampleRate;
2208
+ if (t.config) return r.box(r.types.dOps, a);
2211
2209
  var s = [];
2212
2210
  switch (e) {
2213
2211
  case 1:
@@ -2259,13 +2257,13 @@ var Tt = { exports: {} };
2259
2257
  case 136:
2260
2258
  s = [1, 1, 8, 0, 1, 2, 3, 4, 5, 6, 7];
2261
2259
  }
2262
- var n = new Uint8Array(Ht([0, i, 0, 0, a >>> 24 & 255, a >>> 17 & 255, a >>> 8 & 255, a >>> 0 & 255, 0, 0], s));
2263
- return r.box(r.types.dOps, n);
2260
+ var a = new Uint8Array(Ht([0, i, 0, 0, n >>> 24 & 255, n >>> 17 & 255, n >>> 8 & 255, n >>> 0 & 255, 0, 0], s));
2261
+ return r.box(r.types.dOps, a);
2264
2262
  }, r.avc1 = function(t) {
2265
- var i = t.avcc, e = t.codecWidth, a = t.codecHeight, s = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, a >>> 8 & 255, 255 & a, 0, 72, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 0, 1, 10, 120, 113, 113, 47, 102, 108, 118, 46, 106, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 255, 255]);
2263
+ var i = t.avcc, e = t.codecWidth, n = t.codecHeight, s = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, n >>> 8 & 255, 255 & n, 0, 72, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 0, 1, 10, 120, 113, 113, 47, 102, 108, 118, 46, 106, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 255, 255]);
2266
2264
  return r.box(r.types.avc1, s, r.box(r.types.avcC, i));
2267
2265
  }, r.hvc1 = function(t) {
2268
- var i = t.hvcc, e = t.codecWidth, a = t.codecHeight, s = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, a >>> 8 & 255, 255 & a, 0, 72, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 0, 1, 10, 120, 113, 113, 47, 102, 108, 118, 46, 106, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 255, 255]);
2266
+ var i = t.hvcc, e = t.codecWidth, n = t.codecHeight, s = new Uint8Array([0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, e >>> 8 & 255, 255 & e, n >>> 8 & 255, 255 & n, 0, 72, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 0, 1, 10, 120, 113, 113, 47, 102, 108, 118, 46, 106, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 255, 255]);
2269
2267
  return r.box(r.types.hvc1, s, r.box(r.types.hvcC, i));
2270
2268
  }, r.mvex = function(t) {
2271
2269
  return r.box(r.types.mvex, r.trex(t));
@@ -2278,22 +2276,22 @@ var Tt = { exports: {} };
2278
2276
  var i = new Uint8Array([0, 0, 0, 0, t >>> 24 & 255, t >>> 16 & 255, t >>> 8 & 255, 255 & t]);
2279
2277
  return r.box(r.types.mfhd, i);
2280
2278
  }, r.traf = function(t, i) {
2281
- var e = t.id, a = r.box(r.types.tfhd, new Uint8Array([0, 0, 0, 0, e >>> 24 & 255, e >>> 16 & 255, e >>> 8 & 255, 255 & e])), s = r.box(r.types.tfdt, new Uint8Array([0, 0, 0, 0, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i])), n = r.sdtp(t), o = r.trun(t, n.byteLength + 16 + 16 + 8 + 16 + 8 + 8);
2282
- return r.box(r.types.traf, a, s, o, n);
2279
+ var e = t.id, n = r.box(r.types.tfhd, new Uint8Array([0, 0, 0, 0, e >>> 24 & 255, e >>> 16 & 255, e >>> 8 & 255, 255 & e])), s = r.box(r.types.tfdt, new Uint8Array([0, 0, 0, 0, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i])), a = r.sdtp(t), o = r.trun(t, a.byteLength + 16 + 16 + 8 + 16 + 8 + 8);
2280
+ return r.box(r.types.traf, n, s, o, a);
2283
2281
  }, r.sdtp = function(t) {
2284
- for (var i = t.samples || [], e = i.length, a = new Uint8Array(4 + e), s = 0; s < e; s++) {
2285
- var n = i[s].flags;
2286
- a[s + 4] = n.isLeading << 6 | n.dependsOn << 4 | n.isDependedOn << 2 | n.hasRedundancy;
2282
+ for (var i = t.samples || [], e = i.length, n = new Uint8Array(4 + e), s = 0; s < e; s++) {
2283
+ var a = i[s].flags;
2284
+ n[s + 4] = a.isLeading << 6 | a.dependsOn << 4 | a.isDependedOn << 2 | a.hasRedundancy;
2287
2285
  }
2288
- return r.box(r.types.sdtp, a);
2286
+ return r.box(r.types.sdtp, n);
2289
2287
  }, r.trun = function(t, i) {
2290
- var e = t.samples || [], a = e.length, s = 12 + 16 * a, n = new Uint8Array(s);
2291
- i += 8 + s, n.set([0, 0, 15, 1, a >>> 24 & 255, a >>> 16 & 255, a >>> 8 & 255, 255 & a, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i], 0);
2292
- for (var o = 0; o < a; o++) {
2288
+ var e = t.samples || [], n = e.length, s = 12 + 16 * n, a = new Uint8Array(s);
2289
+ i += 8 + s, a.set([0, 0, 15, 1, n >>> 24 & 255, n >>> 16 & 255, n >>> 8 & 255, 255 & n, i >>> 24 & 255, i >>> 16 & 255, i >>> 8 & 255, 255 & i], 0);
2290
+ for (var o = 0; o < n; o++) {
2293
2291
  var p = e[o].duration, g = e[o].size, E = e[o].flags, A = e[o].cts;
2294
- n.set([p >>> 24 & 255, p >>> 16 & 255, p >>> 8 & 255, 255 & p, g >>> 24 & 255, g >>> 16 & 255, g >>> 8 & 255, 255 & g, E.isLeading << 2 | E.dependsOn, E.isDependedOn << 6 | E.hasRedundancy << 4 | E.isNonSync, 0, 0, A >>> 24 & 255, A >>> 16 & 255, A >>> 8 & 255, 255 & A], 12 + 16 * o);
2292
+ a.set([p >>> 24 & 255, p >>> 16 & 255, p >>> 8 & 255, 255 & p, g >>> 24 & 255, g >>> 16 & 255, g >>> 8 & 255, 255 & g, E.isLeading << 2 | E.dependsOn, E.isDependedOn << 6 | E.hasRedundancy << 4 | E.isNonSync, 0, 0, A >>> 24 & 255, A >>> 16 & 255, A >>> 8 & 255, 255 & A], 12 + 16 * o);
2295
2293
  }
2296
- return r.box(r.types.trun, n);
2294
+ return r.box(r.types.trun, a);
2297
2295
  }, r.mdat = function(t) {
2298
2296
  return r.box(r.types.mdat, t);
2299
2297
  }, r;
@@ -2341,14 +2339,14 @@ var Tt = { exports: {} };
2341
2339
  if (!this._onMediaSegment) throw new C.a("MP4Remuxer: onMediaSegment callback must be specificed!");
2342
2340
  this._dtsBaseInited || this._calculateDtsBase(t, i), i && this._remuxVideo(i), t && this._remuxAudio(t);
2343
2341
  }, r.prototype._onTrackMetadataReceived = function(t, i) {
2344
- var e = null, a = "mp4", s = i.codec;
2345
- if (t === "audio") this._audioMeta = i, i.codec === "mp3" && this._mp3UseMpegAudio ? (a = "mpeg", s = "", e = new Uint8Array()) : e = ze.generateInitSegment(i);
2342
+ var e = null, n = "mp4", s = i.codec;
2343
+ if (t === "audio") this._audioMeta = i, i.codec === "mp3" && this._mp3UseMpegAudio ? (n = "mpeg", s = "", e = new Uint8Array()) : e = ze.generateInitSegment(i);
2346
2344
  else {
2347
2345
  if (t !== "video") return;
2348
2346
  this._videoMeta = i, e = ze.generateInitSegment(i);
2349
2347
  }
2350
2348
  if (!this._onInitSegment) throw new C.a("MP4Remuxer: onInitSegment callback must be specified!");
2351
- this._onInitSegment(t, { type: t, data: e.buffer, codec: s, container: t + "/" + a, mediaDuration: i.duration });
2349
+ this._onInitSegment(t, { type: t, data: e.buffer, codec: s, container: t + "/" + n, mediaDuration: i.duration });
2352
2350
  }, r.prototype._calculateDtsBase = function(t, i) {
2353
2351
  this._dtsBaseInited || (t && t.samples && t.samples.length && (this._audioDtsBase = t.samples[0].dts), i && i.samples && i.samples.length && (this._videoDtsBase = i.samples[0].dts), this._dtsBase = Math.min(this._audioDtsBase, this._videoDtsBase), this._dtsBaseInited = !0);
2354
2352
  }, r.prototype.getTimestampBase = function() {
@@ -2356,14 +2354,14 @@ var Tt = { exports: {} };
2356
2354
  }, r.prototype.flushStashedSamples = function() {
2357
2355
  var t = this._videoStashedLastSample, i = this._audioStashedLastSample, e = { type: "video", id: 1, sequenceNumber: 0, samples: [], length: 0 };
2358
2356
  t != null && (e.samples.push(t), e.length = t.length);
2359
- var a = { type: "audio", id: 2, sequenceNumber: 0, samples: [], length: 0 };
2360
- i != null && (a.samples.push(i), a.length = i.length), this._videoStashedLastSample = null, this._audioStashedLastSample = null, this._remuxVideo(e, !0), this._remuxAudio(a, !0);
2357
+ var n = { type: "audio", id: 2, sequenceNumber: 0, samples: [], length: 0 };
2358
+ i != null && (n.samples.push(i), n.length = i.length), this._videoStashedLastSample = null, this._audioStashedLastSample = null, this._remuxVideo(e, !0), this._remuxAudio(n, !0);
2361
2359
  }, r.prototype._remuxAudio = function(t, i) {
2362
2360
  if (this._audioMeta != null) {
2363
- var e, a = t, s = a.samples, n = void 0, o = -1, p = this._audioMeta.refSampleDuration, g = this._audioMeta.codec === "mp3" && this._mp3UseMpegAudio, E = this._dtsBaseInited && this._audioNextDts === void 0, A = !1;
2361
+ var e, n = t, s = n.samples, a = void 0, o = -1, p = this._audioMeta.refSampleDuration, g = this._audioMeta.codec === "mp3" && this._mp3UseMpegAudio, E = this._dtsBaseInited && this._audioNextDts === void 0, A = !1;
2364
2362
  if (s && s.length !== 0 && (s.length !== 1 || i)) {
2365
2363
  var S = 0, w = null, I = 0;
2366
- g ? (S = 0, I = a.length) : (S = 8, I = 8 + a.length);
2364
+ g ? (S = 0, I = n.length) : (S = 8, I = 8 + n.length);
2367
2365
  var z = null;
2368
2366
  if (s.length > 1 && (I -= (z = s.pop()).length), this._audioStashedLastSample != null) {
2369
2367
  var N = this._audioStashedLastSample;
@@ -2371,17 +2369,17 @@ var Tt = { exports: {} };
2371
2369
  }
2372
2370
  z != null && (this._audioStashedLastSample = z);
2373
2371
  var J = s[0].dts - this._dtsBase;
2374
- if (this._audioNextDts) n = J - this._audioNextDts;
2375
- else if (this._audioSegmentInfoList.isEmpty()) n = 0, this._fillSilentAfterSeek && !this._videoSegmentInfoList.isEmpty() && this._audioMeta.originalCodec !== "mp3" && (A = !0);
2372
+ if (this._audioNextDts) a = J - this._audioNextDts;
2373
+ else if (this._audioSegmentInfoList.isEmpty()) a = 0, this._fillSilentAfterSeek && !this._videoSegmentInfoList.isEmpty() && this._audioMeta.originalCodec !== "mp3" && (A = !0);
2376
2374
  else {
2377
2375
  var W = this._audioSegmentInfoList.getLastSampleBefore(J);
2378
2376
  if (W != null) {
2379
2377
  var q = J - (W.originalDts + W.duration);
2380
- q <= 3 && (q = 0), n = J - (W.dts + W.duration + q);
2381
- } else n = 0;
2378
+ q <= 3 && (q = 0), a = J - (W.dts + W.duration + q);
2379
+ } else a = 0;
2382
2380
  }
2383
2381
  if (A) {
2384
- var de = J - n, he = this._videoSegmentInfoList.getLastSegmentBefore(J);
2382
+ var de = J - a, he = this._videoSegmentInfoList.getLastSegmentBefore(J);
2385
2383
  if (he != null && he.beginDts < de) {
2386
2384
  if (ke = ht.getSilentFrame(this._audioMeta.originalCodec, this._audioMeta.channelCount)) {
2387
2385
  var K = he.beginDts, Q = de - he.beginDts;
@@ -2390,19 +2388,19 @@ var Tt = { exports: {} };
2390
2388
  } else A = !1;
2391
2389
  }
2392
2390
  for (var _e = [], te = 0; te < s.length; te++) {
2393
- var ne = (N = s[te]).unit, be = N.dts - this._dtsBase, Ae = (K = be, !1), le = null, ve = 0;
2391
+ var ae = (N = s[te]).unit, be = N.dts - this._dtsBase, Ae = (K = be, !1), le = null, ve = 0;
2394
2392
  if (!(be < -1e-3)) {
2395
2393
  if (this._audioMeta.codec !== "mp3") {
2396
2394
  var Re = be;
2397
- if (this._audioNextDts && (Re = this._audioNextDts), (n = be - Re) <= -3 * p) {
2398
- m.a.w(this.TAG, "Dropping 1 audio frame (originalDts: " + be + " ms ,curRefDts: " + Re + " ms) due to dtsCorrection: " + n + " ms overlap.");
2395
+ if (this._audioNextDts && (Re = this._audioNextDts), (a = be - Re) <= -3 * p) {
2396
+ m.a.w(this.TAG, "Dropping 1 audio frame (originalDts: " + be + " ms ,curRefDts: " + Re + " ms) due to dtsCorrection: " + a + " ms overlap.");
2399
2397
  continue;
2400
2398
  }
2401
- if (n >= 3 * p && this._fillAudioTimestampGap && !b.a.safari) {
2399
+ if (a >= 3 * p && this._fillAudioTimestampGap && !b.a.safari) {
2402
2400
  Ae = !0;
2403
- var ke, Ne = Math.floor(n / p);
2401
+ var ke, Ne = Math.floor(a / p);
2404
2402
  m.a.w(this.TAG, `Large audio timestamp gap detected, may cause AV sync to drift. Silent frames will be generated to avoid unsync.
2405
- originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.round(n) + " ms, generate: " + Ne + " frames"), K = Math.floor(Re), ve = Math.floor(Re + p) - K, (ke = ht.getSilentFrame(this._audioMeta.originalCodec, this._audioMeta.channelCount)) == null && (m.a.w(this.TAG, "Unable to generate silent frame for " + this._audioMeta.originalCodec + " with " + this._audioMeta.channelCount + " channels, repeat last frame"), ke = ne), le = [];
2403
+ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.round(a) + " ms, generate: " + Ne + " frames"), K = Math.floor(Re), ve = Math.floor(Re + p) - K, (ke = ht.getSilentFrame(this._audioMeta.originalCodec, this._audioMeta.channelCount)) == null && (m.a.w(this.TAG, "Unable to generate silent frame for " + this._audioMeta.originalCodec + " with " + this._audioMeta.channelCount + " channels, repeat last frame"), ke = ae), le = [];
2406
2404
  for (var Pe = 0; Pe < Ne; Pe++) {
2407
2405
  Re += p;
2408
2406
  var Ge = Math.floor(Re), je = Math.floor(Re + p) - Ge, Fe = { dts: Ge, pts: Ge, cts: 0, unit: ke, size: ke.byteLength, duration: je, originalDts: be, flags: { isLeading: 0, dependsOn: 1, isDependedOn: 0, hasRedundancy: 0 } };
@@ -2411,34 +2409,34 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2411
2409
  this._audioNextDts = Re + p;
2412
2410
  } else K = Math.floor(Re), ve = Math.floor(Re + p) - K, this._audioNextDts = Re + p;
2413
2411
  } else
2414
- K = be - n, te !== s.length - 1 ? ve = s[te + 1].dts - this._dtsBase - n - K : z != null ? ve = z.dts - this._dtsBase - n - K : ve = _e.length >= 1 ? _e[_e.length - 1].duration : Math.floor(p), this._audioNextDts = K + ve;
2412
+ K = be - a, te !== s.length - 1 ? ve = s[te + 1].dts - this._dtsBase - a - K : z != null ? ve = z.dts - this._dtsBase - a - K : ve = _e.length >= 1 ? _e[_e.length - 1].duration : Math.floor(p), this._audioNextDts = K + ve;
2415
2413
  o === -1 && (o = K), _e.push({ dts: K, pts: K, cts: 0, unit: N.unit, size: N.unit.byteLength, duration: ve, originalDts: be, flags: { isLeading: 0, dependsOn: 1, isDependedOn: 0, hasRedundancy: 0 } }), Ae && _e.push.apply(_e, le);
2416
2414
  }
2417
2415
  }
2418
- if (_e.length === 0) return a.samples = [], void (a.length = 0);
2416
+ if (_e.length === 0) return n.samples = [], void (n.length = 0);
2419
2417
  for (g ? w = new Uint8Array(I) : ((w = new Uint8Array(I))[0] = I >>> 24 & 255, w[1] = I >>> 16 & 255, w[2] = I >>> 8 & 255, w[3] = 255 & I, w.set(ze.types.mdat, 4)), te = 0; te < _e.length; te++)
2420
- ne = _e[te].unit, w.set(ne, S), S += ne.byteLength;
2418
+ ae = _e[te].unit, w.set(ae, S), S += ae.byteLength;
2421
2419
  var Ce = _e[_e.length - 1];
2422
2420
  e = Ce.dts + Ce.duration;
2423
2421
  var ge = new Me.b();
2424
- ge.beginDts = o, ge.endDts = e, ge.beginPts = o, ge.endPts = e, ge.originalBeginDts = _e[0].originalDts, ge.originalEndDts = Ce.originalDts + Ce.duration, ge.firstSample = new Me.d(_e[0].dts, _e[0].pts, _e[0].duration, _e[0].originalDts, !1), ge.lastSample = new Me.d(Ce.dts, Ce.pts, Ce.duration, Ce.originalDts, !1), this._isLive || this._audioSegmentInfoList.append(ge), a.samples = _e, a.sequenceNumber++;
2422
+ ge.beginDts = o, ge.endDts = e, ge.beginPts = o, ge.endPts = e, ge.originalBeginDts = _e[0].originalDts, ge.originalEndDts = Ce.originalDts + Ce.duration, ge.firstSample = new Me.d(_e[0].dts, _e[0].pts, _e[0].duration, _e[0].originalDts, !1), ge.lastSample = new Me.d(Ce.dts, Ce.pts, Ce.duration, Ce.originalDts, !1), this._isLive || this._audioSegmentInfoList.append(ge), n.samples = _e, n.sequenceNumber++;
2425
2423
  var xe = null;
2426
- xe = g ? new Uint8Array() : ze.moof(a, o), a.samples = [], a.length = 0;
2424
+ xe = g ? new Uint8Array() : ze.moof(n, o), n.samples = [], n.length = 0;
2427
2425
  var Ue = { type: "audio", data: this._mergeBoxes(xe, w).buffer, sampleCount: _e.length, info: ge };
2428
2426
  g && E && (Ue.timestampOffset = o), this._onMediaSegment("audio", Ue);
2429
2427
  }
2430
2428
  }
2431
2429
  }, r.prototype._remuxVideo = function(t, i) {
2432
2430
  if (this._videoMeta != null) {
2433
- var e, a, s = t, n = s.samples, o = void 0, p = -1, g = -1;
2434
- if (n && n.length !== 0 && (n.length !== 1 || i)) {
2431
+ var e, n, s = t, a = s.samples, o = void 0, p = -1, g = -1;
2432
+ if (a && a.length !== 0 && (a.length !== 1 || i)) {
2435
2433
  var E = 8, A = null, S = 8 + t.length, w = null;
2436
- if (n.length > 1 && (S -= (w = n.pop()).length), this._videoStashedLastSample != null) {
2434
+ if (a.length > 1 && (S -= (w = a.pop()).length), this._videoStashedLastSample != null) {
2437
2435
  var I = this._videoStashedLastSample;
2438
- this._videoStashedLastSample = null, n.unshift(I), S += I.length;
2436
+ this._videoStashedLastSample = null, a.unshift(I), S += I.length;
2439
2437
  }
2440
2438
  w != null && (this._videoStashedLastSample = w);
2441
- var z = n[0].dts - this._dtsBase;
2439
+ var z = a[0].dts - this._dtsBase;
2442
2440
  if (this._videoNextDts) o = z - this._videoNextDts;
2443
2441
  else if (this._videoSegmentInfoList.isEmpty()) o = 0;
2444
2442
  else {
@@ -2448,22 +2446,22 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2448
2446
  J <= 3 && (J = 0), o = z - (N.dts + N.duration + J);
2449
2447
  } else o = 0;
2450
2448
  }
2451
- for (var W = new Me.b(), q = [], de = 0; de < n.length; de++) {
2452
- var he = (I = n[de]).dts - this._dtsBase, K = I.isKeyframe, Q = he - o, _e = I.cts, te = Q + _e;
2449
+ for (var W = new Me.b(), q = [], de = 0; de < a.length; de++) {
2450
+ var he = (I = a[de]).dts - this._dtsBase, K = I.isKeyframe, Q = he - o, _e = I.cts, te = Q + _e;
2453
2451
  p === -1 && (p = Q, g = te);
2454
- var ne = 0;
2455
- if (de !== n.length - 1 ? ne = n[de + 1].dts - this._dtsBase - o - Q : w != null ? ne = w.dts - this._dtsBase - o - Q : ne = q.length >= 1 ? q[q.length - 1].duration : Math.floor(this._videoMeta.refSampleDuration), K) {
2456
- var be = new Me.d(Q, te, ne, I.dts, !0);
2452
+ var ae = 0;
2453
+ if (de !== a.length - 1 ? ae = a[de + 1].dts - this._dtsBase - o - Q : w != null ? ae = w.dts - this._dtsBase - o - Q : ae = q.length >= 1 ? q[q.length - 1].duration : Math.floor(this._videoMeta.refSampleDuration), K) {
2454
+ var be = new Me.d(Q, te, ae, I.dts, !0);
2457
2455
  be.fileposition = I.fileposition, W.appendSyncPoint(be);
2458
2456
  }
2459
- q.push({ dts: Q, pts: te, cts: _e, units: I.units, size: I.length, isKeyframe: K, duration: ne, originalDts: he, flags: { isLeading: 0, dependsOn: K ? 2 : 1, isDependedOn: K ? 1 : 0, hasRedundancy: 0, isNonSync: K ? 0 : 1 } });
2457
+ q.push({ dts: Q, pts: te, cts: _e, units: I.units, size: I.length, isKeyframe: K, duration: ae, originalDts: he, flags: { isLeading: 0, dependsOn: K ? 2 : 1, isDependedOn: K ? 1 : 0, hasRedundancy: 0, isNonSync: K ? 0 : 1 } });
2460
2458
  }
2461
2459
  for ((A = new Uint8Array(S))[0] = S >>> 24 & 255, A[1] = S >>> 16 & 255, A[2] = S >>> 8 & 255, A[3] = 255 & S, A.set(ze.types.mdat, 4), de = 0; de < q.length; de++) for (var Ae = q[de].units; Ae.length; ) {
2462
2460
  var le = Ae.shift().data;
2463
2461
  A.set(le, E), E += le.byteLength;
2464
2462
  }
2465
2463
  var ve = q[q.length - 1];
2466
- if (e = ve.dts + ve.duration, a = ve.pts + ve.duration, this._videoNextDts = e, W.beginDts = p, W.endDts = e, W.beginPts = g, W.endPts = a, W.originalBeginDts = q[0].originalDts, W.originalEndDts = ve.originalDts + ve.duration, W.firstSample = new Me.d(q[0].dts, q[0].pts, q[0].duration, q[0].originalDts, q[0].isKeyframe), W.lastSample = new Me.d(ve.dts, ve.pts, ve.duration, ve.originalDts, ve.isKeyframe), this._isLive || this._videoSegmentInfoList.append(W), s.samples = q, s.sequenceNumber++, this._forceFirstIDR) {
2464
+ if (e = ve.dts + ve.duration, n = ve.pts + ve.duration, this._videoNextDts = e, W.beginDts = p, W.endDts = e, W.beginPts = g, W.endPts = n, W.originalBeginDts = q[0].originalDts, W.originalEndDts = ve.originalDts + ve.duration, W.firstSample = new Me.d(q[0].dts, q[0].pts, q[0].duration, q[0].originalDts, q[0].isKeyframe), W.lastSample = new Me.d(ve.dts, ve.pts, ve.duration, ve.originalDts, ve.isKeyframe), this._isLive || this._videoSegmentInfoList.append(W), s.samples = q, s.sequenceNumber++, this._forceFirstIDR) {
2467
2465
  var Re = q[0].flags;
2468
2466
  Re.dependsOn = 2, Re.isNonSync = 0;
2469
2467
  }
@@ -2479,8 +2477,8 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2479
2477
  function r(t, i) {
2480
2478
  this.TAG = "TransmuxingController", this._emitter = new B.a(), this._config = i, t.segments || (t.segments = [{ duration: t.duration, filesize: t.filesize, url: t.url }]), typeof t.cors != "boolean" && (t.cors = !0), typeof t.withCredentials != "boolean" && (t.withCredentials = !1), this._mediaDataSource = t, this._currentSegmentIndex = 0;
2481
2479
  var e = 0;
2482
- this._mediaDataSource.segments.forEach(function(a) {
2483
- a.timestampBase = e, e += a.duration, a.cors = t.cors, a.withCredentials = t.withCredentials, i.referrerPolicy && (a.referrerPolicy = i.referrerPolicy);
2480
+ this._mediaDataSource.segments.forEach(function(n) {
2481
+ n.timestampBase = e, e += n.duration, n.cors = t.cors, n.withCredentials = t.withCredentials, i.referrerPolicy && (n.referrerPolicy = i.referrerPolicy);
2484
2482
  }), isNaN(e) || this._mediaDataSource.duration === e || (this._mediaDataSource.duration = e), this._mediaInfo = null, this._demuxer = null, this._remuxer = null, this._ioctl = null, this._pendingSeekTime = null, this._pendingResolveSeekPoint = null, this._statisticsReporter = null;
2485
2483
  }
2486
2484
  return r.prototype.destroy = function() {
@@ -2493,8 +2491,8 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2493
2491
  this._loadSegment(0), this._enableStatisticsReporter();
2494
2492
  }, r.prototype._loadSegment = function(t, i) {
2495
2493
  this._currentSegmentIndex = t;
2496
- var e = this._mediaDataSource.segments[t], a = this._ioctl = new qt.a(e, this._config, t);
2497
- a.onError = this._onIOException.bind(this), a.onSeeked = this._onIOSeeked.bind(this), a.onComplete = this._onIOComplete.bind(this), a.onRedirect = this._onIORedirect.bind(this), a.onRecoveredEarlyEof = this._onIORecoveredEarlyEof.bind(this), i ? this._demuxer.bindDataSource(this._ioctl) : a.onDataArrival = this._onInitChunkArrival.bind(this), a.open(i);
2494
+ var e = this._mediaDataSource.segments[t], n = this._ioctl = new qt.a(e, this._config, t);
2495
+ n.onError = this._onIOException.bind(this), n.onSeeked = this._onIOSeeked.bind(this), n.onComplete = this._onIOComplete.bind(this), n.onRedirect = this._onIORedirect.bind(this), n.onRecoveredEarlyEof = this._onIORecoveredEarlyEof.bind(this), i ? this._demuxer.bindDataSource(this._ioctl) : n.onDataArrival = this._onInitChunkArrival.bind(this), n.open(i);
2498
2496
  }, r.prototype.stop = function() {
2499
2497
  this._internalAbort(), this._disableStatisticsReporter();
2500
2498
  }, r.prototype._internalAbort = function() {
@@ -2510,31 +2508,31 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2510
2508
  var e = this._mediaInfo.segments[i];
2511
2509
  if (e == null) this._pendingSeekTime = t;
2512
2510
  else {
2513
- var a = e.getNearestKeyframe(t);
2514
- this._remuxer.seek(a.milliseconds), this._ioctl.seek(a.fileposition), this._pendingResolveSeekPoint = a.milliseconds;
2511
+ var n = e.getNearestKeyframe(t);
2512
+ this._remuxer.seek(n.milliseconds), this._ioctl.seek(n.fileposition), this._pendingResolveSeekPoint = n.milliseconds;
2515
2513
  }
2516
2514
  } else {
2517
2515
  var s = this._mediaInfo.segments[i];
2518
- s == null ? (this._pendingSeekTime = t, this._internalAbort(), this._remuxer.seek(), this._remuxer.insertDiscontinuity(), this._loadSegment(i)) : (a = s.getNearestKeyframe(t), this._internalAbort(), this._remuxer.seek(t), this._remuxer.insertDiscontinuity(), this._demuxer.resetMediaInfo(), this._demuxer.timestampBase = this._mediaDataSource.segments[i].timestampBase, this._loadSegment(i, a.fileposition), this._pendingResolveSeekPoint = a.milliseconds, this._reportSegmentMediaInfo(i));
2516
+ s == null ? (this._pendingSeekTime = t, this._internalAbort(), this._remuxer.seek(), this._remuxer.insertDiscontinuity(), this._loadSegment(i)) : (n = s.getNearestKeyframe(t), this._internalAbort(), this._remuxer.seek(t), this._remuxer.insertDiscontinuity(), this._demuxer.resetMediaInfo(), this._demuxer.timestampBase = this._mediaDataSource.segments[i].timestampBase, this._loadSegment(i, n.fileposition), this._pendingResolveSeekPoint = n.milliseconds, this._reportSegmentMediaInfo(i));
2519
2517
  }
2520
2518
  this._enableStatisticsReporter();
2521
2519
  }
2522
2520
  }, r.prototype._searchSegmentIndexContains = function(t) {
2523
- for (var i = this._mediaDataSource.segments, e = i.length - 1, a = 0; a < i.length; a++) if (t < i[a].timestampBase) {
2524
- e = a - 1;
2521
+ for (var i = this._mediaDataSource.segments, e = i.length - 1, n = 0; n < i.length; n++) if (t < i[n].timestampBase) {
2522
+ e = n - 1;
2525
2523
  break;
2526
2524
  }
2527
2525
  return e;
2528
2526
  }, r.prototype._onInitChunkArrival = function(t, i) {
2529
- var e = this, a = 0;
2530
- if (i > 0) this._demuxer.bindDataSource(this._ioctl), this._demuxer.timestampBase = this._mediaDataSource.segments[this._currentSegmentIndex].timestampBase, a = this._demuxer.parseChunks(t, i);
2527
+ var e = this, n = 0;
2528
+ if (i > 0) this._demuxer.bindDataSource(this._ioctl), this._demuxer.timestampBase = this._mediaDataSource.segments[this._currentSegmentIndex].timestampBase, n = this._demuxer.parseChunks(t, i);
2531
2529
  else {
2532
2530
  var s = null;
2533
- (s = _.probe(t)).match && (this._setupFLVDemuxerRemuxer(s), a = this._demuxer.parseChunks(t, i)), s.match || s.needMoreData || (s = lt.probe(t)).match && (this._setupTSDemuxerRemuxer(s), a = this._demuxer.parseChunks(t, i)), s.match || s.needMoreData || (s = null, m.a.e(this.TAG, "Non MPEG-TS/FLV, Unsupported media type!"), Promise.resolve().then(function() {
2531
+ (s = _.probe(t)).match && (this._setupFLVDemuxerRemuxer(s), n = this._demuxer.parseChunks(t, i)), s.match || s.needMoreData || (s = lt.probe(t)).match && (this._setupTSDemuxerRemuxer(s), n = this._demuxer.parseChunks(t, i)), s.match || s.needMoreData || (s = null, m.a.e(this.TAG, "Non MPEG-TS/FLV, Unsupported media type!"), Promise.resolve().then(function() {
2534
2532
  e._internalAbort();
2535
2533
  }), this._emitter.emit(Le.a.DEMUX_ERROR, Y.a.FORMAT_UNSUPPORTED, "Non MPEG-TS/FLV, Unsupported media type!"));
2536
2534
  }
2537
- return a;
2535
+ return n;
2538
2536
  }, r.prototype._setupFLVDemuxerRemuxer = function(t) {
2539
2537
  this._demuxer = new _(t, this._config), this._remuxer || (this._remuxer = new ct(this._config));
2540
2538
  var i = this._mediaDataSource;
@@ -2547,8 +2545,8 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2547
2545
  this._mediaInfo == null && (this._mediaInfo = Object.assign({}, t), this._mediaInfo.keyframesIndex = null, this._mediaInfo.segments = [], this._mediaInfo.segmentCount = this._mediaDataSource.segments.length, Object.setPrototypeOf(this._mediaInfo, y.a.prototype));
2548
2546
  var e = Object.assign({}, t);
2549
2547
  Object.setPrototypeOf(e, y.a.prototype), this._mediaInfo.segments[this._currentSegmentIndex] = e, this._reportSegmentMediaInfo(this._currentSegmentIndex), this._pendingSeekTime != null && Promise.resolve().then(function() {
2550
- var a = i._pendingSeekTime;
2551
- i._pendingSeekTime = null, i.seek(a);
2548
+ var n = i._pendingSeekTime;
2549
+ i._pendingSeekTime = null, i.seek(n);
2552
2550
  });
2553
2551
  }, r.prototype._onMetaDataArrived = function(t) {
2554
2552
  this._emitter.emit(Le.a.METADATA_ARRIVED, t);
@@ -2586,8 +2584,8 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2586
2584
  this._emitter.emit(Le.a.INIT_SEGMENT, t, i);
2587
2585
  }, r.prototype._onRemuxerMediaSegmentArrival = function(t, i) {
2588
2586
  if (this._pendingSeekTime == null && (this._emitter.emit(Le.a.MEDIA_SEGMENT, t, i), this._pendingResolveSeekPoint != null && t === "video")) {
2589
- var e = i.info.syncPoints, a = this._pendingResolveSeekPoint;
2590
- this._pendingResolveSeekPoint = null, b.a.safari && e.length > 0 && e[0].originalDts === a && (a = e[0].pts), this._emitter.emit(Le.a.RECOMMEND_SEEKPOINT, a);
2587
+ var e = i.info.syncPoints, n = this._pendingResolveSeekPoint;
2588
+ this._pendingResolveSeekPoint = null, b.a.safari && e.length > 0 && e[0].originalDts === n && (n = e[0].pts), this._emitter.emit(Le.a.RECOMMEND_SEEKPOINT, n);
2591
2589
  }
2592
2590
  }, r.prototype._enableStatisticsReporter = function() {
2593
2591
  this._statisticsReporter == null && (this._statisticsReporter = self.setInterval(this._reportStatisticsInfo.bind(this), this._config.statisticsInfoReportInterval));
@@ -2603,7 +2601,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2603
2601
  }();
2604
2602
  Z.a = Kt;
2605
2603
  }, function(fe, Z, O) {
2606
- var x, B = O(0), m = function() {
2604
+ var U, B = O(0), m = function() {
2607
2605
  function T() {
2608
2606
  this._firstCheckpoint = 0, this._lastCheckpoint = 0, this._intervalBytes = 0, this._totalBytes = 0, this._lastSecondBytes = 0, self.performance && self.performance.now ? this._now = self.performance.now.bind(self.performance) : this._now = Date.now;
2609
2607
  }
@@ -2621,8 +2619,8 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2621
2619
  var l = (this._now() - this._firstCheckpoint) / 1e3;
2622
2620
  return this._totalBytes / l / 1024;
2623
2621
  }, enumerable: !1, configurable: !0 }), T;
2624
- }(), b = O(2), y = O(4), f = O(3), k = (x = function(T, l) {
2625
- return (x = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, _) {
2622
+ }(), b = O(2), y = O(4), f = O(3), L = (U = function(T, l) {
2623
+ return (U = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(u, _) {
2626
2624
  u.__proto__ = _;
2627
2625
  } || function(u, _) {
2628
2626
  for (var c in _) _.hasOwnProperty(c) && (u[c] = _[c]);
@@ -2631,13 +2629,13 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2631
2629
  function u() {
2632
2630
  this.constructor = T;
2633
2631
  }
2634
- x(T, l), T.prototype = l === null ? Object.create(l) : (u.prototype = l.prototype, new u());
2635
- }), U = function(T) {
2632
+ U(T, l), T.prototype = l === null ? Object.create(l) : (u.prototype = l.prototype, new u());
2633
+ }), x = function(T) {
2636
2634
  function l(u, _) {
2637
2635
  var c = T.call(this, "fetch-stream-loader") || this;
2638
2636
  return c.TAG = "FetchStreamLoader", c._seekHandler = u, c._config = _, c._needStash = !0, c._requestAbort = !1, c._abortController = null, c._contentLength = null, c._receivedLength = 0, c;
2639
2637
  }
2640
- return k(l, T), l.isSupported = function() {
2638
+ return L(l, T), l.isSupported = function() {
2641
2639
  try {
2642
2640
  var u = y.a.msedge && y.a.version.minor >= 15048, _ = !y.a.msedge || u;
2643
2641
  return self.fetch && self.ReadableStream && _;
@@ -2658,22 +2656,22 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2658
2656
  }
2659
2657
  var ye = { method: "GET", headers: F, mode: "cors", cache: "default", referrerPolicy: "no-referrer-when-downgrade" };
2660
2658
  if (typeof this._config.headers == "object") for (var pe in this._config.headers) F.append(pe, this._config.headers[pe]);
2661
- u.cors === !1 && (ye.mode = "same-origin"), u.withCredentials && (ye.credentials = "include"), u.referrerPolicy && (ye.referrerPolicy = u.referrerPolicy), self.AbortController && (this._abortController = new self.AbortController(), ye.signal = this._abortController.signal), this._status = b.c.kConnecting, self.fetch(D.url, ye).then(function(L) {
2662
- if (c._requestAbort) return c._status = b.c.kIdle, void L.body.cancel();
2663
- if (L.ok && L.status >= 200 && L.status <= 299) {
2664
- if (L.url !== D.url && c._onURLRedirect) {
2665
- var d = c._seekHandler.removeURLParameters(L.url);
2659
+ u.cors === !1 && (ye.mode = "same-origin"), u.withCredentials && (ye.credentials = "include"), u.referrerPolicy && (ye.referrerPolicy = u.referrerPolicy), self.AbortController && (this._abortController = new self.AbortController(), ye.signal = this._abortController.signal), this._status = b.c.kConnecting, self.fetch(D.url, ye).then(function(k) {
2660
+ if (c._requestAbort) return c._status = b.c.kIdle, void k.body.cancel();
2661
+ if (k.ok && k.status >= 200 && k.status <= 299) {
2662
+ if (k.url !== D.url && c._onURLRedirect) {
2663
+ var d = c._seekHandler.removeURLParameters(k.url);
2666
2664
  c._onURLRedirect(d);
2667
2665
  }
2668
- var h = L.headers.get("Content-Length");
2669
- return h != null && (c._contentLength = parseInt(h), c._contentLength !== 0 && c._onContentLengthKnown && c._onContentLengthKnown(c._contentLength)), c._pump.call(c, L.body.getReader());
2666
+ var h = k.headers.get("Content-Length");
2667
+ return h != null && (c._contentLength = parseInt(h), c._contentLength !== 0 && c._onContentLengthKnown && c._onContentLengthKnown(c._contentLength)), c._pump.call(c, k.body.getReader());
2670
2668
  }
2671
- if (c._status = b.c.kError, !c._onError) throw new f.d("FetchStreamLoader: Http code invalid, " + L.status + " " + L.statusText);
2672
- c._onError(b.b.HTTP_STATUS_CODE_INVALID, { code: L.status, msg: L.statusText });
2673
- }).catch(function(L) {
2669
+ if (c._status = b.c.kError, !c._onError) throw new f.d("FetchStreamLoader: Http code invalid, " + k.status + " " + k.statusText);
2670
+ c._onError(b.b.HTTP_STATUS_CODE_INVALID, { code: k.status, msg: k.statusText });
2671
+ }).catch(function(k) {
2674
2672
  if (!c._abortController || !c._abortController.signal.aborted) {
2675
- if (c._status = b.c.kError, !c._onError) throw L;
2676
- c._onError(b.b.EXCEPTION, { code: -1, msg: L.message });
2673
+ if (c._status = b.c.kError, !c._onError) throw k;
2674
+ c._onError(b.b.EXCEPTION, { code: -1, msg: k.message });
2677
2675
  }
2678
2676
  });
2679
2677
  }, l.prototype.abort = function() {
@@ -2960,7 +2958,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
2960
2958
  if (!this._onError) throw new f.d(_.msg);
2961
2959
  this._onError(b.b.EXCEPTION, _);
2962
2960
  }, l;
2963
- }(b.a), ae = function() {
2961
+ }(b.a), ne = function() {
2964
2962
  function T(l) {
2965
2963
  this._zeroStart = l || !1;
2966
2964
  }
@@ -3047,7 +3045,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3047
3045
  return this._loader.type;
3048
3046
  }, enumerable: !1, configurable: !0 }), T.prototype._selectSeekHandler = function() {
3049
3047
  var l = this._config;
3050
- if (l.seekType === "range") this._seekHandler = new ae(this._config.rangeLoadZeroStart);
3048
+ if (l.seekType === "range") this._seekHandler = new ne(this._config.rangeLoadZeroStart);
3051
3049
  else if (l.seekType === "param") {
3052
3050
  var u = l.seekParamStart || "bstart", _ = l.seekParamEnd || "bend";
3053
3051
  this._seekHandler = new v(u, _);
@@ -3059,7 +3057,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3059
3057
  }, T.prototype._selectLoader = function() {
3060
3058
  if (this._config.customLoader != null) this._loaderClass = this._config.customLoader;
3061
3059
  else if (this._isWebSocketURL) this._loaderClass = Y;
3062
- else if (U.isSupported()) this._loaderClass = U;
3060
+ else if (x.isSupported()) this._loaderClass = x;
3063
3061
  else if (V.isSupported()) this._loaderClass = V;
3064
3062
  else {
3065
3063
  if (!ue.isSupported()) throw new f.d("Your browser doesn't support xhr with arraybuffer responseType!");
@@ -3182,7 +3180,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3182
3180
  }();
3183
3181
  Z.a = G;
3184
3182
  }, function(fe, Z, O) {
3185
- var x = function() {
3183
+ var U = function() {
3186
3184
  function B() {
3187
3185
  }
3188
3186
  return B.install = function() {
@@ -3192,82 +3190,82 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3192
3190
  if (m == null) throw new TypeError("Cannot convert undefined or null to object");
3193
3191
  for (var b = Object(m), y = 1; y < arguments.length; y++) {
3194
3192
  var f = arguments[y];
3195
- if (f != null) for (var k in f) f.hasOwnProperty(k) && (b[k] = f[k]);
3193
+ if (f != null) for (var L in f) f.hasOwnProperty(L) && (b[L] = f[L]);
3196
3194
  }
3197
3195
  return b;
3198
3196
  }, typeof self.Promise != "function" && O(15).polyfill();
3199
3197
  }, B;
3200
3198
  }();
3201
- x.install(), Z.a = x;
3199
+ U.install(), Z.a = U;
3202
3200
  }, function(fe, Z, O) {
3203
- function x(y) {
3201
+ function U(y) {
3204
3202
  var f = {};
3205
- function k(C) {
3203
+ function L(C) {
3206
3204
  if (f[C]) return f[C].exports;
3207
3205
  var V = f[C] = { i: C, l: !1, exports: {} };
3208
- return y[C].call(V.exports, V, V.exports, k), V.l = !0, V.exports;
3206
+ return y[C].call(V.exports, V, V.exports, L), V.l = !0, V.exports;
3209
3207
  }
3210
- k.m = y, k.c = f, k.i = function(C) {
3208
+ L.m = y, L.c = f, L.i = function(C) {
3211
3209
  return C;
3212
- }, k.d = function(C, V, H) {
3213
- k.o(C, V) || Object.defineProperty(C, V, { configurable: !1, enumerable: !0, get: H });
3214
- }, k.r = function(C) {
3210
+ }, L.d = function(C, V, H) {
3211
+ L.o(C, V) || Object.defineProperty(C, V, { configurable: !1, enumerable: !0, get: H });
3212
+ }, L.r = function(C) {
3215
3213
  Object.defineProperty(C, "__esModule", { value: !0 });
3216
- }, k.n = function(C) {
3214
+ }, L.n = function(C) {
3217
3215
  var V = C && C.__esModule ? function() {
3218
3216
  return C.default;
3219
3217
  } : function() {
3220
3218
  return C;
3221
3219
  };
3222
- return k.d(V, "a", V), V;
3223
- }, k.o = function(C, V) {
3220
+ return L.d(V, "a", V), V;
3221
+ }, L.o = function(C, V) {
3224
3222
  return Object.prototype.hasOwnProperty.call(C, V);
3225
- }, k.p = "/", k.oe = function(C) {
3226
- throw console.error(C), C;
3223
+ }, L.p = "/", L.oe = function(C) {
3224
+ throw C;
3227
3225
  };
3228
- var U = k(k.s = ENTRY_MODULE);
3229
- return U.default || U;
3226
+ var x = L(L.s = ENTRY_MODULE);
3227
+ return x.default || x;
3230
3228
  }
3231
3229
  function B(y) {
3232
3230
  return (y + "").replace(/[.?*+^$[\]\\(){}|-]/g, "\\$&");
3233
3231
  }
3234
- function m(y, f, k) {
3235
- var U = {};
3236
- U[k] = [];
3232
+ function m(y, f, L) {
3233
+ var x = {};
3234
+ x[L] = [];
3237
3235
  var C = f.toString(), V = C.match(/^function\s?\w*\(\w+,\s*\w+,\s*(\w+)\)/);
3238
- if (!V) return U;
3239
- for (var H, ue = V[1], se = new RegExp("(\\\\n|\\W)" + B(ue) + "\\(\\s*(/\\*.*?\\*/)?\\s*.*?([\\.|\\-|\\+|\\w|/|@]+).*?\\)", "g"); H = se.exec(C); ) H[3] !== "dll-reference" && U[k].push(H[3]);
3240
- for (se = new RegExp("\\(" + B(ue) + '\\("(dll-reference\\s([\\.|\\-|\\+|\\w|/|@]+))"\\)\\)\\(\\s*(/\\*.*?\\*/)?\\s*.*?([\\.|\\-|\\+|\\w|/|@]+).*?\\)', "g"); H = se.exec(C); ) y[H[2]] || (U[k].push(H[1]), y[H[2]] = O(H[1]).m), U[H[2]] = U[H[2]] || [], U[H[2]].push(H[4]);
3241
- for (var Y, ae = Object.keys(U), v = 0; v < ae.length; v++) for (var G = 0; G < U[ae[v]].length; G++) Y = U[ae[v]][G], isNaN(1 * Y) || (U[ae[v]][G] = 1 * U[ae[v]][G]);
3242
- return U;
3236
+ if (!V) return x;
3237
+ for (var H, ue = V[1], se = new RegExp("(\\\\n|\\W)" + B(ue) + "\\(\\s*(/\\*.*?\\*/)?\\s*.*?([\\.|\\-|\\+|\\w|/|@]+).*?\\)", "g"); H = se.exec(C); ) H[3] !== "dll-reference" && x[L].push(H[3]);
3238
+ for (se = new RegExp("\\(" + B(ue) + '\\("(dll-reference\\s([\\.|\\-|\\+|\\w|/|@]+))"\\)\\)\\(\\s*(/\\*.*?\\*/)?\\s*.*?([\\.|\\-|\\+|\\w|/|@]+).*?\\)', "g"); H = se.exec(C); ) y[H[2]] || (x[L].push(H[1]), y[H[2]] = O(H[1]).m), x[H[2]] = x[H[2]] || [], x[H[2]].push(H[4]);
3239
+ for (var Y, ne = Object.keys(x), v = 0; v < ne.length; v++) for (var G = 0; G < x[ne[v]].length; G++) Y = x[ne[v]][G], isNaN(1 * Y) || (x[ne[v]][G] = 1 * x[ne[v]][G]);
3240
+ return x;
3243
3241
  }
3244
3242
  function b(y) {
3245
- return Object.keys(y).reduce(function(f, k) {
3246
- return f || y[k].length > 0;
3243
+ return Object.keys(y).reduce(function(f, L) {
3244
+ return f || y[L].length > 0;
3247
3245
  }, !1);
3248
3246
  }
3249
3247
  fe.exports = function(y, f) {
3250
3248
  f = f || {};
3251
- var k = { main: O.m }, U = f.all ? { main: Object.keys(k.main) } : function(se, Y) {
3252
- for (var ae = { main: [Y] }, v = { main: [] }, G = { main: {} }; b(ae); ) for (var T = Object.keys(ae), l = 0; l < T.length; l++) {
3253
- var u = T[l], _ = ae[u].pop();
3249
+ var L = { main: O.m }, x = f.all ? { main: Object.keys(L.main) } : function(se, Y) {
3250
+ for (var ne = { main: [Y] }, v = { main: [] }, G = { main: {} }; b(ne); ) for (var T = Object.keys(ne), l = 0; l < T.length; l++) {
3251
+ var u = T[l], _ = ne[u].pop();
3254
3252
  if (G[u] = G[u] || {}, !G[u][_] && se[u][_]) {
3255
3253
  G[u][_] = !0, v[u] = v[u] || [], v[u].push(_);
3256
- for (var c = m(se, se[u][_], u), P = Object.keys(c), D = 0; D < P.length; D++) ae[P[D]] = ae[P[D]] || [], ae[P[D]] = ae[P[D]].concat(c[P[D]]);
3254
+ for (var c = m(se, se[u][_], u), P = Object.keys(c), D = 0; D < P.length; D++) ne[P[D]] = ne[P[D]] || [], ne[P[D]] = ne[P[D]].concat(c[P[D]]);
3257
3255
  }
3258
3256
  }
3259
3257
  return v;
3260
- }(k, y), C = "";
3261
- Object.keys(U).filter(function(se) {
3258
+ }(L, y), C = "";
3259
+ Object.keys(x).filter(function(se) {
3262
3260
  return se !== "main";
3263
3261
  }).forEach(function(se) {
3264
- for (var Y = 0; U[se][Y]; ) Y++;
3265
- U[se].push(Y), k[se][Y] = "(function(module, exports, __webpack_require__) { module.exports = __webpack_require__; })", C = C + "var " + se + " = (" + x.toString().replace("ENTRY_MODULE", JSON.stringify(Y)) + ")({" + U[se].map(function(ae) {
3266
- return JSON.stringify(ae) + ": " + k[se][ae].toString();
3262
+ for (var Y = 0; x[se][Y]; ) Y++;
3263
+ x[se].push(Y), L[se][Y] = "(function(module, exports, __webpack_require__) { module.exports = __webpack_require__; })", C = C + "var " + se + " = (" + U.toString().replace("ENTRY_MODULE", JSON.stringify(Y)) + ")({" + x[se].map(function(ne) {
3264
+ return JSON.stringify(ne) + ": " + L[se][ne].toString();
3267
3265
  }).join(",") + `});
3268
3266
  `;
3269
- }), C = C + "new ((" + x.toString().replace("ENTRY_MODULE", JSON.stringify(y)) + ")({" + U.main.map(function(se) {
3270
- return JSON.stringify(se) + ": " + k.main[se].toString();
3267
+ }), C = C + "new ((" + U.toString().replace("ENTRY_MODULE", JSON.stringify(y)) + ")({" + x.main.map(function(se) {
3268
+ return JSON.stringify(se) + ": " + L.main[se].toString();
3271
3269
  }).join(",") + "}))(self);";
3272
3270
  var V = new window.Blob([C], { type: "text/javascript" });
3273
3271
  if (f.bare) return V;
@@ -3277,7 +3275,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3277
3275
  }, function(fe, Z, O) {
3278
3276
  fe.exports = O(19).default;
3279
3277
  }, function(fe, Z, O) {
3280
- (function(x, B) {
3278
+ (function(U, B) {
3281
3279
  /*!
3282
3280
  * @overview es6-promise - a tiny implementation of Promises/A+.
3283
3281
  * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
@@ -3292,10 +3290,10 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3292
3290
  }
3293
3291
  var y = Array.isArray ? Array.isArray : function(M) {
3294
3292
  return Object.prototype.toString.call(M) === "[object Array]";
3295
- }, f = 0, k = void 0, U = void 0, C = function(M, j) {
3296
- v[f] = M, v[f + 1] = j, (f += 2) === 2 && (U ? U(G) : c());
3297
- }, V = typeof window < "u" ? window : void 0, H = V || {}, ue = H.MutationObserver || H.WebKitMutationObserver, se = typeof self > "u" && x !== void 0 && {}.toString.call(x) === "[object process]", Y = typeof Uint8ClampedArray < "u" && typeof importScripts < "u" && typeof MessageChannel < "u";
3298
- function ae() {
3293
+ }, f = 0, L = void 0, x = void 0, C = function(M, j) {
3294
+ v[f] = M, v[f + 1] = j, (f += 2) === 2 && (x ? x(G) : c());
3295
+ }, V = typeof window < "u" ? window : void 0, H = V || {}, ue = H.MutationObserver || H.WebKitMutationObserver, se = typeof self > "u" && U !== void 0 && {}.toString.call(U) === "[object process]", Y = typeof Uint8ClampedArray < "u" && typeof importScripts < "u" && typeof MessageChannel < "u";
3296
+ function ne() {
3299
3297
  var M = setTimeout;
3300
3298
  return function() {
3301
3299
  return M(G, 1);
@@ -3325,7 +3323,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3325
3323
  return ye(j, M), j;
3326
3324
  }
3327
3325
  se ? c = function() {
3328
- return x.nextTick(G);
3326
+ return U.nextTick(G);
3329
3327
  } : ue ? (l = 0, u = new ue(G), _ = document.createTextNode(""), u.observe(_, { characterData: !0 }), c = function() {
3330
3328
  _.data = l = ++l % 2;
3331
3329
  }) : Y ? ((T = new MessageChannel()).port1.onmessage = G, c = function() {
@@ -3333,13 +3331,13 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3333
3331
  }) : c = V === void 0 ? function() {
3334
3332
  try {
3335
3333
  var M = Function("return this")().require("vertx");
3336
- return (k = M.runOnLoop || M.runOnContext) !== void 0 ? function() {
3337
- k(G);
3338
- } : ae();
3334
+ return (L = M.runOnLoop || M.runOnContext) !== void 0 ? function() {
3335
+ L(G);
3336
+ } : ne();
3339
3337
  } catch {
3340
- return ae();
3338
+ return ne();
3341
3339
  }
3342
- }() : ae();
3340
+ }() : ne();
3343
3341
  var F = Math.random().toString(36).substring(2);
3344
3342
  function ee() {
3345
3343
  }
@@ -3381,14 +3379,14 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3381
3379
  }
3382
3380
  var ie, re;
3383
3381
  }
3384
- function L(M) {
3382
+ function k(M) {
3385
3383
  M._onerror && M._onerror(M._result), X(M);
3386
3384
  }
3387
3385
  function d(M, j) {
3388
3386
  M._state === void 0 && (M._result = j, M._state = 1, M._subscribers.length !== 0 && C(X, M));
3389
3387
  }
3390
3388
  function h(M, j) {
3391
- M._state === void 0 && (M._state = 2, M._result = j, C(L, M));
3389
+ M._state === void 0 && (M._state = 2, M._result = j, C(k, M));
3392
3390
  }
3393
3391
  function R(M, j, $, ie) {
3394
3392
  var re = M._subscribers, ce = re.length;
@@ -3498,7 +3496,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3498
3496
  var j = new this(ee);
3499
3497
  return h(j, M), j;
3500
3498
  }, Te._setScheduler = function(M) {
3501
- U = M;
3499
+ x = M;
3502
3500
  }, Te._setAsap = function(M) {
3503
3501
  C = M;
3504
3502
  }, Te._asap = C, Te.polyfill = function() {
@@ -3524,7 +3522,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3524
3522
  }, fe.exports = m();
3525
3523
  }).call(this, O(16), O(17));
3526
3524
  }, function(fe, Z) {
3527
- var O, x, B = fe.exports = {};
3525
+ var O, U, B = fe.exports = {};
3528
3526
  function m() {
3529
3527
  throw new Error("setTimeout has not been defined");
3530
3528
  }
@@ -3551,47 +3549,47 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3551
3549
  O = m;
3552
3550
  }
3553
3551
  try {
3554
- x = typeof clearTimeout == "function" ? clearTimeout : b;
3552
+ U = typeof clearTimeout == "function" ? clearTimeout : b;
3555
3553
  } catch {
3556
- x = b;
3554
+ U = b;
3557
3555
  }
3558
3556
  })();
3559
- var f, k = [], U = !1, C = -1;
3557
+ var f, L = [], x = !1, C = -1;
3560
3558
  function V() {
3561
- U && f && (U = !1, f.length ? k = f.concat(k) : C = -1, k.length && H());
3559
+ x && f && (x = !1, f.length ? L = f.concat(L) : C = -1, L.length && H());
3562
3560
  }
3563
3561
  function H() {
3564
- if (!U) {
3562
+ if (!x) {
3565
3563
  var Y = y(V);
3566
- U = !0;
3567
- for (var ae = k.length; ae; ) {
3568
- for (f = k, k = []; ++C < ae; ) f && f[C].run();
3569
- C = -1, ae = k.length;
3570
- }
3571
- f = null, U = !1, function(v) {
3572
- if (x === clearTimeout) return clearTimeout(v);
3573
- if ((x === b || !x) && clearTimeout) return x = clearTimeout, clearTimeout(v);
3564
+ x = !0;
3565
+ for (var ne = L.length; ne; ) {
3566
+ for (f = L, L = []; ++C < ne; ) f && f[C].run();
3567
+ C = -1, ne = L.length;
3568
+ }
3569
+ f = null, x = !1, function(v) {
3570
+ if (U === clearTimeout) return clearTimeout(v);
3571
+ if ((U === b || !U) && clearTimeout) return U = clearTimeout, clearTimeout(v);
3574
3572
  try {
3575
- x(v);
3573
+ U(v);
3576
3574
  } catch {
3577
3575
  try {
3578
- return x.call(null, v);
3576
+ return U.call(null, v);
3579
3577
  } catch {
3580
- return x.call(this, v);
3578
+ return U.call(this, v);
3581
3579
  }
3582
3580
  }
3583
3581
  }(Y);
3584
3582
  }
3585
3583
  }
3586
- function ue(Y, ae) {
3587
- this.fun = Y, this.array = ae;
3584
+ function ue(Y, ne) {
3585
+ this.fun = Y, this.array = ne;
3588
3586
  }
3589
3587
  function se() {
3590
3588
  }
3591
3589
  B.nextTick = function(Y) {
3592
- var ae = new Array(arguments.length - 1);
3593
- if (arguments.length > 1) for (var v = 1; v < arguments.length; v++) ae[v - 1] = arguments[v];
3594
- k.push(new ue(Y, ae)), k.length !== 1 || U || y(H);
3590
+ var ne = new Array(arguments.length - 1);
3591
+ if (arguments.length > 1) for (var v = 1; v < arguments.length; v++) ne[v - 1] = arguments[v];
3592
+ L.push(new ue(Y, ne)), L.length !== 1 || x || y(H);
3595
3593
  }, ue.prototype.run = function() {
3596
3594
  this.fun.apply(null, this.array);
3597
3595
  }, B.title = "browser", B.browser = !0, B.env = {}, B.argv = [], B.version = "", B.versions = {}, B.on = se, B.addListener = se, B.once = se, B.off = se, B.removeListener = se, B.removeAllListeners = se, B.emit = se, B.prependListener = se, B.prependOnceListener = se, B.listeners = function(Y) {
@@ -3618,12 +3616,12 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3618
3616
  fe.exports = O;
3619
3617
  }, function(fe, Z, O) {
3620
3618
  O.r(Z);
3621
- var x = O(9), B = O(12), m = O(10), b = O(1);
3619
+ var U = O(9), B = O(12), m = O(10), b = O(1);
3622
3620
  Z.default = function(y) {
3623
- var f = null, k = (function(D, F) {
3621
+ var f = null, L = (function(D, F) {
3624
3622
  y.postMessage({ msg: "logcat_callback", data: { type: D, logcat: F } });
3625
3623
  }).bind(this);
3626
- function U(D, F) {
3624
+ function x(D, F) {
3627
3625
  var ee = { msg: b.a.INIT_SEGMENT, data: { type: D, data: F } };
3628
3626
  y.postMessage(ee, [F.data]);
3629
3627
  }
@@ -3651,7 +3649,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3651
3649
  var F = { msg: b.a.SCRIPTDATA_ARRIVED, data: D };
3652
3650
  y.postMessage(F);
3653
3651
  }
3654
- function ae(D) {
3652
+ function ne(D) {
3655
3653
  var F = { msg: b.a.TIMED_ID3_METADATA_ARRIVED, data: D };
3656
3654
  y.postMessage(F);
3657
3655
  }
@@ -3687,7 +3685,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3687
3685
  B.a.install(), y.addEventListener("message", function(D) {
3688
3686
  switch (D.data.cmd) {
3689
3687
  case "init":
3690
- (f = new m.a(D.data.param[0], D.data.param[1])).on(b.a.IO_ERROR, _.bind(this)), f.on(b.a.DEMUX_ERROR, c.bind(this)), f.on(b.a.INIT_SEGMENT, U.bind(this)), f.on(b.a.MEDIA_SEGMENT, C.bind(this)), f.on(b.a.LOADING_COMPLETE, V.bind(this)), f.on(b.a.RECOVERED_EARLY_EOF, H.bind(this)), f.on(b.a.MEDIA_INFO, ue.bind(this)), f.on(b.a.METADATA_ARRIVED, se.bind(this)), f.on(b.a.SCRIPTDATA_ARRIVED, Y.bind(this)), f.on(b.a.TIMED_ID3_METADATA_ARRIVED, ae.bind(this)), f.on(b.a.SMPTE2038_METADATA_ARRIVED, v.bind(this)), f.on(b.a.SCTE35_METADATA_ARRIVED, G.bind(this)), f.on(b.a.PES_PRIVATE_DATA_DESCRIPTOR, T.bind(this)), f.on(b.a.PES_PRIVATE_DATA_ARRIVED, l.bind(this)), f.on(b.a.STATISTICS_INFO, u.bind(this)), f.on(b.a.RECOMMEND_SEEKPOINT, P.bind(this));
3688
+ (f = new m.a(D.data.param[0], D.data.param[1])).on(b.a.IO_ERROR, _.bind(this)), f.on(b.a.DEMUX_ERROR, c.bind(this)), f.on(b.a.INIT_SEGMENT, x.bind(this)), f.on(b.a.MEDIA_SEGMENT, C.bind(this)), f.on(b.a.LOADING_COMPLETE, V.bind(this)), f.on(b.a.RECOVERED_EARLY_EOF, H.bind(this)), f.on(b.a.MEDIA_INFO, ue.bind(this)), f.on(b.a.METADATA_ARRIVED, se.bind(this)), f.on(b.a.SCRIPTDATA_ARRIVED, Y.bind(this)), f.on(b.a.TIMED_ID3_METADATA_ARRIVED, ne.bind(this)), f.on(b.a.SMPTE2038_METADATA_ARRIVED, v.bind(this)), f.on(b.a.SCTE35_METADATA_ARRIVED, G.bind(this)), f.on(b.a.PES_PRIVATE_DATA_DESCRIPTOR, T.bind(this)), f.on(b.a.PES_PRIVATE_DATA_ARRIVED, l.bind(this)), f.on(b.a.STATISTICS_INFO, u.bind(this)), f.on(b.a.RECOMMEND_SEEKPOINT, P.bind(this));
3691
3689
  break;
3692
3690
  case "destroy":
3693
3691
  f && (f.destroy(), f = null), y.postMessage({ msg: "destroyed" });
@@ -3709,151 +3707,151 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3709
3707
  break;
3710
3708
  case "logging_config":
3711
3709
  var F = D.data.param;
3712
- x.a.applyConfig(F), F.enableCallback === !0 ? x.a.addLogListener(k) : x.a.removeLogListener(k);
3710
+ U.a.applyConfig(F), F.enableCallback === !0 ? U.a.addLogListener(L) : U.a.removeLogListener(L);
3713
3711
  }
3714
3712
  });
3715
3713
  };
3716
3714
  }, function(fe, Z, O) {
3717
3715
  O.r(Z);
3718
- var x = O(12), B = O(11), m = { enableWorker: !1, enableStashBuffer: !0, stashInitialSize: void 0, isLive: !1, liveBufferLatencyChasing: !1, liveBufferLatencyMaxLatency: 1.5, liveBufferLatencyMinRemain: 0.5, lazyLoad: !0, lazyLoadMaxDuration: 180, lazyLoadRecoverDuration: 30, deferLoadAfterSourceOpen: !0, autoCleanupMaxBackwardDuration: 180, autoCleanupMinBackwardDuration: 120, statisticsInfoReportInterval: 600, fixAudioTimestampGap: !0, accurateSeek: !1, seekType: "range", seekParamStart: "bstart", seekParamEnd: "bend", rangeLoadZeroStart: !1, customSeekHandler: void 0, reuseRedirectedURL: !1, headers: void 0, customLoader: void 0 };
3716
+ var U = O(12), B = O(11), m = { enableWorker: !1, enableStashBuffer: !0, stashInitialSize: void 0, isLive: !1, liveBufferLatencyChasing: !1, liveBufferLatencyMaxLatency: 1.5, liveBufferLatencyMinRemain: 0.5, lazyLoad: !0, lazyLoadMaxDuration: 180, lazyLoadRecoverDuration: 30, deferLoadAfterSourceOpen: !0, autoCleanupMaxBackwardDuration: 180, autoCleanupMinBackwardDuration: 120, statisticsInfoReportInterval: 600, fixAudioTimestampGap: !0, accurateSeek: !1, seekType: "range", seekParamStart: "bstart", seekParamEnd: "bend", rangeLoadZeroStart: !1, customSeekHandler: void 0, reuseRedirectedURL: !1, headers: void 0, customLoader: void 0 };
3719
3717
  function b() {
3720
3718
  return Object.assign({}, m);
3721
3719
  }
3722
3720
  var y = function() {
3723
- function L() {
3721
+ function k() {
3724
3722
  }
3725
- return L.supportMSEH264Playback = function() {
3723
+ return k.supportMSEH264Playback = function() {
3726
3724
  return window.MediaSource && window.MediaSource.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"');
3727
- }, L.supportMSEH265Playback = function() {
3725
+ }, k.supportMSEH265Playback = function() {
3728
3726
  return window.MediaSource && window.MediaSource.isTypeSupported('video/mp4; codecs="hvc1.1.6.L93.B0"');
3729
- }, L.supportNetworkStreamIO = function() {
3727
+ }, k.supportNetworkStreamIO = function() {
3730
3728
  var d = new B.a({}, b()), h = d.loaderType;
3731
3729
  return d.destroy(), h == "fetch-stream-loader" || h == "xhr-moz-chunked-loader";
3732
- }, L.getNetworkLoaderTypeName = function() {
3730
+ }, k.getNetworkLoaderTypeName = function() {
3733
3731
  var d = new B.a({}, b()), h = d.loaderType;
3734
3732
  return d.destroy(), h;
3735
- }, L.supportNativeMediaPlayback = function(d) {
3736
- L.videoElement == null && (L.videoElement = window.document.createElement("video"));
3737
- var h = L.videoElement.canPlayType(d);
3733
+ }, k.supportNativeMediaPlayback = function(d) {
3734
+ k.videoElement == null && (k.videoElement = window.document.createElement("video"));
3735
+ var h = k.videoElement.canPlayType(d);
3738
3736
  return h === "probably" || h == "maybe";
3739
- }, L.getFeatureList = function() {
3737
+ }, k.getFeatureList = function() {
3740
3738
  var d = { msePlayback: !1, mseLivePlayback: !1, mseH265Playback: !1, networkStreamIO: !1, networkLoaderName: "", nativeMP4H264Playback: !1, nativeMP4H265Playback: !1, nativeWebmVP8Playback: !1, nativeWebmVP9Playback: !1 };
3741
- return d.msePlayback = L.supportMSEH264Playback(), d.networkStreamIO = L.supportNetworkStreamIO(), d.networkLoaderName = L.getNetworkLoaderTypeName(), d.mseLivePlayback = d.msePlayback && d.networkStreamIO, d.mseH265Playback = L.supportMSEH265Playback(), d.nativeMP4H264Playback = L.supportNativeMediaPlayback('video/mp4; codecs="avc1.42001E, mp4a.40.2"'), d.nativeMP4H265Playback = L.supportNativeMediaPlayback('video/mp4; codecs="hvc1.1.6.L93.B0"'), d.nativeWebmVP8Playback = L.supportNativeMediaPlayback('video/webm; codecs="vp8.0, vorbis"'), d.nativeWebmVP9Playback = L.supportNativeMediaPlayback('video/webm; codecs="vp9"'), d;
3742
- }, L;
3743
- }(), f = O(2), k = O(6), U = O.n(k), C = O(0), V = O(4), H = { ERROR: "error", LOADING_COMPLETE: "loading_complete", RECOVERED_EARLY_EOF: "recovered_early_eof", MEDIA_INFO: "media_info", METADATA_ARRIVED: "metadata_arrived", SCRIPTDATA_ARRIVED: "scriptdata_arrived", TIMED_ID3_METADATA_ARRIVED: "timed_id3_metadata_arrived", SMPTE2038_METADATA_ARRIVED: "smpte2038_metadata_arrived", SCTE35_METADATA_ARRIVED: "scte35_metadata_arrived", PES_PRIVATE_DATA_DESCRIPTOR: "pes_private_data_descriptor", PES_PRIVATE_DATA_ARRIVED: "pes_private_data_arrived", STATISTICS_INFO: "statistics_info" }, ue = O(13), se = O.n(ue), Y = O(9), ae = O(10), v = O(1), G = O(8), T = function() {
3744
- function L(d, h) {
3745
- if (this.TAG = "Transmuxer", this._emitter = new U.a(), h.enableWorker && typeof Worker < "u") try {
3739
+ return d.msePlayback = k.supportMSEH264Playback(), d.networkStreamIO = k.supportNetworkStreamIO(), d.networkLoaderName = k.getNetworkLoaderTypeName(), d.mseLivePlayback = d.msePlayback && d.networkStreamIO, d.mseH265Playback = k.supportMSEH265Playback(), d.nativeMP4H264Playback = k.supportNativeMediaPlayback('video/mp4; codecs="avc1.42001E, mp4a.40.2"'), d.nativeMP4H265Playback = k.supportNativeMediaPlayback('video/mp4; codecs="hvc1.1.6.L93.B0"'), d.nativeWebmVP8Playback = k.supportNativeMediaPlayback('video/webm; codecs="vp8.0, vorbis"'), d.nativeWebmVP9Playback = k.supportNativeMediaPlayback('video/webm; codecs="vp9"'), d;
3740
+ }, k;
3741
+ }(), f = O(2), L = O(6), x = O.n(L), C = O(0), V = O(4), H = { ERROR: "error", LOADING_COMPLETE: "loading_complete", RECOVERED_EARLY_EOF: "recovered_early_eof", MEDIA_INFO: "media_info", METADATA_ARRIVED: "metadata_arrived", SCRIPTDATA_ARRIVED: "scriptdata_arrived", TIMED_ID3_METADATA_ARRIVED: "timed_id3_metadata_arrived", SMPTE2038_METADATA_ARRIVED: "smpte2038_metadata_arrived", SCTE35_METADATA_ARRIVED: "scte35_metadata_arrived", PES_PRIVATE_DATA_DESCRIPTOR: "pes_private_data_descriptor", PES_PRIVATE_DATA_ARRIVED: "pes_private_data_arrived", STATISTICS_INFO: "statistics_info" }, ue = O(13), se = O.n(ue), Y = O(9), ne = O(10), v = O(1), G = O(8), T = function() {
3742
+ function k(d, h) {
3743
+ if (this.TAG = "Transmuxer", this._emitter = new x.a(), h.enableWorker && typeof Worker < "u") try {
3746
3744
  this._worker = se()(18), this._workerDestroying = !1, this._worker.addEventListener("message", this._onWorkerMessage.bind(this)), this._worker.postMessage({ cmd: "init", param: [d, h] }), this.e = { onLoggingConfigChanged: this._onLoggingConfigChanged.bind(this) }, Y.a.registerListener(this.e.onLoggingConfigChanged), this._worker.postMessage({ cmd: "logging_config", param: Y.a.getConfig() });
3747
3745
  } catch {
3748
- C.a.e(this.TAG, "Error while initialize transmuxing worker, fallback to inline transmuxing"), this._worker = null, this._controller = new ae.a(d, h);
3746
+ C.a.e(this.TAG, "Error while initialize transmuxing worker, fallback to inline transmuxing"), this._worker = null, this._controller = new ne.a(d, h);
3749
3747
  }
3750
- else this._controller = new ae.a(d, h);
3748
+ else this._controller = new ne.a(d, h);
3751
3749
  if (this._controller) {
3752
3750
  var R = this._controller;
3753
3751
  R.on(v.a.IO_ERROR, this._onIOError.bind(this)), R.on(v.a.DEMUX_ERROR, this._onDemuxError.bind(this)), R.on(v.a.INIT_SEGMENT, this._onInitSegment.bind(this)), R.on(v.a.MEDIA_SEGMENT, this._onMediaSegment.bind(this)), R.on(v.a.LOADING_COMPLETE, this._onLoadingComplete.bind(this)), R.on(v.a.RECOVERED_EARLY_EOF, this._onRecoveredEarlyEof.bind(this)), R.on(v.a.MEDIA_INFO, this._onMediaInfo.bind(this)), R.on(v.a.METADATA_ARRIVED, this._onMetaDataArrived.bind(this)), R.on(v.a.SCRIPTDATA_ARRIVED, this._onScriptDataArrived.bind(this)), R.on(v.a.TIMED_ID3_METADATA_ARRIVED, this._onTimedID3MetadataArrived.bind(this)), R.on(v.a.SMPTE2038_METADATA_ARRIVED, this._onSMPTE2038MetadataArrived.bind(this)), R.on(v.a.SCTE35_METADATA_ARRIVED, this._onSCTE35MetadataArrived.bind(this)), R.on(v.a.PES_PRIVATE_DATA_DESCRIPTOR, this._onPESPrivateDataDescriptor.bind(this)), R.on(v.a.PES_PRIVATE_DATA_ARRIVED, this._onPESPrivateDataArrived.bind(this)), R.on(v.a.STATISTICS_INFO, this._onStatisticsInfo.bind(this)), R.on(v.a.RECOMMEND_SEEKPOINT, this._onRecommendSeekpoint.bind(this));
3754
3752
  }
3755
3753
  }
3756
- return L.prototype.destroy = function() {
3754
+ return k.prototype.destroy = function() {
3757
3755
  this._worker ? this._workerDestroying || (this._workerDestroying = !0, this._worker.postMessage({ cmd: "destroy" }), Y.a.removeListener(this.e.onLoggingConfigChanged), this.e = null) : (this._controller.destroy(), this._controller = null), this._emitter.removeAllListeners(), this._emitter = null;
3758
- }, L.prototype.on = function(d, h) {
3756
+ }, k.prototype.on = function(d, h) {
3759
3757
  this._emitter.addListener(d, h);
3760
- }, L.prototype.off = function(d, h) {
3758
+ }, k.prototype.off = function(d, h) {
3761
3759
  this._emitter.removeListener(d, h);
3762
- }, L.prototype.hasWorker = function() {
3760
+ }, k.prototype.hasWorker = function() {
3763
3761
  return this._worker != null;
3764
- }, L.prototype.open = function() {
3762
+ }, k.prototype.open = function() {
3765
3763
  this._worker ? this._worker.postMessage({ cmd: "start" }) : this._controller.start();
3766
- }, L.prototype.close = function() {
3764
+ }, k.prototype.close = function() {
3767
3765
  this._worker ? this._worker.postMessage({ cmd: "stop" }) : this._controller.stop();
3768
- }, L.prototype.seek = function(d) {
3766
+ }, k.prototype.seek = function(d) {
3769
3767
  this._worker ? this._worker.postMessage({ cmd: "seek", param: d }) : this._controller.seek(d);
3770
- }, L.prototype.pause = function() {
3768
+ }, k.prototype.pause = function() {
3771
3769
  this._worker ? this._worker.postMessage({ cmd: "pause" }) : this._controller.pause();
3772
- }, L.prototype.resume = function() {
3770
+ }, k.prototype.resume = function() {
3773
3771
  this._worker ? this._worker.postMessage({ cmd: "resume" }) : this._controller.resume();
3774
- }, L.prototype._onInitSegment = function(d, h) {
3772
+ }, k.prototype._onInitSegment = function(d, h) {
3775
3773
  var R = this;
3776
3774
  Promise.resolve().then(function() {
3777
3775
  R._emitter.emit(v.a.INIT_SEGMENT, d, h);
3778
3776
  });
3779
- }, L.prototype._onMediaSegment = function(d, h) {
3777
+ }, k.prototype._onMediaSegment = function(d, h) {
3780
3778
  var R = this;
3781
3779
  Promise.resolve().then(function() {
3782
3780
  R._emitter.emit(v.a.MEDIA_SEGMENT, d, h);
3783
3781
  });
3784
- }, L.prototype._onLoadingComplete = function() {
3782
+ }, k.prototype._onLoadingComplete = function() {
3785
3783
  var d = this;
3786
3784
  Promise.resolve().then(function() {
3787
3785
  d._emitter.emit(v.a.LOADING_COMPLETE);
3788
3786
  });
3789
- }, L.prototype._onRecoveredEarlyEof = function() {
3787
+ }, k.prototype._onRecoveredEarlyEof = function() {
3790
3788
  var d = this;
3791
3789
  Promise.resolve().then(function() {
3792
3790
  d._emitter.emit(v.a.RECOVERED_EARLY_EOF);
3793
3791
  });
3794
- }, L.prototype._onMediaInfo = function(d) {
3792
+ }, k.prototype._onMediaInfo = function(d) {
3795
3793
  var h = this;
3796
3794
  Promise.resolve().then(function() {
3797
3795
  h._emitter.emit(v.a.MEDIA_INFO, d);
3798
3796
  });
3799
- }, L.prototype._onMetaDataArrived = function(d) {
3797
+ }, k.prototype._onMetaDataArrived = function(d) {
3800
3798
  var h = this;
3801
3799
  Promise.resolve().then(function() {
3802
3800
  h._emitter.emit(v.a.METADATA_ARRIVED, d);
3803
3801
  });
3804
- }, L.prototype._onScriptDataArrived = function(d) {
3802
+ }, k.prototype._onScriptDataArrived = function(d) {
3805
3803
  var h = this;
3806
3804
  Promise.resolve().then(function() {
3807
3805
  h._emitter.emit(v.a.SCRIPTDATA_ARRIVED, d);
3808
3806
  });
3809
- }, L.prototype._onTimedID3MetadataArrived = function(d) {
3807
+ }, k.prototype._onTimedID3MetadataArrived = function(d) {
3810
3808
  var h = this;
3811
3809
  Promise.resolve().then(function() {
3812
3810
  h._emitter.emit(v.a.TIMED_ID3_METADATA_ARRIVED, d);
3813
3811
  });
3814
- }, L.prototype._onSMPTE2038MetadataArrived = function(d) {
3812
+ }, k.prototype._onSMPTE2038MetadataArrived = function(d) {
3815
3813
  var h = this;
3816
3814
  Promise.resolve().then(function() {
3817
3815
  h._emitter.emit(v.a.SMPTE2038_METADATA_ARRIVED, d);
3818
3816
  });
3819
- }, L.prototype._onSCTE35MetadataArrived = function(d) {
3817
+ }, k.prototype._onSCTE35MetadataArrived = function(d) {
3820
3818
  var h = this;
3821
3819
  Promise.resolve().then(function() {
3822
3820
  h._emitter.emit(v.a.SCTE35_METADATA_ARRIVED, d);
3823
3821
  });
3824
- }, L.prototype._onPESPrivateDataDescriptor = function(d) {
3822
+ }, k.prototype._onPESPrivateDataDescriptor = function(d) {
3825
3823
  var h = this;
3826
3824
  Promise.resolve().then(function() {
3827
3825
  h._emitter.emit(v.a.PES_PRIVATE_DATA_DESCRIPTOR, d);
3828
3826
  });
3829
- }, L.prototype._onPESPrivateDataArrived = function(d) {
3827
+ }, k.prototype._onPESPrivateDataArrived = function(d) {
3830
3828
  var h = this;
3831
3829
  Promise.resolve().then(function() {
3832
3830
  h._emitter.emit(v.a.PES_PRIVATE_DATA_ARRIVED, d);
3833
3831
  });
3834
- }, L.prototype._onStatisticsInfo = function(d) {
3832
+ }, k.prototype._onStatisticsInfo = function(d) {
3835
3833
  var h = this;
3836
3834
  Promise.resolve().then(function() {
3837
3835
  h._emitter.emit(v.a.STATISTICS_INFO, d);
3838
3836
  });
3839
- }, L.prototype._onIOError = function(d, h) {
3837
+ }, k.prototype._onIOError = function(d, h) {
3840
3838
  var R = this;
3841
3839
  Promise.resolve().then(function() {
3842
3840
  R._emitter.emit(v.a.IO_ERROR, d, h);
3843
3841
  });
3844
- }, L.prototype._onDemuxError = function(d, h) {
3842
+ }, k.prototype._onDemuxError = function(d, h) {
3845
3843
  var R = this;
3846
3844
  Promise.resolve().then(function() {
3847
3845
  R._emitter.emit(v.a.DEMUX_ERROR, d, h);
3848
3846
  });
3849
- }, L.prototype._onRecommendSeekpoint = function(d) {
3847
+ }, k.prototype._onRecommendSeekpoint = function(d) {
3850
3848
  var h = this;
3851
3849
  Promise.resolve().then(function() {
3852
3850
  h._emitter.emit(v.a.RECOMMEND_SEEKPOINT, d);
3853
3851
  });
3854
- }, L.prototype._onLoggingConfigChanged = function(d) {
3852
+ }, k.prototype._onLoggingConfigChanged = function(d) {
3855
3853
  this._worker && this._worker.postMessage({ cmd: "logging_config", param: d });
3856
- }, L.prototype._onWorkerMessage = function(d) {
3854
+ }, k.prototype._onWorkerMessage = function(d) {
3857
3855
  var h = d.data, R = h.data;
3858
3856
  if (h.msg === "destroyed" || this._workerDestroying) return this._workerDestroying = !1, this._worker.terminate(), void (this._worker = null);
3859
3857
  switch (h.msg) {
@@ -3888,22 +3886,22 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3888
3886
  case "logcat_callback":
3889
3887
  C.a.emitter.emit("log", R.type, R.logcat);
3890
3888
  }
3891
- }, L;
3889
+ }, k;
3892
3890
  }(), l = { ERROR: "error", SOURCE_OPEN: "source_open", UPDATE_END: "update_end", BUFFER_FULL: "buffer_full" }, u = O(7), _ = O(3), c = function() {
3893
- function L(d) {
3894
- this.TAG = "MSEController", this._config = d, this._emitter = new U.a(), this._config.isLive && this._config.autoCleanupSourceBuffer == null && (this._config.autoCleanupSourceBuffer = !0), this.e = { onSourceOpen: this._onSourceOpen.bind(this), onSourceEnded: this._onSourceEnded.bind(this), onSourceClose: this._onSourceClose.bind(this), onSourceBufferError: this._onSourceBufferError.bind(this), onSourceBufferUpdateEnd: this._onSourceBufferUpdateEnd.bind(this) }, this._mediaSource = null, this._mediaSourceObjectURL = null, this._mediaElement = null, this._isBufferFull = !1, this._hasPendingEos = !1, this._requireSetMediaDuration = !1, this._pendingMediaDuration = 0, this._pendingSourceBufferInit = [], this._mimeTypes = { video: null, audio: null }, this._sourceBuffers = { video: null, audio: null }, this._lastInitSegments = { video: null, audio: null }, this._pendingSegments = { video: [], audio: [] }, this._pendingRemoveRanges = { video: [], audio: [] }, this._idrList = new u.a();
3891
+ function k(d) {
3892
+ this.TAG = "MSEController", this._config = d, this._emitter = new x.a(), this._config.isLive && this._config.autoCleanupSourceBuffer == null && (this._config.autoCleanupSourceBuffer = !0), this.e = { onSourceOpen: this._onSourceOpen.bind(this), onSourceEnded: this._onSourceEnded.bind(this), onSourceClose: this._onSourceClose.bind(this), onSourceBufferError: this._onSourceBufferError.bind(this), onSourceBufferUpdateEnd: this._onSourceBufferUpdateEnd.bind(this) }, this._mediaSource = null, this._mediaSourceObjectURL = null, this._mediaElement = null, this._isBufferFull = !1, this._hasPendingEos = !1, this._requireSetMediaDuration = !1, this._pendingMediaDuration = 0, this._pendingSourceBufferInit = [], this._mimeTypes = { video: null, audio: null }, this._sourceBuffers = { video: null, audio: null }, this._lastInitSegments = { video: null, audio: null }, this._pendingSegments = { video: [], audio: [] }, this._pendingRemoveRanges = { video: [], audio: [] }, this._idrList = new u.a();
3895
3893
  }
3896
- return L.prototype.destroy = function() {
3894
+ return k.prototype.destroy = function() {
3897
3895
  (this._mediaElement || this._mediaSource) && this.detachMediaElement(), this.e = null, this._emitter.removeAllListeners(), this._emitter = null;
3898
- }, L.prototype.on = function(d, h) {
3896
+ }, k.prototype.on = function(d, h) {
3899
3897
  this._emitter.addListener(d, h);
3900
- }, L.prototype.off = function(d, h) {
3898
+ }, k.prototype.off = function(d, h) {
3901
3899
  this._emitter.removeListener(d, h);
3902
- }, L.prototype.attachMediaElement = function(d) {
3900
+ }, k.prototype.attachMediaElement = function(d) {
3903
3901
  if (this._mediaSource) throw new _.a("MediaSource has been attached to an HTMLMediaElement!");
3904
3902
  var h = this._mediaSource = new window.MediaSource();
3905
3903
  h.addEventListener("sourceopen", this.e.onSourceOpen), h.addEventListener("sourceended", this.e.onSourceEnded), h.addEventListener("sourceclose", this.e.onSourceClose), this._mediaElement = d, this._mediaSourceObjectURL = window.URL.createObjectURL(this._mediaSource), d.src = this._mediaSourceObjectURL;
3906
- }, L.prototype.detachMediaElement = function() {
3904
+ }, k.prototype.detachMediaElement = function() {
3907
3905
  if (this._mediaSource) {
3908
3906
  var d = this._mediaSource;
3909
3907
  for (var h in this._sourceBuffers) {
@@ -3930,7 +3928,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3930
3928
  d.removeEventListener("sourceopen", this.e.onSourceOpen), d.removeEventListener("sourceended", this.e.onSourceEnded), d.removeEventListener("sourceclose", this.e.onSourceClose), this._pendingSourceBufferInit = [], this._isBufferFull = !1, this._idrList.clear(), this._mediaSource = null;
3931
3929
  }
3932
3930
  this._mediaElement && (this._mediaElement.src = "", this._mediaElement.removeAttribute("src"), this._mediaElement = null), this._mediaSourceObjectURL && (window.URL.revokeObjectURL(this._mediaSourceObjectURL), this._mediaSourceObjectURL = null);
3933
- }, L.prototype.appendInitSegment = function(d, h) {
3931
+ }, k.prototype.appendInitSegment = function(d, h) {
3934
3932
  if (!this._mediaSource || this._mediaSource.readyState !== "open") return this._pendingSourceBufferInit.push(d), void this._pendingSegments[d.type].push(d);
3935
3933
  var R = d, X = "" + R.container;
3936
3934
  R.codec && R.codec.length > 0 && (X += ";codecs=" + R.codec);
@@ -3949,12 +3947,12 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3949
3947
  this._mimeTypes[R.type] = X;
3950
3948
  }
3951
3949
  h || this._pendingSegments[R.type].push(R), oe || this._sourceBuffers[R.type] && !this._sourceBuffers[R.type].updating && this._doAppendSegments(), V.a.safari && R.container === "audio/mpeg" && R.mediaDuration > 0 && (this._requireSetMediaDuration = !0, this._pendingMediaDuration = R.mediaDuration / 1e3, this._updateMediaSourceDuration());
3952
- }, L.prototype.appendMediaSegment = function(d) {
3950
+ }, k.prototype.appendMediaSegment = function(d) {
3953
3951
  var h = d;
3954
3952
  this._pendingSegments[h.type].push(h), this._config.autoCleanupSourceBuffer && this._needCleanupSourceBuffer() && this._doCleanupSourceBuffer();
3955
3953
  var R = this._sourceBuffers[h.type];
3956
3954
  !R || R.updating || this._hasPendingRemoveRanges() || this._doAppendSegments();
3957
- }, L.prototype.seek = function(d) {
3955
+ }, k.prototype.seek = function(d) {
3958
3956
  for (var h in this._sourceBuffers) if (this._sourceBuffers[h]) {
3959
3957
  var R = this._sourceBuffers[h];
3960
3958
  if (this._mediaSource.readyState === "open") try {
@@ -3975,12 +3973,12 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3975
3973
  }
3976
3974
  }
3977
3975
  }
3978
- }, L.prototype.endOfStream = function() {
3976
+ }, k.prototype.endOfStream = function() {
3979
3977
  var d = this._mediaSource, h = this._sourceBuffers;
3980
3978
  d && d.readyState === "open" ? h.video && h.video.updating || h.audio && h.audio.updating ? this._hasPendingEos = !0 : (this._hasPendingEos = !1, d.endOfStream()) : d && d.readyState === "closed" && this._hasPendingSegments() && (this._hasPendingEos = !0);
3981
- }, L.prototype.getNearestKeyframe = function(d) {
3979
+ }, k.prototype.getNearestKeyframe = function(d) {
3982
3980
  return this._idrList.getLastSyncPointBeforeDts(d);
3983
- }, L.prototype._needCleanupSourceBuffer = function() {
3981
+ }, k.prototype._needCleanupSourceBuffer = function() {
3984
3982
  if (!this._config.autoCleanupSourceBuffer) return !1;
3985
3983
  var d = this._mediaElement.currentTime;
3986
3984
  for (var h in this._sourceBuffers) {
@@ -3991,7 +3989,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
3991
3989
  }
3992
3990
  }
3993
3991
  return !1;
3994
- }, L.prototype._doCleanupSourceBuffer = function() {
3992
+ }, k.prototype._doCleanupSourceBuffer = function() {
3995
3993
  var d = this._mediaElement.currentTime;
3996
3994
  for (var h in this._sourceBuffers) {
3997
3995
  var R = this._sourceBuffers[h];
@@ -4009,18 +4007,18 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4009
4007
  oe && !R.updating && this._doRemoveRanges();
4010
4008
  }
4011
4009
  }
4012
- }, L.prototype._updateMediaSourceDuration = function() {
4010
+ }, k.prototype._updateMediaSourceDuration = function() {
4013
4011
  var d = this._sourceBuffers;
4014
4012
  if (this._mediaElement.readyState !== 0 && this._mediaSource.readyState === "open" && !(d.video && d.video.updating || d.audio && d.audio.updating)) {
4015
4013
  var h = this._mediaSource.duration, R = this._pendingMediaDuration;
4016
4014
  R > 0 && (isNaN(h) || R > h) && (C.a.v(this.TAG, "Update MediaSource duration from " + h + " to " + R), this._mediaSource.duration = R), this._requireSetMediaDuration = !1, this._pendingMediaDuration = 0;
4017
4015
  }
4018
- }, L.prototype._doRemoveRanges = function() {
4016
+ }, k.prototype._doRemoveRanges = function() {
4019
4017
  for (var d in this._pendingRemoveRanges) if (this._sourceBuffers[d] && !this._sourceBuffers[d].updating) for (var h = this._sourceBuffers[d], R = this._pendingRemoveRanges[d]; R.length && !h.updating; ) {
4020
4018
  var X = R.shift();
4021
4019
  h.remove(X.start, X.end);
4022
4020
  }
4023
- }, L.prototype._doAppendSegments = function() {
4021
+ }, k.prototype._doAppendSegments = function() {
4024
4022
  var d = this._pendingSegments;
4025
4023
  for (var h in d) if (this._sourceBuffers[h] && !this._sourceBuffers[h].updating && d[h].length > 0) {
4026
4024
  var R = d[h].shift();
@@ -4035,48 +4033,48 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4035
4033
  this._pendingSegments[h].unshift(R), me.code === 22 ? (this._isBufferFull || this._emitter.emit(l.BUFFER_FULL), this._isBufferFull = !0) : (C.a.e(this.TAG, me.message), this._emitter.emit(l.ERROR, { code: me.code, msg: me.message }));
4036
4034
  }
4037
4035
  }
4038
- }, L.prototype._onSourceOpen = function() {
4036
+ }, k.prototype._onSourceOpen = function() {
4039
4037
  if (C.a.v(this.TAG, "MediaSource onSourceOpen"), this._mediaSource.removeEventListener("sourceopen", this.e.onSourceOpen), this._pendingSourceBufferInit.length > 0) for (var d = this._pendingSourceBufferInit; d.length; ) {
4040
4038
  var h = d.shift();
4041
4039
  this.appendInitSegment(h, !0);
4042
4040
  }
4043
4041
  this._hasPendingSegments() && this._doAppendSegments(), this._emitter.emit(l.SOURCE_OPEN);
4044
- }, L.prototype._onSourceEnded = function() {
4042
+ }, k.prototype._onSourceEnded = function() {
4045
4043
  C.a.v(this.TAG, "MediaSource onSourceEnded");
4046
- }, L.prototype._onSourceClose = function() {
4044
+ }, k.prototype._onSourceClose = function() {
4047
4045
  C.a.v(this.TAG, "MediaSource onSourceClose"), this._mediaSource && this.e != null && (this._mediaSource.removeEventListener("sourceopen", this.e.onSourceOpen), this._mediaSource.removeEventListener("sourceended", this.e.onSourceEnded), this._mediaSource.removeEventListener("sourceclose", this.e.onSourceClose));
4048
- }, L.prototype._hasPendingSegments = function() {
4046
+ }, k.prototype._hasPendingSegments = function() {
4049
4047
  var d = this._pendingSegments;
4050
4048
  return d.video.length > 0 || d.audio.length > 0;
4051
- }, L.prototype._hasPendingRemoveRanges = function() {
4049
+ }, k.prototype._hasPendingRemoveRanges = function() {
4052
4050
  var d = this._pendingRemoveRanges;
4053
4051
  return d.video.length > 0 || d.audio.length > 0;
4054
- }, L.prototype._onSourceBufferUpdateEnd = function() {
4052
+ }, k.prototype._onSourceBufferUpdateEnd = function() {
4055
4053
  this._requireSetMediaDuration ? this._updateMediaSourceDuration() : this._hasPendingRemoveRanges() ? this._doRemoveRanges() : this._hasPendingSegments() ? this._doAppendSegments() : this._hasPendingEos && this.endOfStream(), this._emitter.emit(l.UPDATE_END);
4056
- }, L.prototype._onSourceBufferError = function(d) {
4054
+ }, k.prototype._onSourceBufferError = function(d) {
4057
4055
  C.a.e(this.TAG, "SourceBuffer Error: " + d);
4058
- }, L;
4056
+ }, k;
4059
4057
  }(), P = O(5), D = { NETWORK_ERROR: "NetworkError", MEDIA_ERROR: "MediaError", OTHER_ERROR: "OtherError" }, F = { NETWORK_EXCEPTION: f.b.EXCEPTION, NETWORK_STATUS_CODE_INVALID: f.b.HTTP_STATUS_CODE_INVALID, NETWORK_TIMEOUT: f.b.CONNECTING_TIMEOUT, NETWORK_UNRECOVERABLE_EARLY_EOF: f.b.UNRECOVERABLE_EARLY_EOF, MEDIA_MSE_ERROR: "MediaMSEError", MEDIA_FORMAT_ERROR: P.a.FORMAT_ERROR, MEDIA_FORMAT_UNSUPPORTED: P.a.FORMAT_UNSUPPORTED, MEDIA_CODEC_UNSUPPORTED: P.a.CODEC_UNSUPPORTED }, ee = function() {
4060
- function L(d, h) {
4061
- this.TAG = "MSEPlayer", this._type = "MSEPlayer", this._emitter = new U.a(), this._config = b(), typeof h == "object" && Object.assign(this._config, h);
4058
+ function k(d, h) {
4059
+ this.TAG = "MSEPlayer", this._type = "MSEPlayer", this._emitter = new x.a(), this._config = b(), typeof h == "object" && Object.assign(this._config, h);
4062
4060
  var R = d.type.toLowerCase();
4063
4061
  if (R !== "mse" && R !== "mpegts" && R !== "m2ts" && R !== "flv") throw new _.b("MSEPlayer requires an mpegts/m2ts/flv MediaDataSource input!");
4064
4062
  d.isLive === !0 && (this._config.isLive = !0), this.e = { onvLoadedMetadata: this._onvLoadedMetadata.bind(this), onvSeeking: this._onvSeeking.bind(this), onvCanPlay: this._onvCanPlay.bind(this), onvStalled: this._onvStalled.bind(this), onvProgress: this._onvProgress.bind(this) }, self.performance && self.performance.now ? this._now = self.performance.now.bind(self.performance) : this._now = Date.now, this._pendingSeekTime = null, this._requestSetTime = !1, this._seekpointRecord = null, this._progressChecker = null, this._mediaDataSource = d, this._mediaElement = null, this._msectl = null, this._transmuxer = null, this._mseSourceOpened = !1, this._hasPendingLoad = !1, this._receivedCanPlay = !1, this._mediaInfo = null, this._statisticsInfo = null;
4065
4063
  var X = V.a.chrome && (V.a.version.major < 50 || V.a.version.major === 50 && V.a.version.build < 2661);
4066
4064
  this._alwaysSeekKeyframe = !!(X || V.a.msedge || V.a.msie), this._alwaysSeekKeyframe && (this._config.accurateSeek = !1);
4067
4065
  }
4068
- return L.prototype.destroy = function() {
4066
+ return k.prototype.destroy = function() {
4069
4067
  this._progressChecker != null && (window.clearInterval(this._progressChecker), this._progressChecker = null), this._transmuxer && this.unload(), this._mediaElement && this.detachMediaElement(), this.e = null, this._mediaDataSource = null, this._emitter.removeAllListeners(), this._emitter = null;
4070
- }, L.prototype.on = function(d, h) {
4068
+ }, k.prototype.on = function(d, h) {
4071
4069
  var R = this;
4072
4070
  d === H.MEDIA_INFO ? this._mediaInfo != null && Promise.resolve().then(function() {
4073
4071
  R._emitter.emit(H.MEDIA_INFO, R.mediaInfo);
4074
4072
  }) : d === H.STATISTICS_INFO && this._statisticsInfo != null && Promise.resolve().then(function() {
4075
4073
  R._emitter.emit(H.STATISTICS_INFO, R.statisticsInfo);
4076
4074
  }), this._emitter.addListener(d, h);
4077
- }, L.prototype.off = function(d, h) {
4075
+ }, k.prototype.off = function(d, h) {
4078
4076
  this._emitter.removeListener(d, h);
4079
- }, L.prototype.attachMediaElement = function(d) {
4077
+ }, k.prototype.attachMediaElement = function(d) {
4080
4078
  var h = this;
4081
4079
  if (this._mediaElement = d, d.addEventListener("loadedmetadata", this.e.onvLoadedMetadata), d.addEventListener("seeking", this.e.onvSeeking), d.addEventListener("canplay", this.e.onvCanPlay), d.addEventListener("stalled", this.e.onvStalled), d.addEventListener("progress", this.e.onvProgress), this._msectl = new c(this._config), this._msectl.on(l.UPDATE_END, this._onmseUpdateEnd.bind(this)), this._msectl.on(l.BUFFER_FULL, this._onmseBufferFull.bind(this)), this._msectl.on(l.SOURCE_OPEN, function() {
4082
4080
  h._mseSourceOpened = !0, h._hasPendingLoad && (h._hasPendingLoad = !1, h.load());
@@ -4086,9 +4084,9 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4086
4084
  d.currentTime = this._pendingSeekTime, this._pendingSeekTime = null;
4087
4085
  } catch {
4088
4086
  }
4089
- }, L.prototype.detachMediaElement = function() {
4087
+ }, k.prototype.detachMediaElement = function() {
4090
4088
  this._mediaElement && (this._msectl.detachMediaElement(), this._mediaElement.removeEventListener("loadedmetadata", this.e.onvLoadedMetadata), this._mediaElement.removeEventListener("seeking", this.e.onvSeeking), this._mediaElement.removeEventListener("canplay", this.e.onvCanPlay), this._mediaElement.removeEventListener("stalled", this.e.onvStalled), this._mediaElement.removeEventListener("progress", this.e.onvProgress), this._mediaElement = null), this._msectl && (this._msectl.destroy(), this._msectl = null);
4091
- }, L.prototype.load = function() {
4089
+ }, k.prototype.load = function() {
4092
4090
  var d = this;
4093
4091
  if (!this._mediaElement) throw new _.a("HTMLMediaElement must be attached before load()!");
4094
4092
  if (this._transmuxer) throw new _.a("MSEPlayer.load() has been called, please call unload() first!");
@@ -4128,35 +4126,35 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4128
4126
  }), this._transmuxer.on(v.a.RECOMMEND_SEEKPOINT, function(h) {
4129
4127
  d._mediaElement && !d._config.accurateSeek && (d._requestSetTime = !0, d._mediaElement.currentTime = h / 1e3);
4130
4128
  }), this._transmuxer.open()));
4131
- }, L.prototype.unload = function() {
4129
+ }, k.prototype.unload = function() {
4132
4130
  this._mediaElement && this._mediaElement.pause(), this._msectl && this._msectl.seek(0), this._transmuxer && (this._transmuxer.close(), this._transmuxer.destroy(), this._transmuxer = null);
4133
- }, L.prototype.play = function() {
4131
+ }, k.prototype.play = function() {
4134
4132
  return this._mediaElement.play();
4135
- }, L.prototype.pause = function() {
4133
+ }, k.prototype.pause = function() {
4136
4134
  this._mediaElement.pause();
4137
- }, Object.defineProperty(L.prototype, "type", { get: function() {
4135
+ }, Object.defineProperty(k.prototype, "type", { get: function() {
4138
4136
  return this._type;
4139
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "buffered", { get: function() {
4137
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "buffered", { get: function() {
4140
4138
  return this._mediaElement.buffered;
4141
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "duration", { get: function() {
4139
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "duration", { get: function() {
4142
4140
  return this._mediaElement.duration;
4143
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "volume", { get: function() {
4141
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "volume", { get: function() {
4144
4142
  return this._mediaElement.volume;
4145
4143
  }, set: function(d) {
4146
4144
  this._mediaElement.volume = d;
4147
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "muted", { get: function() {
4145
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "muted", { get: function() {
4148
4146
  return this._mediaElement.muted;
4149
4147
  }, set: function(d) {
4150
4148
  this._mediaElement.muted = d;
4151
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "currentTime", { get: function() {
4149
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "currentTime", { get: function() {
4152
4150
  return this._mediaElement ? this._mediaElement.currentTime : 0;
4153
4151
  }, set: function(d) {
4154
4152
  this._mediaElement ? this._internalSeek(d) : this._pendingSeekTime = d;
4155
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "mediaInfo", { get: function() {
4153
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "mediaInfo", { get: function() {
4156
4154
  return Object.assign({}, this._mediaInfo);
4157
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "statisticsInfo", { get: function() {
4155
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "statisticsInfo", { get: function() {
4158
4156
  return this._statisticsInfo == null && (this._statisticsInfo = {}), this._statisticsInfo = this._fillStatisticsInfo(this._statisticsInfo), Object.assign({}, this._statisticsInfo);
4159
- }, enumerable: !1, configurable: !0 }), L.prototype._fillStatisticsInfo = function(d) {
4157
+ }, enumerable: !1, configurable: !0 }), k.prototype._fillStatisticsInfo = function(d) {
4160
4158
  if (d.playerType = this._type, !(this._mediaElement instanceof HTMLVideoElement)) return d;
4161
4159
  var h = !0, R = 0, X = 0;
4162
4160
  if (this._mediaElement.getVideoPlaybackQuality) {
@@ -4164,7 +4162,7 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4164
4162
  R = oe.totalVideoFrames, X = oe.droppedVideoFrames;
4165
4163
  } else this._mediaElement.webkitDecodedFrameCount != null ? (R = this._mediaElement.webkitDecodedFrameCount, X = this._mediaElement.webkitDroppedFrameCount) : h = !1;
4166
4164
  return h && (d.decodedFrames = R, d.droppedFrames = X), d;
4167
- }, L.prototype._onmseUpdateEnd = function() {
4165
+ }, k.prototype._onmseUpdateEnd = function() {
4168
4166
  var d = this._mediaElement.buffered, h = this._mediaElement.currentTime;
4169
4167
  if (this._config.isLive && this._config.liveBufferLatencyChasing && d.length > 0 && !this._mediaElement.paused) {
4170
4168
  var R = d.end(d.length - 1);
@@ -4183,11 +4181,11 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4183
4181
  }
4184
4182
  oe >= h + this._config.lazyLoadMaxDuration && this._progressChecker == null && (C.a.v(this.TAG, "Maximum buffering duration exceeded, suspend transmuxing task"), this._suspendTransmuxer());
4185
4183
  }
4186
- }, L.prototype._onmseBufferFull = function() {
4184
+ }, k.prototype._onmseBufferFull = function() {
4187
4185
  C.a.v(this.TAG, "MSE SourceBuffer is full, suspend transmuxing task"), this._progressChecker == null && this._suspendTransmuxer();
4188
- }, L.prototype._suspendTransmuxer = function() {
4186
+ }, k.prototype._suspendTransmuxer = function() {
4189
4187
  this._transmuxer && (this._transmuxer.pause(), this._progressChecker == null && (this._progressChecker = window.setInterval(this._checkProgressAndResume.bind(this), 1e3)));
4190
- }, L.prototype._checkProgressAndResume = function() {
4188
+ }, k.prototype._checkProgressAndResume = function() {
4191
4189
  for (var d = this._mediaElement.currentTime, h = this._mediaElement.buffered, R = !1, X = 0; X < h.length; X++) {
4192
4190
  var oe = h.start(X), me = h.end(X);
4193
4191
  if (d >= oe && d < me) {
@@ -4196,13 +4194,13 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4196
4194
  }
4197
4195
  }
4198
4196
  R && (window.clearInterval(this._progressChecker), this._progressChecker = null, R && (C.a.v(this.TAG, "Continue loading from paused position"), this._transmuxer.resume()));
4199
- }, L.prototype._isTimepointBuffered = function(d) {
4197
+ }, k.prototype._isTimepointBuffered = function(d) {
4200
4198
  for (var h = this._mediaElement.buffered, R = 0; R < h.length; R++) {
4201
4199
  var X = h.start(R), oe = h.end(R);
4202
4200
  if (d >= X && d < oe) return !0;
4203
4201
  }
4204
4202
  return !1;
4205
- }, L.prototype._internalSeek = function(d) {
4203
+ }, k.prototype._internalSeek = function(d) {
4206
4204
  var h = this._isTimepointBuffered(d), R = !1, X = 0;
4207
4205
  if (d < 1 && this._mediaElement.buffered.length > 0) {
4208
4206
  var oe = this._mediaElement.buffered.start(0);
@@ -4216,20 +4214,20 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4216
4214
  } else this._requestSetTime = !0, this._mediaElement.currentTime = d;
4217
4215
  this._progressChecker != null && this._checkProgressAndResume();
4218
4216
  } else this._progressChecker != null && (window.clearInterval(this._progressChecker), this._progressChecker = null), this._msectl.seek(d), this._transmuxer.seek(Math.floor(1e3 * d)), this._config.accurateSeek && (this._requestSetTime = !0, this._mediaElement.currentTime = d);
4219
- }, L.prototype._checkAndApplyUnbufferedSeekpoint = function() {
4217
+ }, k.prototype._checkAndApplyUnbufferedSeekpoint = function() {
4220
4218
  if (this._seekpointRecord) if (this._seekpointRecord.recordTime <= this._now() - 100) {
4221
4219
  var d = this._mediaElement.currentTime;
4222
4220
  this._seekpointRecord = null, this._isTimepointBuffered(d) || (this._progressChecker != null && (window.clearTimeout(this._progressChecker), this._progressChecker = null), this._msectl.seek(d), this._transmuxer.seek(Math.floor(1e3 * d)), this._config.accurateSeek && (this._requestSetTime = !0, this._mediaElement.currentTime = d));
4223
4221
  } else window.setTimeout(this._checkAndApplyUnbufferedSeekpoint.bind(this), 50);
4224
- }, L.prototype._checkAndResumeStuckPlayback = function(d) {
4222
+ }, k.prototype._checkAndResumeStuckPlayback = function(d) {
4225
4223
  var h = this._mediaElement;
4226
4224
  if (d || !this._receivedCanPlay || h.readyState < 2) {
4227
4225
  var R = h.buffered;
4228
4226
  R.length > 0 && h.currentTime < R.start(0) && (C.a.w(this.TAG, "Playback seems stuck at " + h.currentTime + ", seek to " + R.start(0)), this._requestSetTime = !0, this._mediaElement.currentTime = R.start(0), this._mediaElement.removeEventListener("progress", this.e.onvProgress));
4229
4227
  } else this._mediaElement.removeEventListener("progress", this.e.onvProgress);
4230
- }, L.prototype._onvLoadedMetadata = function(d) {
4228
+ }, k.prototype._onvLoadedMetadata = function(d) {
4231
4229
  this._pendingSeekTime != null && (this._mediaElement.currentTime = this._pendingSeekTime, this._pendingSeekTime = null);
4232
- }, L.prototype._onvSeeking = function(d) {
4230
+ }, k.prototype._onvSeeking = function(d) {
4233
4231
  var h = this._mediaElement.currentTime, R = this._mediaElement.buffered;
4234
4232
  if (this._requestSetTime) this._requestSetTime = !1;
4235
4233
  else {
@@ -4245,70 +4243,70 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4245
4243
  this._progressChecker != null && this._checkProgressAndResume();
4246
4244
  } else this._seekpointRecord = { seekPoint: h, recordTime: this._now() }, window.setTimeout(this._checkAndApplyUnbufferedSeekpoint.bind(this), 50);
4247
4245
  }
4248
- }, L.prototype._onvCanPlay = function(d) {
4246
+ }, k.prototype._onvCanPlay = function(d) {
4249
4247
  this._receivedCanPlay = !0, this._mediaElement.removeEventListener("canplay", this.e.onvCanPlay);
4250
- }, L.prototype._onvStalled = function(d) {
4248
+ }, k.prototype._onvStalled = function(d) {
4251
4249
  this._checkAndResumeStuckPlayback(!0);
4252
- }, L.prototype._onvProgress = function(d) {
4250
+ }, k.prototype._onvProgress = function(d) {
4253
4251
  this._checkAndResumeStuckPlayback();
4254
- }, L;
4252
+ }, k;
4255
4253
  }(), pe = function() {
4256
- function L(d, h) {
4257
- this.TAG = "NativePlayer", this._type = "NativePlayer", this._emitter = new U.a(), this._config = b(), typeof h == "object" && Object.assign(this._config, h);
4254
+ function k(d, h) {
4255
+ this.TAG = "NativePlayer", this._type = "NativePlayer", this._emitter = new x.a(), this._config = b(), typeof h == "object" && Object.assign(this._config, h);
4258
4256
  var R = d.type.toLowerCase();
4259
4257
  if (R === "mse" || R === "mpegts" || R === "m2ts" || R === "flv") throw new _.b("NativePlayer does't support mse/mpegts/m2ts/flv MediaDataSource input!");
4260
4258
  if (d.hasOwnProperty("segments")) throw new _.b("NativePlayer(" + d.type + ") doesn't support multipart playback!");
4261
4259
  this.e = { onvLoadedMetadata: this._onvLoadedMetadata.bind(this) }, this._pendingSeekTime = null, this._statisticsReporter = null, this._mediaDataSource = d, this._mediaElement = null;
4262
4260
  }
4263
- return L.prototype.destroy = function() {
4261
+ return k.prototype.destroy = function() {
4264
4262
  this._mediaElement && (this.unload(), this.detachMediaElement()), this.e = null, this._mediaDataSource = null, this._emitter.removeAllListeners(), this._emitter = null;
4265
- }, L.prototype.on = function(d, h) {
4263
+ }, k.prototype.on = function(d, h) {
4266
4264
  var R = this;
4267
4265
  d === H.MEDIA_INFO ? this._mediaElement != null && this._mediaElement.readyState !== 0 && Promise.resolve().then(function() {
4268
4266
  R._emitter.emit(H.MEDIA_INFO, R.mediaInfo);
4269
4267
  }) : d === H.STATISTICS_INFO && this._mediaElement != null && this._mediaElement.readyState !== 0 && Promise.resolve().then(function() {
4270
4268
  R._emitter.emit(H.STATISTICS_INFO, R.statisticsInfo);
4271
4269
  }), this._emitter.addListener(d, h);
4272
- }, L.prototype.off = function(d, h) {
4270
+ }, k.prototype.off = function(d, h) {
4273
4271
  this._emitter.removeListener(d, h);
4274
- }, L.prototype.attachMediaElement = function(d) {
4272
+ }, k.prototype.attachMediaElement = function(d) {
4275
4273
  if (this._mediaElement = d, d.addEventListener("loadedmetadata", this.e.onvLoadedMetadata), this._pendingSeekTime != null) try {
4276
4274
  d.currentTime = this._pendingSeekTime, this._pendingSeekTime = null;
4277
4275
  } catch {
4278
4276
  }
4279
- }, L.prototype.detachMediaElement = function() {
4277
+ }, k.prototype.detachMediaElement = function() {
4280
4278
  this._mediaElement && (this._mediaElement.src = "", this._mediaElement.removeAttribute("src"), this._mediaElement.removeEventListener("loadedmetadata", this.e.onvLoadedMetadata), this._mediaElement = null), this._statisticsReporter != null && (window.clearInterval(this._statisticsReporter), this._statisticsReporter = null);
4281
- }, L.prototype.load = function() {
4279
+ }, k.prototype.load = function() {
4282
4280
  if (!this._mediaElement) throw new _.a("HTMLMediaElement must be attached before load()!");
4283
4281
  this._mediaElement.src = this._mediaDataSource.url, this._mediaElement.readyState > 0 && (this._mediaElement.currentTime = 0), this._mediaElement.preload = "auto", this._mediaElement.load(), this._statisticsReporter = window.setInterval(this._reportStatisticsInfo.bind(this), this._config.statisticsInfoReportInterval);
4284
- }, L.prototype.unload = function() {
4282
+ }, k.prototype.unload = function() {
4285
4283
  this._mediaElement && (this._mediaElement.src = "", this._mediaElement.removeAttribute("src")), this._statisticsReporter != null && (window.clearInterval(this._statisticsReporter), this._statisticsReporter = null);
4286
- }, L.prototype.play = function() {
4284
+ }, k.prototype.play = function() {
4287
4285
  return this._mediaElement.play();
4288
- }, L.prototype.pause = function() {
4286
+ }, k.prototype.pause = function() {
4289
4287
  this._mediaElement.pause();
4290
- }, Object.defineProperty(L.prototype, "type", { get: function() {
4288
+ }, Object.defineProperty(k.prototype, "type", { get: function() {
4291
4289
  return this._type;
4292
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "buffered", { get: function() {
4290
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "buffered", { get: function() {
4293
4291
  return this._mediaElement.buffered;
4294
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "duration", { get: function() {
4292
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "duration", { get: function() {
4295
4293
  return this._mediaElement.duration;
4296
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "volume", { get: function() {
4294
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "volume", { get: function() {
4297
4295
  return this._mediaElement.volume;
4298
4296
  }, set: function(d) {
4299
4297
  this._mediaElement.volume = d;
4300
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "muted", { get: function() {
4298
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "muted", { get: function() {
4301
4299
  return this._mediaElement.muted;
4302
4300
  }, set: function(d) {
4303
4301
  this._mediaElement.muted = d;
4304
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "currentTime", { get: function() {
4302
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "currentTime", { get: function() {
4305
4303
  return this._mediaElement ? this._mediaElement.currentTime : 0;
4306
4304
  }, set: function(d) {
4307
4305
  this._mediaElement ? this._mediaElement.currentTime = d : this._pendingSeekTime = d;
4308
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "mediaInfo", { get: function() {
4306
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "mediaInfo", { get: function() {
4309
4307
  var d = { mimeType: (this._mediaElement instanceof HTMLAudioElement ? "audio/" : "video/") + this._mediaDataSource.type };
4310
4308
  return this._mediaElement && (d.duration = Math.floor(1e3 * this._mediaElement.duration), this._mediaElement instanceof HTMLVideoElement && (d.width = this._mediaElement.videoWidth, d.height = this._mediaElement.videoHeight)), d;
4311
- }, enumerable: !1, configurable: !0 }), Object.defineProperty(L.prototype, "statisticsInfo", { get: function() {
4309
+ }, enumerable: !1, configurable: !0 }), Object.defineProperty(k.prototype, "statisticsInfo", { get: function() {
4312
4310
  var d = { playerType: this._type, url: this._mediaDataSource.url };
4313
4311
  if (!(this._mediaElement instanceof HTMLVideoElement)) return d;
4314
4312
  var h = !0, R = 0, X = 0;
@@ -4317,15 +4315,15 @@ originalDts: ` + be + " ms, curRefDts: " + Re + " ms, dtsCorrection: " + Math.ro
4317
4315
  R = oe.totalVideoFrames, X = oe.droppedVideoFrames;
4318
4316
  } else this._mediaElement.webkitDecodedFrameCount != null ? (R = this._mediaElement.webkitDecodedFrameCount, X = this._mediaElement.webkitDroppedFrameCount) : h = !1;
4319
4317
  return h && (d.decodedFrames = R, d.droppedFrames = X), d;
4320
- }, enumerable: !1, configurable: !0 }), L.prototype._onvLoadedMetadata = function(d) {
4318
+ }, enumerable: !1, configurable: !0 }), k.prototype._onvLoadedMetadata = function(d) {
4321
4319
  this._pendingSeekTime != null && (this._mediaElement.currentTime = this._pendingSeekTime, this._pendingSeekTime = null), this._emitter.emit(H.MEDIA_INFO, this.mediaInfo);
4322
- }, L.prototype._reportStatisticsInfo = function() {
4320
+ }, k.prototype._reportStatisticsInfo = function() {
4323
4321
  this._emitter.emit(H.STATISTICS_INFO, this.statisticsInfo);
4324
- }, L;
4322
+ }, k;
4325
4323
  }();
4326
- x.a.install();
4327
- var ye = { createPlayer: function(L, d) {
4328
- var h = L;
4324
+ U.a.install();
4325
+ var ye = { createPlayer: function(k, d) {
4326
+ var h = k;
4329
4327
  if (h == null || typeof h != "object") throw new _.b("MediaDataSource must be an javascript object!");
4330
4328
  if (!h.hasOwnProperty("type")) throw new _.b("MediaDataSource must has type field to indicate video file type!");
4331
4329
  switch (h.type) {
@@ -4368,35 +4366,35 @@ const Rt = /* @__PURE__ */ di(ui), li = ["element-loading-text", "element-loadin
4368
4366
  dc851078: G.value
4369
4367
  }));
4370
4368
  const Z = Ie, O = fe;
4371
- let x;
4369
+ let U;
4372
4370
  const {
4373
4371
  fit: B,
4374
4372
  loadingText: m = At("加载中"),
4375
4373
  loading: b = !1,
4376
4374
  error: y = !1,
4377
4375
  errorText: f = At("das-ui-live-player-videoLoadFailedRetry")
4378
- } = Zt(Z), k = ot(() => Z.src || ""), U = ot(() => {
4379
- const l = k.value.split(".").pop() || void 0;
4376
+ } = Zt(Z), L = ot(() => Z.src || ""), x = ot(() => {
4377
+ const l = L.value.split(".").pop() || void 0;
4380
4378
  return Z.type ?? l ?? "flv";
4381
4379
  }), C = ot(() => Z.config || {}), V = Xe(Z.retryTime || 0), H = Xe(null), ue = async () => {
4382
4380
  if (!H.value) return;
4383
4381
  const l = {
4384
- type: U.value,
4382
+ type: x.value,
4385
4383
  isLive: !0,
4386
- url: k.value
4384
+ url: L.value
4387
4385
  };
4388
- x = Rt.createPlayer(l, C.value), x.attachMediaElement(H.value), x.load(), x.play(), x.on(Rt.Events.ERROR, se), O("loaded", x);
4386
+ U = Rt.createPlayer(l, C.value), U.attachMediaElement(H.value), U.load(), U.play(), U.on(Rt.Events.ERROR, se), O("loaded", U);
4389
4387
  }, se = (l, u) => {
4390
- console.error("mpegts error:", l, u), Y();
4388
+ Y();
4391
4389
  }, Y = () => {
4392
- V.value !== 0 && (V.value = V.value - 1, ae(), ue());
4393
- }, ae = () => {
4394
- x && (console.log("destroy", x), x.pause(), x.unload(), x.detachMediaElement(), x.destroy(), x = null);
4390
+ V.value !== 0 && (V.value = V.value - 1, ne(), ue());
4391
+ }, ne = () => {
4392
+ U && (U.pause(), U.unload(), U.detachMediaElement(), U.destroy(), U = null);
4395
4393
  };
4396
4394
  $t(() => {
4397
4395
  ue();
4398
4396
  }), Qt(() => {
4399
- ae();
4397
+ ne();
4400
4398
  }), Ye({
4401
4399
  video: H
4402
4400
  });
@@ -4417,7 +4415,7 @@ const Rt = /* @__PURE__ */ di(ui), li = ["element-loading-text", "element-loadin
4417
4415
  onClick: T
4418
4416
  }, [
4419
4417
  ii(l.$slots, "error", {}, () => [
4420
- ri(ai(We(f)), 1)
4418
+ ri(ni(We(f)), 1)
4421
4419
  ], !0)
4422
4420
  ])) : (dt(), ut("video", {
4423
4421
  key: 0,
@@ -4447,7 +4445,7 @@ const Rt = /* @__PURE__ */ di(ui), li = ["element-loading-text", "element-loadin
4447
4445
  }
4448
4446
  };
4449
4447
  oi(fi);
4450
- const Si = ni(ci), Ei = () => Xe(null);
4448
+ const Si = ai(ci), Ei = () => Xe(null);
4451
4449
  export {
4452
4450
  Si as DasLivePlayer,
4453
4451
  Ei as getDasLivePlayerRef