Skip to content

Add mp4 support

jvoisin requested to merge add_mp4_support into master

Since the mp4 format has some mandatory metadata, I don't know what to do with them. Currently, I'm hiding all the irrelevant/nullified ones, but some are remaining:

$ ./mat2 -s ./tests/data/dirty.cleaned.mp4
[+] Metadata for ./tests/data/dirty.cleaned.mp4:
    CompatibleBrands: ['isom', 'iso2', 'avc1', 'mp41']
    CompressorID: avc1
    GraphicsMode: srcCopy
    HandlerDescription: SoundHandler
    HandlerType: Metadata
    HandlerVendorID: Apple
    MajorBrand: MP4  Base Media v1 [IS0 14496-12:2003]
    MediaHeaderVersion: 0
    MinorVersion: 0.2.0
    MovieDataOffset: 48
    MovieHeaderVersion: 0
    NextTrackID: 3
    PreferredRate: 1
    Rotation: 0
    TimeScale: 1000
    TrackHeaderVersion: 0
    TrackID: 1
    TrackLayer: 0

I'm a bit afraid that users will think that this is a bug, since mat2 is supposed to remove metadata; but on the other hand, I'm not comfortable hiding scary values like "HandlerVendorID: Apple", even if it's only ffmpeg using funky "default" values.

Thoughts?

Merge request reports

Loading