-
Notifications
You must be signed in to change notification settings - Fork 428
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
feat: support MPD.Location #926
Conversation
Are we supposed to use Location as the new baseUrl as well, if a baseUrl isn't provided? |
Seems like handleManifestRedirect seems to make those streams work without requiring this change, so, we'll want to get another stream to test that we actually make subsequent requests appropriately. |
OK, I've confirmed this does the right thing and requests the updates from the MPD.Location. I did so by grabbing https://livesim.dashif.org/livesim/startrel_-60/stoprel_-20/timeoffset_0/testpic_2s/Manifest.mpd locally, adding an MPD.BaseURL with the same url as MPD.Location. I also added a minimumUpdatePeriod so that we request updates to the manifest. I can confirm that when MPD.Location is present, it'll make requests there instead of localhost. |
Tests will start passing once mpd-parser is updated and released. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
src/dash-playlist-loader.js
Outdated
this.master = updatedManifest; | ||
|
||
// if locations isn't set or is an empty array, exist early | ||
if (!this.master.locations || this.master.locations && !this.master.locations.length) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this just be !this.master.locations || !this.master.locations.length
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let me check. I thought I tried this and it was showing an error but I may have tried it with &&
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, I think I had &&
locally. with ||
seems to work.
Co-authored-by: Brandon Casey <[email protected]>
Co-authored-by: Garrett Singer <[email protected]>
Depends on videojs/mpd-parser#102
With it, I can see that we properly update the srcUrl internally based on the location, for example with a stream like https://livesim.dashif.org/livesim/startrel_-20/stoprel_20/timeoffset_0/testpic_2s/Manifest.mpd
TODO