[Implemented] HDR->SDR Transcoding

Ahhh good point about the hevc. I knew that. Could have answered my own question. Thanks.

Really wish this would get addressed already. With my entire collection in 4K, I don’t want to have to store 2x copies of everything for when I want to stream remote on the road. So frustrating. This isn’t all that complicated, it should be doable with decent hardware.

Yea same. For everyone using 4K media, the transcoder is a bug, not a feature. Fortunately, you can turn it off and a benefit of that is that your users will be forced into finding ways to direct play your content.

Need that so much! I want my library in 4K HDR but also be able to sometimes watch content in lower quality on mobile or sync my media for offline viewing on a flight. Managing a separate library for 4K content can’t be the solution!

According to Jellyfin devs, tonemapping is so demanding it will require gpu assistance to work in any meaningful capacity. Whats worse, the can only get it working with nvenc. The uhd630, which I would guess is the most common alternative, is not working pre 10th gen.

I wish Plex would communicate their progress better, but from what I have gathered, implementing the feature is difficult, and requires very specific hardware to work.

This is likely true, but the other option would be to transcode in HEVC maintaining HDR and BT. 2020 colorspace. Then leave it up to the players or client devices to tonemap.

2 Likes

This! Just keep the hdr and let the player tonemap

1 Like

Aparently, Tiger Lakes new igpu supports tonemapping so Im guessing this feature might be easier to implement once those chips are availiable.

Is it currently working in Plex if you use a Nvidia NVENC Turing or newer card? Would be nice if it did.

New update on the shield pro. They added hdr to sdr tonemaping and its working great with plex hdr on non hdr 4k tv

1 Like

As more and mote clients support tonemapping, I think Plex should rather focus on transcoding to HEVC and preserving the 10 bit colors.

2 Likes

I also think that converting to h265 is much better. Then the client can decide if it wants to play HDR or do the tonemapping. Already moved my vote to that feature request:

Furthermore I think that it’s also important to be able to sync h265 content as most devices today are able to decode that. You can add your vote here:

Yea same. Removed my vote here… Server-side tonemapping doesnt seem like the right sollution. H265 is much more future proof

I’m sure they are/will be tackling the issue at both the client and server levels, in order to support the widest range of device combinations.

Although I agree with this statement, there are still instances where server-side conversion is necessary. For instance, Plex (for some crazy unexplainable reason) doesn’t let you sync titles to mobile devices unless it transcodes it first. That is definitely a shortcoming in my opinion but if that’s how it’s intended to operate, then hdr-to-sdr conversion needs to happen at the server level for sync content.

As for all the people saying that it’s a complex issue and hard to do… No, it’s not. Implementing a simple Hable algorithm to handle the conversion is extremely simple and can cover most of your conversion needs (I’ve tested it extensively). The best part is, Hable is supported in modern GPU transcoders (especially NVIDIA). There really isn’t any reason to not implement this feature on both the server and client side (true Direct Play).

1 Like

Not really. iOS devices will tonemap themselves if they dont support HDR. I imagine most android devices can to. So you could just feed them a smaller, transcoded 10 bit HEVC file with the HDR preserved, if Plex absolutely must transcode.

For old devices, sure, tonemapping is great. But those will be absolete soon anyways, so I dont think Plex should make the effort. Better move forward and transcode to HEVC.

That’s not the problem. The problem is that Plex Sync transcodes the file from 10-bit HDR to 8-bit SDR with no tone-mapping. The file the mobile device receives and tries to play has no extended color information and the color range was cut off to fit inside the new range. What you end up with is an image that looks flat and washed out with no way for any player to determine the original color values. I only use Android devices (which are capable of playing back 10-bit media) so maybe this is how Plex handles Sync with Android but it’s definitely a horrible experience and should be addressed.

4 Likes

I’d say they are waiting on ffmpeg to implement it so it works in Plex - seeing as Plex uses ffmpeg to do the transcoding work - but ffmpeg apparently has had multiple tonemapping algorithms implemented since 4.1 in late 2018. I’m not surprised that it may be computationally expensive, but that’s the point of transcoding. I have a fancy media server precisely so it can do this kind of heavy lifting. If I wanted my client players to have to do work, I’d just use Kodi, or whatever native player my various platforms have. Client players are supposed to be dumb boxes that just show what they’re given, and they’re given what they can take.

Closing as this has now been implemented

4 Likes