You are not logged in.
So my laptop is from 2016 with these specs:
Make: Asus Vivobook X556UQK
CPU: Intel Core i5 7200U
GPU: Intel HD graphics 620 and Nvidia Geforce 940MX 2GB
Nvidia driver: nvidia-lts 1:545.29.06-20
I used to run fedora before this Archlinux, i had working Hardware Acceleration using Nvidia without any problem, and mpv respected the config to use hwdec=nvidia or nvdec, now from sometime the HW acceleration doesn't seem to work at all on arch, I use this to determine whether it's working or not
mpv --hwdec=all --hwdec-codecs=all video.mp4and i get bunch of errors like:
[ffmpeg/video] h264: Hardware is lacking required capabilities
[ffmpeg/video] h264: Failed setup for format cuda: hwaccel initialisation returned error.
[vaapi] libva: vaGetDriverNames() failed with unknown libva error
[ffmpeg/video] h264: Hardware is lacking required capabilities
[ffmpeg/video] h264: Failed setup for format cuda: hwaccel initialisation returned error.
[ffmpeg/video] h264: No support for codec h264 profile 77.
[ffmpeg/video] h264: Failed setup for format vaapi: hwaccel initialisation returned error.I know that my laptop is using nvidia gpu only as below command returns is:
glxinfo | grep -E "OpenGL vendor|OpenGL renderer"
output:
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: NVIDIA GeForce 940MX/PCIe/SSE2First thing i did is to verify which wiki says to run vainfo, which gives me:
Trying display: wayland
Trying display: x11
libva error: vaGetDriverNames() failed with unknown libva error
vaInitialize failed with error code -1 (unknown libva error),exitthen i did what archwiki says to set env variables in /etc/environment but it didn't worked!
and running this command gives:
grep -iE 'vdpau | dri driver' /var/log/Xorg.0.log
output:
[ 48.644] (II) NVIDIA(0): [DRI2] VDPAU driver: nvidia
[ 49.141] (II) modeset(G0): [DRI2] DRI driver: iris
[ 49.141] (II) modeset(G0): [DRI2] VDPAU driver: va_glI use mpv a lot on this old laptop & using only nvidia gpu is a necessity for me, and HW Acceleration can make the video playback so smooth for me because currently any video which is bigger than 2GB lags a lot, can anyone point me into right direction?
Offline
i did what archwiki says to set env variables in /etc/environment but it didn't worked!
What didn't work? Did you try setting LIBVA_DRIVER_NAME=nvidia?
Offline
mpv --hwdec=vdpau video.mp4For VA you'll need a https://wiki.archlinux.org/title/Hardwa … ion_layers
Offline
pointyjayhawk wrote:i did what archwiki says to set env variables in /etc/environment but it didn't worked!
What didn't work? Did you try setting LIBVA_DRIVER_NAME=nvidia?
Yes as I told, I read and tried whatever variables needed to be set like "LIBVA_DRIVER_NAME=nvidia", "VDPAU_DRIVER=nvidia" and "DRI_PRIME=1" in /etc/environment file and VA didn't worked.
Offline
mpv --hwdec=vdpau video.mp4For VA you'll need a https://wiki.archlinux.org/title/Hardwa … ion_layers
Yes as i use nvidia as a primary gpu so "libva-nvidia-driver" is installed, if i try to install "libva-vdpau-driver" then these 2 are in conflict.
Offline
Yes, you'd need *one* vdpau => vaapi mapper, have you tried to use vdpau?
As long as vainfo doesn't work, using vaapi for mpv won't either.
I read and tried whatever variables needed to be set like "LIBVA_DRIVER_NAME=nvidia", "VDPAU_DRIVER=nvidia" and "DRI_PRIME=1" in /etc/environment fileprintenv | grep nvidiaOffline