从 MP4/FLV 中提取帧? [英] Extracting frames from MP4/FLV?

查看:64
本文介绍了从 MP4/FLV 中提取帧?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道使用 FFMPEG 是可能的,但是如果我有部分文件(例如没有开头和结尾)该怎么办.是否可以从中提取一些帧?

I know it's possible with FFMPEG, but what to do if I have a partial file (like without the beginning and the end). Is is possible to extract some frames from it?

推荐答案

命令

ffmpeg -ss 00:00:25 -t 00:00:00.04 -i YOURMOVIE.MP4 -r 25.0 YOURIMAGE%4d.jpg

将提取帧

  • 从 25 秒开始 [-ss 00:00:25]
  • 在 0.04 秒后停止 [-t 00:00:00.04]
  • 从输入文件 YOURMOVIE.MP4 中读取
  • 每秒仅使用 25.0 帧,即e.每 1/25 秒一帧 [-r 25.0]
  • 作为名称为 YOURIMAGE%04d.jpg 的 JPEG 图像,其中 %4d 是带有前导零的 4 位自动递增数字

在应用选项 [-r] 之前检查电影的帧速率,同样适用于 [-t],除非您想以自定义速率提取帧.

Check you movie for the framerate before applying option [-r], same applicable for [-t], unless you want to extract the frames with the custom rate.

不过,从未尝试过使用裁剪(损坏?)的输入文件进行此操作.值得一试.

Never tried this with the cropped (corrupted?) input file though. Worth to try.

这篇关于从 MP4/FLV 中提取帧?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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