ffmpeg 转换x264到Fragmented MP4

来源:互联网 发布:帝国cms仿站视频下载 编辑:程序博客网 时间:2024/05/17 01:07
ffmpeg -re -i d:\test.264 -g 52 -acodec libvo_aacenc -ab 64k -vcodec libx264 -vb 448k -f mp4 -movflags frag_keyframe+empty_moov d:\output.mp4
D:\ffmpeg\bin>ffmpeg -i d:\test.264 -g 52 -vcodec copy -f mp4 -movflags frag_keyframe+empty_moov d:\output.mp4
  • frag_keyframe 导致碎片输出,
  • empty_moov将导致输出100%分段; 没有这个,第一个片段将被多路复用为短片(使用moov),其后是片段中的其余媒体,
  • -re 在实时流传输(在媒体比特率上输出)时很有用,如果您正在创建文件,不要使用它,
  • -g 52 强制(至少)每第52帧作为关键帧
ismv muxer AVOptions:-movflags          <flags> E.... MOV muxer flags   rtphint                 E.... Add RTP hint tracks   empty_moov              E.... Make the initial moov atom empty (not supported by QuickTime)   frag_keyframe           E.... Fragment at video keyframes   separate_moof           E.... Write separate moof/mdat atoms for each track   frag_custom             E.... Flush fragments on caller requests   isml                    E.... Create a live smooth streaming feed (for pushing to a publishing point)-moov_size         <int>   E.... maximum moov size so it can be placed at the begin-rtpflags          <flags> E.... RTP muxer flags   latm                    E.... Use MP4A-LATM packetization instead of MPEG4-GENERIC for AAC   rfc2190                 E.... Use RFC 2190 packetization instead of RFC 4629 for H.263   skip_rtcp               E.... Don't send RTCP sender reports-skip_iods         <int>   E.... Skip writing iods atom.-iods_audio_profile <int>  E.... iods audio profile atom.-iods_video_profile <int>  E.... iods video profile atom.-frag_duration     <int>   E.... Maximum fragment duration-min_frag_duration <int>   E.... Minimum fragment duration-frag_size         <int>   E.... Maximum fragment size-ism_lookahead     <int>   E.... Number of lookahead entries for ISM files

0 0
原创粉丝点击