-
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
Manifest with different subtitle track order than existing video TextTracks breaks caption display and selection #4571
Comments
Hi @SivanA-Kaltura Lines 340 to 376 in 492a103
|
Thanks @mtoczko. Since hls.js reuses text tracks in timeline-controller, this could be resolved by mapping a video element track index to a manifest track index, or by allowing track selection by name/label and not by index, but it's a design decision whether to fix or to leave as a limitation. |
Tested this against v1.2.9 and found another issue. The first HLS produces an English TextTrack of kind "captions" but the second HLS expects one of kind "subtitles". This may be a regression introduced after this issue was reported, made to match the track kind values produced by Safari. Please have a look at how the change in this branch changes the outcome: https:/video-dev/hls.js/compare/bugfix/texttrack-reuse-mixed-kind. HLS.js will respond to TextTrack state changes so that track selection can be performed in the DOM or on the HTMLMediaElement. The state of reused tracks or a change made in setup may be overriding the default HLS subtitles for a new player instance > loadSource. If video element reuse and native TextTrack rendering and selection is something you need, please consider contributing a fix. If not, the |
@robwalch do you think this issue will have a fix in upcoming versions? |
Would Kaltura be willing to contribute a fix? |
Hi @giladna and @SivanA-Kaltura, #5371 is a start. Sorry I spoke too soon. The issue with default track selection is just the tip of the iceberg. |
…abling and find match when indexes do not align #4571
…abling and find match when indexes do not align #4571
…abling and find match when indexes do not align #4571
…enabling and find match when indexes do not align - Reset default subtitle track selection on manifest loading and do not disable on detach Fixes #4571
…enabling and find match when indexes do not align - Reset default subtitle track selection on manifest loading and do not disable on detach Fixes #4571
…enabling and find match when indexes do not align - Reset default subtitle track selection on manifest loading and do not disable on detach Fixes #4571
…ons TextTrack rather than subtitleTrack index Resolves #4571
…ons TextTrack rather than subtitleTrack index Resolves #4571
…ed TextTracks (#5880) * Use subtitle track name and language to find and match subtitle/captions TextTrack rather than subtitleTrack index Resolves #4571 * Fix regression in dev where AUDIO_TRACKS_UPDATED is re-dispatched with zero tracks Allow selection of audioTrack on AUDIO_TRACKS_UPDATED (overriding default selection - Resolves #5831) Cleanup selection of subtitleTrack on SUBTITLE_TRACKS_UPDATED (overriding default selection) * Fix TextTrack use with ASSOC-LANGUAGE Match the initial default/forced/autoselect choice made when playing HLS in Safari
What version of Hls.js are you using?
1.1.5
What browser (including version) are you using?
Chrome 98.0.4758.102 (x86_64)
What OS (including version) are you using?
macOS Big Sur
Test stream
https://codepen.io/sivana-kaltura/pen/oNoqwba
Configuration
Additional player setup steps
No response
Checklist
Steps to reproduce
Expected behaviour
English captions are showing in both videos.
What actually happened?
English captions are not showing in second video.
Some additional information after debugging:
In manifest 1, english is at index 0 and swedish is at index 1
In manifest 2, german is at index 0 and english is at index 1
and video element.textTracks[1].mode="showing" (swedish)
this.textTracks[1].mode and because its "disabled", no cues are appended
Console output
It's over the max length limit :(
Chrome media internals output
No response
The text was updated successfully, but these errors were encountered: