使用 ffmpeg 进行 GPU 加速的视频处理 [英] GPU-accelerated video processing with ffmpeg

查看:48
本文介绍了使用 ffmpeg 进行 GPU 加速的视频处理的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用 ffmpeg 通过 NVIDIA GPU 加速视频编码和解码.

I want to use ffmpeg to accelerate video encode and decode with an NVIDIA GPU.

来自 NVIDIA 网站:

NVIDIA GPU 包含一个或多个基于硬件的解码器和编码器(独立于 CUDA 内核),可为多种流行的编解码器提供完全加速的基于硬件的视频解码和编码.解码/编码卸载后,图形引擎和 CPU 可用于其他操作.

NVIDIA GPUs contain one or more hardware-based decoder and encoder(s) (separate from the CUDA cores) which provides fully-accelerated hardware-based video decoding and encoding for several popular codecs. With decoding/encoding offloaded, the graphics engine and the CPU are free for other operations.

我的问题是:我可以使用 CUDA 内核编码和​​解码视频吗,也许更快?

My question is: can I use CUDA cores to encode and decode video, maybe faster?

推荐答案

FFmpeg 提供了一个硬件加速子系统,其中包括 NVIDIA:https://trac.ffmpeg.org/wiki/HWAccelIntro

FFmpeg provides a subsystem for hardware acceleration, which includes NVIDIA: https://trac.ffmpeg.org/wiki/HWAccelIntro

为了支持使用 NVIDIA GPU 进行 GPU 辅助编码,您需要:

In order to enable support for GPU-assisted encoding with an NVIDIA GPU, you need:

  • A ​supported GPU
  • Supported drivers for your operating system
  • The NVIDIA Codec SDK
  • ffmpeg configured with --enable-nvenc (default if the drivers are detected while configuring)

这篇关于使用 ffmpeg 进行 GPU 加速的视频处理的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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