Dolby Vision Profile 7 & 8 support (.ts/.mkv files)

There’s a bug we’re looking into which can affect some Dolby Vision files when stored locally on the device. Hoping to have a fix available soon.

Any chance we will ever see on the fly conversion from DV Profile 7 to DV Profile 8? Or is this more limited on the Apple TV.

That’s a lot of computational work and would be pretty slick if they pulled something like that off

For a MEL DV7, it’s not too much additional work. I think it is probably doable. Really more like a remux.

Although, if you do it yourself, you can save several gigabytes per file, in some instances

I can understand that handling DV7 FEL with enhancement layer (EL) is very tricky but I wonder if Infuse could play DV7 without EL, only with RPU metadata that is common for both profiles DV7 and DV8. It should not be difficult to handle.

Unfortunately, this is not possible at this time.

I’m not sure why previous links I had posted to my script had stopped working, but here’s a new link to my script for converting files to Profile 8 until I find the time to move this to GitHub.

Can anyone help me understand.

I thought Infuse/ATV could read DV Profile 7 without the FEL. Like the nvidia shield.

I also thought that profile 8 was exactly like a profile 7 without FEL.

I’m not sure I understand why I should convert files to profile 8?

Infuse/ATV cannot read Dolby Vision profile 7. Profile 7 is made up of two separate streams while profile 8 is a single stream.

For MEL you can easily discard it without quality loss during p8 conversion. For FEL, you generally want to avoid converting to p8 unless you can re-encode the extra data into the stream (use davinci resolve, etc).

AFAIK it’s fine to discard the EL unless the base layer was mapped to a lower brightness. This should be detectable by comparing mastering display peek brightness in both static and dynamic metadata. If they are the same, I convert to P8. Didn’t have any issue so far.

Can you elaborate more on how to do that comparison? I have some DV7 files and want to ensure that converting to P8 isn’t going to result in incorrect brightness.

A post was merged into an existing topic: 115.com cloud drive

If you open the files in makemkv it will tell you if it is MEL or FEL

First, the why. From Dolby Vision UHD Blu-ray Authoring Workflow Guide (pdf):
“If mapping the base layer is desired, make sure the HDR10 base layer has the correct ST.2086. By default, the encoder should populate the mastering display peak brightness field with the mapping target display peak brightness value.”

You can use mediainfo to check the base layer “Mastering display luminance”. For the DV metadata value, you can use ffmpeg and dovi_tool to either produce a brightness (L1) plot or use the info command in summary mode. Here is an example bash script to produce a plot image:

Usage: ./your_script_name.sh your_DV7_file.mkv.
Output: your_DV7_file_dvplot.png

#!/bin/bash

ffmpeg -i "$1" -c:v copy -bsf:v hevc_mp4toannexb -f hevc - | dovi_tool extract-rpu - -o RPU.bin
dovi_tool plot RPU.bin -t "$1" -o "${1%.*}_dvplot.png"

# Cleanup
rm RPU.bin

On the plot image, you will see the “RPU mastering display” values. Now you check if the max value is the same as “Mastering display luminance” from mediainfo. If it’s not, you should not convert to P8 or watch on a device that doesn’t properly support FEL.

3 Likes

Are there any profile 8 test files with the ‘extra data’ ?

It would need to be a Profile 7 FEL. The enhancement layer is lost if converted to profile 8 without processing/baking it to the video stream, which results in innacurate playback when the enhancement layer brightens the image.

So then are there any test files of profile 8 with the EL ‘processed/baked’ into the video?

Thanks so much for that! It’s very useful.

A question for the thread:

Let’s say I have a few files where “Mastering display luminance” and “RPU mastering display” don’t match. How exactly could I reencode the extra data into the stream? How is it done?

Is it something that’s possible with something like Handbrake? I’m on macOS and have access to the full Final Cut Pro’s suite of tools if it can help (Final Cut Pro, Compressor, etc.) Or maybe another software would be more appropriate?

I don’t know about official tools, I don’t think they would support that since it’s not a legitimate production use case. AFAIK DoVi_Scripts is the most widely used tool for this, but it is Windows only.

Personnaly I prefer just watching those in regular HDR mode, since I don’t trust that “baking” and it requires re-encoding the video. Another option which I’ll try soon would be to use a Ugoos AM6b+ with CoreElec, which supports FEL properly.

1 Like

Thanks. Yeah, it all makes a lot of sense. Especially about trusting this whole baking process, I wonder if proper measurements have been made.

In any case, I really hope DoVi_Scripts will get ported to macOS/Linux eventually. It’s a bit weird for such a tool to be locked on Windows.

And I’m open to other suggestions if some people have more experience with this process on macOS.

Edit:
@nekno, I just saw you did port DoVi_Scripts to macOS here. Thanks! The latest release was in March 2024, is this project still supported/working?

1 Like