From a7e0db7a4fe8755795b08905e399bc1a2fde2c0e Mon Sep 17 00:00:00 2001 From: Trevor Mears Date: Sun, 28 Dec 2025 01:29:27 -0800 Subject: [PATCH] Added two new HLS settings to help with audio issues on some streaming services --- public/js/components/VideoPlayer.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/public/js/components/VideoPlayer.js b/public/js/components/VideoPlayer.js index 368da3a..5939eba 100644 --- a/public/js/components/VideoPlayer.js +++ b/public/js/components/VideoPlayer.js @@ -69,6 +69,9 @@ class VideoPlayer { // Live stream settings - stay further from live edge for stability liveSyncDurationCount: 3, // Stay 3 segments behind live liveMaxLatencyDurationCount: 10, // Allow up to 10 segments behind before catching up + // Handle audio discontinuities (fixes garbled audio during ad transitions) + stretchShortVideoTrack: true, // Stretch short segments to avoid gaps + forceKeyFrameOnDiscontinuity: true, // Force keyframe sync on discontinuity // Faster recovery from errors levelLoadingMaxRetry: 4, manifestLoadingMaxRetry: 4,