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

Extend support for ISO/IEC base media format #330

Merged
merged 1 commit into from
May 15, 2021

Conversation

contradict
Copy link
Contributor

MP4 files are often encoded using this format, the first 4 bytes are a
box length and should not be part of the file identity magic.

MP4 files are often encoded using this format, the first 4 bytes are a
box length and should not be part of the file identity magic.
@codecov
Copy link

codecov bot commented May 6, 2021

Codecov Report

Merging #330 (259fe10) into master (f2d16a5) will increase coverage by 0.09%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #330      +/-   ##
==========================================
+ Coverage   88.01%   88.11%   +0.09%     
==========================================
  Files          10       10              
  Lines         626      631       +5     
==========================================
+ Hits          551      556       +5     
  Misses         75       75              
Impacted Files Coverage Δ
src/registry.jl 90.84% <100.00%> (+0.30%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f2d16a5...259fe10. Read the comment docs.

@johnnychen94 johnnychen94 mentioned this pull request May 13, 2021
5 tasks
Copy link
Member

@johnnychen94 johnnychen94 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No objections but would be better to have @IanButterworth double-check it.

Comment on lines +194 to +197
Detect ISO/IEC 14496-12 ISO/IEC base media format files. These files start with
a 32-bit big-endian length, and then the string 'ftyp' which is followed by
details of the container and codec. Finding 'ftyp' is enough to know to dispatch
to VideoIO.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Finding 'ftyp' is enough to know to dispatch to VIdeoIO

I'm not an expert on video formats. Are there any references for this that can help me/others to clarify this?

Copy link
Contributor Author

@contradict contradict May 14, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not an expert either, I used these three references to come to this conclusion:
Wikipedia has a readable introduction: https://en.wikipedia.org/wiki/ISO/IEC_base_media_file_format#File_type_box

There is a publicly available version of the spec here: https://standards.iso.org/ittf/PubliclyAvailableStandards/c068960_ISO_IEC_14496-12_2015.zip
Section 4.3.1 is the relevant part I think.

As a check, I compared to the C++ code here: https://github.com/DigiDNA/ISOBMFF

@johnnychen94 johnnychen94 merged commit 7228f88 into JuliaIO:master May 15, 2021
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.

2 participants