hls.js 1.6.0-beta.3.0.canary.10976 → 1.6.0-beta.3.0.canary.10979
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/hls.d.mts +1 -0
- package/dist/hls.d.ts +1 -0
- package/dist/hls.js +63 -60
- package/dist/hls.js.d.ts +1 -0
- package/dist/hls.js.map +1 -1
- package/dist/hls.light.js +27 -24
- package/dist/hls.light.js.map +1 -1
- package/dist/hls.light.min.js +1 -1
- package/dist/hls.light.min.js.map +1 -1
- package/dist/hls.light.mjs +25 -22
- package/dist/hls.light.mjs.map +1 -1
- package/dist/hls.min.js +1 -1
- package/dist/hls.min.js.map +1 -1
- package/dist/hls.mjs +55 -52
- package/dist/hls.mjs.map +1 -1
- package/dist/hls.worker.js +1 -1
- package/dist/hls.worker.js.map +1 -1
- package/package.json +2 -2
- package/src/controller/abr-controller.ts +6 -2
package/dist/hls.light.js
CHANGED
@@ -1030,7 +1030,7 @@
|
|
1030
1030
|
// Some browsers don't allow to use bind on console object anyway
|
1031
1031
|
// fallback to default if needed
|
1032
1032
|
try {
|
1033
|
-
newLogger.log("Debug logs enabled for \"" + context + "\" in hls.js version " + "1.6.0-beta.3.0.canary.
|
1033
|
+
newLogger.log("Debug logs enabled for \"" + context + "\" in hls.js version " + "1.6.0-beta.3.0.canary.10979");
|
1034
1034
|
} catch (e) {
|
1035
1035
|
/* log fn threw an exception. All logger methods are no-ops. */
|
1036
1036
|
return createLogger();
|
@@ -2315,12 +2315,18 @@
|
|
2315
2315
|
// not enough time budget even with quality level 0 ... rebuffering might happen
|
2316
2316
|
return -1;
|
2317
2317
|
};
|
2318
|
+
_proto.deriveNextAutoLevel = function deriveNextAutoLevel(nextLevel) {
|
2319
|
+
var _this$hls2 = this.hls,
|
2320
|
+
maxAutoLevel = _this$hls2.maxAutoLevel,
|
2321
|
+
minAutoLevel = _this$hls2.minAutoLevel;
|
2322
|
+
return Math.min(Math.max(nextLevel, minAutoLevel), maxAutoLevel);
|
2323
|
+
};
|
2318
2324
|
return _createClass(AbrController, [{
|
2319
2325
|
key: "firstAutoLevel",
|
2320
2326
|
get: function get() {
|
2321
|
-
var _this$
|
2322
|
-
maxAutoLevel = _this$
|
2323
|
-
minAutoLevel = _this$
|
2327
|
+
var _this$hls3 = this.hls,
|
2328
|
+
maxAutoLevel = _this$hls3.maxAutoLevel,
|
2329
|
+
minAutoLevel = _this$hls3.minAutoLevel;
|
2324
2330
|
var bwEstimate = this.getBwEstimate();
|
2325
2331
|
var maxStartDelay = this.hls.config.maxStarvationDelay;
|
2326
2332
|
var abrAutoLevel = this.findBestLevel(bwEstimate, minAutoLevel, maxAutoLevel, 0, maxStartDelay, 1, 1);
|
@@ -2371,10 +2377,7 @@
|
|
2371
2377
|
return nextABRAutoLevel;
|
2372
2378
|
},
|
2373
2379
|
set: function set(nextLevel) {
|
2374
|
-
var
|
2375
|
-
maxAutoLevel = _this$hls3.maxAutoLevel,
|
2376
|
-
minAutoLevel = _this$hls3.minAutoLevel;
|
2377
|
-
var value = Math.min(Math.max(nextLevel, minAutoLevel), maxAutoLevel);
|
2380
|
+
var value = this.deriveNextAutoLevel(nextLevel);
|
2378
2381
|
if (this._nextAutoLevel !== value) {
|
2379
2382
|
this.nextAutoLevelKey = '';
|
2380
2383
|
this._nextAutoLevel = value;
|
@@ -9365,6 +9368,21 @@
|
|
9365
9368
|
};
|
9366
9369
|
}
|
9367
9370
|
|
9371
|
+
function toArrayBuffer(view) {
|
9372
|
+
if (view instanceof ArrayBuffer) {
|
9373
|
+
return view;
|
9374
|
+
} else {
|
9375
|
+
if (view.byteOffset == 0 && view.byteLength == view.buffer.byteLength) {
|
9376
|
+
// This is a TypedArray over the whole buffer.
|
9377
|
+
return view.buffer;
|
9378
|
+
}
|
9379
|
+
// This is a 'view' on the buffer. Create a new buffer that only contains
|
9380
|
+
// the data. Note that since this isn't an ArrayBuffer, the 'new' call
|
9381
|
+
// will allocate a new buffer to hold the copy.
|
9382
|
+
return new Uint8Array(view).buffer;
|
9383
|
+
}
|
9384
|
+
}
|
9385
|
+
|
9368
9386
|
function toUint8(data, offset, length) {
|
9369
9387
|
if (offset === void 0) {
|
9370
9388
|
offset = 0;
|
@@ -9401,21 +9419,6 @@
|
|
9401
9419
|
return obj && obj.buffer instanceof ArrayBuffer && obj.byteLength !== undefined && obj.byteOffset !== undefined;
|
9402
9420
|
}
|
9403
9421
|
|
9404
|
-
function toArrayBuffer(view) {
|
9405
|
-
if (view instanceof ArrayBuffer) {
|
9406
|
-
return view;
|
9407
|
-
} else {
|
9408
|
-
if (view.byteOffset == 0 && view.byteLength == view.buffer.byteLength) {
|
9409
|
-
// This is a TypedArray over the whole buffer.
|
9410
|
-
return view.buffer;
|
9411
|
-
}
|
9412
|
-
// This is a 'view' on the buffer. Create a new buffer that only contains
|
9413
|
-
// the data. Note that since this isn't an ArrayBuffer, the 'new' call
|
9414
|
-
// will allocate a new buffer to hold the copy.
|
9415
|
-
return new Uint8Array(view).buffer;
|
9416
|
-
}
|
9417
|
-
}
|
9418
|
-
|
9419
9422
|
function decodeId3ImageFrame(frame) {
|
9420
9423
|
var metadataFrame = {
|
9421
9424
|
key: frame.type,
|
@@ -20001,7 +20004,7 @@
|
|
20001
20004
|
return !remuxResult.audio && !remuxResult.video && !remuxResult.text && !remuxResult.id3 && !remuxResult.initSegment;
|
20002
20005
|
}
|
20003
20006
|
|
20004
|
-
var version = "1.6.0-beta.3.0.canary.
|
20007
|
+
var version = "1.6.0-beta.3.0.canary.10979";
|
20005
20008
|
|
20006
20009
|
// ensure the worker ends up in the bundle
|
20007
20010
|
// If the worker should not be included this gets aliased to empty.js
|