You are not logged in.

#1 2019-12-01 19:12:30

lezned
Member
Registered: 2016-07-24
Posts: 8

NVIDIA and HEVC Hardware video acceleration

Hi everybody.
I recently bought a new Nvidia GeForce 1050Ti video card and I am not able to get hardware video acceleration working, for hevc 4k@10bit.
According to the table here it is supported.

I'm quite sure my configuration is wrong/missing something. This is my current situation:

Nvidia drivers and Nvidia vdpau lib are installed:

$ pacman -Qs nvidia
local/libvdpau 1.3-1
    Nvidia VDPAU library
local/libxnvctrl 440.36-1
    NVIDIA NV-CONTROL X extension
local/nvidia 440.36-2
    NVIDIA drivers for linux
local/nvidia-settings 440.36-1
    Tool for configuring the NVIDIA graphics driver
local/nvidia-utils 440.36-1
    NVIDIA drivers utilities
$ pacman -Qs vdpau
local/libvdpau 1.3-1
    Nvidia VDPAU library
local/vdpauinfo 1.0-3
    Command line utility for querying the capabilities of a VDPAU device.

then

$ sudo lspci -v
02:00.0 VGA compatible controller: NVIDIA Corporation GP107 [GeForce GTX 1050 Ti] (rev a1) (prog-if 00 [VGA controller])
	Subsystem: ASUSTeK Computer Inc. GP107 [GeForce GTX 1050 Ti]
	Flags: bus master, fast devsel, latency 0, IRQ 43
	Memory at de000000 (32-bit, non-prefetchable) [size=16M]
	Memory at c0000000 (64-bit, prefetchable) [size=256M]
	Memory at d0000000 (64-bit, prefetchable) [size=32M]
	I/O ports at e000 [size=128]
	[virtual] Expansion ROM at 000c0000 [disabled] [size=128K]
	Capabilities: [60] Power Management version 3
	Capabilities: [68] MSI: Enable+ Count=1/1 Maskable- 64bit+
	Capabilities: [78] Express Legacy Endpoint, MSI 00
	Capabilities: [100] Virtual Channel
	Capabilities: [250] Latency Tolerance Reporting
	Capabilities: [128] Power Budgeting <?>
	Capabilities: [420] Advanced Error Reporting
	Capabilities: [600] Vendor Specific Information: ID=0001 Rev=1 Len=024 <?>
	Capabilities: [900] Secondary PCI Express <?>
	Kernel driver in use: nvidia
	Kernel modules: nouveau, nvidia_drm, nvidia

Other info:

$ echo $XDG_SESSION_TYPE
x11
$ vdpauinfo 
display: :1   screen: 0
API version: 1
Information string: NVIDIA VDPAU Driver Shared Library  440.36  Tue Nov 12 08:08:10 UTC 2019

Video surface:

name   width height types
-------------------------------------------
420     8192  8192  NV12 YV12 
422     8192  8192  UYVY YUYV 
444     8192  8192  

Decoder capabilities:

name                        level macbs width height
----------------------------------------------------
MPEG1                           0 65536  4096  4096
MPEG2_SIMPLE                    3 65536  4096  4096
MPEG2_MAIN                      3 65536  4096  4096
H264_BASELINE                  51 65536  4096  4096
H264_MAIN                      51 65536  4096  4096
H264_HIGH                      51 65536  4096  4096
VC1_SIMPLE                      1  8190  2048  2048
VC1_MAIN                        2  8190  2048  2048
VC1_ADVANCED                    4  8190  2048  2048
MPEG4_PART2_SP                  3  8192  2048  2048
MPEG4_PART2_ASP                 5  8192  2048  2048
DIVX4_QMOBILE                   0  8192  2048  2048
DIVX4_MOBILE                    0  8192  2048  2048
DIVX4_HOME_THEATER              0  8192  2048  2048
DIVX4_HD_1080P                  0  8192  2048  2048
DIVX5_QMOBILE                   0  8192  2048  2048
DIVX5_MOBILE                    0  8192  2048  2048
DIVX5_HOME_THEATER              0  8192  2048  2048
DIVX5_HD_1080P                  0  8192  2048  2048
H264_CONSTRAINED_BASELINE      51 65536  4096  4096
H264_EXTENDED                  51 65536  4096  4096
H264_PROGRESSIVE_HIGH          51 65536  4096  4096
H264_CONSTRAINED_HIGH          51 65536  4096  4096
H264_HIGH_444_PREDICTIVE       51 65536  4096  4096
HEVC_MAIN                      153 262144  8192  8192
HEVC_MAIN_10                   --- not supported ---
HEVC_MAIN_STILL                --- not supported ---
HEVC_MAIN_12                   --- not supported ---
HEVC_MAIN_444                  --- not supported ---

