Dolby Vision now possible through MP4 Mux.

Please post here for issues related to UHD discs
RESET_9999
Posts: 1853
Joined: Mon Aug 05, 2019 7:12 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by RESET_9999 »

djanvi2020 wrote:
Fri Jul 22, 2022 8:40 am
Interesting thought,

A majority of my Dolby Atmos DV discs have 7.1 and DD+ can do 7.1 Unless i missed the memo that DV MP4 or TS files doesnt like 7.1, why aernt we using it if Dolby Atmos or Dolby True HD tracks are in 7.1 and the Dolby Scripts downgrades it to 5.1?

why are we losing those two channels cause i do have a system that can do 7.1 and DD+ can have 7.1?

??????
Hi,
Just to let you know that I've added a free way to encode 7.1 EC3 track in DoVi_Scripts_1.5.8 (6-3-8).
https://drive.google.com/drive/u/1/fold ... J2M9DvOQRu
The only problem right now is that tsmuxer cant mux those files properly but it should be fixed in the next nightly build. Mkvtoolnix is fine.
Jose1001 wrote:
Sat Sep 24, 2022 11:46 am
Hello RESST_999 to see if this is possible and how it could be done.
I have a Remastered version of a movie, which instead of having a Bitrate of 50Mb/s like the one in UHD, has a Bitrate of 72Mb/s. I also have the DV(1920x1080) video track from the Full UHD version, and my intention is to put this DV track into the remastered video track to create a profile 8, but according to StaxRip they have a frame difference of 22.
How could this be done, if possible?
Thank you very much and greetings
MODE.I (1-1) can do that but your two sources are most likely different HDR grades so unless you compare the brightness/colors (6-2-3 6-2-2) and get a close enough match, I wouldn't do that.
Donpoku wrote:
Sat Sep 24, 2022 12:00 pm
No your C9 is not affected, it was C1/C2(new Cm4)on x7/800(old cm2).
The C9 also has the CMV4.0 engine and according to @ deadchip12 it has the same L1/L2 reaction difference as shown here:
https://www.youtube.com/watch?v=TJtwu1bwlug
deadchip12 wrote:
Fri Sep 23, 2022 12:13 pm
Sorry I'm a bit confused. So tv led and player led dolby vision, each has their own issues?
If I watch a dolby vision movie on the x700 connected to an lg oled, and I suppose what I get is tv led dolby vision, will there be any issue?
yes, two different issues. Again, forget about LLDV if you have an LG TV (or any recent TVs I guess).
Slennox wrote:
Sat Sep 24, 2022 9:21 am
Hi RESET_9999,
The link is not working anymore. It was very useful. Can you repost it again? Thanks for your great effort.
The link in my signature contains all the info about DV.

Image
legosoff
Posts: 42
Joined: Sun Sep 25, 2022 1:43 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by legosoff »

Hi! 7) MODE.M4= MP4_MUXER Workflows / 4) MODE.4= Apple iOS compatible MP4 after my iPhone 12 Pro max why is the screen green? https://radikal.host/i/photo.1wEtX
sw5163
Posts: 140
Joined: Sat Jun 25, 2022 7:28 am

Re: Dolby Vision now possible through MP4 Mux.

Post by sw5163 »

