hls.js 1.6.0-beta.1.0.canary.10810 → 1.6.0-beta.1.0.canary.10811
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.js +12 -8
- package/dist/hls.js.map +1 -1
- package/dist/hls.light.js +12 -8
- 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 +12 -8
- 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 +12 -8
- 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 +1 -1
- package/src/remux/mp4-remuxer.ts +11 -7
package/dist/hls.light.mjs
CHANGED
@@ -400,7 +400,7 @@ function enableLogs(debugConfig, context, id) {
|
|
400
400
|
// Some browsers don't allow to use bind on console object anyway
|
401
401
|
// fallback to default if needed
|
402
402
|
try {
|
403
|
-
newLogger.log(`Debug logs enabled for "${context}" in hls.js version ${"1.6.0-beta.1.0.canary.
|
403
|
+
newLogger.log(`Debug logs enabled for "${context}" in hls.js version ${"1.6.0-beta.1.0.canary.10811"}`);
|
404
404
|
} catch (e) {
|
405
405
|
/* log fn threw an exception. All logger methods are no-ops. */
|
406
406
|
return createLogger();
|
@@ -15297,19 +15297,23 @@ class MP4Remuxer {
|
|
15297
15297
|
this.videoTrackConfig = undefined;
|
15298
15298
|
}
|
15299
15299
|
getVideoStartPts(videoSamples) {
|
15300
|
+
// Get the minimum PTS value relative to the first sample's PTS, normalized for 33-bit wrapping
|
15300
15301
|
let rolloverDetected = false;
|
15302
|
+
const firstPts = videoSamples[0].pts;
|
15301
15303
|
const startPTS = videoSamples.reduce((minPTS, sample) => {
|
15302
|
-
|
15304
|
+
let pts = sample.pts;
|
15305
|
+
let delta = pts - minPTS;
|
15303
15306
|
if (delta < -4294967296) {
|
15304
15307
|
// 2^32, see PTSNormalize for reasoning, but we're hitting a rollover here, and we don't want that to impact the timeOffset calculation
|
15305
15308
|
rolloverDetected = true;
|
15306
|
-
|
15307
|
-
|
15309
|
+
pts = normalizePts(pts, firstPts);
|
15310
|
+
delta = pts - minPTS;
|
15311
|
+
}
|
15312
|
+
if (delta > 0) {
|
15308
15313
|
return minPTS;
|
15309
|
-
} else {
|
15310
|
-
return sample.pts;
|
15311
15314
|
}
|
15312
|
-
|
15315
|
+
return pts;
|
15316
|
+
}, firstPts);
|
15313
15317
|
if (rolloverDetected) {
|
15314
15318
|
this.logger.debug('PTS rollover detected');
|
15315
15319
|
}
|
@@ -19142,7 +19146,7 @@ class GapController extends Logger {
|
|
19142
19146
|
}
|
19143
19147
|
}
|
19144
19148
|
|
19145
|
-
const version = "1.6.0-beta.1.0.canary.
|
19149
|
+
const version = "1.6.0-beta.1.0.canary.10811";
|
19146
19150
|
|
19147
19151
|
// ensure the worker ends up in the bundle
|
19148
19152
|
// If the worker should not be included this gets aliased to empty.js
|