Merge remote-tracking branch 'origin/main'

This commit is contained in:
guy
2026-11-19 00:38:12 -03:00
3 changed files with 111 additions and 13 deletions
+7 -1
View File
@@ -473,7 +473,13 @@ function openView(c) {
// los 3 segmentos de hls.js, que es lo que usaba la 076 para que el inglés llegue a tiempo.
// Con hasta 1,1x de velocidad llega al objetivo (hls.js arranca más atrás del HOLD-BACK).
// Con más de 6 segmentos de atraso (después de un corte de la fuente) salta al vivo (083).
hls = new Hls({ maxLiveSyncPlaybackRate: 1.1, liveMaxLatencyDurationCount: 6 });
// A mano y no con liveMaxLatencyDurationCount: sin liveSyncDurationCount hls.js tira
// "Illegal hls.js config" y no reproduce nada, y con él se pisa el HOLD-BACK (2026-11-19).
hls = new Hls({ maxLiveSyncPlaybackRate: 1.1 });
hls.on(Hls.Events.LEVEL_UPDATED, (ev, d) => {
const td = d.details.targetduration, obj = hls.targetLatency, pos = hls.liveSyncPosition;
if (td && obj && pos && hls.latency > obj + 6 * td) v.currentTime = pos;
});
hls.on(Hls.Events.ERROR, (ev, d) => { if (!d.fatal) return; if (d.type === Hls.ErrorTypes.MEDIA_ERROR) hls.recoverMediaError(); else hls.startLoad(); });
hls.loadSource(src); hls.attachMedia(v);
hls.on(Hls.Events.SUBTITLE_TRACKS_UPDATED, () => {