-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Buffer hole on level switch #5631
Comments
Any fix available? Current workaround right now is setting a startLevel at 2 for me in the config, but that isn't ideal for slower connections. |
|
I tried with #5806. It addresses the gap in @M-Joyce's sample, but for your example @tvinko, the decode timestamps align perfectly, however the subsequent append still produces a gap.
That's an excellent work-around. |
Can you each confirm whether or not the gap is only present in Chrome? If that's the case please add comments with additional reproduction steps to https://bugs.chromium.org/p/chromium/issues/detail?id=1478681 |
Since this is fairly common in Chrome and the stall behavior in Chrome is bad when crossing gaps, I may consider adding logic to preempt the stall after crossing video TimeRanges with a nudge-seek. |
Just did some testing. Edge: Still freezes As for #5806, is this something I can pull down locally and test myself? Is it part of the dev hls releases? The issue still happens in chrome on hlsjs-dev. |
See the Cloudflare Pages build check Details link |
Tested my issue on https://bugfix-chrome-avc-gaps-m2ts.hls-js-4zn.pages.dev/ and it resolves the freeze. Video continues playing normally, with no or unnoticeable buffer. |
@tvinko, I'll revisit more proactive nudging over video buffer gaps in v1.6. I've done what I could to repair remuxed mp4 fragments before append (#5805, #5806) and prevent overlapping segment selection on switch (#5804) for this next release. Since the symptom involves no rendering of video past the gap / new TimeRange, followed by a stall, we should also look at how dropped frames are measured and consider a combined solution with late append reporting in master...feature/video-buffer-starved |
Related issue and novel workaround w3c/media-source#160 (comment) |
I like "novel workaround" instead of the name I had been using :) |
What version of Hls.js are you using?
1.4.7
What browser (including version) are you using?
Chrome v114.0.5735.198 (Official Build) (arm64)
What OS (including version) are you using?
MacOS
Test stream
https://hlsjs.video-dev.org/demo/?src=https%3A%2F%2Fvz-ced6ec5f-c54.b-cdn.net%2F55d2cc15-6524-48f7-aa7f-677d41d17eb2%2Fplaylist.m3u8&demoConfig=eyJlbmFibGVTdHJlYW1pbmciOnRydWUsImF1dG9SZWNvdmVyRXJyb3IiOnRydWUsInN0b3BPblN0YWxsIjpmYWxzZSwiZHVtcGZNUDQiOmZhbHNlLCJsZXZlbENhcHBpbmciOi0xLCJsaW1pdE1ldHJpY3MiOi0xfQ==
Configuration
Additional player setup steps
No response
Checklist
Steps to reproduce
Expected behaviour
Video doesn't switch on resolution change
What actually happened?
Problem occured only on Chrome. Safari and Firefox are not experiencing this issue.
There is a buffer hole for some reason that starts on 3.921333 second of the video and ends on 3.988
Buffer state:
Duration: 9.215999
Buffered: [0.021333, 3.921333] [3.988, 9.215999]
Seekable: [0, 9.215999]
Played: [0, 9.215999]
Buffer for audio contains:[0, 9.215999]
Buffer for video contains:[0.021333, 3.921333] [3.988, 9.187999]
Dropped frames: 0
Corrupted frames: 0
TTFB Estimate: 5.000
Bandwidth Estimate: 32859297.994
Console output
7.655 | Buffer stalled error
Chrome media internals output
No response
The text was updated successfully, but these errors were encountered: