How do I add a custom thumbnail to a .mp4 file using ffmpeg?

前端 未结 2 609
无人共我
无人共我 2020-11-30 09:29

I am trying to find the proper ffmpeg command to add a .png or .jpg image to a .mp4 video as a thumbnail. The command will eventually automatically be executed by a C# prog

2条回答
  •  忘掉有多难
    2020-11-30 09:58

    As in version 4.2.2...See Section 5.4 in FFmpeg documentation

    To add an embedded cover/thumbnail:

    ffmpeg -i in.mp4 -i IMAGE -map 0 -map 1 -c copy -c:v:1 png -disposition:v:1 attached_pic out.mp4
    

    Not all muxers support embedded thumbnails, and those who do, only support a few formats, like JPEG or PNG.

提交回复
热议问题