Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow editing metadata blocks for HDR10+, madVR sourced generation #91

Closed
quietvoid opened this issue Dec 28, 2021 · 4 comments
Closed
Assignees
Labels
enhancement New feature or request

Comments

@quietvoid
Copy link
Owner

Currently, the shots are overwritten by those created with only L1 metadata.
It should technically be replacing the metadata blocks (probably excluding L1?) by those in the JSON.

Then comes the question, how do we define a default list of blocks for all shots?

@quietvoid quietvoid added the enhancement New feature or request label Dec 28, 2021
@ghost
Copy link

ghost commented Jan 2, 2022

Previous versions used a globally defined L2 (like the old generator_example.json had) for the entire video that wasn't discarded when generating from madvr data. I think this worked out fine even if it's technically supposed to be per-shot. I actually had to revert to an older version for the time being because of it.

I'm converting regular 1080p Rec.709 bluray to 1080p BT.2020 HDR10 8.1 DolbyVision using incredibly generic zscale conversion and abuse power and slope values found through trial and error to compensate for something that seems to be more or less constant across every source disk tried that could probably be better done by applying a LUT if I had any reasonable way of generating an appropriate one at the moment. I'm pretty convinced that the upscaling being done in hardware on modern TVs is better than any algorithm studios had access to (or were willing to spend the time running) until recently... so doing it this way looks better than some 2k upscale UHD BDs... which is very, very sad.

Currently either global or shot-list metadata is overwritten when generating so there isn't a way to use L2 as the bug says. If the shot specification from the current generator_example is used for metadata that can vary in the future, I'd suggest allowing the duration to be left out (where the default would be the entire length of the generated data). It can currently be set to an extremely high value for the same effect but I don't know how correct this is or if it will actually get "fixed" in the binary data.

@quietvoid
Copy link
Owner Author

quietvoid commented Jan 2, 2022

At first I wanted to make the first shot the list of default metadata, but that wouldn't work for people that want to actually edit shots even for HDR10+/madVR sourced metadata.

So I might just make a new "default metadata" array of blocks that would disallow L5/L6 blocks (because those already have a defined config).
And of course will have to correctly set metadata according to the initial shot/frame edits.

@quietvoid
Copy link
Owner Author

quietvoid commented Jan 3, 2022

@GabeBlincoln It should now again be possible to do what you're looking for.
Example (along with --madvr-file param):

{
    "level6": {
        "max_display_mastering_luminance": 1000,
        "min_display_mastering_luminance": 1,
        "max_content_light_level": 1000,
        "max_frame_average_light_level": 400
    },
    "default_metadata_blocks": [
        {
            "Level2": {
                "target_max_pq": 2851,
                "trim_slope": 2048,
                "trim_offset": 2048,
                "trim_power": 1800,
                "trim_chroma_weight": 2048,
                "trim_saturation_gain": 2048,
                "ms_weight": 2048
            }
        }
    ]
}

@ghost
Copy link

ghost commented Jan 3, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant