將webm格式轉換為gif

ubuntu自帶錄屏,默認保存為webm格式。

根據這裏的敍述,可通過以下方法把webm轉為gif:

ffmpeg -y -i input.webm -vf palettegen palette.png
ffmpeg -y -i input.webm -i palette.png -filter_complex paletteuse -r 10 output.gif

如果沒有ffmpeg,用apt裝一個也是很快的。

同時,https://ezgif.com/video-to-gif在線轉換也是可以的,不過由於網路原因可能會慢一些。並且在線轉換有個奇怪的限寬,最寬是800px。

Leave a Comment