ffmpeg

版本

ffmpeg version N-89803-g856b7cae9f Copyright (c) 2000-2018 the FFmpeg developers
  built with gcc 7.2.0 (GCC)
  configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-bzlib --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-amf --enable-cuda --enable-cuvid --enable-d3d11va --enable-nvenc --enable-dxva2 --enable-avisynth --enable-libmfx
  libavutil      56.  7.100 / 56.  7.100
  libavcodec     58.  9.100 / 58.  9.100
  libavformat    58.  3.100 / 58.  3.100
  libavdevice    58.  0.100 / 58.  0.100
  libavfilter     7. 11.101 /  7. 11.101
  libswscale      5.  0.101 /  5.  0.101
  libswresample   3.  0.101 /  3.  0.101
  libpostproc    55.  0.100 / 55.  0.100

用法

ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}...

获取帮助

-h              -- 输出基本选项
-h long         -- 输出更多的选择
-h full         -- 输出所有选项(包括所有格式和编码特定的选项,很长)
-h type=name    -- 输出所有选项指定的decoder/encoder/demuxer/muxer/filter

获取 帮助/信息/功能

-L                  show license
-h topic            show help
-? topic            show help
-help topic         show help
--help topic        show help
-version            show version
-buildconf          show 构建配置
-formats            show available 格式
-muxers             show available 复用器
-demuxers           show available 解复用器
-devices            show available 设备
-codecs             show available 编解码器
-decoders           show available 解码器
-encoders           show available 编码器
-bsfs               show available 位流过滤
-protocols          show available 协议
-filters            show available 过滤器
-pix_fmts           show available 像素格式 
-layouts            show 标准的渠道布局
-sample_fmts        show available 音频样本格式
-colors             show available 色彩名称 
-sources device     list sources of the input device
-sinks device       list sinks of the output device
-hwaccels           show available HW加速度方法

全局选项 (影响整个程序,而不是一个文件)

-loglevel loglevel              设置日志级别
-v loglevel                     设置日志级别
-report                         生成一个报告
-max_alloc bytes                设置一个单独分配的块的最大大小
-y                              覆盖输出文件
-n                              不覆盖输出文件
-ignore_unknown                 忽略未知的流类型
-filter_threads                 过滤线程数(非复数)
-filter_complex_threads         过滤线程数(复数)
-stats                          在编码过程中打印进度报告
-max_error_rate ratio of errors 最大错误率(0.0:没有错误,1.0:100%错误)
-bits_per_raw_sample number     设置每个原始样本的比特数
-vol volume                     改变音频音量(256=normal)

每个文件的主要选项:

-f fmt                  强制格式
-c codec                编解码器名称 
-codec codec            编解码器名称
-pre preset             预设的名称
-map_metadata outfile[,metadata]:infile[,metadata]  
                        从infile中设置outfile的元数据信息
-t duration             记录或转码 "duration" seconds of audio/video
-to time_stop           录或转码停止时间
-fs limit_size          设置文件大小的上限(字节)
-ss time_off            设置开始时间偏移量
-sseof time_off         设置起始时间偏移量相对于EOF
-seek_timestamp         启用/禁用 seeking by timestamp with -ss
-timestamp time         设置记录时间戳('now'来设置当前时间)
-metadata string=string 添加元数据
-program title=string:st=number...      
                        添加指定流的程序
-target type            指定目标文件类型 ("vcd", "svcd", "dvd", "dv" or "dv50" with 可选的前缀 "pal-", "ntsc-" or "film-")
-apad                   音频垫
-frames number          将帧数设置为输出
-filter filter_graph    设置流的过滤图
-filter_script filename 从文件中读取流过滤图描述
-reinit_filter          对输入参数的改变进行重新初始化
-discard                discard
-disposition            disposition

视频选项

-vframes number     将视频帧的数量设置为输出
-r rate             设置帧速率 (Hz值,分数或abbreviation)
-s size             设置帧大小 (WxH or abbreviation)
-aspect aspect      设置长宽比 (4:3, 16:9 or 1.3333, 1.7777)
-bits_per_raw_sample number  设置每个原始样本的比特数
-vn                 禁用视频
-vcodec codec       强加视频编解码器 ('copy' to copy stream)
-timecode hh:mm:ss[:;.]ff  设置初始时间码值.
-pass n             选择通过数量 (1 to 3)
-vf filter_graph    设置视频过滤器
-ab bitrate         声频码率 (please use -b:a)
-b bitrate          视频码率 (please use -b:v)
-dn                 禁用数据

音频选项

-aframes number    将音频帧的数量设置为输出
-aq quality        设置音频质量 (codec-specific)
-ar rate           设置音频采样率 (in Hz)
-ac channels       设置音频信道数
-an                禁用音频
-acodec codec      强加音频编解码器 ('copy' to copy stream)
-vol volume        改变音频音量(256=normal)
-af filter_graph   设置音频过滤器

字幕选项

-s size             设置帧大小 (WxH or abbreviation)
-sn                 用副标题
-scodec codec       force 副标题编解码器 ('copy' to copy stream)
-stag fourcc/tag    force 副标题 tag/fourcc
-fix_sub_duration   修正字幕时间
-canvas_size size   设置画布大小 (WxH or abbreviation)
-spre preset        将字幕选项设置为指定的预设值
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值