ffmpeg avfilter小结

来源:互联网 发布:安卓ssr软件 编辑:程序博客网 时间:2024/05/17 04:13

参考雷老师:

filter 视频添加水印log:      http://blog.csdn.net/leixiaohua1020/article/details/29368911


一  filter概念

详细概念描述和官方demo,参考: http://blog.csdn.net/rootusers/article/details/43305387

如下图,filter就是一个容器,通过该容器,av数据会发生一些变化。在ffmpeg的转码过程中filter是最复杂的。多个filter可以构成filterchain,使用逗号分隔;多个filterchain可以构成filtergraph,用分号分隔。filtergraph分为简单和复杂两种。简单的filtergraph通常是可以线形顺序描述的filtergraph,比如下图:

 _______        _____________        _______        ________|       |      |             |      |       |      |        || input | ---> | deinterlace | ---> | scale | ---> | output ||_______|      |_____________|      |_______|      |________|

复杂的filtergraph通常是具有多个输入输出文件,并有多条执行路径。比如下面的例子,

 _________|         || input 0 |\                    __________|_________| \                  |          |             \   _________    /| output 0 |              \ |         |  / |__________| _________     \| complex | /|         |     |         |/| input 1 |---->| filter  |\|_________|     |         | \   __________               /| graph   |  \ |          |              / |         |   \| output 1 | _________   /  |_________|    |__________||         | /| input 2 |/|_________|


二 filter How to

参考翻译官方介绍:  http://blog.yikuyiku.com/?p=3023

0 1
原创粉丝点击