Dolby Vision now possible through MP4 Mux.
Re: Dolby Vision now possible through MP4 Mux.
The value in the RPU should be multiplied by 10 000*, for the min.
So the common values: 0.0001 = 1, 0.0050 = 50, etc.
So the common values: 0.0001 = 1, 0.0050 = 50, etc.
Last edited by quietvoid on Mon Oct 25, 2021 3:02 pm, edited 1 time in total.
-
mattmarsden
- Posts: 88
- Joined: Mon Sep 03, 2018 10:36 am
-
mattmarsden
- Posts: 88
- Joined: Mon Sep 03, 2018 10:36 am
Re: Dolby Vision now possible through MP4 Mux.
Make that 10 000.mattmarsden wrote: ↑Mon Oct 25, 2021 2:14 pmSorry to keep going on about this but 0.0050 x 1000 = 5 - is 50 definitely correct for the value?
-
mattmarsden
- Posts: 88
- Joined: Mon Sep 03, 2018 10:36 am
Re: Dolby Vision now possible through MP4 Mux.
Great, thanks - just checking I got it right!quietvoid wrote: ↑Mon Oct 25, 2021 2:29 pmMake that 10 000.mattmarsden wrote: ↑Mon Oct 25, 2021 2:14 pmSorry to keep going on about this but 0.0050 x 1000 = 5 - is 50 definitely correct for the value?
Re: Dolby Vision now possible through MP4 Mux.
Wow, this HDR10+ -> DV stuff seems pretty amazing
It seems to work on Amazons streaming content as well, based on a quick test. However i don't currently have anything i really want to watch through to check, but i'll definitely put some new episodes of The Expanse through this procedure when they arrive (december i believe)
-
BetaExorcist
- Posts: 3
- Joined: Wed Nov 04, 2020 1:14 am
Re: Dolby Vision now possible through MP4 Mux.
I looked at the guide on avsforum but I am having a little trouble with the installing from the Dolby labs GitHub do you think you could explain the installation process or know of some clear documentation or video that can help? I got as far as devenv mp4muxer_2010.sln /Rebuild but I got 2 errors one of which is a fatal one and I am not even sure I am doing it right in the first place.staknhalo wrote: ↑Sat Oct 23, 2021 6:24 pmI wrote up how this idiot does it here:mattmarsden wrote: ↑Sat Oct 23, 2021 5:46 pmThanks for that. Is there an idiots guide on HDR10+ to DV conversion?
https://www.avsforum.com/threads/author ... t-60952335
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Turn HDR10+ metadata into Dolby Vision metadata**
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Command 1: 'hdr10plus_tool extract Video.hevc -o Metadata.json' (Extracts HDR10+ metadata and saves to .json file)
>>Next commands go through Dovi_Tool and v0.5.0 minimum required<<<
Command 2: 'dovi_tool generate -j Extra.json --hdr10plus-json Metadata.json --rpu-out RPUPlus.bin' (combines metadata from edited 'Extra.json' - template is below and you need to do one for every title specifically - and metadata from extracted 'Metadata.json' and combines+converts them into p8 RPU metadata format)
Command 3: 'dovi_tool.exe inject-rpu --input Video.hevc --rpu-in RPUPlus.bin' (Injects HDR10+ generated RPU metadata into HEVC stream turning it into single layer Dolby Vision 8 stream)
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Blank Template for 'Extra.json'
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
{
"length": (title specific framelength here without parenthesis),
"level2": [
{
"target_nits": 100
},
{
"target_nits": 600
},
{
"target_nits": 1000
},
{
"target_nits": 2000
}
],
"level6": {
"max_display_mastering_luminance": (title specific metadata info here without parenthesis),
"min_display_mastering_luminance": (title specific metadata info here without parenthesis),
"max_content_light_level": (title specific metadata info here without parenthesis),
"max_frame_average_light_level": (title specific metadata info here without parenthesis)
}
}
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
error 1: 1>..\..\..\src\mp4_muxer.c : error C4335: Mac file format detected: please convert the source file to either DOS or UNIX format
fatal error: 2>LINK : fatal error LNK1104: cannot open file '<path>\dlb_mp4base\make\mp4muxer\windows_amd64\debug\VS2010\libmp4base.lib'
Re: Dolby Vision now possible through MP4 Mux.
Hello All,
i would like to reduce dolvby vision (profile 5) mp4 file from 9GB to ~3GB by re-encode video in Staxrip.
My file mediainfo looks like below:
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.2@Main
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : dvhe
Codec ID/Info : High Efficiency Video Coding with Dolby Vision
Duration : 25 min 4 s
Bit rate : 22.4 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 0)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.112
Stream size : 3.92 GiB (99%)
Default : Yes
Alternate group : 1
Encoded date : UTC 2021-06-18 06:42:54
Tagged date : UTC 2021-06-18 06:43:27
Color range : Full
Codec configuration box : hvcC+dvcC
what i did to reduce video file size is:
1) extra DV profile 5 by this command:
ffmpeg.exe -i DV_TEST.mp4 -c:v copy -vbsf hevc_mp4toannexb -f hevc - | dovi_tool.exe extract-rpu - -o RPU.bin
2) Setup StaxRip x265 encoder with Profile 5 and path to RPU.bin
3) After re-encode is done i mux hevc to mp4 by executing this command:
mp4muxer.exe --dv-profile 5 --input-file DV_TEST.mp4 --output-file mp4muxer_out.mp4
4) Add audio.eac3 and subtitles are done by this command:
mp4box.exe -add mp4muxer_out.mp4 -add audio.eac3 mp4box_out.mp4
and i got file like below:
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.2@Main
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : hvc1
Codec ID/Info : High Efficiency Video Coding
Duration : 2 min 59 s
Source duration : 3 min 0 s
Bit rate : 21.1 Mb/s
Maximum bit rate : 38.8 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 0)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.106
Stream size : 454 MiB (99%)
Source stream size : 454 MiB (99%)
Default : Yes
Alternate group : 1
Encoded date : UTC 2021-06-18 06:42:54
Tagged date : UTC 2021-10-22 17:05:16
Color range : Full
Codec configuration box : hvcC+dvcC
but when i try play it on my LG oled 55b7v TV from usb drive dolby vision is recognized but when try to move forward it stops play this file and start plays next one.
Could someone guide me where is the problem?
i would like to reduce dolvby vision (profile 5) mp4 file from 9GB to ~3GB by re-encode video in Staxrip.
My file mediainfo looks like below:
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.2@Main
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : dvhe
Codec ID/Info : High Efficiency Video Coding with Dolby Vision
Duration : 25 min 4 s
Bit rate : 22.4 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 0)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.112
Stream size : 3.92 GiB (99%)
Default : Yes
Alternate group : 1
Encoded date : UTC 2021-06-18 06:42:54
Tagged date : UTC 2021-06-18 06:43:27
Color range : Full
Codec configuration box : hvcC+dvcC
what i did to reduce video file size is:
1) extra DV profile 5 by this command:
ffmpeg.exe -i DV_TEST.mp4 -c:v copy -vbsf hevc_mp4toannexb -f hevc - | dovi_tool.exe extract-rpu - -o RPU.bin
2) Setup StaxRip x265 encoder with Profile 5 and path to RPU.bin
3) After re-encode is done i mux hevc to mp4 by executing this command:
mp4muxer.exe --dv-profile 5 --input-file DV_TEST.mp4 --output-file mp4muxer_out.mp4
4) Add audio.eac3 and subtitles are done by this command:
mp4box.exe -add mp4muxer_out.mp4 -add audio.eac3 mp4box_out.mp4
and i got file like below:
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.2@Main
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : hvc1
Codec ID/Info : High Efficiency Video Coding
Duration : 2 min 59 s
Source duration : 3 min 0 s
Bit rate : 21.1 Mb/s
Maximum bit rate : 38.8 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 0)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.106
Stream size : 454 MiB (99%)
Source stream size : 454 MiB (99%)
Default : Yes
Alternate group : 1
Encoded date : UTC 2021-06-18 06:42:54
Tagged date : UTC 2021-10-22 17:05:16
Color range : Full
Codec configuration box : hvcC+dvcC
but when i try play it on my LG oled 55b7v TV from usb drive dolby vision is recognized but when try to move forward it stops play this file and start plays next one.
Could someone guide me where is the problem?
Re: Dolby Vision now possible through MP4 Mux.
Dolby provides binaries: https://github.com/DolbyLaboratories/dl ... master/binBetaExorcist wrote: ↑Tue Oct 26, 2021 7:17 amI looked at the guide on avsforum but I am having a little trouble with the installing from the Dolby labs GitHub do you think you could explain the installation process or know of some clear documentation or video that can help? I got as far as devenv mp4muxer_2010.sln /Rebuild but I got 2 errors one of which is a fatal one and I am not even sure I am doing it right in the first place.
error 1: 1>..\..\..\src\mp4_muxer.c : error C4335: Mac file format detected: please convert the source file to either DOS or UNIX format
fatal error: 2>LINK : fatal error LNK1104: cannot open file '<path>\dlb_mp4base\make\mp4muxer\windows_amd64\debug\VS2010\libmp4base.lib'
-
Tormented12
- Posts: 13
- Joined: Tue Oct 26, 2021 4:15 pm
Re: Dolby Vision now possible through MP4 Mux.
I have a question regarding encoding a file to 1920x1080p and add the Dolby Vision later. Somehow, I don't get the right file after RPU insertion.
I have encoded a Game of Thrones Episode (4K REMUX, which is Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU). I encoded it without cropping, (which I do for every encode, also movies, I just resize it from 3840x2160 to 1920x1080).
It got me an 1080p episode, which is HDR10. I used the following command to change the .mkv file to hevc:
ffmpeg -y -i GOT.S01E01.mkv -an -c:v copy -f hevc GOT.S01E01.hevc
After this, I use the command to extract the RPU from the HEVC with mode 2:
dovi_tool -m 2 extract-rpu GOT.S01E01.hevc, which gives me an RPU.bin, which, I think should be converted to profile 8.
After this, I use the ffmpeg command to change the re-encoded file from .mkv file to hevc.file. I then usethe following command to inject the RPU into the re-encoded HEVC.file:
dovi_tool inject-rpu -i GOT.S01E01.HDR.hevc --rpu-in RPU.bin -o injected_output.hevc
But somehow, I doesn't work for me. It keeps begin SMPTE 2086, HDR10. Dolby Vision won't be visible in the hevc output file. When I mux the hevc.file to .mkv, then it still is only HDR10, and not Dolby Vision.
What is the part where I screw up? I'm doing it somewhere, but I just can't put my finger on it. Or is it a cropping thing? Some help with this would be very appreciated!
Regards,
Tormented12
I have encoded a Game of Thrones Episode (4K REMUX, which is Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU). I encoded it without cropping, (which I do for every encode, also movies, I just resize it from 3840x2160 to 1920x1080).
It got me an 1080p episode, which is HDR10. I used the following command to change the .mkv file to hevc:
ffmpeg -y -i GOT.S01E01.mkv -an -c:v copy -f hevc GOT.S01E01.hevc
After this, I use the command to extract the RPU from the HEVC with mode 2:
dovi_tool -m 2 extract-rpu GOT.S01E01.hevc, which gives me an RPU.bin, which, I think should be converted to profile 8.
After this, I use the ffmpeg command to change the re-encoded file from .mkv file to hevc.file. I then usethe following command to inject the RPU into the re-encoded HEVC.file:
dovi_tool inject-rpu -i GOT.S01E01.HDR.hevc --rpu-in RPU.bin -o injected_output.hevc
But somehow, I doesn't work for me. It keeps begin SMPTE 2086, HDR10. Dolby Vision won't be visible in the hevc output file. When I mux the hevc.file to .mkv, then it still is only HDR10, and not Dolby Vision.
What is the part where I screw up? I'm doing it somewhere, but I just can't put my finger on it. Or is it a cropping thing? Some help with this would be very appreciated!
Regards,
Tormented12
-
mattmarsden
- Posts: 88
- Joined: Mon Sep 03, 2018 10:36 am
Re: Dolby Vision now possible through MP4 Mux.
Try running the muxed mkv through MakeMKVTormented12 wrote: ↑Tue Oct 26, 2021 4:26 pmI have a question regarding encoding a file to 1920x1080p and add the Dolby Vision later. Somehow, I don't get the right file after RPU insertion.
I have encoded a Game of Thrones Episode (4K REMUX, which is Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU). I encoded it without cropping, (which I do for every encode, also movies, I just resize it from 3840x2160 to 1920x1080).
It got me an 1080p episode, which is HDR10. I used the following command to change the .mkv file to hevc:
ffmpeg -y -i GOT.S01E01.mkv -an -c:v copy -f hevc GOT.S01E01.hevc
After this, I use the command to extract the RPU from the HEVC with mode 2:
dovi_tool -m 2 extract-rpu GOT.S01E01.hevc, which gives me an RPU.bin, which, I think should be converted to profile 8.
After this, I use the ffmpeg command to change the re-encoded file from .mkv file to hevc.file. I then usethe following command to inject the RPU into the re-encoded HEVC.file:
dovi_tool inject-rpu -i GOT.S01E01.HDR.hevc --rpu-in RPU.bin -o injected_output.hevc
But somehow, I doesn't work for me. It keeps begin SMPTE 2086, HDR10. Dolby Vision won't be visible in the hevc output file. When I mux the hevc.file to .mkv, then it still is only HDR10, and not Dolby Vision.
What is the part where I screw up? I'm doing it somewhere, but I just can't put my finger on it. Or is it a cropping thing? Some help with this would be very appreciated!
Regards,
Tormented12
-
Tormented12
- Posts: 13
- Joined: Tue Oct 26, 2021 4:15 pm
Re: Dolby Vision now possible through MP4 Mux.
It worked. It now has the following in MediaInfo:
Dolby Vision, Version 1.0, dvhe.08.03, BL+RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible
Is this the right profile? Sometimes I see 08.06? If I encode 3840x2160 -> 1920x1080 without cropping, will I need to use the cropping feature from dovi_tool? Or wont it matter to use if the encode isn't cropped? And if so, do I manually need to set the cropping offsets?
-
BetaExorcist
- Posts: 3
- Joined: Wed Nov 04, 2020 1:14 am
Re: Dolby Vision now possible through MP4 Mux.
I am trying to get the DV8 + HDR10 BL single layer with the yuesope's tool and I keep getting the same error:
and when I try to use the Dovi tool I get this message:Exception in thread Thread-5:SIS: 0.0% BL_EL_RPU WRITING: 0.0% (BL AUs: 105 EL AUs: 52)
Traceback (most recent call last):
File "E:\Video\Dolby Vision\v0.0.4_BETA_TEST_FEL_TO_MEL_PLUS_UHDBD_TO_81__PLUS_SKIP_HDR10plus__PLUS_EXPERIM_MUXER_17102020\python-3.7.6.amd64\lib\threading.py", line 926, in _bootstrap_inner
self.run()
File "src\app.py", line 929, in run
self.write(access_unit)
File "src\app.py", line 912, in write
nalu.data.prepend("0x00000001")
AttributeError: 'int' object has no attribute 'prepend'
BL_ANALYSIS: 0.0% EL_ANALYSIS: 0.0% BL_EL_RPU WRITING: 0.0% (BL AUs: 124 EL AUs: 52)
BL_ANALYSIS: 0.0% EL_ANALYSIS: 0.0% BL_EL_RPU WRITING: 0.0% (BL AUs: 515 EL AUs: 502)
I was wondering if anyone knows how to fix this or if there is something else I can use?E:\Video\Dolby Vision\dovi_tool-1.1.3-x86_64-pc-windows-msvc\dist>dovi_tool -m 2 extract-rpu EL_RPU.hevc
thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', C:\Users\runneradmin\.cargo\registry\src\github.com-1ecc6299db9ec823\hevc_parser-0.2.0\src\hevc\slice.rs:39:55
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Re: Dolby Vision now possible through MP4 Mux.
So I've tried using mp4muxer and I've converted this mkv file:
Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
to this mp4 file:
Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
The mp4 file plays fine on my LG C7 and even the DV logo is displayed. Is it possible it could work or do I just get some sort of fake DV?
Re: Dolby Vision now possible through MP4 Mux.
I don't know. You could try remuxing the file here: viewtopic.php?p=113537#p113537
In the same way, if you see changes then it should probably work.