videoffmpegmp4video-conversion

ffmpeg how to convert an existing mp4 to mpeg-4 part 14?


I need a video to comply with the following specifications

I cannot get to work. So far I have tried the following:

ffmpeg -i input.mp4 -c:v libx264 -aspect 16:9 -crf 18 -vf "scale=iw*min(1280/iw\,720/ih):ih*min(1280/iw\,720/ih),pad=1280:720:(1280-iw)/2:(720-ih)/2" -fpsmax 60 -preset ultrafast -c:a aac -b:a 128k -ac 1 -pix_fmt yuv420p -movflags +faststart -t 59 -y output.mp4

I always end up with MPEG-4 Part 10.


Solution

  • MPEG-4 Part 10 is a video codec (H.264 a.k.a. AVC).

    MPEG-4 Part 14 is a container specification. In your requirement source (looks to be IG), it's almost certainly a typo or misunderstanding by the author. Very few consumers require (or can parse) part 14 and will usually work with Part 12 also called ISO BMFF, which is what your command generates.

    There are a couple other requirements that your command does not enforce.

    -use_editlist false for no edit lists
    -ar 48000 for 48khz sample rate maximum, in case it's higher.

    Finally, you can add -brand mp42 to pretend the file is MPEG-4 Part 14.