# HDR Video source - Tonemapping to SDR stream



## Jose Tortola (Dec 3, 2018)

First of all, I'm sorry if this is not the place to ask for this.

I'm using a dual-PC setup, one PC playing in 4K HDR 60 FPS, other PC with Avermedia Live Gamer 4K to passthrough the video to my monitor and capturing that video. OBS Studio to stream that video to Twitch at 6000kbps 1080p 60FPS SDR.

I don't know if the HDR tonemapping to SDR occurs in the Avermedia capture card itself or if it is done by software in OBS Studio. 

Obviously, after tonemapping, the streamed video looks with some inacurate lights/shadows (darker) and a bit washed colours. I've tryed to correct that effect as much as possible by trying some configurations for the video imput source (xRGB, NV12... 709, 601... full, limited...) and also making some manual adjusts to the video source input (elevating saturation, brigthness and contrast...)

And, after that tweaking  (NV12, 601, full, some more saturation, brigthness and contrast), the SDR stream preview in OBS Studio looks really good and somehow accurate to original. If I stream with that configuration, the stream looks good too... but depends on where you watch it. In my mobile phone, looks really good, but in a PC it looks overexposed and oversaturated. Is this even possible?, maybe I'm doing something wrong...

Anyway, I know that there are no strict rules to take an HDR image and tonemapping it to a SDR output. But I was wondering if it would be possible to have some kind of resource (plugin or something else) that could add "simply" tonemapping image configuration to OBS Studio, and maybe some "all in the same place" tweaking for it.

Thank you very much in advance.


----------



## RashbaNor (Jan 16, 2019)

Hey Jose!
Unfortunately nobody answered your question but maybe you've found a solution by yourself?
I've just ordered Live Gamer 4K and I wonder if I'll be able to play in 4K HDR while streaming 1080p SDR (two PC setup)?


----------



## Jose Tortola (Jan 23, 2019)

RashbaNor said:


> Hey Jose!
> Unfortunately nobody answered your question but maybe you've found a solution by yourself?
> I've just ordered Live Gamer 4K and I wonder if I'll be able to play in 4K HDR while streaming 1080p SDR (two PC setup)?


Yes, of course you can.

I also use a two PC setup, play in 4K HDR and stream in 1080p SDR. 

You can do that with Avermedia's own RECentral and the tonemaping (the conversion from the HDR colour space to the SDR colour space) looks really good, it's almost perfect. But RECentral has a lot of limitations and weak points, it has no integration with Elgato Stream Deck, it has limited options of tweak your encoding (even selecting x.264) and it does not seem to manage well multiple scenes, overlays... In every single poinf of that list, OBS Studio excells that program... except in the HDR to SDR tonemapping.

So it was difficult for me to choose what program to use for streaming... but due to the coding tweaking and Stream Deck compatibility, I finally choose OBS Studio.

The direct tonemapping in OBS Studio left my stream very dark and with pale colours. So then the problem was to make the stream look with decent colours and brightness and contrast levels. Maybe one good option can be the use of LUTs. And other option is jus add a image filter to the source of your video imput in the source settings on OBS Studio and tweak there contrast, saturation, gamma... The second option will lead to no as good results as the first one, but it is also the easiest to use, so it's what I'm using at this moment.

I got my streams pretty decent looking now, but the use of that image filters is not perfect and adds some grainy to the image that can be more visible if you don't make a good fine adjustment of the filter. I'm searching and trying to learn more to try to create my custom LUTs to replace the simple image filter in order to see if I can make a better image adjustment.

But maybe the really perfect and best option should be that OBS Studio could have a built-in tonemapping adjustment option, something that mixes the image filter options and the different colour conversions from a LUT in a comprehensive and handly way, as a filter to be applied in image or video sources, so we users can tweak that colour space adjustment all in one place. That will make OBS Studio even more perfect.


----------



## gabriel316 (Feb 4, 2019)

Jose Tortola said:


> Yes, of course you can.
> 
> I also use a two PC setup, play in 4K HDR and stream in 1080p SDR.
> 
> ...




Hey there,  would you be willing to share your image filter ?  I have the same capture card and looking at getting an HDR monitor


----------



## Jose Tortola (Feb 15, 2019)

gabriel316 said:


> Hey there,  would you be willing to share your image filter ?  I have the same capture card and looking at getting an HDR monitor


Bright 144 (default 128)
Contrast 137 (default 128)
Saturation 140 (default 128)

Those settings make BFV HDR to SDR tonemapping in OBS Studio look good almost allways. But you need to tune for every game. And they won't fit every game's scene.

