Kodi Community Forum

Full Version: NVDEC (NVDECODE API) support in Kodi to decode 4K/8K 10-bit/12-bit HDR on Linux?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Any thoughts on Kodi VideoPlayer supporting NVDECODE API (formerly called NVCUVID API) for Nvidia GPU-accelerated video-processing as it is now supported by FFmpeg as well as Libav on Linux?

More information on the website for Nvidia Video Codec SDK => https://developer.nvidia.com/nvidia-video-codec-sdk

That is, enable the use of NVDECODE/NVDEC as an alternative to or replacement of VDPAU on Linux because VDPAU does not support 10-bit video decoding however NVDEC supports 10-bit and even 12-bit.

I don't have inside information from Nvidia but from the outside it looks like Nvidia have abandoned development of VDPAU in favor of this NVDECODE API as its new cross-platform unified API.

http://on-demand.gputechconf.com/gtc/201...logies.pdf

All focus is on it so looks like Kodi VideoPlayer should move to NVDECODE/NVDEC (formerly called NVCUVID/CUVID) to get 4K/8K HDR hardware video decoding working with Nvidia graphics on Linux.

Video SDK forums: https://devtalk.nvidia.com/default/board...hnologies/

This 'new' API enable hardware accelerated video decode on Linux (and Windows) for HEVC and VP9 up to 12-bit @ max 8192 x 8192 resolution and more on newer Nvidia graphic controllers:

https://developer.nvidia.com/nvidia-vide...ECFeatures

FFmpeg doesn't yet feature a 12-bit hwaccel accelerated pipeline for HEVC Main12 but FFmpeg v3.3 and later already have a 10-bit hwaccel accelerated pipeline for HEVC Main10 with NVDEC:

https://developer.nvidia.com/FFmpeg

NVDEC (part of NVDECODE API) was previously known as CUVID (part of NVCUVID, which was short for Nvidia CUDA Video hardware acceleration), and still called CUVID in FFmpeg/Libav:

https://trac.ffmpeg.org/wiki/HWAccelIntro

(FYI; FFmpeg 3.4.1 "Cantor" support currently uses NVDEC/CUVID headers from Nvidia Video Codec SDK 8.0.14)

http://trac.ffmpeg.org/wiki/HWAccelIntro...IDNvDecode

NVDEC compatibility also looks to be greater than that if VDPAU, as seen in this NVDEC support matrix:

https://developer.nvidia.com/video-encod...ix#Decoder

Team Kodi's VideoPlayer developers coukld probably just e-mail Nvidia Video SDK support do get a closer collaboration on NVDEC / NVENC for Kodi if needed:

[email protected]

Kodi VideoPlayer developer thoughts?
(2017-12-11, 13:28)RockerC Wrote: [ -> ]Any thoughts on Kodi VideoPlayer supporting NVDECODE API (formerly called NVCUVID API) for Nvidia GPU-accelerated video-processing as it is now supported by FFmpeg as well as Libav on Linux?


Kodi VideoPlayer developer thoughts?
 In order to further support NVidia, this is the way to go. If anybody wants to take this task, be my guest. It is not anything that is on my todo list because I don't see much benefit. Intel and AMD integrated CPUs can decode videos. There are not many cases why somebody wants to offload decoding to a discrete gfx card.
