Closed pcruiksh closed 2 years ago
Hi all, we have been trying the solution proposed by infocity-hirata in this topic.
This solution works for us. Do you know if this fix will be included coming soon, or the core of hlsjs are thinking in an other way?
Does anyone else have the same problem or have checked this solution?
infocity-hirata Thanks so much!!!
What version of Hls.js are you using?
1.1.4
What browser (including version) are you using?
Chrome 99
What OS (including version) are you using?
Mac OS 12.3
Test stream
No response
Configuration
Additional player setup steps
n/a
Checklist
Steps to reproduce
Load a live stream.
Expected behaviour
Player should buffer audio when audio and main track info is available.
What actually happened?
Occasionally,
AUDIO_TRACK_LOADED
is dispatched beforeLEVEL_LOADED
, which means the audio stream controller will ignore the track data because it hasn't received the main level data in order to align the segment start times by PDT. This has the effect of occasionally deferring video playback by a full playlist update period, as no audio is buffered.Currently we are working around this by caching the audio level details on the controller, when
mainDetails
is still null, and just immediately invokingonAudioTrackLoaded
with the data, after receivingLEVEL_LOADED
.In the attached console log, note the player is idle (with no playback occurring) for approximately six seconds between 2022-04-04 09:30:08.028 and 2022-04-04 09:30:13.736, until the next audio track playlist is fetched.
Console output
Chrome media internals output
No response