Jump to content

Tone-mapping in transcoding HDR for playback on SDR screens??


griffindodd
Go to solution Solved by Luke,

Recommended Posts

8 hours ago, Mkilbride said:

Hey so, I'm wondering, why so Dolby Vision files not transcode to Normal HDR10 when not supported? When streaming to my friends HDR Only TV, the colors are all screwed up, usually with a green or purple filter. They don't even transcode to SDR. Just fucked up colors.

Bottom line is that to play Dolby Vision files, you need equipment that understands the proprietary format.

Link to comment
Share on other sites

  • 1 month later...
  • 2 months later...

Hi

Are there any updates on the clients reporting the HDR status of their display back so SDR / HDR streams can be chosen without interaction?

Playing around with tonemapping and the various android clients I have Fire Tablet (Emby for Android 3.2.89), Fire TV (AndroidTv 2.0.79a), Chromecast HD (AndroidTv 2.0.83g) etc all try and play an HDR stream even though the OS (and attached display) is set to SDR. If you drop the streaming quality low enough so that the file has to be transcoded then tone mapping will kick in and the colours are as expected.     

Even a toggle similar to the supported audio formats (Always use SDR Y/N) would be great as I bet most people don't switch devices between displays all that often..

Thanks!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Agree 1
Link to comment
Share on other sites

rbjtech
15 minutes ago, jon_ said:

Hi

Are there any updates on the clients reporting the HDR status of their display back so SDR / HDR streams can be chosen without interaction?

Playing around with tonemapping and the various android clients I have Fire Tablet (Emby for Android 3.2.89), Fire TV (AndroidTv 2.0.79a), Chromecast HD (AndroidTv 2.0.83g) etc all try and play an HDR stream even though the OS (and attached display) is set to SDR. If you drop the streaming quality low enough so that the file has to be transcoded then tone mapping will kick in and the colours are as expected.     

Even a toggle similar to the supported audio formats (Always use SDR Y/N) would be great as I bet most people don't switch devices between displays all that often..

Thanks!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

The issue is the device capability is being got from the playback device - not the display device.    

This is yet another reason why I'd like the 'devices' to be fully configurable with capabilities that overwrite 'auto' settings - as then you could set it to 'force SDR' for example - as you know it is connected to an SDR only TV.   

Emby tries to be smart - but in somes cases, it's way off because it does not have all the information to make a calculated decision.

  • Like 1
Link to comment
Share on other sites

8 hours ago, rbjtech said:

The issue is the device capability is being got from the playback device - not the display device.    

This is yet another reason why I'd like the 'devices' to be fully configurable with capabilities that overwrite 'auto' settings - as then you could set it to 'force SDR' for example - as you know it is connected to an SDR only TV.   

Emby tries to be smart - but in somes cases, it's way off because it does not have all the information to make a calculated decision.

Actually android is able to incorporate the capabilities of both the device and display.

Link to comment
Share on other sites

rbjtech
7 hours ago, Luke said:

Actually android is able to incorporate the capabilities of both the device and display.

Ah ok - thanks - that's useful to know. 

Like the OP - I have a 4K FireTV linked to a 1080p/SDR TV - because the client is 4K/hdr capable - it will direct play the file - but the output is SDR.    Thus the colours are totally off.

Scaling (down) is done by the FireTV (or the TV I guess) so that is not the issue.

If the full 'chain' is known, then it should transcode because of the HDR>SDR requirement - and (maybe) because of the 4K>1080p requirement as well ?

@softworkz

Link to comment
Share on other sites

This is a problem on several devices. I asked early on to have a config option in the client that can be used to force transcoding HDR to SDR.
Some clients get this correct such as the Shield and Xiaomi Mi (configured correctly) but other devices like the FireTV/Sticks "lie" to Emby.

The sure fire way to fix this on a per client basis is to have an option "Force HDR to SDR on the Server".  When checked Emby Server would either use a non HDR version if the media is stacked or would transcode/tonemap the HDR to SDR.

What I don't remember as it's been a while since testing is if a FireStick (example) can tonemap HDR+ but not one of the other formats. So it would be worth checking to see if the device can tonemap any of the HDR formats.

  • Like 1
Link to comment
Share on other sites

rbjtech
10 hours ago, cayars said:

What I don't remember as it's been a while since testing is if a FireStick (example) can tonemap HDR+ but not one of the other formats. So it would be worth checking to see if the device can tonemap any of the HDR formats.

Not that I can see - this is on a Cube 2nd Gen - so relatively new.

Having capabilities per device override does seem an obvious thing to add - but unless this was architected in from the start - probably a difficult thing to now add. 

  • Like 1
Link to comment
Share on other sites

  • 1 month later...
gongdao123@gmail.com
On 5/3/2021 at 7:12 PM, niallobr said:

Very similar findings here on 8700K Coffee Lake.

- Software bt.2390 looks great

- Native VAAPI is very dark and not really usable

- OpenCL has higher brightness which can be adjusted nicely using the Tonemap Paramaters but all colours still look desaturated and there seems to be a green or yellow hue in videos I've tested. Skin tones aren’t looking natural.

- QuickSync I just get a mix of colours on non HDR videos (already reported)

Currently using Reinhard with Tonemap Paramaters 0.7. Desaturation Strength 0 (default).

Thanks for the link @softworkz I’ll try those out during the week.

Same here, and after some digging I found this.
https://github.com/intel/media-driver#video-processing-features

Seems HDR10 Tone Mapping only support ice lake and tiger lake + ,  i7 8700 is coffee lake (KBL+)
So it appears OpenCL is the only way to go for us.

@softworkz May be we need should only use Native VAAPI for ice lake and tiger lake +, and rest should use OpenCL?

Link to comment
Share on other sites

4 hours ago, gongdao123@gmail.com said:

Same here, and after some digging I found this.
https://github.com/intel/media-driver#video-processing-features

Seems HDR10 Tone Mapping only support ice lake and tiger lake + ,  i7 8700 is coffee lake (KBL+)
So it appears OpenCL is the only way to go for us.

@softworkz May be we need should only use Native VAAPI for ice lake and tiger lake +, and rest should use OpenCL?

Intel's tone mapping uses a 3D lookup table which has the consequence that it cannot be configured. There are no parameters, no algorithm selection, etc, so there results are either okay or not and if not, there's nothing you can do.

Their tone mapping is quite notably bit faster than the OpenCL tone mapping that ffmpeg has. But our Super-T and Extra-T OpenCL tone mapping is different. At least one of the two is usually getting close to Intel's LUT tone mapping.

So, there is not really a drawback in not having Intel's tone mapping.

  • Agree 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...