Ability to load captions/subtitles from file not listed in the manifest
Created by: malthejorgensen
Is your feature request related to a problem? Please describe. I have a use-case in my company where it's impractical to add captions to the manifest files once they've been produced. We already have a large number of manifest files with no captions listed, since the video is produced first and captions added later. Customers would like to upload captions for these videos in cases where it makes sense.
For that reason, it would be nice to be able to load captions from a source that is not listed in the manifest file.
A similar use case could be the dash.js
sample here: https://reference.dashif.org/dash.js/latest/samples/captioning/caption_vtt.html.
The sample doesn't work since the manifest file it loads lists the captions as an http://
-URL while the page is loaded via https://
. Modern browsers like Chrome will block the request fetching the captions since it's Mixed-Content: Loading a http://
-resource from a https://
-Origin. This is different from my own issue, but can be solved in the same way – by allowing loading of captions from outside the manifest.
Describe the solution you'd like
I'd like for dash.js
to support loading captions from sources not listed in the manifest.
Describe alternatives you've considered Players like Plyr and Video.js fully rely on Dash.js for caption playback, so it's not possible to load external captions that way either.
Additional context I've made a proof-of-concept PR here: https://github.com/Dash-Industry-Forum/dash.js/pull/3573 I'm happy to adjust it to the style and requirements of this project.