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 10th April 2024, 09:05   #261  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Boulder View Post
The transfer characteristics is incorrect in both files so it's no wonder the HDR mode is not switched on.
Yeah, I knew that had to be wrong... I just wanted to post this to show how some people just get it all wrong.

It'll be "fun" fixing it
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 10th April 2024, 12:01   #262  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
Quote:
Originally Posted by TheHooligan95 View Post
I think you're a fantastic person and I wish I could have even a tenth of your knowledge. Thanks for your work, OP. Truly.
Thanks

FYI, I did an installation tutorial video last night:

https://www.youtube.com/watch?v=6SLtsVDse2w


Quote:
Originally Posted by TDS View Post
Hi Kuler,

I grabbed this movie earlier today, and was surprised that MediaInfo stated it was a DV encode, but as it's was .mkv, I knew it wouldn't play on my LG, so I quickly ran it thru Mp4 muxer, and it changed completely, and doesn't display either HDR or DV on the LG, the original .mkv didn't display HDR either....what a mess, so I thought I'd share the before & after MediaInfo, info:-

So this is the original .mkv

Yeah, this is not common. Maybe someone attempted to make a profile 8.2 rip if that even possible ?

__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 11th April 2024, 13:41   #263  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Kuler087 View Post

Yeah, this is not common. Maybe someone attempted to make a profile 8.2 rip if that even possible ?
I had a bit of a play with this mess, and I'm not going to waste anymore time on it, it's not worth it.

I did a quick conversion to BT2020, but it's looks crap, too dark, too red'ish.

I'll just get a better "proper" copy.
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 24th April 2024, 05:14   #264  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Brightness/contrast question..

Hi Reset,

I have a question about a couple of settings..

I have been editing GoT episodes, and I have them looking pretty nice as HDR, however, after I run them thru 3-1, the video is noticeably brighter, which basically negates the adjustments I made prior.

The original video is:-

Code:
Color range                              : Limited
Color primaries                          : BT.2020
Transfer characteristics                 : PQ
Matrix coefficients                      : BT.2020 non-constant
Mastering display color primaries        : BT.2020
Mastering display luminance              : min: 0.0020 cd/m2, max: 1000 cd/m2
and the DS DV encode is the same:-

Code:
Color range                              : Limited
Color primaries                          : BT.2020
Transfer characteristics                 : PQ
Matrix coefficients                      : BT.2020 non-constant
Mastering display color primaries        : BT.2020
Mastering display luminance              : min: 0.0020 cd/m2, max: 1000 cd/m2
So what option do I need to use here:-

Code:
 BL Mastering Display Luminance and Colors:
 min: 0.0020 cd/m2, max: 1000 cd/m2 BT.2020
------------------------------------------------

What is the Mastering Display? Choices are: 1000nits-P3= 20(default) / 1000nits-BT2020= 21 / 4000nits-P3= 7 / 4000nits-BT2020= 8 / 2000nits-P3= 30 / 2000nits-BT2020= 31
I've been using..
Code:
1000nits-BT2020= 21
I'm still using 2.0.3, not that that should matter with this.

Maybe a simple solution might be to not do any colour/brightness changes beforehand (with these files, anyway)..I guess I'll figure out what needs to be done before the DS DV conversion.

Regards
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 24th April 2024, 12:01   #265  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
Yes you should always match your source mastering luminance and primaries so 21 is correct. Generataed DV is just brightness metadata for tone mapping, it doesn't touch the colors like the L2-L8 trim pass can do.
Maybe your TV is like my old LG C8 where OOTB, DV looked so much brighter than HDR10 regardless of the content.

PS This show already has DV, why are you generating DV?
__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 24th April 2024, 12:32   #266  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Kuler087 View Post
Yes you should always match your source mastering luminance and primaries so 21 is correct. Generataed DV is just brightness metadata for tone mapping, it doesn't touch the colors like the L2-L8 trim pass can do.
Maybe your TV is like my old LG C8 where OOTB, DV looked so much brighter than HDR10 regardless of the content.

PS This show already has DV, why are you generating DV?
Thanks for the reply, so as a reference, moving forward, I will match the source with the options available.

I will have to compensate my color corrections, prior to running DS.

I generally like to reduce any redness, and maybe brightness, a little, more than anything.

Yes, I'm sure that GoT is available with DV, but the 4K copies I have are a little old, so I'll just convert them, thanks to DS

Cheers.
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 24th April 2024, 13:19   #267  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
Instead of touching the BL , you could add some desaturation in the L2 trims like this:

change the duration("duration": 120000,) value to match your RPU framecount and run:
dovi_tool.exe generate -j X:\edits.json -o X:\P8_generated.bin

Then copy the generated L2 to your generated RPU from 3-1. You can do that with workflow 2-6


