Vidstack llhls with Preload Hint#96
Merged
Merged
Conversation
989c6f5 to
21617ca
Compare
Member
|
Works great, thanks a lot for the PR & demo! |
samrat
reviewed
Sep 22, 2024
| this.player.src = opts.url; | ||
|
|
||
| this.player.addEventListener("provider-change", (event) => { | ||
| const provider = event.detail; |
There was a problem hiding this comment.
Sorry for commenting on a closed PR, but trying to understand how this works.
Since provider goes out of scope in line 241, does setting the target latency have any effect?
Maybe I'm missing something, but AFAICT, this event listener doesn't do anything.
There was a problem hiding this comment.
Ah, I think I understand: the listener is being passed a reference to the MediaProviderAdapter which this function mutates.
lastcanal
added a commit
to lastcanal/tv
that referenced
this pull request
Dec 7, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR vendors and activates (via Vidstack) the feature/preload-hint branch of HLS.js that implements
X-PRELOAD-HINT.Even though
X-PRELOAD-HINTis supported by the Pipeline, the default setup of Vidstack does not exercise any of the preload hint code. This change will prevent stalls by moving the parsing of manifests and connection negotiation for new segments out of the 'critical path' of requesting new segments from the network.Here is a demo showing the difference between Vidstack's default implementation and Vidstack with the
feature/preload_hintbranch of HLS.js. You'll notice in the waterfall for the new version that requests for partial segments are held open until the segment is ready, instead of waiting to parse the new manifest before requesting the segment.Screencast.from.2024-09-16.17-21-36.webm
/claim #91