mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-29 06:15:24 +00:00
2b5e8c86a6
The old code was trying to save time by only scanning until the first "mdat" (the encoded data for all the frames) and first "moov" (track headers etc.) atoms were found. If a "moof" (for segmented headers in MP4 DASH) atom was found during that scan, it switched to scanning all top level atoms in order to find all other "moof" atoms. However, there are DASH files where the first "moof" atom is located behind the first "mdat" and "moov" atoms. Reading such a file mkvmerge aborted its top-level atom scan before encountering the "moof" atom and therefore never switched to DASH mode. The result was that only a small portion of the file was read: as much as was given via the tables in the "moov" atom. The new code does away with that shortcut and always scans all top level atoms. It will therefore switch to DASH mode even if the first "moof" atom is located behind the first "mdat" and "moov" atoms. Part of the fix for #1867.
5 lines
170 B
Ruby
Executable File
5 lines
170 B
Ruby
Executable File
#!/usr/bin/ruby -w
|
|
|
|
describe "mkvmerge / MP4 DASH with first 'moof' atom located behind first 'moov' and 'mdat' atoms"
|
|
test_merge "data/mp4/moof_after_moov_and_mdat.mp4"
|