Output surface:

name              width height nat types
----------------------------------------------------
B8G8R8A8         32768 32768    y  Y8U8V8A8 V8U8Y8A8 A4I4 I4A4 A8I8 I8A8 
R10G10B10A2      32768 32768    y  Y8U8V8A8 V8U8Y8A8 A4I4 I4A4 A8I8 I8A8 

Bitmap surface:

name              width height
------------------------------
B8G8R8A8         32768 32768
R8G8B8A8         32768 32768
R10G10B10A2      32768 32768
B10G10R10A2      32768 32768
A8               32768 32768

Video mixer:

feature name                    sup
------------------------------------
DEINTERLACE_TEMPORAL             y
DEINTERLACE_TEMPORAL_SPATIAL     y
INVERSE_TELECINE                 y
NOISE_REDUCTION                  y
SHARPNESS                        y
LUMA_KEY                         y
HIGH QUALITY SCALING - L1        y
HIGH QUALITY SCALING - L2        -
HIGH QUALITY SCALING - L3        -
HIGH QUALITY SCALING - L4        -
HIGH QUALITY SCALING - L5        -
HIGH QUALITY SCALING - L6        -
HIGH QUALITY SCALING - L7        -
HIGH QUALITY SCALING - L8        -
HIGH QUALITY SCALING - L9        -

parameter name                  sup      min      max
-----------------------------------------------------
VIDEO_SURFACE_WIDTH              y         1     8192
VIDEO_SURFACE_HEIGHT             y         1     8192
CHROMA_TYPE                      y  
LAYERS                           y         0        4

attribute name                  sup      min      max
-----------------------------------------------------
BACKGROUND_COLOR                 y  
CSC_MATRIX                       y  
NOISE_REDUCTION_LEVEL            y      0.00     1.00
SHARPNESS_LEVEL                  y     -1.00     1.00
LUMA_KEY_MIN_LUMA                y  
LUMA_KEY_MAX_LUMA                y  
$ vainfo
vaInitialize failed with error code -1 (unknown libva error),exit
$ grep -iE 'vdpau | dri driver' /var/log/Xorg.0.log
[     5.894] (II) NVIDIA(0): [DRI2]   VDPAU driver: nvidia

Finally, my two env variables LIBVA_DRIVER_NAME and VDPAU_DRIVER are not set.

Apparently, as the output of `vdpauinfo` states, HEVC@10bit is not supported in my setup?
Any clue?


Thanks in advance

Last edited by lezned (2019-12-01 19:13:47)

Offline

#2 2019-12-02 21:16:42

liewkj
Member
Registered: 2019-07-08
Posts: 70

Re: NVIDIA and HEVC Hardware video acceleration

lezned wrote:

I recently bought a new Nvidia GeForce 1050Ti video card and I am not able to get hardware video acceleration working, for hevc 4k@10bit.
According to the table here it is supported.

The table shows supported for NVENCODE/NVDECODE. If you look at the table before that for VDPAU, HEVC 10-bit is not supported. You will need to make use of video encoding/decoding software that support NVENCODE/NVDECODE APIs to have GPU accelerated HEVC 10-bit.

Offline

#3 2019-12-03 09:28:47

lezned
Member
Registered: 2016-07-24
Posts: 8

Re: NVIDIA and HEVC Hardware video acceleration

Many thanks liewkj, you pointed me out the right direction.

$ mpv --hwdec=nvdec --vo=gpu path/to/video

Offline

Board footer

Powered by FluxBB