HDR on x86 Hardware

  • So I've figured some stuff out, mainly about my projector and reciever (TR-NX787) that's in between the projector and LE.

    It appears that the Intel 730 is putting out an HDR signal. It's just not sending the right meta data from the file -the BT2020 colspace, across the HDMI to trip the projector into the correct mode. Kodi itself knows that the content is HDR as it identified it in the tags. Maybe LE isn't enabling that with the Intel drivers or, the Intel drivers are lacking that feaure under Linux.

    Now, looking back on things, 3D content is the same way. I remember I had a RBPi years back and when I played 3D content on that, the Samsung TV would automatically flip into 3d mode by itself, whether it was TAB or SBS. That was awesome. The 5040 is acting the same way with 3D content as it is with HDR. Because it isn't seeing the right metadata, it doesn't flip the modes automatically.

    As for what the right metadata is or how to get the Intel GPU to send it. That's well above my paygrade unfortunately.

    I can force the projector into BT2020 colorspace manually in the settings -auto is the default. I also dropped Kodi's resolution down to 1080p30. With that I get 36bit color reported by my TR-NX787, and the projector shows 12bit in the color depth field. This could be some kind of limitation with the Intel GPU dropping chroma and bit depth down to achieve the higher 4K resolution.

    So because the BT2020 mode on the projector is dependant on the meta data being sent, it won't go there automatically. I also can't save a memory preset with that colorspace set in the projector, which would have made it a bit easier to go back and forth. So I am forced to flip the mode manually whenever I want HDR content. That sucks but the HDR collection is small so far.

    There is a big difference in experience I must say. I'll bet it's even better on a full (aka newer) HDR system as apposed to my 2016 projector. And eventually, LE and Kodi will build on it's HDR support. But one can hope for a sooner than later metadata fix ;)

    Thanks for the help everyone!

  • AGLyons, I had something similar happen on an older Onkyo receiver that did not support HDMI 2.0/HDCP 2.2 on all HDMI inputs. If I connect my Zotac mini PC to HDMI 1-3 I can get 3840x2160p 23.976Hz 36bit RGB with BT2020 colorspace (with the latest LibreELEC build from this thread). But If I connect to other inputs I can get 3840x2160p 23.976Hz 24bit RGB with BT2020 somehow.

    Does your receiver support full HDMI 2.0 on both outputs, or on only one (the main one)? Try hooking up the projector to the main output to see if it makes any difference. The other reason you might have issues flipping the projector to HDR mode automatically is that the Inter driver defaults to RGB colorspace , and the projector might be expecting the very specific YUV 4:2:2 color space to recognize the signal as HDR.

    Since you can force it to BT2020 colorspace manually, at least you get to have this functionality (with a bit of fiddling).

  • Hello SMP,

    Just tried your latest build on a new Adler miniPC, N95 cpu, Ace Magician AD03 one (rebranded from WeiBu Mfg) connected to an external display TV UHD with DV.

    Got a problem : your image is not booting (live) when TV edid is set to 2.0, at 60Hz.

    Only booting on edid 1.4 TV so only 30Hz,

    and no way at all when refreshing ou changing reso on Kodi, which stay wrapped to initial booting 30Hz.

    Even when unpluging 1.4 / pluging 2.0. cable, KODI 20 will never refresh the EDID data ans keep 30Hz as limit !!

    If at 4K 30Hz I ran successfully AV1 hw decode 17mbps 2160p, max 50% iGP et low CPU, when playing HDR10 or DV videos, no hw acceleration occurs as @ 30hz limit, so very shoppy, unviewable videos....

    So my question is about the reason why usb booting on edid 2.0 4k@60 DV external display on miniPC is not functionnal ?

    At least, is there an hidden/expert way to refresh an edid reading in Kodi next to switching on TV or via cable ?

    Thanks by advance for your attention, and your great job!

    Fab233

  • Kodi only reads mode data once at startup so swaping cables after boot will not change anything. And if the 4K 50/60 modes configured in the mode whitelist are not available (due to 1.4 cables) they will be silently dropped; requiring you to edit the list and reinstate them if you reboot with higher spec 2.0 cables attached again. NB: Lots of users think they have high-speed cables and will swear on their mothers life that their cables are not the issue; but issues often magically go away when a new certified cable is purchased /shrug

  • Not booting at all or just no signal?

    Well, black screen and no signal .... this as soon as 10-11sec auto start booting (syslinux menu is displayed, showing 5 seconds to start live) and mini-PC still running, no reboot at all, stuck in "no signal" on screen, must be shut down by long press on power button.

    This only appears when the TV(dolby vision capable) is defined as EDID 2.0, ie 2160p @60, which is verified as 'bubbled' when powering ON the mini-PC.

    BUT when defined as EDID 1.4, power-on is then bubbled 2160p @ 30 on TV and LE 20230331 starting after 10-11sec on live, then it take control of the display with another 2160o@30 bubble showing in the 2 sec, then immediatly appears the LE Welcome screen !, and everything is fine.

    Also I just tried Ubuntu 2304, same problem at 4K60hz with native boot, then only booting on '(safe graphics)' option, while native default boot is ok as soon as downgraded to 30hz.

    As i saw on reddit & other unix forums that some problems were related to AdlerLake 12thgen intel, may be within i915 or others points.

    And as I will receive soon two other Adler Mini-PC, so two other bioses, i will diagnose if it could be my ACE Magician bios that could be buggy ... But note also that a W11 22h2 to GO key gives all the best, leting better think a software problem (in driver made by intel for open world?).

    See you later ...

  • fab233 add "video=HDMI-A-1:1920x1080M@60" to boot params in syslinux.cfg; this should force Linux to 1080p@60 instead of the 4K modes which either driver or TV seems to dislike. Kodi GUI will run best @ 1080p with 4K modes only used for video playback via whitelist and adjust-refresh set to start/stop.

  • AGLyons, I had something similar happen on an older Onkyo receiver that did not support HDMI 2.0/HDCP 2.2 on all HDMI inputs. If I connect my Zotac mini PC to HDMI 1-3 I can get 3840x2160p 23.976Hz 36bit RGB with BT2020 colorspace (with the latest LibreELEC build from this thread). But If I connect to other inputs I can get 3840x2160p 23.976Hz 24bit RGB with BT2020 somehow.

    Does your receiver support full HDMI 2.0 on both outputs, or on only one (the main one)? Try hooking up the projector to the main output to see if it makes any difference. The other reason you might have issues flipping the projector to HDR mode automatically is that the Inter driver defaults to RGB colorspace , and the projector might be expecting the very specific YUV 4:2:2 color space to recognize the signal as HDR.

    Since you can force it to BT2020 colorspace manually, at least you get to have this functionality (with a bit of fiddling).

    So it seems that not only could there be a Kodi/Librelec growing pains. It could also be my hardware. I checked my TX-NR787 reciever and according to the specs, all HDMI inputs are HDCP2.2 compliant.

    Onkyo TX-NR787 Review and Specs
    Read our detailed analysis and evaluation of Onkyo TX-NR787, find out its strengths and weaknesses, and how it compares to its predecessor and successor.
    www.zkelectronics.com

    BUT, I then came across a post explaning the differences between HDCPv2.2 and HDMIv2.0. There was blurb in that that referred to Onk's units;

    Quote

    On the flip side, new Onkyo receivers are listed with HDCP 2.2. What they aren't telling you is that the HDMI 2.0 implementation is limited to 10.2Gbps (just like HDMI 1.4). While this allows the Onkyo receiver to pass the HDCP 2.2 handshake, it will limit how much data can be passed, negating many of the benefits of HDMI 2.0.

    Untangling HDMI 2.0 and HDCP 2.2
    HDCP 2.2 must be on a HDMI 2.0 terminal but not all HDMI connections support the full HDMI 2.0 spec. Consumers need to purchase with care lest they buy a…
    www.audioholics.com

    This to me is bullsh!t. Manufacturers shouldn't be allowed to pull this kind of stuff and still get certification with the licensing bodies. Either they stick to the spec or they don't get certified to show the logo.

  • So it seems that not only could there be a Kodi/Librelec growing pains. It could also be my hardware. I checked my TX-NR787 reciever and according to the specs, all HDMI inputs are HDCP2.2 compliant.

    https://www.zkelectronics.com/receiver/onkyo-tx-nr787/

    BUT, I then came across a post explaning the differences between HDCPv2.2 and HDMIv2.0. There was blurb in that that referred to Onk's units;

    https://www.audioholics.com/hdtv-formats/hdmi-2.0-hdcp-2.2

    This to me is bullsh!t. Manufacturers shouldn't be allowed to pull this kind of stuff and still get certification with the licensing bodies. Either they stick to the spec or they don't get certified to show the logo.

    I have Onkyo TX-NR646 (launched in 2015) and I suspect that this HDMI bandwidth limitation definitely affects my model. It seems like that I have to turn off support for more than 8 bit per color channel in order to have proper audio pass-through when utilizing dtsX or Dolby TrueHD (Atmos) in combination with 2160p 23.976 Hz video.

    If I leave the default support for 12 bit per channel enabled, the receiver indicates that it is showing RGB 36bit 3840x2160 23.976Hz video. The issue is that when the sound channels are utilized intensively (action scene with a backing soundtrack), the sound will cut out for a second or two, and then come back on as if nothing happened. This is very jarring and usually happens in the most annoying moments.

    This does not affect other audio formats, only dtsX/DTS.MA and Dolby Atmos/TrueHD, and only when using 36bit 3840x2160 23.976Hz video. If I turn off Deep Color support on the receiver or use non HDMI 2.0/HDCP 2.2 ports, the video is shown in 24 bit color and everything works just fine. They probably didn't expect 36bit RGB UHD video when they made this design tradeoff

    I think they may have fixed this issue by the time your model came out (2018).

    This may be a HDMI cable issue. I checked the necessary bandwidth for image transmission with resolution of 2160p at 24bit per channel and you only have enough bandwidth for 68 frames per second at max HDMI 2.0 capacity. Adding in audio transmission and you are at full capacity at 60 Hz. I would get a HDMI 2.1 compliant cable and try it to see if this is the problem.

    HDMI v1.4 and HDMI v2.0 cables are wired identically, and if you use short cables (under 2 m) you could probably get away with using a HDMI v1.4 cable. But just to be safe, get a decent HDMI v2.0 or v2.1 cable and avoid the hassle.

  • fab233 add "video=HDMI-A-1:1920x1080M@60" to boot params in syslinux.cfg; this should force Linux to 1080p@60 instead of the 4K modes which either driver or TV seems to dislike. Kodi GUI will run best @ 1080p with 4K modes only used for video playback via whitelist and adjust-refresh set to start/stop.

    Hi,

    smp & MatrixNetrunner

    Thanx for your 'pro' advices.

    My hdmi cable is (and was) a 8K'one.

    Change in syslinux.cfg, HDMI-A-1 orA-2 or A-2, had no effect.

    But swapping Ace Magician AD03 to Beelink MINI-S 12 let the latter full booting good ending to KODI 2160p@60 this time. So problem relied on bioses quality...

    But now, with Beelink, I have no access to hw decoding on my AlderLake N95 iGP capable (is UHD grafics from gen 11).

    Ubuntu 23.04 will use kernel linux 6.2, so with inside any possible intel drv from icelake+ now better working...

    I saw kernel 6.1 used on LE Prime edition, so possible "i915" embedded drivers are not Alder compatible to get hw acceleration in new intel coding ...

    Well, I'm waiting ubuntu 23.04 launch to test ubuntu hw video codecs to diagnose my late problem...

    See you later ...

    Thx again for your help

    Edited 2 times, last by fab233: edit : probably this is NOT an HW Decode problem on KODI & N95 ! Hevc, 4k hdr10, 2k/4k DV , 2k/4k AV1 finally runs quite well when DRM PRIME is let disabled on the Player menu (as it's the default) ... BUT such runs are then w/o the rich colors of hdr10 nor with DV color mapping). More : with VP9.2 w/o PRIME, and when DRM PRIME is set on, all codecs become so slow that the mouse'arrow is like a full animated cartoon and nothing is played on the video... : these so very slow frame rates of mouse w/o any frame on screen made me upper write that they were no hw acceleration... There are, but no HDR10 nor DolbyVision for Adler chip. I used your previous 20200830 version on my GLK to decode HDR10 videos, on a Beelink X45 mini-PC, i recalled my testings and HDR10 was working in DRM PRIME with Direct to plane (that were at that time the default values) and VP9.2 was also played HDR. On this same GLK box with your latest 20230331, i got only one of my 4khdr10 video to play ok as hdr10, this w/o PRIME ! as with PRIME et EGL set (the new defaults), only washed colors (hdr,dv,vp9.2). I hope you understand what pn the road from 2020 to 2023 made all this changes ... GLK was 9.5 gen, N95 is gen-11 GPU in gen-12 CPU, but do have AV1 decoding when i3-1125g4 did not !! Still need some testing and time to get intel things working on unix ! (April 14, 2023 at 10:05 PM).

  • fab233 I can’t quote your notes about editing your last post but I have same results on my NUC8 with latest SMP build and official 11.01 LE.

    Here are your notes. I wish we could get a response from the experts as this last versions of smp builds and LE with Kodi 20.1 the HDR colour is not the same as older builds:

    Quote:

    Edited 2 times, last by fab233: edit : probably this is NOT an HW Decode problem on KODI & N95 ! Hevc, 4k hdr10, 2k/4k DV , 2k/4k AV1 finally runs quite well when DRM PRIME is let disabled on the Player menu (as it's the default) ... BUT such runs are then w/o the rich colors of hdr10 nor with DV color mapping). More : with VP9.2 w/o PRIME, and when DRM PRIME is set on, all codecs become so slow that the mouse'arrow is like a full animated cartoon and nothing is played on the video... : these so very slow frame rates of mouse w/o any frame on screen made me upper write that they were no hw acceleration... There are, but no HDR10 nor DolbyVision for Adler chip. I used your previous 20200830 version on my GLK to decode HDR10 videos, on a Beelink X45 mini-PC, i recalled my testings and HDR10 was working in DRM PRIME with Direct to plane (that were at that time the default values) and VP9.2 was also played HDR. On this same GLK box with your latest 20230331, i got only one of my 4khdr10 video to play ok as hdr10, this w/o PRIME ! as with PRIME et EGL set (the new defaults), only washed colors (hdr,dv,vp9.2). I hope you understand what pn the road from 2020 to 2023 made all this changes ... GLK was 9.5 gen, N95 is gen-11 GPU in gen-12 CPU, but do have AV1 decoding when i3-1125g4 did not !! Still need some testing and time to get intel things working on unix ! (Saturday, 7:05 am).

  • Hi! I hope you can point me in the right direction. How to begin to diagnose the case, where some files are not switching the tv to HDR mode? In Kodi's interface, they are marked as HDR content. When played directly from the tv, they work as expected. Nothing specific in the log, I've compared a working and non-working file's log. I'm running LE11 stable on a Zotac ZBOX, connected directly via hdmi cable. Kodi resolution is set to 4k, because setting it to 1080p yields with no signal screen on the tv. I got 4k and 1080p modes whitelisted.

    Working file:
    Stream #0:0: Video: hevc (Main 10), yuv420p10le(tv, bt2020nc/bt2020/smpte2084), 2872x2156 [SAR 1:1 DAR 718:539], 23.98 fps, 23.98 tbr, 1k tbn, 23.98 tbc (default)

    Non working, colors washed out:
    Stream #0:0: Video: hevc (Main 10), yuv420p10le(pc, bt2020nc/bt2020/smpte2084), 3840x1610 [SAR 1:1 DAR 384:161], 23.98 fps, 23.98 tbr, 1k tbn, 23.98 tbc (default)

    Any ideas?

  • I've just realized that I forgot to add the actual log file - log(with debug), playback starts at line 3323. Also, I've noticed one thing. Whenever I'm playing a SDR file, its starts instantly, but with HDR, there is always a slight delay, the screen goes black for a moment before tv switches into HDR mode and then the playback starts. I get the same delay with this file, but the tv in not switching mode.

  • Thought I'd report in that using a Beelink n100-based mini PC and the latest build posted in this thread I am getting proper HDR10/bt.2020 triggering on my setup: Pioneer AVR to LG C1 TV. It's looking great!