legosoff wrote:
Sun Sep 25, 2022 1:55 pm
Hi! 7) MODE.M4= MP4_MUXER Workflows / 4) MODE.4= Apple iOS compatible MP4 after my iPhone 12 Pro max why is the screen green? https://radikal.host/i/photo.1wEtX
It's most likely caused by the additional mapping data in FEL RPU.
sw5163 wrote:
Tue Sep 06, 2022 12:28 am
staknhalo wrote:
Mon Sep 05, 2022 10:54 pm
You see flashing color artifacts as a result of RPU being improperly misaligned, but processed (or attempted, it's affecting it in some way)
I think those are caused by processing "reshaping data" in RPU (polynomial, and MMR mapping).

From my understanding, P5 RPU has "reshaping data" for ICtCp->YCbCr.
P8.1 RPU doesn't need "reshaping data" for HDR10->HDR10.
P8.4 RPU has "reshaping data" for HLG->PQ.
P7 RPU has "reshaping data" for processing the weird colour in EL (I'm not sure what it really does)

MPV can adapt those polynomial, and MMR mapping for ICtCp->YCbCr, HLG->HDR10 etc.
However, it can't process EL and merge that with BL like proper dolby decoding engine.
Resulting in wrongly processing those "reshaping data" on BL.

I think RPU consists ("reshaping data" for colour space transformation) + (Levels for brightness/contrast trimming)
So you can see some artifacts when scene/brightness change, but it's wrong.
And MPV just abandons all the brightness/contrast trimming.

It’s also probably the reason why it’s so important to “remove_mapping” when converting FEL->MEL

I'm not sure about this, please point out my mistakes, many thanks.
I'm not sure if RESET_9999 's script supports "remove_mapping", you may need to wait for his guidance.
If not, you can also do it manually https://www.avsforum.com/threads/apple- ... n.3252865/
RESET_9999
Posts: 1853
Joined: Mon Aug 05, 2019 7:12 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by RESET_9999 »

yes, all the workflows except the manual one remove the mapping.( hevc input workflow 1: since I didn't expect someone to input raw p7 hevc, i dont even remember adding support for p7 there lol)
His file looks like a real profile 5 though. I don't have any apple devices so I can't help him.
legosoff
Posts: 42
Joined: Sun Sep 25, 2022 1:43 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by legosoff »

sw5163 wrote:
Mon Sep 26, 2022 12:13 am
legosoff wrote:
Sun Sep 25, 2022 1:55 pm
Hi! 7) MODE.M4= MP4_MUXER Workflows / 4) MODE.4= Apple iOS compatible MP4 after my iPhone 12 Pro max why is the screen green? https://radikal.host/i/photo.1wEtX
It's most likely caused by the additional mapping data in FEL RPU.
sw5163 wrote:
Tue Sep 06, 2022 12:28 am
staknhalo wrote:
Mon Sep 05, 2022 10:54 pm
You see flashing color artifacts as a result of RPU being improperly misaligned, but processed (or attempted, it's affecting it in some way)
I think those are caused by processing "reshaping data" in RPU (polynomial, and MMR mapping).

From my understanding, P5 RPU has "reshaping data" for ICtCp->YCbCr.
P8.1 RPU doesn't need "reshaping data" for HDR10->HDR10.
P8.4 RPU has "reshaping data" for HLG->PQ.
P7 RPU has "reshaping data" for processing the weird colour in EL (I'm not sure what it really does)

MPV can adapt those polynomial, and MMR mapping for ICtCp->YCbCr, HLG->HDR10 etc.
However, it can't process EL and merge that with BL like proper dolby decoding engine.
Resulting in wrongly processing those "reshaping data" on BL.

I think RPU consists ("reshaping data" for colour space transformation) + (Levels for brightness/contrast trimming)
So you can see some artifacts when scene/brightness change, but it's wrong.
And MPV just abandons all the brightness/contrast trimming.

It’s also probably the reason why it’s so important to “remove_mapping” when converting FEL->MEL

I'm not sure about this, please point out my mistakes, many thanks.
I'm not sure if RESET_9999 's script supports "remove_mapping", you may need to wait for his guidance.
If not, you can also do it manually https://www.avsforum.com/threads/apple- ... n.3252865/
Thanks for the reply. How do I re-process, 4) MODE.P= / 2) MODE.2= right?
RESET_9999
Posts: 1853
Joined: Mon Aug 05, 2019 7:12 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by RESET_9999 »

legosoff wrote:
Mon Sep 26, 2022 8:17 am
Thanks for the reply. How do I re-process, 4) MODE.P= / 2) MODE.2= right?
if your input is a bluray disc folder yes. 7-4-2 or 7-4-3
if it's a P7 mkv then use 7-4-4 or 7-4-5

7-4-1 is only for when you want to mux raw P5/P8 HEVC,AC3,EC3,SRT...
hell001
Posts: 11
Joined: Sat Mar 26, 2022 1:29 am

Re: Dolby Vision now possible through MP4 Mux.

Post by hell001 »

Hi all. Stupid question here, but is there a difference between a 1080p DV layer and 2160p DV layer? There is a release I am trying to hybridize and I have the 4K HDR, but only have access to the 1080p Profile 5 DV. Does anyone have any experience with something like that?
kazuma
Posts: 132
Joined: Fri Nov 08, 2019 9:51 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by kazuma »

RESET_9999 wrote:
Mon Sep 26, 2022 12:51 pm
legosoff wrote:
Mon Sep 26, 2022 8:17 am
Thanks for the reply. How do I re-process, 4) MODE.P= / 2) MODE.2= right?
if your input is a bluray disc folder yes. 7-4-2 or 7-4-3
if it's a P7 mkv then use 7-4-4 or 7-4-5

