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

It definitely is, but if Apple will play it…

Via this loophole, it’s possible to manually convert both P7 to P8 and P8 to P5 losslessly so that Infuse and the built in Apple player can play real Dolby Vision on virtually every DV release.

Edit: FEL Profile 7 to Profile 8 conversion is not lossless. MEL P7 to P8 conversion is lossless.

This post has the techniques well summed up with proof where necessary:

4 Likes

Not to sound like an idiot but is there a more detailed breakdown on how exactly to do this (a guide for dummies so to speak)? Maybe one that includes steps needed in MakeMKV and how to identify which DV format a disc has.

All DV blu-rays use profile 7. MakeMKV will say on the video track whether it’s FEL or MEL. MEL has no info in the enhancement layer so it can be losslessly converted to profile 8.1. For FEL, inside is the difference between the 10-bit base layer and a 12-bit version. Most would say 12-bit TV panels don’t exist so that’s pointless but sometimes BLs have errors that the FEL corrects.

Also, MakeMKV automatically converts the dual-track, dual-layer profile 7 into single-track, dual-layer when making MKV for max compat. You would still need to convert this into profile 8.1, then fake profile 5 for display on Apple devices.

1 Like

With the latest update 7.4.10, the files with Dolby Vision Profile 8 (w/ HDR10 base layer), makes the tv launch DV instead of HDR10, is this correct, or is it a bug?

3 Likes

It is a bug, ATV will only handle the RPU if the file is Profile 5 or fake Profile 5 even if it is 8.4.

1 Like

We have a beta available with (experimental) on-the-fly DoVi P8 —> P5 conversion available in TestFlight.

Drop me a PM if you’d like to give it a try.

10 Likes

Nice James, before I PM to try can you confirm if this is all levels of Profile 8 including files with HDR fallback?

I would assume @james is referring to Dolby Vision Profile 8.1 to Profile 5. I’d also assume that they’re not actually on-the-fly transcoding to ICtCp, but probably just transcoding the container to MP4 and the metadata to fake the Apple TV into think it’s a Profile 5 file… The Apple TV seems to be willing to play Profile 8.1 files that are incorrectly tagged as Profile 5 files… my understanding is that this is how Apple plays back their screensavers while Dolby Vision content is playing.

2 Likes

I believe the logic is currently active for all P8 levels, but will likely only be useable for 8.1.

In essence, we’re re-tagging these files as P5 which can then be decoded natively on the Apple TV. As @speedy suggests, there is no actual conversion going on here as that is a much heavier process that could not be done in real-time.

7 Likes

Hi @james , is there a macOS build available for testing?

I’m interested in iOS and macOS builds with this enabled if it’s not a feature specific to Apple TV.

FEL->MEL would also be nice

3 Likes

Here are some samples I made for testing. All files share the same original source video and metadata. They should be almost identical (in theory).

The naming rule of suffix:

_IPT: encoded bitstream is IPT colorspace, for profile 5.

_PQ: encoded bitstream is BT2020 YCbCr colorspace (normal HDR10)

_P5 / _P81: the container has a profile 5 / 8.1 configuration box.

_CM29 / _CM4: the RPU in bitstream is CM v2.9 / v4. The CM v4 RPU also has CM v2.9 fallback metadata in it.

The following tests are done with macOS. More tests are needed with tvOS. Please note you should not use macOS reference modes with fixed luminance for Dolby Vision tone-map testing, as they skip the Display Management part in Dolby Vision pipeline.

With QuickTime, PQ P81 files fallback to HDR10, PQ P5 files trigger Dolby Vision. IPT P5 CM2 matches IPT P5 CM4 (Apple ignores CMv4 metadata in profile 5 playback, it only uses CM v2.9 metadata).

With latest infuse beta, PQ P5 files match PQ P81 files, so the re-tagging on the fly works well.

However, the problem is PQ CM4 files don’t match IPT P5 files, it’s heavily oversaturated, and it can be noticed without a comparison. The PQ CM2 files has a more acceptable difference (hard to tell the difference / hard to notice without comparison).

So infuse needs to check the RPU in bitstream, if the container said it’s profile 8.1. If the RPU has CMv4 metadata, it should not playback as Dolby Vision. It can be done with just single frame of RPU.

3 Likes

On my iPad Pro 2017, CMv4 saturation seems OK.

I have seen you mentioned it a few times, but I have watched several contents that are CMv4 and I never noticed any oversaturation, could it be a device-based problem?

Left = IPT_CM4, Right = PQ_CM4


Both are displaying Dolby Vision.

Also from my test results, L2_saturation_gain is used in CMv4 instead of L8 saturation, so maybe it’s fine on iOS devices?

L8 saturation = no work

CMv29 vs CMv4


OK, maybe my eyes aren’t picky enough.

Just from the thumbnails alone, the red, grid structure in the background has a minor but noticeably brighter beige for PQ.

Yes it depends on devices, on macOS the PQ P5 CMv4 is unacceptable, on iPhone it still has a larger difference compared to other videos. It seems like difference on iPad is small.

1 Like

OK that is over saturated, like they are drunk high for drinking what inside the glowing blue bottle, lol.

What uses cm4 anyways? So far, all I’ve noticed is that the blu-rays I’ve went through all use cm2.9

Hitman’s Wife’s Bodyguard
Ambulance 2022
Puss in Boots 2022
I would love to check if there’s any list.