-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
NVDEC/NVENC acceleration not applied #3169
Comments
I tried compiling ffmpeg again with cuda and libavutil:
then uninstalled In the end, I used When Zoneminder is running,
|
Update: It seems that
|
Update: I put For encoding, the "Optional Encoder Parameters" in Source -> Storage does not allow |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Describe Your Environment
VM Host: Ubuntu 20.04/qemu
VM Guest: Debian GNU/Linux 10 (buster) 5.10.0-0.bpo.3-amd64
PCI passthrough: Quadro P400
If the issue concerns a camera
IP camera with rtsp unicast
Describe the bug
A clear and concise description of what the bug is.
The passed-through Quadro P400 is working correctly in guest os:
nvidia-smi
lists the devicewhen I manually type and run ffmpeg,
nvidia-smi
shows the process entry, andnvidia-smi dmon
records a fluctuation in decoder & encoder usage.ffmpeg -vsync 0 -nostdin -err_detect aggressive -fflags discardcorrupt -hwaccel cuvid -c:v h264_cuvid -y -i 290466-video.mp4 -c:a copy -c:v h264_nvenc -movflags frag_keyframe+empty_moov+faststart test.mp4
and the output file plays just fine. Replacing the disk input file with the rtsp stream also works just fine.
But Zoneminder does not pick up my own build of ffmpeg with cuvid enabled.
In "Options -> Images":
OPT_FFMPEG [v]
PATH_FFMPEG /usr/local/bin/ffmpeg
FFMPEG_INPUT_OPTIONS -nostdin -err_detect aggressive -fflags discardcorrupt -vsync 0 -hwaccel cuvid -c:v h264_cuvid
FFMPEG_OUTPUT_OPTIONS -c:v h264_nvenc -c:a copy -movflags frag_keyframe+empty_moov+faststart
FFMPEG_FORMATS mp4* asf avi 3gp mp4**
In camera source "Source":
Options (empty) (tried
hwaccel=cuvid,c:v=h264_cuvid
but log said ffmpeg flagshwaccel
andc:v
were not recognized)DecoderHWAccelName cuvid
DecoderHWAccelDevice (empty)
With the above setup,
nvidia-smi
does not report any usage from zma or zmc (empty process list).top
shows same CPU usage as before the graphics card was installed.Tried apt remove and apt install zoneminder.
Tried reboot.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A clear and concise description of what you expected to happen.
From the debug log, it seems that Zoneminder is not using the correct version of ffmpeg. It still says "drm" and no "cuvid". My own build has "cuvid" and but no "drm" in hwaccels.
Debug Logs
The text was updated successfully, but these errors were encountered: