axiomatic-systems / Bento4

Full-featured MP4 format, MPEG DASH, HLS, CMAF SDK and tools
http://www.bento4.com
1.96k stars 478 forks source link

How to encode fragment mp4 (fmp4) used H.264/aac frame by Bento4 #277

Open 1OliverReed opened 6 years ago

1OliverReed commented 6 years ago

Hi everyone I read Bento4 source code, and I know that mp4 file can be covert fmp4 by cmd "mp4fragment" , but I want to use h264 and aac frame encode fmp4 directly, the source code is very complicated

barbibulle commented 6 years ago

The ‘mp4mux’ tool does that (produce an mp4 file directly from elementary streams)

1OliverReed commented 6 years ago

Hi Barbibulle: Thanks for your comment, I had read 'mp4mux'. Emm, I follow the command " ./mp4mux --track h264:test2.h264#frame_rate=20.0 --track aac:test3.aac outTest.mp4 ";

It's works by video player. However, I read the mp4 file structure by a tool called MP4info, the mp4 file is just a nomal mp4. It is not fragmented mp4 structre. So How should I do ?