kkroening / ffmpeg-python

Python bindings for FFmpeg - with complex filtering support
Apache License 2.0
9.82k stars 880 forks source link

Would this package support CUDA hardware acceleration SDK, like NVEnc and NVDec back-end? #133

Open oscarriddle opened 5 years ago

oscarriddle commented 5 years ago

Hi,

FFmpeg is supposed to support NVIDIA CUDA CODEC SDK, please refer to https://developer.nvidia.com/FFmpeg So I wonder whether this wrapper also support the GPU back-end encode and decode? I believe it'll be extremely useful.

Thanks,

153957 commented 5 years ago

From the linked page:

… it’s simply a matter of compiling FFmpeg binary with the required support for NVIDIA libraries and using the resulting binaries to speed up video encoding/decoding.

So configuring ffmpeg with the nvidea libraries is the first requirement (the who to is also described on that page).

Then you need to choose the correct video codecs when actually encoding the video. The exact process it not yet perfectly clear to me. It seems you can use h264_cuvid to decode h264 streams into YUV and encode streams to h264 using h264_nvenc.

aleksandaratanasov commented 2 years ago

Check the official documentation on this provided by NVIDIA here. I would also love to have this feature especially since my Python application already uses CUDA.

NeighborhoodCoding commented 1 year ago

Is the problem is solved?

Pedrexus commented 8 months ago

any update on this? My ffmpeg installtion can use cuda, but this lib cannot. I wonder what is the reason.