使用FFmpeg从大电影创建缩略图花费的时间太长 [英] create thumbnails from big movies with FFmpeg takes too long
本文介绍了使用FFmpeg从大电影创建缩略图花费的时间太长的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用此shell命令在123秒内从VIDEO_FILE制作缩略图并将其保存到THUMBNAIL_FILE.
I'm using this shell command to make thumbnail from VIDEO_FILE from 123 second and save it to THUMBNAIL_FILE.
ffmpeg -i VIDEO_FILE -r 1 -ss 123 -f image2 THUMBNAIL_FILE
它可以工作,但是对于大型电影来说确实很慢.有什么方法可以使其更快一点吗?
It works, but it is really slow for big movies. Is there any way to make it a little faster?
推荐答案
我也遇到了这种情况,更改参数顺序可以解决此问题. 在1.4GB的90分钟mp4视频上进行了测试-大约需要1-2秒.在那之前花了MINUTES ...
it has happened to me also, changing the argument order fixes this problem. tested on a 1.4GB 90 minute mp4 video - took about 1-2 seconds. before that it took MINUTES...
尝试一下:
ffmpeg -ss 123 -i "VIDEO_FILE" "THUMBNAIL_FILE" -r 1 -vframes 1 -an -vcodec mjpeg
这篇关于使用FFmpeg从大电影创建缩略图花费的时间太长的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文