ffmpeg水印处理非常慢 [英] ffmpeg watermarking processing is very slow

查看:264
本文介绍了ffmpeg水印处理非常慢的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在做一个视频处理项目,并使用ffmpeg进行水印处理.我完全达到了我想要的目标,但是问题是过程非常缓慢.

I am working on a video processing project and using ffmpeg for watermarking. I achieve exactly what i want but the problem is that the process is very very slow.

我在32位操作系统Microsoft Windows-8和64位CPU上使用具有4GB RAM的Intel Smart第二代家族Core-i5处理器.

I am using a Intel Smart 2nd gen family Core-i5 Processor with 4GB RAM on a 32 bit operating system Microsoft Windows-8 on a 64-bit CPU.

我尝试为长度为1:30分钟的视频[mp4]加水印.文件大小为1.5GB

I tried watermarking a video [mp4] of length 1:30 Min. size of file is 1.5GB

整个过程需要3小时才能为我的视频文件加水印,而过程中我注意到的是ffmpeg首先每秒处理28帧,然后再减慢到每秒20帧.正常的人类观看视频,其帧速率为每秒30帧,并且处理速度甚至更慢,这就是为什么要花更多时间[3小时]而不是视频本身的实际长度[1:33]

Whole process accomplish in 3 Hrs to watermark my video file and what i noticed while process is that ffmpeg was processing 28 frames per sec first and then later it slow down up to 20 frames per second. a normal human watch video with frame rate of 30 frame per second and process was even slower then this that's why it took more time [3 Hrs] then the actual length of video itself [1:33]

我认为使流程高效的是使用ffmpeg水印源代码并对其进行一些修改...

What i think to make process efficient is to use ffmpeg Watermarking Source Code and modify it somewhat...

我想问一下是否有人通过其他任何方式实现了快速水印,或者为了节省时间而修改了此代码以实现更快的处理...

I want to ask if someone have achieve fast watermarking before by any other way or have modified this code to achieve faster process in order to save my time...

推荐答案

要加快速度,您可以尝试跳过中间帧,例如如果该数字没有创建flickr,则在下一个第5帧上应用水印

To speed up you might try to skip middle frames like apply watermark on next 5th frame if that number dont create flickr

这篇关于ffmpeg水印处理非常慢的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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