如何将视频转化为Gif

  1. Table of Contents
  2. How to convert .mov or .mp4 to .gif using the command line
    1. How to convert

编写进度

Table of Contents

  1. How to convert .mov or .mp4 to .gif using the command line
    1. How to convert

How to convert .mov or .mp4 to .gif using the command line

Requirements

brew install ffmpeg
brew install gifsicle

How to convert

ffmpeg -i in.mov -s 600x400 -pix_fmt rgb24 -r 10 -f gif - | gifsicle --optimize=3 --delay=3 > out.gif

Arguments:

-r 10 to reduce the frame rate from 25 fps to 10 fps
-s 600x400 to determine the output size.
--delay=3 to have a delay of 30ms between each gif
--optimize=3 to use the most file-size optimized algorithm

转载请注明来源,欢迎对文章中的引用来源进行考证,欢迎指出任何有错误或不够清晰的表达。可以在下面评论区评论,也可以邮件至 askding@qq.com

💰

×

Help us with donation