[Nouveau] Hardware decoding in video playback with Nvidia GT 218 (NVA8)
Hi all, I'm trying to make running hardware acceleration decoding on my old GeForce 210 (AKA GT-218, or NVA8 / NV-50 Tesla family). -- 02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [GeForce 210] [10de:0a65] (rev a2) -- I usually used proprietary nvidia-legacy340.108 driver and it works quite well even if I noticed some A-V sync (or a bit of frame dropping) issues during video playback of some videos having 1080p and 60 FPS (h264 encoded). Those issues seem solved by turn off hardware decoding. With MPV player and closed nvidia driver I used options: "-vo=gpu -hwdec=auto" And it automatically chooses "vdpau" decoding. CPU rests on 5% of load and so on... But I read about good if not better performances of some nvidia cards by using Nouveau open drivers, especially for old GPUs which could have poorly updated/maintained proprietary driver. So I decided to switch to open ones. I'm using Slackware64-15.0 with multilib support. It runs kernel 5.15.38. I read on nouveau page about the need of some files extracted from proprietary driver, a closed firmware for video hardware decoding. On slackware it is provided by SlackBuilds community: https://slackbuilds.org/repository/15.0/system/nvidia-firmware/ It populated /lib/firmware/nouveau with variuos files I think related to my GPU: -- $ file /lib/firmware/nouveau/nva{3_{b,p,v},8}* /lib/firmware/nouveau/nva3_bsp:data /lib/firmware/nouveau/nva3_ppp:data /lib/firmware/nouveau/nva3_vp: data /lib/firmware/nouveau/nva8_fuc084: symbolic link to nva3_bsp /lib/firmware/nouveau/nva8_fuc085: symbolic link to nva3_vp /lib/firmware/nouveau/nva8_fuc086: symbolic link to nva3_ppp I also enable "nouveau" in /etc/X11/xorg.conf.d/20-nouveau -- $ cat /etc/X11/xorg.conf.d/20-nouveau.conf Section "Device" Identifier "Nvidia card" Driver "nouveau" EndSection -- Here is env-var VDPAU_DRIVER defined to "nouveau" -- $ grep -v "^#\|^$" /etc/profile.d/vdpau.sh export VDPAU_LOG=0 export VDPAU_DRIVER="nouveau" - On my system are installed: - libvdpau-1.4-x86_64-3 libvdpau-compat32-1.4-x86_64-3compat32 -- The second one is related to multilib environment. Now some infos about vdpau: --- $ vdpauinfo display: :0 screen: 0 API version: 1 Information string: G3DVL VDPAU Driver Shared Library version 1.0 Video surface: name width height types --- 420 8192 8192 NV12 YV12 422 8192 8192 UYVY YUYV 444 8192 8192 Y8U8V8A8 V8U8Y8A8 420_16 8192 8192 422_16 8192 8192 444_16 8192 8192 Decoder capabilities: namelevel macbs width height MPEG1 0 8192 2048 2048 MPEG2_SIMPLE3 8192 2048 2048 MPEG2_MAIN 3 8192 2048 2048 H264_BASELINE 41 8192 2048 2048 H264_MAIN 41 8192 2048 2048 H264_HIGH 41 8192 2048 2048 VC1_SIMPLE 1 8190 2048 2048 VC1_MAIN2 8190 2048 2048 VC1_ADVANCED4 8190 2048 2048 MPEG4_PART2_SP 3 8192 2048 2048 MPEG4_PART2_ASP 5 8192 2048 2048 DIVX4_QMOBILE --- not supported --- DIVX4_MOBILE --- not supported --- DIVX4_HOME_THEATER --- not supported --- DIVX4_HD_1080P --- not supported --- DIVX5_QMOBILE --- not supported --- DIVX5_MOBILE --- not supported --- DIVX5_HOME_THEATER --- not supported --- DIVX5_HD_1080P --- not supported --- H264_CONSTRAINED_BASELINE 41 8192 2048 2048 H264_EXTENDED --- not supported --- H264_PROGRESSIVE_HIGH --- not supported --- H264_CONSTRAINED_HIGH --- not supported --- H264_HIGH_444_PREDICTIVE --- not supported --- VP9_PROFILE_0 --- not supported --- VP9_PROFILE_1 --- not supported --- VP9_PROFILE_2 --- not supported --- VP9_PROFILE_3 --- not supported --- HEVC_MAIN --- not supported --- HEVC_MAIN_10 --- not supported --- HEVC_MAIN_STILL--- not supported --- HEVC_MAIN_12 --- not supported --- HEVC_MAIN_444 --- not supported --- HEVC_MAIN_444_10 --- not supported --- HEVC_MAIN_444_12 --- not supported --- Output surface: name width height nat types -
Re: [Nouveau] Hardware decoding in video playback with Nvidia GT 218 (NVA8)
Hi Joe, On Sun, May 29, 2022 at 6:58 PM Joe wrote: > > Hi all, I'm trying to make running hardware acceleration decoding on > my old GeForce 210 (AKA GT-218, or NVA8 / NV-50 Tesla family). > -- > 02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 > [GeForce 210] [10de:0a65] (rev a2) > -- > [ ... ] > > But when I touch something, for instance "f" to enlarge to fullscreen, > or "q" to quit MPV... > Surprise! > > My system freeze, nothing work again, just the mouse cursor can still > be moved around. > > [ ... ] > > I'd like to use open drivers, but I'd like to take advantage of > hardware decoding too, so that my CPU rests as quiet and fresh as > possible. Is there some other suggest to configure some other aspect > and try to achieve my scope? > Or my tests are all I can do? > So for hwdec is better to switch back to closed source nvidia driver > legacy 340.108 ? Proprietary driver will definitely work better for hwdec than nouveau. Forgetting about any stability/performance issues, there are some reference frame ordering issues in H.264 decoding that were never addressed. This leads to occasional corruption in some videos. FWIW I've mostly tested with mplayer, and I didn't run into problems there. There should be instructions on using mplayer at https://nouveau.freedesktop.org/VideoAcceleration.html. The thing you esp want to avoid is using VDPAU + GL in the same process -- so things like "-vo vdpau" are much more likely to work than "-vo gpu" or "-vo gl". You can try enabling DRI3 -- perhaps something broke in the DRI2 paths. You can add Option "DRI" "3" into the Driver section of the xorg.conf to expose it. It's not on by default because there are some annoying corner cases that some window managers run into with it (KDE as I recall). I'm also not sure why VA-API is corrupted for you, it has worked in the past. But it gets a lot of changes only reviewed by AMD developers, so it can get broken pretty easily with AMD-specific assumptions which don't hold on NVIDIA. I suspect it should be easy to fix by someone who is interested in investigating -- probably a bisect to sort out what broke it, and then revert or get the person who wrote it to fix it. Cheers, -ilia