Code:
{
    "cm_version": "V29",
    "profile": "8.1",
    "long_play_mode": false,
	"source_min_pq": 7,
    "source_max_pq": 3079,
    "level5": {
        "active_area_left_offset": 0,
        "active_area_right_offset": 0,
        "active_area_top_offset": 0,
        "active_area_bottom_offset":0
    },
    "level6": {
        "max_display_mastering_luminance": 1000,
        "min_display_mastering_luminance": 20,
        "max_content_light_level": 0,
        "max_frame_average_light_level":0
    },
    "shots": [
        {
            "start": 0,
            "duration": 120000,
            "metadata_blocks": [
                {
                    "Level1": {
                        "min_pq": 0,
                        "max_pq": 2081,
                        "avg_pq": 1229
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 2081,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1900,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 2851,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1950,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 3079,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 2000,
                        "ms_weight": 2048
                    }
                }        
            ]
        }
    ]
}
you can play the the trim_saturation_gain values. Values under 2048 desaturate.
__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 24th April 2024, 13:44   #268  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Kuler087 View Post
Instead of touching the BL , you could add some desaturation in the L2 trims like this:

change the duration("duration": 120000,) value to match your RPU framecount and run:
dovi_tool.exe generate -j X:\edits.json -o X:\P8_generated.bin

Then copy the generated L2 to your generated RPU from 3-1. You can do that with workflow 2-6


Code:
{
    "cm_version": "V29",
    "profile": "8.1",
    "long_play_mode": false,
	"source_min_pq": 7,
    "source_max_pq": 3079,
    "level5": {
        "active_area_left_offset": 0,
        "active_area_right_offset": 0,
        "active_area_top_offset": 0,
        "active_area_bottom_offset":0
    },
    "level6": {
        "max_display_mastering_luminance": 1000,
        "min_display_mastering_luminance": 20,
        "max_content_light_level": 0,
        "max_frame_average_light_level":0
    },
    "shots": [
        {
            "start": 0,
            "duration": 120000,
            "metadata_blocks": [
                {
                    "Level1": {
                        "min_pq": 0,
                        "max_pq": 2081,
                        "avg_pq": 1229
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 2081,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1900,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 2851,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1950,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 3079,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 2000,
                        "ms_weight": 2048
                    }
                }        
            ]
        }
    ]
}
you can play the the trim_saturation_gain values. Values under 2048 desaturate.


Might take me a while to figure out how to do this ...

How do I check the RPU's framecount ?
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 24th April 2024, 13:55   #269  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
input a rpu in 2-2

__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 24th April 2024, 14:09   #270  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Kuler087 View Post
input a rpu in 2-2
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..

Last edited by TDS; 25th April 2024 at 01:55.
TDS is offline   Reply With Quote
Old 25th April 2024, 02:58   #271  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Sorted, kind of...

OK, I have kind of figured out what to do with this, (I created the .json file) but you say to load the RPU from the original video, well, what if it isn't DV ?? where does the RPU come from ??