The best option is using 3D LUTs for that tonemapping (from 2020 to 709 colour space). If OBS Studio could have an option for tweaking that, it would be perfect.


----------



## Beaver (Mar 14, 2019)

Trying to do the same thing on one PC for Division 2, just narrowed down it was the HDR setting making the stream look so horrible.  I can't for the life of me fix the colour correction with a filter in OBS Studio...  can't get the yellow to be orange without making everything else pink rofl...


----------



## Mecro (Mar 18, 2019)

Hi.
First, forgive me for my English. Google translator.
I have also observed that some intensity of color is lost in the HDR to SDR recording.
In the next video, I recorded "The Division 2". The source is 4k HDR and the recording is made with OBS at 4k / 60fps SDR.

https://www.youtube.com/watch?v=wcJIC_hrUV8&t=694s

I have tried to correct this aspect by increasing the saturation of the color but the effect produced is not the desired one.

Let's see if we can find among all a correct LUT to be able to load it in OBS and correct this deficiency.


----------



## Jose Tortola (Apr 1, 2019)

I'm playing and streaming The Division 2. And I created my own LUT and use it as a image filter for my game's video source. Just follow the steps on this thread:

https://obsproject.com/forum/resour...reaming-wide-gamut-monitors-lut-solution.678/

In my case, the LUT created wasn't enough to make the capture look as good as I want, so I added another filter to the game source to fine tunning the gamma, saturation, contrast, luminance, etc.

With both filters, LUT and colour correction, my stream looks really good. But that was not easy.

If only OBS could have some "HDR capture to SDR streaming" direct controls...


----------



## Kevin Crocker (Sep 9, 2019)

I found this LUT from a video editor who was converting stuff from HDR to SDR. I made a PNG version from it. Seems to work quite well. Give it a go.


----------



## Aaroz Ezio (Sep 23, 2019)

Kevin Crocker said:


> I found this LUT from a video editor who was converting stuff from HDR to SDR. I made a PNG version from it. Seems to work quite well. Give it a go.



Awesome!! It work very well. I have to to say capturing from HDR source is much better than SDR. Just look at the extra detail in blacks from all shots and compared to the standard one. Thank you for contributing. I;ve been searching a way to make this happen for years. Finally I can enjoy playing in HDR while my viewers get to watch the SDR version without the washed out colors.

Game : Resident Evil 2 Remake
HDR To SDR Conversion (Facebook Live)
SDR  (Youtube)


----------



## Nickyeet37 (Feb 7, 2020)

Aaroz Ezio said:


> Awesome!! It work very well. I have to to say capturing from HDR source is much better than SDR. Just look at the extra detail in blacks from all shots and compared to the standard one. Thank you for contributing. I;ve been searching a way to make this happen for years. Finally I can enjoy playing in HDR while my viewers get to watch the SDR version without the washed out colors.
> 
> Game : Resident Evil 2 Remake
> HDR To SDR Conversion (Facebook Live)
> SDR  (Youtube)



How did you get that set up? It's just a png for me.


----------



## Kevin Crocker (Feb 13, 2020)

Nickyeet37 said:


> How did you get that set up? It's just a png for me.


Right click on the video source that you want to apply this to and select filter. From there hit the plus sign and select LUT. Then you can choose the PNG file and it should tone map your image.

 My apologies if I haven't named the menu items exactly, but I'm on my phone at the moment and not in front of my computer.


----------



## JohnnyDi (Mar 30, 2020)

Here's some help, guys! I posted a video recently, explaining how to stream HDR games through OBS. I's all about perfect tonemapping. But you should repeat the steps for each game. Result is amazing.
https://youtu.be/BZ5G6DLSc_U


----------



## oscarwty (May 29, 2020)

Kevin Crocker said:


> I found this LUT from a video editor who was converting stuff from HDR to SDR. I made a PNG version from it. Seems to work quite well. Give it a go.


 Sorry to bother you, but if I could have your original lut file? I need this for Premiere, thank you


----------



## Aaroz Ezio (Nov 2, 2020)

Kevin Crocker said:


> I found this LUT from a video editor who was converting stuff from HDR to SDR. I made a PNG version from it. Seems to work quite well. Give it a go.


This LUT trick is not working with some games such as Far Cry 5 and Assassin's Creed Odyssey if the output is too bright (bloom effect on max) and oversaturated no matter how you do it. Tonemapping does not work at all with this games. The result is always the same before applying it.


----------



