在 linux 上将 gif 动画转换为 avi [英] Animated gif to avi on linux

查看:37
本文介绍了在 linux 上将 gif 动画转换为 avi的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有什么方法可以在 Linux 上将 gif 动画转换为视频格式(例如 .avi)?

Is there any way to convert an animated gif to a video format (e.g. .avi) on Linux?

我已经试过了

ffmpeg -i thegif.gif thevideo.avi

但我得到的只是视频的第一张图片.

but all I get is the first image of the video.

推荐答案

我可以建议将 imagemagick 和 ffmpeg 结合起来

I can suggest combination of imagemagick and ffmpeg

这样做以将每一帧提取为 png/jpeg

do this to extract each frame as png/jpeg

$magick> convert 'images.gif[0]' image.png

这样做可以将图像转换为电影序列

Do this to convert images to movie sequence

ffmpeg -f image2 -i image%d.jpg video.mpg

有关命令的更多帮助

http://www.imagemagick.org/script/command-line-处理.php

http://www.catswhocode.com/blog/19-ffmpeg-commands-for-all-needs

http://electron.mit.edu/~gsteele/ffmpeg/

这篇关于在 linux 上将 gif 动画转换为 avi的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