webm to mp4 conversion using ffmpeg

一曲冷凌霜 提交于 2019-11-28 15:53:40
alexbuisson

As your input file report a strange frame rate value 1k fps coming from the tbs and tbr value (look here for their definition)

the encoder generate a different result, 16k tbn, 1k tbc (default)

So by calling :

ffmpeg -fflags +genpts -i 1.webm -r 24 1.mp4

You configure ffmpeg to generate new pts (a/k.a Presentation TimeStamp) for each frame and you set the target frame-rate to 24.

So your output mp4 file info (ffmpeg -i ....) change from

Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 4327 kb/s, 1000.09 fps, 1k tbr, 16k tbn, 2k tbc

to

Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 1670 kb/s, 24 fps, 24 tbr, 12288 tbn, 48 tbc
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!