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

MP4Demuxer probe fix for large "emsg" payloads #5852

Merged
merged 1 commit into from
Sep 26, 2023

Conversation

robwalch
Copy link
Collaborator

@robwalch robwalch commented Sep 26, 2023

This PR will...

Remove 16kB constraint on "moof" offset when probing segments to detect fmp4.

Why is this Pull Request needed?

Segments with large or many emsg boxes can push the moof box offset to much further out in the segment. This is not uncommon for media carrying image data over id3 emsg.

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

Added a new method optimized to exit on the first moof box found and skip quickly over others. When testing how this worked with TS and unwrapped audio the method tended to exit after first iteration because size was out of bounds (which is good).

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

…ct fmp4

(Required for segments with large or many emsg boxes)
@robwalch
Copy link
Collaborator Author

CC @nicoweilelemental

@robwalch robwalch added this to the 1.5.0 milestone Sep 26, 2023
@robwalch robwalch merged commit 1f2a7b0 into master Sep 26, 2023
15 of 16 checks passed
@robwalch robwalch deleted the bugfix/mp4-probe-remove-moof-offset-constraint branch September 26, 2023 23:37
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.

None yet

1 participant