Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > High Efficiency Video Coding (HEVC)

Reply
 
Thread Tools Search this Thread Display Modes
Old 25th August 2018, 16:10   #1  |  Link
Mike-uk
Registered User
 
Join Date: Jun 2018
Location: Dorset
Posts: 164
Convert 4k HDR to 1080p removing HDR

Hi, iv just attempted to convert a 4k video to MKV 1080p with handbreak, all went well it plays

but it has retained the HDR info( wasn't expecting it to ), so it looks all washed out on a non 4k tv

is there a way to remove HDR, so essently making a blu ray from 4k HDR source material ?


cheers


Mike
Mike-uk is offline   Reply With Quote
Old 25th August 2018, 16:28   #2  |  Link
videoh
Useful n00b
 
Join Date: Jul 2014
Posts: 1,667
DGSource + DGHDRtoSDR + Avisynth+

http://rationalqm.us/hdr/DGHDRtoSDR_1.9.rar

Requires an nVidia card. Use jpsdr's HDRTools if you do not have nVidia.
videoh is offline   Reply With Quote
Old 25th August 2018, 17:33   #3  |  Link
Mike-uk
Registered User
 
Join Date: Jun 2018
Location: Dorset
Posts: 164
Thanks

Thanks ill take a look at those tools
Mike-uk is offline   Reply With Quote
Old 28th August 2018, 18:21   #4  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,750
Quote:
Originally Posted by Mike-uk View Post
Hi, iv just attempted to convert a 4k video to MKV 1080p with handbreak, all went well it plays

but it has retained the HDR info( wasn't expecting it to ), so it looks all washed out on a non 4k tv

is there a way to remove HDR, so essently making a blu ray from 4k HDR source material ?
And note that a SDR derived from HDR isn't going to match what an actual SDR grade looks like. A colorist will make separate passes, making different creative decisions based on what each color space can do. A fully automated HDR->SDR is better than SDR->HDR, but just watching the SDR version is almost always going to be a superior experience.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 29th August 2018, 13:18   #5  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,806
Quote:
but just watching the SDR version is almost always going to be a superior experience.
key word "almost"
BD


Matrix Remastered BD


HDR to SDR tonemapping via DGTonemap.dll (Hable)


More screenshots
https://www.bloodsuckerz.cx/bd-1080p...tml#post618794

Last edited by Atak_Snajpera; 29th August 2018 at 13:21.
Atak_Snajpera is offline   Reply With Quote
Old 30th August 2018, 08:44   #6  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,558
Quote:
Originally Posted by Atak_Snajpera View Post
key word "almost"
BD


Matrix Remastered BD


HDR to SDR tonemapping via DGTonemap.dll (Hable)


More screenshots
https://www.bloodsuckerz.cx/bd-1080p...tml#post618794
That's way WAY beyond just SDR-vs-HDR, that's a creative decision to wholly regrade the Wachowskis' original vision of the film into a more neutral, audience-friendly tone. You may as well have two separate movies to pick from at that point.
foxyshadis is offline   Reply With Quote
Old 30th August 2018, 12:58   #7  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,806
My point is that it is better to do own HDR->SDR conversion than rely on some "professionals". Remastered Matrix looks overexposed to me. Tonemapped version looks more natural.
Ps. Yes I prefer original green version in case if we want to talk about color grading.
Atak_Snajpera is offline   Reply With Quote
Old 30th August 2018, 21:15   #8  |  Link
Gser
Registered User
 
Join Date: Apr 2008
Posts: 418
Quote:
Originally Posted by Atak_Snajpera View Post
My point is that it is better to do own HDR->SDR conversion than rely on some "professionals". Remastered Matrix looks overexposed to me. Tonemapped version looks more natural.
Ps. Yes I prefer original green version in case if we want to talk about color grading.
Actually the "original" version shown in theaters was not as green, the new 4K HDR remaster of Matrix is very close to it, the home releases kept getting greener and greener. I'm very satisfied with the new release of Matrix overall, so happy it wasn't spoiled with too much DNR like so many other old movies. I just finished watching the new HDR release on an HDR tv, nothing looked over-exposed to me. I'm guessing they wanted to make the old matrix look more like second and third releases thus they made it greener.

Last edited by Gser; 30th August 2018 at 21:19.
Gser is offline   Reply With Quote
Old 31st August 2018, 12:11   #9  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,806
Quote:
I just finished watching the new HDR release on an HDR tv, nothing looked over-exposed to me.
I'm comparing remastered SDR BD to tonemapped version (HDR->SDR) using free avisynth plugin.

Original version


Remastered SDR BD


HDR to SDR tonemapped with DGHable

Last edited by Atak_Snajpera; 31st August 2018 at 12:19.
Atak_Snajpera is offline   Reply With Quote
Old 31st August 2018, 14:19   #10  |  Link
videoh
Useful n00b
 
Join Date: Jul 2014
Posts: 1,667
Atak_Snajpera, can you give us your script for the DGHable version, please? Thank you.
videoh is offline   Reply With Quote
Old 31st August 2018, 16:32   #11  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,750
Quote:
Originally Posted by Atak_Snajpera View Post
My point is that it is better to do own HDR->SDR conversion than rely on some "professionals". Remastered Matrix looks overexposed to me. Tonemapped version looks more natural.
Ps. Yes I prefer original green version in case if we want to talk about color grading.
The thing is, most colorists spend WAY more time on the SDR grade than the HDR grade for home theater, as SDR still dominates audience-hours and revenue. So the creative intent of the actual SDR grade can be quite different from a HDR->SDR conversion.

If you want a more "pleasing" color, which is a controversial choice with something as intentionally stylized as the Matrix films, you could also switch your TV from Cinema to Standard mode.

If you want to see what the filmmakers intended their SDR to look like, watch the original SDR version. And the Matrix films are pretty unique color-wise, so aren't good content to make broader generalizations from.

Now, I certainly have seen HDR->SDR conversion be useful. For live sports, for example, where the color is pretty much all done in camera without significant creative color work happening in the truck.

But for major movies and TV shows, the SDR represents a lot of creative work and expression. In many cases, the home video HDR starts with the SDR grade and is modified from there, with some scenes remaining roughly SDR. No automated conversion is going to understand creative intent like that.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 7th September 2018, 05:16   #12  |  Link
hydra3333
Registered User
 
Join Date: Oct 2009
Location: crow-land
Posts: 540
Quote:
Originally Posted by videoh View Post
Atak_Snajpera, can you give us your script for the DGHable version, please? Thank you.
yes, +1
hydra3333 is offline   Reply With Quote
Old 29th May 2019, 01:45   #13  |  Link
an3k
Registered User
 
an3k's Avatar
 
Join Date: Oct 2006
Location: Omicron Persei 8
Posts: 180
It should be this
Code:
loadplugin("DGDecodeNV.dll")
loadplugin("DGTonemap.dll")
loadplugin("avsresize.dll")
SetFilterMTMode("z_ConvertFormat", MT_MULTI_INSTANCE) # May not be needed.
DGSource("THE GREAT WALL.dgi",fulldepth=true)
z_ConvertFormat(pixel_type="RGBPS",colorspace_op="2020ncl:st2084:2020:l=>rgb:linear:2020:l", dither_type="none")
DGHable()
z_ConvertFormat(pixel_type="YV12",colorspace_op="rgb:linear:2020:l=>709:709:709:l",dither_type="ordered")
prefetch(4)
If you want to crop and/or resize either use DGSource for that or the AviSynth internal filters. Be sure to put them before z_ConvertFormat()

Last edited by an3k; 30th May 2019 at 06:59.
an3k is offline   Reply With Quote
Old 29th May 2019, 06:04   #14  |  Link
StvG
Registered User
 
Join Date: Jul 2018
Posts: 447
Quote:
Originally Posted by an3k View Post
It should be this
Code:
loadplugin("DGDecodeNV.dll")
loadplugin("DGTonemap.dll")
loadplugin("avsresize.dll")
SetFilterMTMode("z_ConvertFormat", MT_MULTI_INSTANCE) # May not be needed.
DGSource("THE GREAT WALL.dgi",fulldepth=true)
ConvertBits(10) # Use 12 for 12-bit
z_ConvertFormat(pixel_type="RGBPS",colorspace_op="2020ncl:st2084:2020:l=>rgb:linear:2020:l", dither_type="none")
DGHable()
z_ConvertFormat(pixel_type="YV12",colorspace_op="rgb:linear:2020:l=>709:709:709:l",dither_type="ordered")
prefetch(4)
If you want to crop and/or resize either use DGSource for that or the AviSynth internal filters. Be sure to put them before z_ConvertFormat()
"ConvertBits(10) # Use 12 for 12-bit" - remove that line.
StvG is offline   Reply With Quote
Old 29th May 2019, 06:57   #15  |  Link
an3k
Registered User
 
an3k's Avatar
 
Join Date: Oct 2006
Location: Omicron Persei 8
Posts: 180
Quote:
Originally Posted by StvG View Post
"ConvertBits(10) # Use 12 for 12-bit" - remove that line.
The whole code is taken from the plugin author. Without that line You have YUV420P16 but afaik you want YUV420P10. Or am I missing something?
an3k is offline   Reply With Quote
Old 29th May 2019, 07:18   #16  |  Link
StvG
Registered User
 
Join Date: Jul 2018
Posts: 447
DGSource output is YUV420P16 (even if you have 10-bit video). You convert it to YUV420P10 and then to RGBPS (32-bit float). Just convert YUV420P16 to RGBPS.

Here you can see what DGSource author used.
StvG is offline   Reply With Quote
Old 30th May 2019, 06:59   #17  |  Link
an3k
Registered User
 
an3k's Avatar
 
Join Date: Oct 2006
Location: Omicron Persei 8
Posts: 180
Quote:
Originally Posted by StvG View Post
DGSource output is YUV420P16 (even if you have 10-bit video). You convert it to YUV420P10 and then to RGBPS (32-bit float). Just convert YUV420P16 to RGBPS.
You're absolutely right. I totally did not thought about this process. I just took what was written in the readme that comes with the plugin.

Quote:
Originally Posted by StvG View Post
Here you can see what DGSource author used.
Updated my previous posting. Thanks for heads-up
an3k is offline   Reply With Quote
Old 30th May 2019, 18:23   #18  |  Link
SpasV
Guest
 
Posts: n/a
Quote:
Originally Posted by Mike-uk View Post
Hi, iv just attempted to convert a 4k video to MKV 1080p with handbreak, ...
but it has retained the HDR info, so it looks all washed out ...
Mike
It hasn't retained HDR. Just opposite. The HDR has gone, you've got 8-bit color video, which cannot be HDR, in the source's color space, which is BT.2020.
The colors may seem washed out but I like them because they are closer to the natural colors. Look at the human skin for example.
Personally, I'm entirely negative about HDR to SDR tone maping.
  Reply With Quote
Old 30th May 2019, 21:03   #19  |  Link
Asmodian
Registered User
 
Join Date: Feb 2002
Location: San Jose, California
Posts: 4,406
I think you might be confused. 8 bit color video can be HDR, why couldn't it? Watching BT.2020 on a sRGB/BT.709 display is simply wrong. Just don't watch HDR if you don't want to tone map it and don't have a HDR display that can display the entire range of the mastering display (complicated since no publisher does 4K SDR releases).

Closer to the natural colors? My world looks nothing like BT.2020 content on a BT.709 display. HDR tone mapping often looks odd in some ways, and I think you should just watch the SDR master if you have an SDR display, but that doesn't mean watching BT.2020 on a BT.709 display is in anyway useful.
__________________
madVR options explained
Asmodian is offline   Reply With Quote
Old 30th May 2019, 21:32   #20  |  Link
SpasV
Guest
 
Posts: n/a
Look at this http://forum.doom9.net/showthread.ph...ht=alternative
  Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 14:33.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.