Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to adapt cv::cuda::VideoWriter for Linux? #3044

Open
Bycob opened this issue Sep 20, 2021 · 1 comment
Open

How to adapt cv::cuda::VideoWriter for Linux? #3044

Bycob opened this issue Sep 20, 2021 · 1 comment

Comments

@Bycob
Copy link

Bycob commented Sep 20, 2021

System information (version)
  • OpenCV => 4.5.3
  • Operating System / Platform => Ubuntu 18.04
  • Compiler => gcc 7
Detailed description

cv::cuda::VideoWriter (doc) is only available for Windows, but I would like to use it on Linux.

What is the reason for the lack of Linux support? nvcuvenc does exist in Linux, so would it be possible to make a Linux-compatible version? What would be the amount of work needed to do so? Is it just changing some nvidia function calls to fit their linux version or is there more to it?

@antortjim
Copy link

I have implemented a cv2.VideoWriter-like class in my module here https://github.com/shaliulab/ffmpeg-gpu-benchmark.
You should be able to encode videos with your GPU using this class, by replacing all the instances of cv2.VideoWriter with cv2cuda.VideoWriter. This is the only way I found of making use of my Nvidia GPU from Python in Linux

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants