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

[DRAFT] Mark fragments with empty appends with gap #6218

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

robwalch
Copy link
Collaborator

@robwalch robwalch commented Feb 15, 2024

This PR will...

  • Mark fragments with empty appends with gap
  • Find first keyframe in video fmp4 and detect non-independent segments and transmux results for mp4
  • Error on empty append and on non-independent fragment parsing (backtrack handler)

Why is this Pull Request needed?

mp4 segments missing IDR frames at the start will result in nothing added to the buffer after first append.

Frag parsing error events resolve with a level switch which can result in an alternative to media missing an IDR.

HLS mp4 segments should always start with an IDR frame (ISO BMFF) so warning when that is not the case and it is expected to result in gaps (non-contiguous append) will help to identify bad HLS assets.

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

Backtracking was tuned to work with the TS pipeline (primarily muxed content). It won't always find the ideal candidate. Erroring helps if there are alternatives, but if there are none HLS.js may still end up loop loading around gaps.

Relates to:

Resolves issues:

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

@robwalch robwalch marked this pull request as draft February 16, 2024 20:07
@robwalch robwalch changed the title Mark fragments with empty appends with gap [DRAFT] Mark fragments with empty appends with gap May 3, 2024
@robwalch
Copy link
Collaborator Author

robwalch commented May 3, 2024

CC @cmugla (in case there is an ask for non-gop fragmented mp4 samples)

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.

1 participant