Changed HDR handling to use svtav1-params and accompanying values and syntax. #3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context
Current handling of HDR encoding appears to be broken. This is due to the libsvtav1-params command not being recognized by the libsvtav1 encoder in FFmpeg. Reading GitLab documentation suggests using svtav1-params. Documentation: https://gitlab.com/AOMediaCodec/SVT-AV1/-/blob/master/Docs/Parameters.md
Choices
The first change is a find and replace within the run_ffmpeg function. This updates the options in in encode_settings to use svtav1-params and its associated values as replacements for the old libsvtav1-params and its associated values.
get_hdr_settings has also been updated as svtav1-params does not accept the standard ffprobe output in color_spaces but instead requires tweaked values. A dictionary has been added and if a match from the dictionary is found in the color_space variable input it is mapped to an appropriate value; otherwise the dictionary should be ignored.
Test instructions
Note: Some mastering display settings may not be identical as input values are typically simplified rather than having the same input values as pulled from ffprobe. In this case calculated values should still match (e.g. "red_x": "34000/50000" = 0.68 = "red_x": "34000/50000").
Checklist before requesting a review