For Kodi in my NAS with AMD Turion II Neo N54L, it is definitely required.
FernetMenta, this statement is disappointing. Integrated graphics are limited in terms of 4K playback. Yes, Intel and AMD can decode 10 bit HEVC on Linux via VAAPI. But Intel does not have HDMI 2.0 so far so 4K at 30Hz only (there are 4K 60p movies already). Only the new Ryzens G with Vega have HDMI 2.0. Both options have issues with video RAM size limited to 2GB, not enough to play 4K HDR in certain scenarios.
For this purpose my HTPC was long built around low profile GTX 1050 with 4GB of RAM. But since VDPAU is effectively dead on nVidia (and 10 bit HEVC won't be supported in VDPAU) and with the advent of 4K HDR (10bit HEVC) MKVs, this made my Kodi/LibreELEC installation effectively useless for 4K. I switched (back) to Windows and there, sadly, you have now better options than Kodi to play back 4K/HDR.
Support for NVDEC was long awaited in ffmpeg. Such statements mean that Kodi isn't moving forward in certain areas (4K/HDR) but rest of the the world is.

I hope priorities will change.
I would like to see this as well, every media device in my house runs some form if Linux and it would be great if I didn't have to run a bloated version of Windows on my HTPC in order to play 4K 10 Bit content. I have a GTX 1070 in my PC, formerly used for games, but now just for HTPC duties.
Both Intel and AMD have converged to using the VAAPI API on Linux so it's only Nvidia who persist in doing their own thing so blame them. We already support one propriety interface from Nvidia in the VDPAU API, so we have no interest in maintaining yet another Nvidia only API.
also, please don't treat us as if we would be the only ones allowed to do code changes. Everybody is welcome to contribute and there are dozens of developers. So "all" needed is one of these devs having a nVidia card and be in need of this for 4K 60fps 10 bit whatever stuff. It's just that none of the developers in the team have the hardware or need for this kind of stuff.
To be honest, I don't understand it all.

Kodi developers don't have nVidia cards ? nVidia is listed as primary frontpage sponsor of Kodi and not giving you cards ? GT 1030 which does all it that is required (HDMI 2.0, HDCP 2.2, hardware decode support for VP9, HEVC, with 10 bit, up to 8K etc etc) is 80$ card, if that's the only problem to support nVidia properly (see below) I could buy you one.

Everyone can contribute but not everyone is a developer. I'm just a user (or rather was a user since I moved away from Kodi/LibreELEC to Windows because of the above lack of proper 4K/10bit support on nVidia).

Too many interfaces to support ? You're supporting many APIs already by supporting dfdifferent hardware platforms like Wetek etc. I see no point in maintaining VDPAU support anymore now, it's effectively dead and legacy now. For long there was an explanation of ffmpeg not supporting NVDEC but it has changed now. Just forget the past (VDPAU) and move towards future (NVDEC). Thinking of nVidia + VAAPI is a pipe dream. That won't happen. nVidia is too big to follow what 'others' do. I'm not justifying nVidia but these are facts. And again - I wonder how this can be that nVidia is a frontpage sponsor and Kodi is not actively keeping its support up to date.
I think the sponsorship has more to do with NVIDIA shield as an android based device and has nothing to do with GPUs ...
None of the Linux devs who work on video have Nvidia as they perceive Nvidia as anti-open source when it comes to GPU card drivers. The sponsorship is indeed from the Nvidia ShieldTV team, and like lots of huge organisations they have no direct dealings with other divisions.
(2018-03-25, 20:30)jjd-uk Wrote: [ -> ]None of the Linux devs who work on video have Nvidia as they perceive Nvidia as anti-open source when it comes to GPU card drivers. The sponsorship is indeed from the Nvidia ShieldTV team, and like lots of huge organisations they have no direct dealings with other divisions.
I wouldn't want to get mixed in this, being a Windows user I don't have any need for NVDEC support, but what you state here is quite the mixed message. If there are ethical reasons, deals should not be taken with the company involved. It's the same company, no matter the product you decide to support. Boycotting single divisions of a company is pretty much unheard of in the ethical arena, AFAIK.

If the problem is the lack of a latest gen Nvidia card, I'm sure something could be done easily to raise the money needed to gift one to a willing developer (by "easily" I mean "easily by users"). Not being a developer, I can only state that I'd be willing to pay half the cost of the card, to put my money where my mouth is. It wouldn't be my first time supporting the project the only way I can.
While the same parent company, like many big companies the different divisions operate as completely stand alone units.

The Android ShieldTV team has worked with us and Google in improving the Android media API's to make the most out of what their ShieldTV hardware is capable of, and this has been to the the benefit of everyone who uses these standard Android API's, this in complete contrast to the attitude displayed by the desktop GPU part of the business.
In no way I was criticizing the decision to fully support Shield in cooperation with Nvidia. I want to make this crystal clear. I simply sympathize with Linux users because, while it's true that recent CPUs can decode internally, there surely are tons of installations where CPU is simply incapable of handling HEVC/HDR/4K.
Just to further clarify, the decision to work on Nvidia for Lnux is entirely up to the individuals who work on the Linux stuff it is not some Team directive that we don't want to touch Nvidia stuff, not that we could even do any type of Team directive since we are volunteers who work on what we want, thus it is the individuals concerned who've decided they don't want to have anything to do with Nvidia at the current time. If someone were to code support that fits into the architecture and does nothing to hinder the future aims, then idf open a pull request to our github code repository then then it would likely be accepted if they promised to provide ongoing support.
FFmpeg 4.0 (which Kodi master now features) supports NVDEC accelerated video, is this any help to Kodi developers for this?

http://ffmpeg.org/index.html#news
Pages: 1 2