7-4-1 is only for when you want to mux raw P5/P8 HEVC,AC3,EC3,SRT...
how do i know when it is a profile 7 file?
LV8HD
Posts: 20
Joined: Tue Jan 11, 2022 3:48 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by LV8HD »

Hi, I'm kind of new to this script, and every time I try to measure something (HDR10, HDR10Plus or DoVi) I get many errors. I don't know why, since I'm pretty sure I installed all the required py modules. Anyway, this is the log file:

Code: Select all

Drag and drop an MKV HDR10 file and press enter..C:\Muxing\Nobody.2021.2160p.AMZN.WEB-DL.x265.10bit.HDR10Plus.DDP5.1-SWTYBLZ_chunk.mkv
Extracting track 0 with the CodecID 'V_MPEGH/ISO/HEVC' to the file 'C:\TEMP2_folder\BL.hevc'. Container format: HEVC/H.265 elementary stream
Progress: 100%
min: 0.0050 cd/m2, max: 1000 cd/m2
Extracting HDR10plus...
Reading parsed dynamic metadata... Done.
Reordering metadata... Done.
Generating and writing metadata to JSON file... Done.
Reading JSON file..
Plotting graph..
Traceback (most recent call last):
  File "C:\Muxing\Tools\Dolby_Vision\DoVi_Scripts\tools\hdr10plus_plot.py", line 97, in <module>
    plt.savefig('nits_plot.png', dpi=150)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\pyplot.py", line 977, in savefig
    res = fig.savefig(*args, **kwargs)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\figure.py", line 3058, in savefig
    self.canvas.print_figure(fname, **kwargs)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\backends\backend_qtagg.py", line 85, in print_figure
    super().print_figure(*args, **kwargs)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\backend_bases.py", line 2319, in print_figure
    result = print_method(
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\backend_bases.py", line 1648, in wrapper
    return func(*args, **kwargs)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\_api\deprecation.py", line 415, in wrapper
    return func(*inner_args, **inner_kwargs)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\backends\backend_agg.py", line 541, in print_png
    mpl.image.imsave(
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\matplotlib\image.py", line 1675, in imsave
    image.save(fname, **pil_kwargs)
  File "C:\Users\leona\AppData\Local\Programs\Python\Python310\lib\site-packages\PIL\Image.py", line 2317, in save
    fp = builtins.open(filename, "w+b")
PermissionError: [Errno 13] Permission denied: 'nits_plot.png'
Impossibile trovare il file specificato.
""Nobody.2021.2160p.AMZN.WEB-DL.x265.10bit.HDR10Plus.DDP5.1-SWTYBLZ_chunk_HDR10plus_plot.png"" non è riconosciuto come comando interno o esterno,
 un programma eseguibile o un file batch.
the script has completed...
Premere un tasto per continuare . . .

To be 100% sure I have all the required modules this is my py list:

Code: Select all

Package           Version
----------------- -------
astroid           2.12.10
awsmfunc          1.3.2
colorama          0.4.5
colour-science    0.4.1
cycler            0.11.0
dill              0.3.5.1
ffprobe           0.5
fonttools         4.37.1
ijson             3.1.4
imageio           2.21.2
isort             5.10.1
kiwisolver        1.4.4
lazy-object-proxy 1.7.1
matplotlib        3.5.3
mccabe            0.7.0
mypy              0.971
mypy-extensions   0.4.3
numpy             1.23.3
packaging         21.3
Pillow            9.2.0
pip               22.2.2
platformdirs      2.5.2
plotbitrate       1.0.8.0
pylint            2.15.2
pyparsing         3.0.9
PyQt5             5.15.7
PyQt5-Qt5         5.15.2
PyQt5-sip         12.11.0
python-dateutil   2.8.2
scipy             1.9.1
setuptools        63.2.0
six               1.16.0
tomli             2.0.1
tomlkit           0.11.4
typing_extensions 4.3.0
ujson             5.5.0
VapourSynth       60
vs-rekt           1.0.0
vsutil            0.7.0
wheel             0.37.1
wrapt             1.14.1
Could someone help me?
RESET_9999
Posts: 1853
Joined: Mon Aug 05, 2019 7:12 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by RESET_9999 »

hell001 wrote:
Mon Sep 26, 2022 3:46 pm
Hi all. Stupid question here, but is there a difference between a 1080p DV layer and 2160p DV layer? There is a release I am trying to hybridize and I have the 4K HDR, but only have access to the 1080p Profile 5 DV. Does anyone have any experience with something like that?
you only have to edit L5.
kazuma wrote:
Mon Sep 26, 2022 4:02 pm
how do i know when it is a profile 7 file?
mediainfo ( text view / HDR format):
Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU

you only need to know that information when you are using Workflow.1 (manual). the other workflows auto-detect the input profile.
RESET_9999
Posts: 1853
Joined: Mon Aug 05, 2019 7:12 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by RESET_9999 »

LV8HD wrote:
Mon Sep 26, 2022 4:11 pm
Hi, I'm kind of new to this script, and every time I try to measure something (HDR10, HDR10Plus or DoVi) I get many errors. I don't know why, since I'm pretty sure I installed all the required py modules. Anyway, this is the log
Could someone help me?
interesting, it fails when it tries to save the data into a graph, I have never seen that error and I didn't write that python script so I can't really help you here.( I assure you it's working on my PC)

did you install this version of color science?
https://pypi.org/project/colour-science
hell001
Posts: 11
Joined: Sat Mar 26, 2022 1:29 am

Re: Dolby Vision now possible through MP4 Mux.

Post by hell001 »

RESET_9999 wrote:
Mon Sep 26, 2022 4:18 pm
hell001 wrote:
Mon Sep 26, 2022 3:46 pm
Hi all. Stupid question here, but is there a difference between a 1080p DV layer and 2160p DV layer? There is a release I am trying to hybridize and I have the 4K HDR, but only have access to the 1080p Profile 5 DV. Does anyone have any experience with something like that?
you only have to edit L5.
Sorry, can you clarify what you mean? The phrasing of your answer seems to imply that it doesn't matter that it's 1080p, but I was hoping to hear more about it.
LV8HD
Posts: 20
Joined: Tue Jan 11, 2022 3:48 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by LV8HD »

RESET_9999 wrote:
Mon Sep 26, 2022 4:22 pm
LV8HD wrote:
Mon Sep 26, 2022 4:11 pm
Hi, I'm kind of new to this script, and every time I try to measure something (HDR10, HDR10Plus or DoVi) I get many errors. I don't know why, since I'm pretty sure I installed all the required py modules. Anyway, this is the log
Could someone help me?
interesting, it fails when it tries to save the data into a graph, I have never seen that error and I didn't write that python script so I can't really help you here.( I assure you it's working on my PC)

did you install this version of color science?
https://pypi.org/project/colour-science
I did, as you can see it is in my pip list
RESET_9999
Posts: 1853
Joined: Mon Aug 05, 2019 7:12 pm

Re: Dolby Vision now possible through MP4 Mux.

Post by RESET_9999 »

hell001 wrote:
Mon Sep 26, 2022 4:28 pm
Sorry, can you clarify what you mean? The phrasing of your answer seems to imply that it doesn't matter that it's 1080p, but I was hoping to hear more about it.
You can use my script (Mode.I / Workflow.1) and choose the automatic L5(when the script ask you)...

or

manually:
You convert the RPU to profile 8 as usual and you edit L5 to match the 4k video. E.G. if the 4k video has an active area of 1600px then L5 is:

Code: Select all

{
    "mode": 3,
    "active_area": {
        "crop": false,
        "presets": [
            {
                "id": 0,
                "left": 0,
                "right": 0,
                "top": 280,
                "bottom": 280
            }
        ],
        "edits": {
            "all": 0
        }
    }
}
hell001
Posts: 11
Joined: Sat Mar 26, 2022 1:29 am

Re: Dolby Vision now possible through MP4 Mux.

Post by hell001 »

RESET_9999 wrote:
Mon Sep 26, 2022 4:34 pm
hell001 wrote:
Mon Sep 26, 2022 4:28 pm
Sorry, can you clarify what you mean? The phrasing of your answer seems to imply that it doesn't matter that it's 1080p, but I was hoping to hear more about it.
You can use my script (Mode.I / Worlflow.1) and choose the automatic L5(when the script ask you)...

or

manually:
You convert the RPU to profile 8 as usual and you edit L5 to match the 4k video. E.G. if the video has an active area of 1600px than L5 is:

Code: Select all

{
    "mode": 3,
    "active_area": {
        "crop": false,
        "presets": [
            {
                "id": 0,
                "left": 0,
                "right": 0,
                "top": 280,
                "bottom": 280
            }
        ],
        "edits": {
            "all": 0
        }
    }
}
Thank you, I'll check that out. I've made hybrids before, but not one where the quality on the DV source is different, so I was thrown off. Out of curiosity, what would be the difference if I simply had the 2160p DV layer? Would both layers produce the exact same thing, or is there slight quality loss with the 1080p layer?
Post Reply