I run 3-1 to get the framecount (this test I'm doing had 7209 frames) it's a sample chunk generated with 8-5.


Code:
Which RPU level(s) do you want to copy and press enter... (Choices are 1 2 3 4 5 8 and you can select multiple values) ??
I used "8"..

Also, where do I change the trim_saturation_gain values ?, there's several to choose from (or all of them) ?

Can brightness/luminance be changed ?

Using 2-2 to check each .bin, (until there are any saturation changes, etc), they should be exactly the same ??

So once the "new" .bin is generated, how is it injected info the converted video ??

I'm thinking it might still be a better option to compensate for what DS does, with the previous adjustments..we'll see, I guess.
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..

Last edited by TDS; 25th April 2024 at 03:16.
TDS is offline   Reply With Quote
Old 25th April 2024, 04:15   #272  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
1- Generate DV with 3-1

2- create json with the framecount from the rpu generated in 3-1 step one
the json has three targets of metadata for Level 2 (not L8): 100(2081), 600(2851), and 1000nits(3079). You can use the json exactly as provided or edit it as much as you want.
Value under 2048 desaturates and usually, the 100nits trim has the stronger values followed by the 600 and 1000nits trims. The value at each target should be different for the interpolation to work properly.

3- run the cli to generate the RPU with L2 adjustments

4- Workflow 2-6, input 1 is rpu from step one and input 2 is the rpu from step 3. Select ''2''

5- inject the final rpu (the one with ''l2 copied'')


If you want to do the same for the CMv4.0 bloc (your tv is cmv2.9):

Code:
{
    "cm_version": "V40",
    "profile": "8.1",
    "long_play_mode": false,
	"source_min_pq": 7,
    "source_max_pq": 3079,
    "level5": {
        "active_area_left_offset": 0,
        "active_area_right_offset": 0,
        "active_area_top_offset": 0,
        "active_area_bottom_offset":0
    },
    "level6": {
        "max_display_mastering_luminance": 1000,
        "min_display_mastering_luminance": 20,
        "max_content_light_level": 0,
        "max_frame_average_light_level":0
    },
    "shots": [
        {
            "start": 0,
            "duration": 120000,
            "metadata_blocks": [
                {
                    "Level1": {
                        "min_pq": 0,
                        "max_pq": 2081,
                        "avg_pq": 1229
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 2081,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1900,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 2851,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1950,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level2": {
                        "target_max_pq": 3079,
                        "trim_slope": 2048,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 2000,
                        "ms_weight": 2048
                    }
                },
                {
                    "Level8": {
                        "length": 19,
                        "target_display_index": 1,
                        "trim_slope": 1950,
                        "trim_offset": 2048,
                        "trim_power": 2048,
                        "trim_chroma_weight": 2048,
                        "trim_saturation_gain": 1900,
                        "ms_weight": 2048,
                        "target_mid_contrast": 2048,
                        "clip_trim": 2048,
                        "saturation_vector_field0": 128,
                        "saturation_vector_field1": 128,
                        "saturation_vector_field2": 128,
                        "saturation_vector_field3": 128,
                        "saturation_vector_field4": 128,
                        "saturation_vector_field5": 128 						
					}
                }        
            ]
        }
    ]
}
__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 25th April 2024, 04:58   #273  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Kuler087 View Post
1- Generate DV with 3-1

2- create json with the framecount from the rpu generated in 3-1 step one
the json has three targets of metadata for Level 2 (not L8): 100(2081), 600(2851), and 1000nits(3079). You can use the json exactly as provided or edit it as much as you want.
Value under 2048 desaturates and usually, the 100nits trim has the stronger values followed by the 600 and 1000nits trims. The value at each target should be different for the interpolation to work properly.

3- run the cli to generate the RPU with L2 adjustments

4- Workflow 2-6, input 1 is rpu from step one and input 2 is the rpu from step 3. Select ''2''

5- inject the final rpu (the one with ''l2 copied'')
Oh, RPU's are the .bin files.

Step #2 (have no idea what that's about)

OK, I'm good 'til step #5...what workflow do I use to inject ??

I haven't done these steps before, so I'm a little lost

Sorry.
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 25th April 2024, 11:48   #274  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
you inject the final rpu with 1-1
__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 25th April 2024, 13:32   #275  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
Quote:
Originally Posted by Kuler087 View Post
you inject the final rpu with 1-1
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 26th April 2024, 10:57   #276  |  Link
TDS
Formally known as .......
 
TDS's Avatar
 
Join Date: Sep 2021
Location: Down Under.
Posts: 1,086
If I have a DV movie that I want to filter, etc with RipBot264, and I extract the RPU.bin beforehand, then inject it after the filtering etc, would it be compatible ??

Not really wanting to do any Resolve fiddle.

Also, earlier today I started 3-1'ing an edited episode of GoT, and it was going to take, I'm guessing at least 3 - 4 hours to convert, I think I know why, but I had to stop it part way thru, just WAY TOO LONG

I was using CUDA on an RTX3060 (not fast enough), but would the 7950X or the 13900KF be faster than CUDA ??

Shame
__________________
Long term RipBot264 user.

RipBot264 modded builds..
*new* x264 & x265 addon packs..
TDS is offline   Reply With Quote
Old 26th April 2024, 12:16   #277  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
Quote:
If I have a DV movie that I want to filter, etc with RipBot264, and I extract the RPU.bin beforehand, then inject it after the filtering etc, would it be compatible ??
Depends on what filtering you do. If you change blacks or brightness, the metadata are no longer valid.

Quote:
Not really wanting to do any Resolve fiddle.
Also, earlier today I started 3-1'ing an edited episode of GoT, and it was going to take, I'm guessing at least 3 - 4 hours to convert, I think I know why, but I had to stop it part way thru, just WAY TOO LONG
I was using CUDA on an RTX3060 (not fast enough), but would the 7950X or the 13900KF be faster than CUDA ??
CM_analyze is inconsistent and there's nothing we can do about it. Resolve (or MACos?) is the only other option.
__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 26th April 2024, 22:09   #278  |  Link
Gatorman3385
Registered User
 
Gatorman3385's Avatar
 
Join Date: Feb 2024
Posts: 12
CM_analyze is a great option if you don't own Resolve. However, using Resolve to generate DV was enough for me to make it a worthy investment.

Am I correct that CM_analyze is more consistent with Intel + CUDA than with AMD + CUDA?
Gatorman3385 is offline   Reply With Quote
Old 27th April 2024, 02:17   #279  |  Link
Kuler087
Registered User
 
Kuler087's Avatar
 
Join Date: Aug 2021
Location: Canada
Posts: 277
supposedly

Quote:
Am I correct that CM_analyze is more consistent with Intel + CUDA than with AMD + CUDA?
__________________
DoVi_Scripts
Kuler087 is offline   Reply With Quote
Old 30th April 2024, 15:19   #280  |  Link
jayper
Registered User
 
Join Date: Feb 2024
Posts: 12
Reset, are these the steps you followed to get your Ugoos up and running? https://discourse.coreelec.org/t/gui...allation/51231

It looks like my device is set to be delivered today!
jayper is offline   Reply With Quote
Reply

Tags
batch scripts, dolby vision processing, dovi_scripts

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 13:06.


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