Skip to content
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

Update ID3 cues to span until playlist end, or next cue with same tag type (value.key) on cue append #4719

Merged
merged 1 commit into from
Jul 11, 2022

Conversation

robwalch
Copy link
Collaborator

@robwalch robwalch commented Jun 2, 2022

This PR will...

Update ID3 cues in timed metadata text tracks to span until the playlist end or until the start of the next cue with the same frame type.

Why is this Pull Request needed?

This change improves the handling of ID3 metadata for applications using metadata TextTrack active cues. Since ID3v2 frames have no duration or end time, cues should remain active until the HLS playlist's end or until another cue with the same ID3 frame type begins.

Are there any points in the code the reviewer needs to double check?

In Safari, DataCues are assigned an endTime of Infinity, but since HLS.js may use VTTCues, which must have finite start and end times, the current playlist end time was chosen to keep the number of active cues manageable. Applications wishing to modify the default endTime of new cues may do so on "cuechange".

Resolves issues:

Resolves #3879

Checklist

  • changes have been done against master branch, and PR does not conflict
  • new unit / functional tests have been added (whenever applicable)
  • API or design changes are documented in API.md

@gkatsev
Copy link
Member

gkatsev commented Jun 2, 2022

Technically, a VTTCue is no longer needs to be bounded, as of w3c/webvtt#493. But it doesn't seem like this rolled out into any browser yet. Though, choosing the max time seems reasonable as an alternative.

@robwalch robwalch added this to the 1.2.0 milestone Jun 24, 2022
@robwalch robwalch merged commit 121558f into master Jul 11, 2022
@robwalch robwalch deleted the bugfix/id3-timedmetadata-cue-range branch July 11, 2022 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

miss cuechange event at id3 timed-metadata textTrack
2 participants