ffmpeg: Combine/merge multiple mp4 videos not working, output only contains the first video

前端 未结 10 880
逝去的感伤
逝去的感伤 2020-12-22 22:48

Here is the command I am using to combine multiple videos:

ffmpeg -i 75_540_38HQ2.mp4 -i 76_70_20.mp4 -i 76_173_80.mp4 -i 81_186_35.mp4 -vcodec copy -acodec copy M         


        
10条回答
  •  Happy的楠姐
    2020-12-22 23:01

    Assuming you want to concatenate the movie, you can use the following command:

    ffmpeg -f concat -i inputs.txt -vcodec copy -acodec copy Mux1.mp4
    

    With the following text in inputs.txt:

    file 75_540_38HQ2.mp4 
    file 76_70_20.mp4 
    file 76_173_80.mp4
    file 81_186_35.mp4
    

    Note: some distributions (like Ubuntu) do not have ffmpeg in their repository and instead define ffmpeg to be an alias of avconv. This won't work with avconv, so in such a case you have to compile ffmpeg yourself. You can check whether you have the real ffmpeg by running ffmpeg and checking if the first output line ends with "the FFmpeg developers".

提交回复
热议问题