Windows FFmpeg/libav using NVIDIA GPUs

17 篇文章 0 订阅

FFmpeg GPU HW-Acceleration Support Table

 

 FermiKeplerMaxwell
(1st Gen)
Maxwell
(2nd Gen)
Maxwell
(GM206)
PascalVoltaTuringAmpere
H.264 encodingN/AFFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v4.2
FFmpeg
v4.2
FFmpeg
v4.2
HEVC encodingN/AN/AN/AFFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v4.2
FFmpeg
v4.2
FFmpeg
v4.2
MPEG2, MPEG-4, H.264 decodingFFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v4.2
FFmpeg
v4.2
FFmpeg
v4.2
HEVC decodingN/AN/AN/AN/AFFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v4.2
FFmpeg
v4.2
FFmpeg
v4.2
VP9 decodingN/AN/AN/AFFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v3.3
FFmpeg
v4.2
FFmpeg
v4.2
FFmpeg
v4.2

For guidelines about NVIDIA GPU-accelerated video encoding/decoding performance, please visit the Video Codec SDK page for more details.

 


 

Getting Started with FFmpeg/libav using NVIDIA GPUs

 

Using NVIDIA hardware acceleration in FFmpeg/libav requires the following steps

  • Download and install ffnvcodec:
    git clone https://git.videolan.org/git/ffmpeg/nv-codec-headers.git
    cd nv-codec-headers && sudo make install && cd –
  • Download the latest FFmpeg or libav source code, by cloning the corresponding GIT repositories
  • FFmpeg: https://git.ffmpeg.org/ffmpeg.git
  • Libav: https://github.com/libav/libav
  • Download and install the compatible driver from NVIDIA web site
  • Download and install the CUDA Toolkit CUDA toolkit
  • Use the following configure command (Use correct CUDA library path in config command below)
    ./configure --enable-cuda-sdk --enable-cuvid --enable-nvenc --enable-nonfree --enable-libnpp
    --extra-cflags=-I/usr/local/cuda/include --extra-ldflags=-L/usr/local/cuda/lib64
  • Use the following command to compile: make -j 10
  • Use FFmpeg/libav binary as required. To start with FFmpeg, try the below sample command line for 1:2 transcoding
    ffmpeg -y -hwaccel cuvid -c:v h264_cuvid -vsync 0 -i <input.mp4> -vf scale_npp=1920:1072
    -vcodec h264_nvenc <output0.264> -vf scale_npp=1280:720 -vcodec h264_nvenc <output1.264>

For more information on FFmpeg licensing, please see this page. For more information on the build process, and on building for windows, please see the Using FFmpeg with NVIDIA GPU Hardware Acceleration guide.

 

链接:https://developer.nvidia.com/ffmpeg

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值