ffmpeg裁剪媒体文件:
ffmpeg -i in.mp4 -copyts -ss 00:10:00 -to 00:15:00 -map 0 -c copy out.mp4
ffmpeg合并媒体文件:
- 创建要合并的文件清单vlist.txt,写入:
file '/path/to/video1.mp4'
file '/path/to/video2.mp4'
file '/path/to/video3.mp4'
- ffmpeg -f concat -safe 0 -i vlist.txt -c copy output.mp4
(经测试,参数顺序会影响命令执行)
参考 :
https://stackoverflow.com/questions/49371422/how-to-merge-two-videos-without-re-encoding
https://www.cnblogs.com/feipeng8848/p/9601103.html
No comments:
Post a Comment