## rebotin (Jan 25, 2021)

oscarwty said:


> Sorry to bother you, but if I could have your original lut file? I need this for Premiere, thank you


Here is a good LUT for HDR to SDR conversion that works with premiere https://cc-lut.hotglue.me


----------



## Shuriken200 (May 14, 2021)

Anyone got any tips for when the stream looks way too bright and blown out? In my case, this is what happens when I game in HDR and try to capture it. 
No idea why it is overblown instead of washed out like you guys is saying.


----------



## FortuN (Oct 14, 2021)

Also having overblown videos when doing Hdr on OBS > twitch. Some things are really really bright so it looks so bad even with a hdr > sdr lut.


----------



## Shuriken200 (Oct 15, 2021)

Indeed. I still have this issue. But since the picture is overblown there is no LUT that can fix this issue. :(


----------



## R4NIERI (Nov 23, 2021)

The real problem is that OBS does not support the P010 format, which contains the color data in HDR.
At AVerMedia's ReCentral 4, the app simply has this capture option, so it has the full range of HDR colors available to make a tone mapping to SDR.
As long as OBS does not support P010, we will always have problems with this.
Unfortunately, it seems that only AVerMedia GC553 and GC557 can support P010 so if it's not up to AVerMedia (or someone else) to create a plugin for OBS, we will never get the correct SDR colors in our OBS recordings.
The only way to record an HDR signal or do a correct HDR to SDR conversion is to use ReCentral 4 which supports the color coding P010.




We need P010 support in OBS to make the correct conversion from HDR to SDR.


----------



## Shuriken200 (Dec 7, 2021)

That sucks :( 

Also. I think Elgato has some sort of HDR conversion in their 4K software?

Any other way to at least let me use LUTs for this problem? 

I still do not get why some people get a washed-out picture(that they can then use LUTs for) and other people(me included) gets an overblown picture that no LUTs can help.

Really weird.


----------



## roccityroller (Jan 11, 2022)

Figured out a workaround for this today. I used NDI Scan Converter when I had a 2 PC setup, but I'm moving to 1 PC and was having the blown out image in OBS that couldn't be fixed by LUT. 

But if you install the NDI plugin for OBS and then run scan converter to capture the HDR monitor, Scan converter does the tone mapping and the image looks good in OBS. 

I still did some LUT / CC work, but I can play in HDR and stream through OBS just fine now. 

Hope this helps anyone else who finds this thread.


----------



## Shuriken200 (Jan 15, 2022)

I too might have found a solution. Tho I have only tried with one HDR game so far(GoW 2018 PC edition) 

It seems the capture method has something to do with it. For many years I have been told to NEVER use Game Capture in OBS since that is heavier on the resource on the PC. Instead, I have exclusively used Display Capture with huge success so far(In SDR games I might add) 

Right now I tried to use Game Capture instead. And the image on the stream PC(using dual PC setup) now looks washed out and LUTS can work finally! No Overblown look with detail loss indeed! 

Since both Screen Capture options( and HX) uses Display Capture hook and not Game Capture it cannot(yet) display HDR correctly. But with this method, I can at least revert to Game Capture when playing HDR games. 

I'm so happy! =D


----------



## CartoonistDude (May 6, 2022)

roccityroller said:


> Figured out a workaround for this today. I used NDI Scan Converter when I had a 2 PC setup, but I'm moving to 1 PC and was having the blown out image in OBS that couldn't be fixed by LUT.
> 
> But if you install the NDI plugin for OBS and then run scan converter to capture the HDR monitor, Scan converter does the tone mapping and the image looks good in OBS.
> 
> ...


I'm trying to understand what you mean the NDI "Scan Converter". It looks like it change to that to Screen Capture, but even using it I get the blown out image. Did you have to check anything off in the NDI tools?


----------



## Shuriken200 (Jul 3, 2022)

CartoonistDude said:


> I'm trying to understand what you mean the NDI "Scan Converter". It looks like it change to that to Screen Capture, but even using it I get the blown out image. Did you have to check anything off in the NDI tools?


As far as I understand there is no way to get correct HDR capture using Screen Capture(HX). Therefore you have to use NDI via OBS when capturing HDR games(See post above). This way you get washed out images you can use LUT to fix 95% off it and get a passable image to stream while you enjoy full HDR gaming :D 

Wish you the best!


----------



## Shuriken200 (Aug 7, 2022)

Seems like this problem will be a thing of the past soon with V28 of OBS. HDR tone mapping is natively supported with this update! :D


----------

