View Full Version : [DDVT Tool] Dolby Vision RPU Demuxing / Injecting / Editing.
-QfG-
4th December 2021, 22:16
DDVT Tool Download Folder on MEGA.
(The tool based on quietvoids tools)
-Demuxing DV Metadata from MKVs/MP4s.
-Convert HDR10+ Metadata to DoVi Metadata (Experimental).
-Convert Profile 7/5 Metadata to Profile 8.1.
-Inject DoVi Metadata in Streams.
-Easy Delay Adjustment in Injector.
-Complete Open Source Batch Scripts!
Credits to quietvoid for his awesome tools.
Credits to Atak_Snajpera for the BorderDetect tool.
https://i.imgur.com/33IWTl9.png
https://i.imgur.com/n5LCixv.png
https://i.imgur.com/VNNQXDd.png
>> DOWNLOAD via GITHUB (https://github.com/DonaldFaQ/DDVT) <<
quietvoid
4th December 2021, 23:14
The mastering display metadata you used is correct.
For the min value, it is 10000x the float value. So 10000 * 0.0001 = 1.
Max stays the same.
-QfG-
5th December 2021, 01:17
Ok, thank you quietvoid.
-QfG-
5th December 2021, 04:13
i have created 2 little Batch scripts, one Demuxer and one Injector. With this scripts you can simply:
- Change DoVi Profile 7,5 to Profile 8
- Adding Delays (useful for Hybrid Releases)
- Convert HDR10+ Metadata to DoVi Profile 8 Metadata
- Delete HDR10+ Metadata from Videostream
https://i.imgur.com/XNprZRb.png
https://workupload.com/file/GWpvx2dzvcs
quietvoid many thanks for this awesome tools.
Nico8583
5th December 2021, 11:44
Hi,
I have a question : now if we can convert HDR10+ to DoVi, is it possible to convert DoVi to HDR10+ ?
Thanks !
quietvoid
5th December 2021, 14:48
Hi,
I have a question : now if we can convert HDR10+ to DoVi, is it possible to convert DoVi to HDR10+ ?
Thanks !
In theory it is, but there's no implementation for it.
Nico8583
5th December 2021, 20:00
Thank you, do you plan to add it later ?
quietvoid
5th December 2021, 20:03
No, I have no way to test anything related to HDR10+.
shodan5000
5th December 2021, 21:47
i have created 2 little Batch scripts, one Demuxer and one Injector.
Thank you very much! I am having an issue though. I'm testing a HDR10+ film and running it through the demuxer batch file to convert to DV. Everything seems to go just fine in the conversion and it appears to complete successfully. However, I can't find any resulting RPU.bin file. The generated folder is completely empty.
I've also tested a DV film and that process seems to work well and leaves a generated RPU.bin file.
Also, since dovi_tool is capable of converting the RPU to be profile 8.1 compatible, why is that option not available and only profile 8 is shown? Can that be added?
RanmaCanada
5th December 2021, 22:43
I hate to ask, but are there any plans to make a gui, even a basic one? This is fantastic work, seriously, it's just I am no longer comfortable with command lines in my "old" age haha (decades of AIX in my youth has taken it's toll). If I could, I would buy both you and quietvoid some pizza, or beer, or coffee, or chocolates/candy haha whatever you'd prefer!
von Suppé
6th December 2021, 09:22
Eventhough I got myself accustomed to do every step with the cli of quietvoid's tools, your scripts are welcome and handy additions. Love the drag & drop support.
Thanks, -QfG-
shodan5000
13th December 2021, 00:38
Nothing? No follow-up at all?
-QfG-
28th December 2021, 16:22
Here my newest scripts. Credits to @quietvoid for his awesome Tools. But i still have problems with the HDR10+ to DV conversion. I'm to stupid for this.
If anyone can fix the JSON script for HDR10+ converting, please tell it me.
Whats new?
I have many trouble with FFMPEG, so for MKV files i use mkvextract to demux and for mp4 files mp4box.
You can:
DEMUXER
-Extract RPU from Profile 5,7,8 and switch to profile 8.
-Erase HDR10+ Metadata during extracting.
-Crop the target RPU.
INJECTOR
-You can inject RPU into HDR Stream.
-You can discard HDR10+ Metadata in source stream.
-You can simply Edit Frames for hybrid releases.
-You can mux the raw hevc stream into mkv container (using mkvmerge) with correct DV infos.
Known Bugs:
-HDR10+ to DV Conversion will not working (JSON Script Error)
Everyone can change and fix something on the scripts without any permissions.
Newest Scripts are here:
https://1fichier.com/?6h70dlix91tsgmzaelar
Preview Pictures:
https://i.imgur.com/jrHbp7T.png
https://i.imgur.com/XZ8L4Eh.png
Also, since dovi_tool is capable of converting the RPU to be profile 8.1 compatible, why is that option not available and only profile 8 is shown? Can that be added?
If u convert the RPU in Profile 8 and inject this in an SDR Stream it is 8.2 and in an HDR Stream it is 8.1.
shodan5000
29th December 2021, 02:30
I'm just not understanding the operation here. Apologies in advance, but could you baby step the operation of this for me. I've dropped a profile 5 video onto the demuxer and it creates a folder with the newly created profile 8 RPU in it, nothing else. Now what? I have no other file except the original profile 5 video to drop onto the injector. The injector will not accept this file to operate. How exactly, in steps, do you get the new RPU injected correctly?
-QfG-
29th December 2021, 08:29
You need another HDR10 file where you can now inject the DV RPU. DV Profile 5 Videos are only DV5 without HDR Fallback.
von Suppé
29th December 2021, 13:54
:thanks: for the new scripts, -QfG-
shodan5000
29th December 2021, 18:34
You need another HDR10 file where you can now inject the DV RPU. DV Profile 5 Videos are only DV5 without HDR Fallback.
Thank you for the response. However, I'm even more confused now lol. Is it not one of the points of this program is the ability to convert profile 5 into profile 8 and then inject that?
Cilow
1st January 2022, 20:45
Yes. You need to convert the RPU File from Profile 5 to Profile 8 and then inject it back into the MKV File.
Profile 5 is DV Only, which has no Fallback to HDR10. So in case you play this File (with Profile 5) on a non-dv TV, you will have no Picture or maybe a Picture which will not shown correct.
Thats bc you need to convert it to Profile 8. Profile 8 has a Fallback to HDR and can be played on every player.
von Suppé
2nd January 2022, 21:37
Not having such a file myself, but I understand profile 5 is used for streaming services. It indeed has no backwards compatibility and uses DV's own IPTPQc2 color space.
Converting RPU from profile 5 to 8.1 and injecting it back, I wonder about what HDR10 baselayer it's injected into. Can this be any baselayer (recoded or not) from a different source, like UHDBD? In other words, is RPU interchangable between (a certain number of) profiles the video is deliverd in?
benwaggoner
3rd January 2022, 19:51
Not having such a file myself, but I understand profile 5 is used for streaming services. It indeed has no backwards compatibility and uses DV's own IPTPQc2 color space.
Converting RPU from profile 5 to 8.1 and injecting it back, I wonder about what HDR10 baselayer it's injected into. Can this be any baselayer (recoded or not) from a different source, like UHDBD? In other words, is RPU interchangable between (a certain number of) profiles the video is deliverd in?
8.1 requires a HDR-10 base layer. I doubt it matters much what the source is, as long as it is high quality and frame-synced to the Profile 5 content as long as the HDR-10 is derived from the DoVi master. If it's a different grade, metadata translation wouldn't be enough.
That said, why? Profile 5 is capable of somewhat better compression efficiency than 8.1, and is a lot more compatible. The only real advantage of 8.1 is that the file is backwards-compatible to HDR-10 displays without any DoVi support.
-QfG-
4th January 2022, 17:37
Update to v0.30. Many Bugfixes, HDR10+ to DV Conversion still working.
https://1fichier.com/?86t4gujfcl3hrv8eezw7
DV Profiles:
DV Profile 7 (UHDs [HDR BL+EL+RPU]) = Dual Layer DV Profile, FEL or MEL. Can be repacked in a single Layer stream (not official supported) via makeMKV. Single Layer mkv needs special Hard/Software for viewing in DV. Fallback to HDR: YES
DV Profile 8 (8.1[HDR BL+RPU] 8.2[SDR BL+RPU] 8.4[HLG BL+RPU]) = Single Layer Dolby Vision with Fallback to HDR if DV is not supported. Official DV Profile, can be played on every DV Player in a MP4 Container.
DV Profile 5 (WEB [HDR BL+RPU]) = Single Layer Dolby Vision without Fallback to HDR if DV is not supported. Official DV Profile, can be played on every DV Player in a MP4 Container.
Can this be any baselayer (recoded or not) from a different source, like UHDBD?
Yes, you can inject a converted Profile 8 RPU in a HDR Videostream, like UHD. The streams must be frame identical, if the stream have a delay you can set the delay with the scripts.
von Suppé
5th January 2022, 21:32
Thanks for both your answers, benwaggoner & -QfG-.
:thanks: for the new scripts
Kill3rWolf
10th January 2022, 00:14
Update to v0.30. Many Bugfixes, HDR10+ to DV Conversion still working.
https://1fichier.com/?86t4gujfcl3hrv8eezw7
Could you provide another link except 1fichier.com? 1fichier.com not working for me. Google Drive, Mega, clicknupload.cc & etc.
RanmaCanada
13th January 2022, 02:21
Could you provide another link except 1fichier.com? 1fichier.com not working for me. Google Drive, Mega, clicknupload.cc & etc.
I would suggest you use a VPN then as I just downloaded it with no problems. It's possible 1fichier might be blocked in your country.
Albano
15th January 2022, 09:12
Update to v0.30. Many Bugfixes, HDR10+ to DV Conversion still working.
https://1fichier.com/?86t4gujfcl3hrv8eezw7
DV Profiles:
DV Profile 7 (UHDs [HDR BL+EL+RPU]) = Dual Layer DV Profile, FEL or MEL. Can be repacked in a single Layer stream (not official supported) via makeMKV. Single Layer mkv needs special Hard/Software for viewing in DV. Fallback to HDR: YES
DV Profile 8 (8.1[HDR BL+RPU] 8.2[SDR BL+RPU] 8.4[HLG BL+RPU]) = Single Layer Dolby Vision with Fallback to HDR if DV is not supported. Official DV Profile, can be played on every DV Player in a MP4 Container.
DV Profile 5 (WEB [HDR BL+RPU]) = Single Layer Dolby Vision without Fallback to HDR if DV is not supported. Official DV Profile, can be played on every DV Player in a MP4 Container.
Yes, you can inject a converted Profile 8 RPU in a HDR Videostream, like UHD. The streams must be frame identical, if the stream have a delay you can set the delay with the scripts.
When I drag and drop mkv file into it, your tool close automatically.
GZZ
15th January 2022, 23:40
Did a MKV file create with MakeMKV with this HDR data:
HDR Info = [Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible]
and converted it to profile 8 and ended up with this:
HDR Info = [Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible]
The Profile 8 mkv file works and plays fine in infuse on my Apple TV 4k. Triggering the Dolby Vision logo on my LG Oled.
I though the Dolby vision layer (its the data in the RPU.bin file) would be larger then 65mb, even though its only single layer.
von Suppé
16th January 2022, 13:57
When I drag and drop mkv file into it, your tool close automatically.
You should not drag a file into the tool's window. Instead, drag your video on one of the "*.cmd" files itself.
GZZ
16th January 2022, 15:45
or just use
DDVT DEMUXER.cmd "MyFile.mkv"
DDVT INJECTOR.cmd "MyFile.mkv"
and keep all files in the same folder.
-QfG-
20th January 2022, 17:39
v0.32 Online via MEGA Folder.
-Updated Dovi_Tool.exe to v.1.45 (created by quietvoid).
-minor bugfixes.
Download in the first post.
Boulder
22nd January 2022, 09:36
I tested the extractor on one mkv file I have, but x265 complains that the RPU file contains a different number of frames compared to the video track. How can I verify this, and is it possible to find out the number of frames in the RPU?
GZZ
22nd January 2022, 12:28
v0.32 Online via MEGA Folder.
-Updated Dovi_Tool.exe to v.1.45 (created by quietvoid).
-minor bugfixes.
Download in the first post.
You should update your script by removing this part, as Dovi_tool now just replace the current layer with the new one.
REM if "%ERRORLEVEL%"=="0" (
REM %RED%
REM echo Dolby Vision Layer found.
REM echo.
REM %YELLOW%
REM echo Only HDR or SDR Streams supported.
REM echo Abort Operation now.
REM goto EXIT
REM )
also you should change this line
No Input File. Drag and Drop a file over this script or type "Dolby Vision Tool.bat <targetfile>".
to something like this:
No Input File. Use DDVT INJECTOR.cmd "YourFilename.mkv/mp4" or DDVT DEMUXER.cmd "YourFilename.mkv/mp4"
GZZ
22nd January 2022, 14:01
Anyone know what the CROP function does, I can specify a new Height and Width where the black bars are cropped out. Can anyone explain what it does ?
quietvoid
22nd January 2022, 15:43
I tested the extractor on one mkv file I have, but x265 complains that the RPU file contains a different number of frames compared to the video track. How can I verify this, and is it possible to find out the number of frames in the RPU?
Not really convenient but if you do `dovi_tool info -i RPU.bin -f 999999` it would error and print out the number of frames.
benwaggoner
23rd January 2022, 01:23
Anyone know what the CROP function does, I can specify a new Height and Width where the black bars are cropped out. Can anyone explain what it does ?
It specifies what's outside of the active image area, and doesn't get dynamic metadata or tone mapping.
Black bars are black bars, and should be presented at display black without tone mapping. Conversely a black pixel in the active image area gets treated as part of the continuous tone image, and might wind up displayed differently than a pixel of identical value in the letterbox.
GZZ
23rd January 2022, 11:28
So If I extract the RPU (no crop) and then apply it on a reencoded cropped movie, then part of the image dont get dynamic data or do I misunderstand it ?
benwaggoner
24th January 2022, 03:19
So If I extract the RPU (no crop) and then apply it on a reencoded cropped movie, then part of the image dont get dynamic data or do I misunderstand it ?
If you have a new file that simply doesn't have the letterboxing, than the active image area and the frame size are identical. You shouldn't need to change any other metadata.
-QfG-
25th January 2022, 23:20
v0.33 Online
-v0.33
*Multiple Instances Support
*Injector RAW File Support
EDIT:
v0.33a Online
-v0.33a
*Fixed bad strings if opened without file.
thx @GZZ
https://forum.doom9.org/showthread.php?p=1961946#post1961946
You should update your script by removing this part, as Dovi_tool now just replace the current layer with the new one.
The line in the injector is correct, the injector can't handle DV files, only HDR/SDR files.
Ryushin
27th January 2022, 16:28
Perhaps my mind is just addled having a cold, but reading GZZ's questions and the answers that were given to him regarding cropping still has me confused.
I have the original UHD source ripped into a MKV using MakeMKV that has the Dolby Vision stream encoded in it. I have another encode from the original source that has the letter box bars cropped out.
I would like to know if I need to use the Crop option when using the Demuxer on the original source that has the letterbox bars before using the Injector on the encoded file that does not have any letterbox bars.
BTW, big thanks for a tool that finally makes it easy to get the DV stream out so we can encode it in our own files. Now I'll have to go through all my UHD disks and find the ones that have Dolby Vision and extract it out.
Options I'd like to see to enable batching is the ability for the Demuxer to specify the output directory of RPU.bin along with perhaps naming it the same as the source file with RPU.bin as as the extension. Along those same lines having the Injector having the option of specifying the location and name of the RPU.bin. Also would be nice if the temp directory was removed after it was done.
von Suppé
28th January 2022, 20:33
@Ryushin
Yes. When extracting RPU from letterboxed source (black bars are part of video), for injecting it back in a cropped version, the crop option is required.
-QfG-
29th January 2022, 01:39
Wrong Informations. Correct answer here:
https://forum.doom9.org/showpost.php?p=1962686&postcount=45
von Suppé
29th January 2022, 10:48
how i understand the --crop function...
Source: 3840 x 2160 Letterboxed - Target 3840 x 1608 none Letterboxed = no crop switch needed
Can you tell me why no crop would be needed here? Please read from here: https://github.com/quietvoid/dovi_tool/issues/39#issuecomment-1010640787
If I understand quietvoid correctly, the crop values don't matter to dovitool. It would set the size of letterbox bars to zero.
Which does make me wonder if "undercropping" would cause issues. With undercropping I mean cropping, but not entirely removing the black bars.
-QfG-
29th January 2022, 11:47
Wrong Informations. Correct answer here:
https://forum.doom9.org/showpost.php?p=1962686&postcount=45
Ryushin
29th January 2022, 17:31
@Ryushin
Yes. When extracting RPU from letterboxed source (black bars are part of video), for injecting it back in a cropped version, the crop option is required.
how i understand the --crop function:
Source: 3840 x 2160 Letterboxed - Target 3840 x 2160 Letterboxed = no crop switch needed
Source: 3840 x 2160 Letterboxed - Target 3840 x 1608 none Letterboxed = no crop switch needed
Source: 3840 x 2160 Letterboxed - Target 1920 x 1080 Letterboxed = no crop switch needed
Source: 3840 x 2160 Letterboxed - Target 1920 x 704 none Letterboxed = crop switch needed
LOL. So some say yes to and some say no cropping. Just to get more clarification I'll ask again Github so I can know what cropping is intended for.
Boulder
29th January 2022, 17:36
My assumption is that whenever the final result doesn't have any black borders, you use the cropping option for the RPU.
quietvoid
29th January 2022, 21:23
My assumption is that whenever the final result doesn't have any black borders, you use the cropping option for the RPU.
Yes that's correct.
GZZ
29th January 2022, 22:00
Yes that's correct.
I makes sense, but how do you know how it crops the RPU?. I mean you will need to crop the end result just like the Crop function works on the RPU file. But as you dont set any crop resolution, how do you know how it cropped it ?
Ex.
Source UHD: 3840 x 2160 -> Crop RPU = Resolution ? - Reencoded and cropped movie: 3840 x 1680.
So what if the Cropped RPU has a resultion of 3840 x 1685 and the reencoded is 3840 x 1680, then its off by 5 pixel (not sure you can see that).
Wouldnt it be better if Dovi_tool took crop (Top, Bottom, Left, Right) values, so the RPU matches the Reencoded movie ?
quietvoid
29th January 2022, 22:12
I makes sense, but how do you know how it crops the RPU?. I mean you will need to crop the end result just like the Crop function works on the RPU file. But as you dont set any crop resolution, how do you know how it cropped it ?
Ex.
Source UHD: 3840 x 2160 -> Crop RPU = Resolution ? - Reencoded and cropped movie: 3840 x 1680.
So what if the Cropped RPU has a resultion of 3840 x 1685 and the reencoded is 3840 x 1680, then its off by 5 pixel (not sure you can see that).
The RPU contains active area offsets, which are set according to the size of the letterbox bars.
For example, a source file with resolution 3840x2160 might have an actual aspect ratio of 2.4 without letterbox bars, so the active area is 3840x1600.
In that case, the RPU has a L5 metadata entry with top and bottom offsets set to 280 pixels.
In playback, some devices would use this offset to apply tone mapping to the active area only.
If the RPU is "cropped", the 280 pixel offsets are set to zero. That indicates to the decoder that the video has no letterbox bars.
If the offsets were kept the same as the original, and the letterbox bars are not in the final video, then some players might overcrop the video on playback.
Wouldnt it be better if Dovi_tool took crop (Top, Bottom, Left, Right) values, so the RPU matches the Reencoded movie ?
You can already do this with the editor. The crop argument is only for convenience.
Say you have a final video of resolution 1920x1080 which contains letterbox bars. And the source is the example above, with actual active area of 3840x1600.
That means the offsets need to be halved to match the new resolution, giving us 140 pixels.
You could edit the RPU active area with this:
{
"mode": 2,
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 140,
"bottom": 140
}
],
"edits": {
"all": 0
}
}
}
-QfG-
29th January 2022, 23:08
Dolby_Vision_Tool_v0.34 Online:
-v0.34
*Added Options Menu (you can create Shell Extensions).
*Added info string to crop function.
*Fixed bad FPS settings by muxing in mkv.
https://i.imgur.com/MCyqYFw.png
cool advertise
30th January 2022, 00:03
You could edit the RPU active area with this:
{
"mode": 2,
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 140,
"bottom": 140
}
],
"edits": {
"all": 0
}
}
}
@-QfG-
Since I am not able to edit the crop values of the rpu, it would be of great use if a future version of the -QfG- tool would allow, after enabling the crop, to set the crop values (left, right, top, bottom) before creating the rpu, in order to adapt it exactly to each encoding.
And I think the left and top crop values are positive, and what to do with the right and bottom crop values? Positive or negative?
Not sure but maybe they all have to be positive (if different from 0).
And finally hdr10plus_tool.exe contained in the -QfG- tool is obsolete (1.2.1), the new version has been released (1.2.2).
By the way, great job to both of you, quietvoid and -QfG-
quietvoid
30th January 2022, 00:24
And I think the left and top crop values are positive, and what to do with the right and bottom crop values? Positive or negative?
Not sure but maybe they all have to be positive (if different from 0).
All active area offset values are positive.
They simply represent the size of the letterbox bars, in pixels.
cool advertise
30th January 2022, 02:28
OK, maybe now I understand.
So if I want to do an x265 encode and crop the top and bottom (or left and right) letterbox bars, dovi_tool allows this via the -c command or the CROP RPU "YES" option of the -QfG- tool. If you don't cut letterbox bars then don't use -c or use CROP RPU "NO" of the -QfG- tool.
There is no way or need to specify how many pixels these letterbox bars are via dovi_tool, if coding using crop.
The editor allows via a json configuration file, in case the encoding has letterbox bars and is therefore not cropped to specify the pixel size of these bars by skipping the default ones, or something like that.
I'm writing because I don't have a Dolby Vision TV, and I can't do tests, but I think I understand this.
halls
30th January 2022, 10:48
Hi!
Sorry, worng thread
-QfG-
30th January 2022, 16:13
v0.35 Online
-v0.35
*Added Active Area Editor in Injector.
*Updated hdr10plus_tool.exe to v1.2.2.
https://i.imgur.com/gtbBI6Q.png
halls
30th January 2022, 17:20
Hi!
I know this isn't the specific thread, but i need a little help.
How can i extract the dolby vision meta datas to .xml format?
I have rpu.bin and .json files with using dovi_tool
I need this format /.xml/ for an program.
Thank You!
quietvoid
30th January 2022, 17:30
Hi!
I know this isn't the specific thread, but i need a little help.
How can i extract the dolby vision meta datas to .xml format?
I have rpu.bin and .json files with using dovi_tool
I need this format /.xml/ for an program.
Thank You!
You can't.
cool advertise
30th January 2022, 19:41
v0.35 Online
-v0.35
*Added Active Area Editor in Injector.
*Updated hdr10plus_tool.exe to v1.2.2.
Perfect, but your injector tool is still missing one main function, namely injecting hdr10+ metadata into a hevc or mkv file.
-QfG-
30th January 2022, 21:12
This is a Dolby Vision Tool, not a HDR10+ Tool. ;). I will look to add HDR10+ Injector support on the next Update.
GZZ
30th January 2022, 21:14
Hi!
I know this isn't the specific thread, but i need a little help.
How can i extract the dolby vision meta datas to .xml format?
I have rpu.bin and .json files with using dovi_tool
I need this format /.xml/ for an program.
Thank You!
You can use a online converter to convert from JSON to XML.
It might work, it might not.
https://www.freeformatter.com/json-to-xml-converter.html
-QfG-
30th January 2022, 22:43
-v0.35a
*Minor Bugfixes
*Changed colors of any strings
halls
30th January 2022, 23:17
You can use a online converter to convert from JSON to XML.
It might work, it might not.
https://www.freeformatter.com/json-to-xml-converter.html
Hi!
Yes, i tried.
.JSON file is to big.....
But Thank You!
GZZ
31st January 2022, 09:28
Hi!
Yes, i tried.
.JSON file is to big.....
But Thank You!
There are other free pages, just use Google and search on "Json to XML converter" and then try them all out.
cool advertise
1st February 2022, 04:37
This is a Dolby Vision Tool, not a HDR10+ Tool. ;). I will look to add HDR10+ Injector support on the next Update.
I know how to inject or extract HDR10+ metadata, but if you include in a future version also the extraction of HDR10+ metadata in the demuxer the tool would become a complete dolby vision and HDR10+ management tool.
Only if you want to of course.
shodan5000
1st February 2022, 17:28
I know how to inject or extract HDR10+ metadata, but if you include in a future version also the extraction of HDR10+ metadata in the demuxer the tool would become a complete dolby vision and HDR10+ management tool.
Only if you want to of course.
You might also be interested in HDR-Multi-Tool-Gui if HDR10+ is important to you. It does Dolby as well.
https://github.com/jlw4049/HDR-Multi-Tool-Gui
-QfG-
1st February 2022, 23:49
-v0.36
*HDR10+ Demuxing / Injecting Support.
cool advertise
2nd February 2022, 09:52
-v0.36
*HDR10+ Demuxing / Injecting Support.
Thank you, very good work.
I don't want to be wrong, but shouldn't it be possible to edit the active area while demuxing?
-QfG-
2nd February 2022, 14:59
Thank you, very good work.
I don't want to be wrong, but shouldn't it be possible to edit the active area while demuxing?
You need the resolution of the target video, i think in the injector is the better solution.
quietvoid
2nd February 2022, 15:16
All static edits that don't require modifying a specific frame can technically be done, but it's not implemented in dovi_tool currently.
So, you can't edit anything other than doing mode/crop right now.
von Suppé
3rd February 2022, 11:53
-v0.36
*HDR10+ Demuxing / Injecting Support.
Cool!
A big :thanks: to both quietvoid and -QfC- for continually improving tools and scripts. Highly appreciated!
-QfG-
5th February 2022, 10:51
-v0.37
*Updated dovi_tool.exe to v1.4.6.
*Added DDVT_FRAMEINFO.cmd.
-QfG-
5th February 2022, 11:29
@quietvoid
I have seen that in any RPU.bin's CM29 Metadata not Level5 specified.
Is that the same if i set Active Area to 0,0,0,0?
For example:
"cmv29_metadata": {
"num_ext_blocks": 3,
"ext_metadata_blocks": [
{
"Level1": {
"min_pq": 12,
"max_pq": 2105,
"avg_pq": 819
}
},
{
"Level2": {
"target_max_pq": 2081,
"trim_slope": 2048,
"trim_offset": 2048,
"trim_power": 2048,
"trim_chroma_weight": 2048,
"trim_saturation_gain": 2048,
"ms_weight": 2048
}
},
{
"Level6": {
"max_display_mastering_luminance": 4000,
"min_display_mastering_luminance": 50,
"max_content_light_level": 444,
"max_frame_average_light_level": 393
}
}
]
}
},
"rpu_data_crc32": 1251925187
}
von Suppé
5th February 2022, 14:03
As quietvoid's standalone dovi_tool accepts elementary streams only, I am quite surprised to find out they aren't supported in your scripts, -QfC-. Do you have plans for it?
quietvoid
5th February 2022, 15:28
I have seen that in any RPU.bin's CM29 Metadata not Level5 specified.
Is that the same if i set Active Area to 0,0,0,0?
Probably, but Dolby recommends that L5 should always be present to avoid issues.
-QfG-
5th February 2022, 20:45
As quietvoid's standalone dovi_tool accepts elementary streams only, I am quite surprised to find out they aren't supported in your scripts, -QfC-. Do you have plans for it?
INJECTOR handles RAW Streams, in the next Update i will add DEMUXER RAW Stream support. Also i'm working on an AutoCrop Function.
Probably, but Dolby recommends that L5 should always be present to avoid issues.
Thanks. I'm wondering, because that was in an official Profile 5 RPU.
-QfG-
6th February 2022, 15:11
-v037a
*Added AutoDetect Borders in AA Editor (works only with containers).
*Added Profile 8 to Profile 7 Conversion.
cool advertise
6th February 2022, 16:54
-v037a
*Added AutoDetect Borders in AA Editor (works only with containers).
*Added Profile 8 to Profile 7 Conversion.
Hi, version 0.37a has a problem, in the demuxer, opening a file with dolby vision profile 7, option 4 (Convert RPU), shows only Profile 8 and it is not possible to change it as in previous versions ( Leave untouched).
-QfG-
6th February 2022, 17:28
-v0.37a - FIXED
*Fixed troubleshooting with profile switch in Profile 7 options.
Thx for the response.
cool advertise
6th February 2022, 19:59
If I want to crop a video with source resolution 3840x2160p in dolby vision 8.1, and the letterboxes bars are above 277 px and below 277 px, can I use the -c command of dovi_tool (or the crop RPU option of the -QfG- tool) with avisynth+ and crop like this?
crop(0, 276, 0, -276)
to be compatible with the height (divisible by 2) rule (mod 2) of avisynth?
Without resizing and with a final resolution of the re-encoded video of
3840x1608p
?
Is this correct?
-QfG-
7th February 2022, 02:56
Yes. Simply use the Crop RPU Function of the DEMUXER or use the Active Area Editor in INJECTOR and set all entries to 0.
-v0.37b
*Minor Bugfixes
*Updated mkvtoolnix to v 65.0.0.0
cool advertise
7th February 2022, 07:32
Yes. Simply use the Crop RPU Function of the DEMUXER or use the Active Area Editor in INJECTOR and set all entries to 0.
-v0.37b
*Minor Bugfixes
*Updated mkvtoolnix to v 65.0.0.0
Thanks for the answer, ffmpeg 64bit is up to version 5.00 while 32bit is not. ;)
von Suppé
8th February 2022, 14:26
the letterboxes bars are above 277 px and below 277 px
crop(0, 276, 0, -276)
Thinking about this example, it does raise some questions about RPU's usage with under- and overcropped video.
Undercropping your video (containing 277px black bars) with 276px would leave 2 black lines. As such, shouldn't you better set TOP and BOTTOM crop values both to "1" in -QfC- injector? Using --crop switch would set all offsets to zero. No intention to being pedant here, but I wouldn't know how precise these values need to be and what the chances are of introducing artefacts.
On te opposite side, when overcropping video (even slightly), I also wonder whether (cropped) RPU can get corrupted .
Imagine your same video, but cropping with 280 instead, leaving 3840x1600, which is widely used. Extract RPU with --crop switch: great, no offsets.
But what about this "active area"? I don't know exactly how further this is used in DV's metadata. But I can imagine cropped RPU being left incompatible because of "shrunk active area" as invoked by the overcrop.
cool advertise
9th February 2022, 19:23
DDVT Tool
I think there is a bug in the injector, if you open a simple hdr10 file in mkv (and maybe mp4 as well) and then first inject hdr10+ metadata, enabling mux stream in mkv, and then reopen the created file in the injector, injecting dolby vision 8 (8.1) metadata, and enabling mux stream in mkv again, it fails.
And vice versa, injecting dolby vision metadata first and then hdr10+, with mux stream in mkv enabled it fails.
It works instead without enabling mux stream in mkv.
My mkv test file was 10 seconds long and had a hevc track, an ac3 audio track and a jpg attachment.
I think the error occurs because the injector treats the ac3 audio track as if it were the video track.
Attached log
powered by quietvoids tools Copyright (c) 2021 DonaldFaQ
====================================
Dolby Vision Tool INJECTOR
- HDR10+ INJECTOR -
====================================
== SETTINGS ============================================================================================================
Mux Stream in MKV : [YES]
== INJECTING ===========================================================================================================
ATTENTION! You need many HDD Space for this operation.
Please wait. Extracting the Video Layer ...
Extracting track 0 with the CodecID 'A_AC3' to the file 'E:\Dolby Vision Test\dolby_[TEMP].hevc'. Container format: Dolby Digital (AC-3)
Progress: 100%
Done.
Please wait. Injecting the HDR10+ Metadata into stream...
Processing input video for frame order info...
Warning: mismatched lengths. video 0, metadata 229
Metadata will be skipped at the end to match video length
Computing frame indices..
Rewriting file with interleaved HDR10+ NALUs..
Done.
Deleting Temp File - Done.
Please wait. Injecting Videostream into MKV...
Warning: 'E:\Dolby Vision Test\dolby_[HDR10+ INJECTED].hevc' track 0: This audio track contains 859 bytes of invalid data which were skipped before timestamp 00:00:00.000000000. The audio/video synchronization may have been lost.
Warning: 'E:\Dolby Vision Test\dolby_[HDR10+ INJECTED].hevc' track 0: This audio track contains 1 byte of invalid data which was skipped before timestamp 00:00:03.456007968. The audio/video synchronization may have been lost.
Done.
Please wait. Cleaning and Moving files ...
Deleting Temp File - Done.
All Operations successful.
== EXIT ================================================================================================================
Press [ENTER] to Exit.
mediainfo of final file
General
Unique ID : 263580156875075198637991821584341121842 (0xC64BB112698BD4E74B26AD2DB5CBBB32)
Complete name : E:\Downloads\Dolby Vision Test\dolby_[HDR10+ INJECTED].mkv
Format : Matroska
Format version : Version 4
File size : 1.33 MiB
Duration : 9 s 632 ms
Overall bit rate mode : Constant
Overall bit rate : 1 159 kb/s
Encoded date : UTC 2022-02-10 15:58:37
Writing application : mkvmerge v65.0.0 ('Too Much') 64-bit
Writing library : libebml v1.4.2 + libmatroska v1.6.4
Cover : Yes
Attachments : cover.jpg
Audio #1
ID : 1
Format : AC-3
Format/Info : Audio Coding 3
Commercial name : Dolby Digital
Codec ID : A_AC3
Duration : 9 s 632 ms
Bit rate mode : Constant
Bit rate : 640 kb/s
Channel(s) : 6 channels
Channel layout : L R C LFE Ls Rs
Sampling rate : 48.0 kHz
Frame rate : 31.250 FPS (1536 SPF)
Compression mode : Lossy
Stream size : 752 KiB (55%)
Language : Italian
Service kind : Complete Main
Default : Yes
Forced : No
Audio #2
ID : 2
Format : AC-3
Format/Info : Audio Coding 3
Commercial name : Dolby Digital
Codec ID : A_AC3
Duration : 7 s 328 ms
Bit rate mode : Constant
Bit rate : 640 kb/s
Channel(s) : 6 channels
Channel layout : L R C LFE Ls Rs
Sampling rate : 48.0 kHz
Frame rate : 31.250 FPS (1536 SPF)
Compression mode : Lossy
Stream size : 572 KiB (42%)
Service kind : Complete Main
Default : Yes
Forced : No
-QfG-
11th February 2022, 20:44
Please wait. Extracting the Video Layer ...
Extracting track 0 with the CodecID 'A_AC3' to the file 'E:\Dolby Vision Test\dolby_[TEMP].hevc'. Container format: Dolby Digital (AC-3)
Progress: 100%
Done.
Why is the first Track [0] an Audio Track?
Please Remux the container first and check if the first Track [0] is an Video Track.
Is that file the result of my tool?
cool advertise
11th February 2022, 21:14
Is that file the result of my tool?
Yes the final file is obtained using your tool, the original file was an mkv and had a hevc video track, an ac3 audio track, and a jpg attachment.
After injecting the dolby vision metadata, I get an mkv with a video track, an audio track and a jpg attachment.
mediainfo log
General
Unique ID : 142179199423562187515235590156012874399 (0x6AF6B7BF5FB93FE33E32113790C5EA9F)
Complete name : E:\Downloads\Dolby Vision Test\dolby_[DV INJECTED].mkv
Format : Matroska
Format version : Version 4
File size : 12.3 MiB
Duration : 9 s 632 ms
Overall bit rate : 10.7 Mb/s
Encoded date : UTC 2022-02-09 21:21:03
Writing application : mkvmerge v65.0.0 ('Too Much') 64-bit
Writing library : libebml v1.4.2 + libmatroska v1.6.4
Cover : Yes
Attachments : cover.jpg
Video
ID : 2
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@Main
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 9 s 551 ms
Bit rate : 10.1 Mb/s
Width : 3 840 pixels
Height : 2 076 pixels
Display aspect ratio : 1.85:1
Frame rate mode : Constant
Frame rate : 23.976 (23976/1000) FPS
Original frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.053
Stream size : 11.5 MiB (94%)
Writing library : x265 3.5+1-ce882936d:[Windows][MSVC 1928][64 bit] 10bit
Encoding settings : hidden
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0050 cd/m2, max: 4000 cd/m2
Maximum Content Light Level : 1000 cd/m2
Maximum Frame-Average Light Level : 755 cd/m2
Audio
ID : 1
Format : AC-3
Format/Info : Audio Coding 3
Commercial name : Dolby Digital
Codec ID : A_AC3
Duration : 9 s 632 ms
Bit rate mode : Constant
Bit rate : 640 kb/s
Channel(s) : 6 channels
Channel layout : L R C LFE Ls Rs
Sampling rate : 48.0 kHz
Frame rate : 31.250 FPS (1536 SPF)
Compression mode : Lossy
Stream size : 752 KiB (6%)
Language : Italian
Service kind : Complete Main
Default : Yes
Forced : No
After opening the latter in the injector, to inject hdr10+ I get 2 ac3 audio tracks contained in one mkv file.
And vice versa, injecting first hdr10+ and then dolby vision i get the same result.
After the first injection the file I get is correct, but as you can see from the mediainfo log, the video track has id 2, the audio track has id 1.
So I think your tool at this point makes the error and the bug occurs at the second injection.
-QfG-
12th February 2022, 07:14
the video track has id 2
-v0.37c
*Fixed wrong ID by video track if muxing with INJECTOR
*Updated FFMPEG to v5.0
cool advertise
12th February 2022, 07:39
-v0.37c
*Fixed wrong ID by video track if muxing with INJECTOR
*Updated FFMPEG to v5.0
There are still bugs, if I first inject dolby vision metadata by enabling mux stream in mkv, the ids are correct, but if I later open the file obtained in the injector to inject hdr10+ metadata, enabling mux stream in mkv, the final file you get from your tool is still an mkv with video track ID 2 and audio track ID 1.
And again, if I first inject hdr10+ metadata by enabling mux stream in mkv, the final file you get from your tool is still an mkv with video track ID 2 and audio track ID 1.
-QfG-
12th February 2022, 08:03
Oh my God i fixed the bug only in the DV Area... Give me few seconds i will upload a fixed version of 0.37c
EDIT:
Done!
Please reupload v0.37c and test again.
cool advertise
12th February 2022, 08:27
Oh my God i fixed the bug only in the DV Area... Give me few seconds i will upload a fixed version of 0.37c
EDIT:
Done!
Please reupload v0.37c and test again.
Now it works, at least for sure with mkv.
Thanks
-QfG-
12th February 2022, 20:51
-v0.38
*Updated MP4Box.exe.
*Added MP4 Mux Support in Injector (only if Input file is MP4 und only for Profile8).
*Added DDVT REMOVER.cmd (Remove HDR10+ and/or DoVi Metadata from MP4/MKV Container)
*Minor Bugfixes
Balling
15th February 2022, 16:32
Dilby Vision IPTPQc2 decoder now works in mpv. Including mmr and poly reshaping.
von Suppé
17th February 2022, 09:36
Is it possible to convert RPU profile of an already extracted RPU.bin file? Or does converting need to take place during demux?
Forgive my ignorance.
zzreel
18th February 2022, 23:54
Is it possible to convert RPU profile of an already extracted RPU.bin file? Or does converting need to take place during demux?
Forgive my ignorance.
I was able to drag and drop the .hevc and replace the RPU with the extract converted one. But for some reason it doesn't work on mkvs directly.
zzreel
18th February 2022, 23:55
Registered just to say thank you for this great tool - this has been fantastic to use, I really appreciate it and the HDR10+ full inclusion is especially much appreciated!
There's no MP4 muxer tool like this yet right? ffmpeg added support for lossless audio tracks now, so I wonder if a MP4 muxer would now be the ultimate solution for DV encodes. (I can't get Visual Studio 2010 to install on my machine so I can't try out dlb_mp4base.)
GPhil
19th February 2022, 10:41
Hey folks,
tried to convert HDR10+ to DV with the newest version, but the following error appeared:
https://thumbs4.imagebam.com/af/78/5c/ME7Z18D_t.png (https://www.imagebam.com/view/ME7Z18D)
What's going wrong?
Best regards
GPhil
Hackerjac
19th February 2022, 11:20
I ran into the same problem a couple of days ago, it was caursed by max_content_light_level & max_frame_average_light_level info was missing
GPhil
19th February 2022, 14:21
And is there a way to fix it?
-QfG-
19th February 2022, 15:21
This happens by HDR10+ Profile B streams. I think because missing HDR values like Max/Min CLL.
von Suppé
19th February 2022, 16:53
This happens by HDR10+ Profile B streams.HDR10+ Profile B from BL movie Jaws seems to work like a charm. No errors, putting out RPU profile 8.
quietvoid
19th February 2022, 17:01
dovi_tool requires complete L6 metadata, there is no default used when the JSON is missing "level6".
A decent default might be MDL 1000/1, with MaxCLL/MaxFALL set to 0.
It is up to the user (or in this case the script) to handle this case.
-QfG-
19th February 2022, 19:29
Thx quietvoid, i take a look how i can handle this problem in the next update.
-QfG-
20th February 2022, 09:28
-v0.39
*Fixed HDR10+ converting without HDR metadata strings.
GPhil
22nd February 2022, 16:16
Everything works like a charm now, thank you very much!
GPhil
23rd February 2022, 20:57
Another question from me as a HDR newbie: is it normal that the tool only gets 4000+ frames from the HDR10+ content while there are almost 200000 frames in the whole video? Or is there an error in some file?
https://thumbs4.imagebam.com/26/30/51/ME837QN_t.png (https://www.imagebam.com/view/ME837QN)
quietvoid
23rd February 2022, 22:09
See https://github.com/quietvoid/hdr10plus_tool/issues/42#issuecomment-1011125971
If it's reencoded with x265, look for "dhdr10-opt" in the encoding settings.
-QfG-
25th February 2022, 14:29
-v0.40
*Support for HEVC RAW streams in DDVT Demuxer.
*Support for HEVC RAW streams in DDVT Remover.
*Fixed DV remove Bug in DDVT Remover.
*New Context Menus (create them with DDVT Options).
zzreel
25th February 2022, 19:58
-v0.40
*Support for HEVC RAW streams in DDVT Demuxer.
*Support for HEVC RAW streams in DDVT Remover.
*Fixed DV remove Bug in DDVT Remover.
*New Context Menus (create them with DDVT Options).
Dude, you're the man. Now if only you can add Atmos to JOC conversion lol
von Suppé
25th February 2022, 22:50
Thanks for continuously working on improvements of your scripts, -QfG-. Highly appreciated.
speedy
26th February 2022, 19:30
Now if only you can add Atmos to JOC conversion lol
What does this mean?
-QfG-
26th February 2022, 23:41
-v0.40a
*Fixed number bug in Demuxer.
*Fixed Frameinfo RPU bug.
What does this mean?
It's a joke. ;)
zzreel
27th February 2022, 06:56
What does this mean?
Sorry lol It *is* a joke.
JOC is Joint Object Coding, which is Dolby Atmos in the E-AC3 format. It's what's used in streaming services' versions of Dolby Vision content, especially. Bluray releases use the TrueHD format. It would be awesome if we could convert TrueHD Atmos to E-AC3 JOC for a compressed audio format, but it's not something anyone's figured out yet.
This is pretty interesting tho: https://learning.dolby.com/hc/en-us/articles/4408217194772-Appendix-C-Dolby-Atmos-Delivery-Codecs-
von Suppé
27th February 2022, 08:33
JOC is Joint Object Coding, which is Dolby Atmos in the E-AC3 format. It's what's used in streaming services' versions of Dolby Vision content, especially. Bluray releases use the TrueHD format.
E-AC3 can be found on (UHD)BD also, where the build-up differs from the 'streaming' version.
-QfG-
27th February 2022, 22:42
-v0.40b
*Fixed major Bug by demuxing Profile7 files.
zzreel
28th February 2022, 17:39
What exactly is the difference for "content mapping version" 2.9 vs 4.0 during HDR10+ conversion to DV?
What's a case where it matters - or is one superior to the other? Or maybe more importantly, how can we tell if the source is 2.9 or 4.0 to match it? I'm not seeing this listed in MediaInfo.
From what I've gathered, I'm assuming 4.0 is better, but I have no idea if HDR10+ metadate carries anything that goes into 4.0 or if it's just 2.9 metadata. (especially since 2.9 is default in this tool?)
quietvoid
28th February 2022, 18:08
It doesn't make a difference for HDR10+ conversion only.
It only matters if you want to add extra metadata.
There's no easy way to check other than looking at the RPU and looking for "cmv40_metadata" in "vdr_dm_data".
rco133
5th March 2022, 18:22
Hi.
I am new to this DV stuff, so I might be doing something wrong.
I have demuxed the main m2ts file from UHD disk, and am wondering about the output from the demuxer, when I run it on the EL file.
Video Info = [Resolution = 1920x1080] [Codec = HEVC-10Bit-YUV-4:2:0] [Frames = n.a.] [FPS = 23.976]
HDR Info = [Dolby Vision, Version 1.0, dvhe.07.03, BL+EL+RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible]
Shouldn't it report "dvhe.07.06" as this is a UHD bluray disk?
If I open the disc in makemkv is says "dvhe.07.06".
Is "dvhe.07.03" even a valid profile? Seems like 03 is "Reserved".
But as I am new at this, I might be mixing up things totally :-)
Thanks in advance.
rco133
nevcairiel
5th March 2022, 19:08
dvhe.07.03 means profile 7, level 3 - which is perfectly valid. This is likely because you are looking at the EL stream, which is only 1920x1080, hence the video only being level 3, and not level 6 like the main UHD stream.
rco133
6th March 2022, 10:34
dvhe.07.03 means profile 7, level 3 - which is perfectly valid. This is likely because you are looking at the EL stream, which is only 1920x1080, hence the video only being level 3, and not level 6 like the main UHD stream.
Thanks for the pointer.
As I wrote I am quite new to this DV stuff, and reading the DolbyVisionProfilesLevels made me come to that conclusion :-)
rco133
Albano
11th March 2022, 17:59
@-QfG-
Thanks for sharing but how to run your tool.
https://i.imgur.com/CMJzHIn.png
von Suppé
12th March 2022, 08:44
Read this post and one down: https://forum.doom9.org/showthread.php?p=1961404#post1961404
von Suppé
12th March 2022, 10:14
Hi -QfG-
Will elementary streams for the DDVT remover be supported some time?
-QfG-
12th March 2022, 20:43
Hi -QfG-
Will elementary streams for the DDVT remover be supported some time?
In the next update.
-v0.40c
*RAW Stream Support for all Scripts.
*Turn off Autodetect Borders Feature for RAW Streams.
*DV and HDR10+ Metadata can now replaced in Stream.
Cedvano
15th March 2022, 11:01
Thanks for this software.
If I grab the RPU and compress the video and inject the RPU, will it work?
-QfG-
15th March 2022, 18:16
Thanks for this software.
If I grab the RPU and compress the video and inject the RPU, will it work?
Yes, if your video is hevc and hdr encoded.
Cedvano
16th March 2022, 10:58
Yes, if your video is hevc and hdr encoded.
Thank you.
Cedvano
21st March 2022, 17:45
Hi,
I have an error for some videos.
Invalid pps index
is it possible to repair the dolby vision of a movie?
quietvoid
21st March 2022, 18:04
Hi,
I have an error for some videos.
is it possible to repair the dolby vision of a movie?
Can you share a sample that reproduces the error?
Cedvano
21st March 2022, 19:52
Can you share a sample that reproduces the error?
I can't send sample (for copyright) but I have build the last version from Github of Dovi_tool and it's work.
gacopl
25th March 2022, 20:08
Hi
Thanks for this tool
I created similar tool but for linux to put it on MediaServer/Nas it does everything on autopilot resulting in playable DV MP4, it takes DV5,7,8 or HDR10+ mkv as input
https://github.com/gacopl/dvmkv2mp4/
jboom91
30th March 2022, 16:23
Thank you so much for this software! I have a question about the converting metadata from HDR10+ to Dolby Vision, is there any quality benefit or difference at all in doing so? In my case, I have a 65" 4K television that is capable of HDR10+ and Dolby Vision and has individual video settings for these when detected playing.
quietvoid
30th March 2022, 19:02
Thank you so much for this software! I have a question about the converting metadata from HDR10+ to Dolby Vision, is there any quality benefit or difference at all in doing so? In my case, I have a 65" 4K television that is capable of HDR10+ and Dolby Vision and has individual video settings for these when detected playing.
Converting HDR10+ would in theory be inferior to playing it back natively.
Only parts of the original metadata is used for the Dolby Vision version.
There's no reason to do so if your display supports it.
zzreel
1st April 2022, 23:23
Hey uh, any idea why injecting RPU would result in frame count going from 23.976 to 25? Video length also drops from 2hours 10mins to 2hours 4minutes. Not sure if issue is with extraction/injection or the RPU conversion.
quietvoid
1st April 2022, 23:51
See https://github.com/quietvoid/dovi_tool/issues/134#issuecomment-1085889058
zzreel
2nd April 2022, 00:50
Ah that's exactly it thank you
-QfG-
2nd April 2022, 11:24
Hey uh, any idea why injecting RPU would result in frame count going from 23.976 to 25? Video length also drops from 2hours 10mins to 2hours 4minutes. Not sure if issue is with extraction/injection or the RPU conversion.
If you work with a mkv/mp4 file (not raw file) and you using the "Mux into MKV/MP4" option you didn't have this Bug.
Update to v0.40d
-v0.40d
*Updated MediaInfo to v22.02
*Updated mkvtoolnix to v 66.0.0.0.
*Updated dovi_tool to v1.4.7
*Fixed Minor Bugs
von Suppé
3rd April 2022, 07:16
Is something wrong with latest version 0.40d? Unpacking, 7-Zip seems to hang on ffmpeg.exe. Downloaded & tried several times.
-QfG-
3rd April 2022, 07:53
Extract rar works fine, tested it with 7-Zip 21.07 (x64) and WinRar 6.11d. Download as Standarddownload. In some cases anti-malware block the UPX packed ffmpeg.exe.
von Suppé
4th April 2022, 15:01
I was on older version 7-Zip. Latest version works. Thank you.
rthorntn
6th April 2022, 03:13
Apologies if I missed the answer here (I saw someone ask earlier and get told no but then I saw an update suggesting that the feature had been added), for people with no DV (Samsung TV's) can this tool convert DV to HDR10+? Thanks!
quietvoid
6th April 2022, 16:20
Apologies if I missed the answer here (I saw someone ask earlier and get told no but then I saw an update suggesting that the feature had been added), for people with no DV (Samsung TV's) can this tool convert DV to HDR10+? Thanks!
No, there's no feature to convert Dolby Vision to HDR10+.
rthorntn
8th April 2022, 03:03
Thanks!
-QfG-
10th April 2022, 08:16
-v0.40e
*Fixed container FPS error in INJECTOR.
jboom91
12th April 2022, 15:28
Is there a way to stop the tool from auto exiting? Sometimes I have an error or something doesn't complete correctly when ripping the rpu or injecting an rpu, and if I'm not around my computer I don't see what happened because I think it just auto exits in 30 seconds.
Sorry if this is a noob question, thanks!
-QfG-
12th April 2022, 18:37
Open all Batch Files with an editor, goto ":EXIT" and Change "TIMEOUT 30" with "PAUSE". That's all.
-QfG-
16th April 2022, 12:28
-v0.41
*Add MKVtoMP4 Script.
*Updated mkvtoolnix to v 67.0.0.0.
** Scripts renamed, use DDVT_Options Script for creating new Shell Extensions.
titomoi
17th April 2022, 20:34
great job!
Gser
23rd April 2022, 09:50
I wonder if it would be possible to add pgs to srt subtitle conversion with https://github.com/Tentacule/PgsToSrt like it has been done with https://github.com/gacopl/dvmkv2mp4
von Suppé
23rd April 2022, 10:21
Subtitle conversion is not basically related to Dolby Vision. I wonder if it would ever be implemented.
Even if, the problem with PGS --> srt conversion is that it's subject to reading errors during the OCR process. After which, often - if not always - manual correction is required.
Gser
23rd April 2022, 12:03
Subtitle conversion is not basically related to Dolby Vision. I wonder if it would ever be implemented.
Even if, the problem with PGS --> srt conversion is that it's subject to reading errors during the OCR process. After which, often - if not always - manual correction is required.
Indeed, I have just found it really difficult to mux srts and dolby vision in an mp4 and have it work on my LG C1. With this it actually works, at least with profile 5, still have to test profile 8.
kira0001
30th April 2022, 16:58
Please can you help me with how to convert mkv DV file to mp4 DV... And please can you help me to input video file... Its showing me no input file.. and i don't know how to use ddvt_demuxer.cmd " Myfile" .
. Please can you help me
-QfG-
30th April 2022, 18:42
-v0.41a
*Cropping values from RPU.bin will shown in INJECTOR.
*New Function in DEMUXER called CHECK RPU CROPPING VALUES.
You can fix wrong cropped RPUs directcly.
Works only with Profile 8 MKVs/MP4s and RAW Streams.
Please can you help me with how to convert mkv DV file to mp4 DV... And please can you help me to input video file... Its showing me no input file.. and i don't know how to use ddvt_demuxer.cmd " Myfile" .
. Please can you help me
The simpliest way is to start the "DDVT_OPTIONS.cmd" and add the Shell extensions to your system. Now click with the right mouse button on your videofile and you see the ddvt tool extension in the shell.
I wonder if it would be possible to add pgs to srt subtitle conversion with https://github.com/Tentacule/PgsToSrt like it has been done with https://github.com/gacopl/dvmkv2mp4
Interesting. Will check if i can use this tool for the MKVtoMP4 Converter.
-v0.41b
*Complete reworked Injector. If input file is in mp4/mkv container crop borders will automatically set.
*Fixed wrong FPS Bug with Injector / Check Release.
*Fixed Minor Bugs.
von Suppé
2nd May 2022, 09:33
:thanks: -QfG-
SeeMoreDigital
2nd May 2022, 09:43
As a feature request...
How about an: TS/M2TSTOMP4 muxing option?
-v0.42
*Updated dovi_tool to v1.5.1.
*Updated hdr10plus_tool to v1.2.2.
*Fixed bad Bottom entry after analysing in RPU Output in INJECTOR.
How about an: TS/M2TSTOMP4 muxing option?
i will see if i can implate them.
-v0.43
*INJECTOR supports EL.hevc file for creating DV Profile 7 Single Layer Files.
Copy EL.hevc to source video file directory.
If exist EL.hevc and RPU.bin the tool automatically uses EL.hevc.
*Fixed wrong FPS Bug in REMOVER.
*Minor Bugfixes.
SeeMoreDigital
8th May 2022, 09:24
i will see if i can implate them.Many thanks...
alexflin
8th May 2022, 23:44
Hi, I'm testing this tool with a file to see if I'm able to add the DV to a HDR video, first I use DDVT_DEMUXER to extract the RPU.bin and then I inject with the DDVT_INJECTOR the RPU.bin to another file but i'm stuck in this step
https://i.ibb.co/17YjbR2/image.png (https://ibb.co/HBL3XGg)
cool advertise
9th May 2022, 07:51
Hi, I'm testing this tool with a file to see if I'm able to add the DV to a HDR video, first I use DDVT_DEMUXER to extract the RPU.bin and then I inject with the DDVT_INJECTOR the RPU.bin to another file but i'm stuck in this step
It's simple.
From the screenshot, your video is sdr (uncropped) and not hdr.
At this point if you want dolby vision to be muxed into an mkv file enable option 3 (mux stream in mkv) (by pressing 3), if you don't want to mux it don't touch it instead, and press S (Start) to begin the process of injecting dolby vision into your file.
If your rpu is a profile 8, you will get a dolby vision profile 8.2 (SDR backwards compatible) file, i.e. on dolby vision devices it plays in dolby vision, otherwise in SDR.
If your device does not play dolby vision in mkv, using the mp4 container instead of mkv may solve this.
The video where the rpu comes from and the video where the rpu is injected must be the same (the destination video can be an encoding of the original video), otherwise there is no logic in injecting the rpu on a different video if not to test the procedure.
von Suppé
9th May 2022, 08:34
I'm getting an error-window called "mkvextract.exe - Entry Point Not Found".
It says: "The procedure entry point CreatEventA could not be located in the dynamic link library api-ms-win-core-synch-l1-2-0.dll"
Please advice?
alexflin
9th May 2022, 09:51
It's simple.
From the screenshot, your video is sdr (uncropped) and not hdr.
At this point if you want dolby vision to be muxed into an mkv file enable option 3 (mux stream in mkv) (by pressing 3), if you don't want to mux it don't touch it instead, and press S (Start) to begin the process of injecting dolby vision into your file.
If your rpu is a profile 8, you will get a dolby vision profile 8.2 (SDR backwards compatible) file, i.e. on dolby vision devices it plays in dolby vision, otherwise in SDR.
If your device does not play dolby vision in mkv, using the mp4 container instead of mkv may solve this.
The video where the rpu comes from and the video where the rpu is injected must be the same (the destination video can be an encoding of the original video), otherwise there is no logic in injecting the rpu on a different video if not to test the procedure.
Ok, thanks, but what about the borders error, should I ignore it?.
The videos are not the same, I downloaded two versions from the internet one HDR only and the other DV.
https://i.ibb.co/pncNrZC/image.png (https://ibb.co/Fn2cqJG)
Also, I tested extracting the RPU from an MP4 but the script gets stuck in this step
https://i.ibb.co/BLmtTfM/image.png (https://ibb.co/F69K8hT)
cool advertise
9th May 2022, 10:42
Ok, thanks, but what about the borders error, should I ignore it?.
The videos are not the same, I downloaded two versions from the internet one HDR only and the other DV.
Generally, an hdr video will have this wording in mediainfo
HDR format : SMPTE ST 2086, HDR10 compatible
and this
Mastering display color primaries : Display P3 (or BT.2020)
Your hdr file does not have them, but I think it is a hdr video anyway.
Even the tool screenshot misled me by reporting:
HDR Info [n.a.].
I'm thinking how to help you, if I find an answer I'll tell you.
cool advertise
9th May 2022, 11:02
Your dolby vision video is a profile 5.
I've never used it, always used profile 8 or converted profile 7 to 8 and always in mkv (never mp4).
You could maybe try muxing it to mkv instead of mp4 and try injecting it again, or, convert rpu profile 5 to 8 and try injecting it again.
The tool fixes the borders automatically, it's not an error with the borders, it says that the source video has 276px above and 276px below black bands, while the rpu is cropped (0px), but normally it fixes it automatically when you inject the rpu.
von Suppé
9th May 2022, 12:12
What I find odd is that both videos are 3840x2160 and the native RPU shows no borders, where the video to be injected has 276px borders. Is it possible that the DV file is a totally different, "fullframe, zoomed in" 16:9 version?
Or does the DV file have borders but RPU is then flawed?
alexflin
9th May 2022, 13:34
What I find odd is that both videos are 3840x2160 and the native RPU shows no borders, where the video to be injected has 276px borders. Is it possible that the DV file is a totally different, "fullframe, zoomed in" 16:9 version?
Both videos have same aspect ratio and I think are the same source but one HDR and the another one with DV
https://i.ibb.co/SJ37kGk/image.png (https://ibb.co/vDjvNRN)
Or does the DV file have borders but RPU is then flawed?
No idea
Hi, I'm testing this tool with a file to see if I'm able to add the DV to a HDR video, first I use DDVT_DEMUXER to extract the RPU.bin and then I inject with the DDVT_INJECTOR the RPU.bin to another file but i'm stuck in this step
https://i.ibb.co/17YjbR2/image.png (https://ibb.co/HBL3XGg)
It looks so, that this video is a SDR Video. If u implant the RPU.bin into this video you create a 8.2 DV Profile file. If i understand quitvoid correct, his dovi_tool supports Only Profile 8.1 (HDR+RPU), not 8.2 (SDR+RPU) or 8.4 (HLG+RPU). If u 100% sure that this video is an HDR Video, use mkvtoolnix v67 and Remux the video, or use the raw hevc stream.
Both videos have same aspect ratio and I think are the same source but one HDR and the another one with DV
Many original RPUs in DV Profile 5 files have no borders set. In any thread quietvoid saids that is recommended to set this border entries. If your target video is cropped (You can ignore the AR) and have no black bars, set all border entries to 0 (0,0,0,0). You can ignore all borders or resolutions from the source video. Only interesting point ist the Delay, both videos must be frame identical.
alexflin
10th May 2022, 00:05
And it's possible to use the RPU to create a bluray structure?
-QfG-
10th May 2022, 04:23
No. For BD Structure you need Movie.mkv/hevc and EL.hevc. Than mux a Profile 7 Single Layer File and create an ISO file with TSMuxer.
alexflin
10th May 2022, 09:57
No. For BD Structure you need Movie.mkv/hevc and EL.hevc. Than mux a Profile 7 Single Layer File and create an ISO file with TSMuxer.
EL.hevc ? Sorry, I don't get it. What is that?
cool advertise
10th May 2022, 10:18
It looks so, that this video is a SDR Video.
If i understand quitvoid correct, his dovi_tool supports Only Profile 8.1 (HDR+RPU), not 8.2 (SDR+RPU) or 8.4 (HLG+RPU).
Dovi tool injection support profile 8.1 and 8.2, I have just tested it.
I have not tested profile 8.4.
And by the way, I could be wrong, but I think "alexflin" file is HDR and not SDR, as it contains this text in the mediainfo report:
Colour primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
So if you use the mkv container and convert profile 5 to 8, and then inject the RPU, you'll get dolby vision profile 8.1, in case the video is HDR, or dolby vision profile 8.2 in case the video is SDR.
If the file is SDR mediainfo should show something like this:
HDR format : Dolby Vision, Version 1.0, dvhe.08.03, BL+RPU, SDR compatible
If the file is HDR mediainfo should show something like this:
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
EL.hevc ? Sorry, I don't get it. What is that?
EL stands for enhancement layer.
The enhancement layer can be full enhancement layer (FEL) or minimum enhancement layer (MEL).
It is present in dolby vision profile 7 and commonly in Dolby Vision UHD blurays.
-QfG-
10th May 2022, 10:43
EL.hevc ? Sorry, I don't get it. What is that?
A UHD BD is strictly based on Dolby Vision Profile 7 Double Layer.
You have the Main HDR Video Layer (called [B]ase [L]ayer), a 1080p Dolby Vision Video Layer (called [E]nhanced [L]ayer). You need this layers for creating a P7 UHD compatible BD Structur.
BL.hevc = HDR Base Layer.
EL.hevc = DV Enhanced Layer (FEL/MEL).
RPU.bin = DV Metadata.
alexflin
10th May 2022, 12:24
Ok, now I understand, so I think is not possible to get the EL.hevc with the RPU.bin. I'm creating bluray uhd for my private tv shows collection but actually they are HDR only, I was thinking to use this tool to add the DV but now I think is not possible without the EL.hevc
zzreel
10th May 2022, 16:39
Is there a good solution for identifying how many frames an alternative source RPU may be off by?
I've used VirtualDub64 to see the end frame number but some video sources don't even open in that haha, plus, we'd want a side-by-side or even overlay frame comparison between 2 source video files. How do others do it?
cool advertise
10th May 2022, 17:01
Is there a good solution for identifying how many frames an alternative source RPU may be off by?
It is not an official procedure, but
"dovi_tool.exe" info -i "RPU.bin" -f 999999
executed from the command line reports the number of frames contained in a rpu.bin file, returning an error.
zzreel
10th May 2022, 17:06
It is not an official procedure, but
"dovi_tool.exe" info -i "RPU.bin" -f 999999
executed from the command line reports the number of frames contained in a rpu.bin file, returning an error.
Any way to match up the frames tho when they don't match? People are definitely doing it somehow, but I've yet to find a good solution.
cool advertise
10th May 2022, 17:10
Any way to match up the frames tho when they don't match? People are definitely doing it somehow, but I've yet to find a good solution.
MPC (Media Player Classic), allows you to open as many videos as you like and move to an exact, precise frame to compare them.
dovi_tool injection, if the video has for example 10000 frames and RPU.bin 9000, it will paste the first 1000 frames metadata after 9000 again, to get to 10000.
If you mean editing the rpu, changing the order of the frames, I don't know, I've never done it.
-QfG-
11th May 2022, 01:42
Any way to match up the frames tho when they don't match? People are definitely doing it somehow, but I've yet to find a good solution.
i make a video of one way for check frame differences:
https://www.youtube.com/watch?v=gVZL1vwXFAg
You found MeGui here:
https://sourceforge.net/projects/megui/
executed from the command line reports the number of frames contained in a rpu.bin file, returning an error.
Nice idea.
Ok, now I understand, so I think is not possible to get the EL.hevc with the RPU.bin. I'm creating bluray uhd for my private tv shows collection but actually they are HDR only, I was thinking to use this tool to add the DV but now I think is not possible without the EL.hevc
I build some hybrid Custom UHDs for me. In most cases the ITA Eagle Pictures UHDs have a better picture as the UK StudioAnal UHDs. But no DV. Both Versions from the same Master, so i demux the EL Layer from the UK UHD and mux that Layer in the ITA UHD. But both movies must be frame identical, i know no way to delay a EL.hevc file. If u encode an P7 Movie you can crop the RPU in the EL.hevc and mux this with the Base Layer. Works fine on Shield 2019 pro / Zidoo Z10pro. The INJECTOR in v0.43 can crop RPUs within EL.hevc.
von Suppé
11th May 2022, 07:00
I'm getting an error-window called "mkvextract.exe - Entry Point Not Found".
It says: "The procedure entry point CreatEventA could not be located in the dynamic link library api-ms-win-core-synch-l1-2-0.dll"
Please advice?
After checking and rechecking I found out when replacing mkvextract.exe in the tools folder with another version things are working again.
Am I right to assume that this has to do with versions of Mosu's mkv software not running on Windows 7 anymore?
rwill
12th May 2022, 09:39
Any way to match up the frames tho when they don't match? People are definitely doing it somehow, but I've yet to find a good solution.
Have you tried to align the RPUs scene_refresh_flag=1 to scene changes in the video ?
@-QfG- I am also slightly confused by the automatic Injector values for crop/borders when the video file is full-frame. Is this to save on storage as the borders do not require metadata and thus are cropped off the RPU.bin when injecting? Please confirm in this situation just to leave all settings as is and Inject into .mkv ok? Thank you!!
https://i.ibb.co/ygmWt07/Screenshot-2022-05-12-132054.png (https://ibb.co/RQGzf2d)
-QfG-
12th May 2022, 18:43
The entries are correct.
VIDEO INPUT = 120px on Top and Bottom.
RPU INPUT = set in RPU now to 0,0,0,0 (it looks so, that the source DV file is a cropped video)
RPU OUTPUT = must be have the same values how VIDEO INPUT.
The entries are correct.
VIDEO INPUT = 120px on Top and Bottom.
RPU INPUT = set in RPU now to 0,0,0,0 (it looks so, that the source DV file is a cropped video)
RPU OUTPUT = must be have the same values how VIDEO INPUT.
But, the original DV file from which I demuxed the RPU.bin was also full-frame, NOT cropped? That is why I am confused. All files involved are 2160px in height. I guess in this case, if I DISCARD and leave UNTOUCHED, it wouldn't impact the final output file, as the 120px on top and bottom in the file are just black space? Just want to make sure the crop doesn't actually impact the final file when it combines the HDR and DV metadata and the file is 2160px in height. Thanks for the support.
-QfG-
12th May 2022, 21:04
Sometimes you have wrong values in original DV5 Profile. Or nothing CROP Values in the RPU. Also in original WEB-DLs. In most cases it works with 0,0,0,0 on Full Frame videos with borders. But it doesnt work with Crop values in RPU, but cropped videos without black borders. Shield 2019 pro cuts in the last fall the cropped video. If you have an Imax source with changing AR, use simply 0,0,0,0. This works fine with Shield Pro 2019 / Zidoo Z10pro.
Sometimes you have wrong values in original DV5 Profile. Or nothing CROP Values in the RPU. Also in original WEB-DLs. In most cases it works with 0,0,0,0 on Full Frame videos with borders. But it doesnt work with Crop values in RPU, but cropped videos without black borders. Shield 2019 pro cuts in the last fall the cropped video. If you have an Imax source with changing AR, use simply 0,0,0,0. This works fine with Shield Pro 2019 / Zidoo Z10pro.
Okay, it seems to make sense. Worst case, I can always try to watch and see if it looks good, and re-inject if something is wrong. Cheers!
ShortKatz
15th May 2022, 07:52
Interesting tool. Is this also available for Mac? I have seen that all the tool inside the "tools" folder are at least available for Mac (I am not sure about sfk, because couldn't find the GitHub page for this),
korzh_yura
21st May 2022, 18:23
I have an issue with my player - m9702 ( oppo 203 clone)
Almost all cropped 2160 DV MP4 videos start to freeze after 3 minutes of normal playing
Also - command line is not my strong skill
So can yоu please tell me what should i do step by step to try to demux this video?
korzh_yura
21st May 2022, 18:28
I dont seeany help file inside :(
@-QfG-
What do you make of this error when converting HDR10+ to DV?
UPDATE: I am getting this same error even when I forgo the DDVT_DEMUXER.cmd completely and try to use quietvoid's tools manually. I reached out to them about this possible bug and provided the .json file. I'll let you know if I figure anything out, but I don't think it's DDVT scripts at this point. If you're curious, .json is available @ https://mega.nz/file/8t4G0KSK#pAZfekDaOAoltcLOIp1iR2-m8wO1QBnqKCVYJ5uvFFY
Please wait. Extracting HDR10+ Metadata...
Reading parsed dynamic metadata... Done.
Reordering metadata... Done.
Generating and writing metadata to JSON file... Done.
Done.
Please wait. Prefetching HDR10+ Metadata...
Done.
Please wait. Generate RPU.bin...
Error: invalid type: floating point `0.025`, expected u16 at line 6 column 44
Error during RPU.bin creating.
Please wait. Cleaning and Moving files ...
Deleting Temp File - Done.
Deleting JSon Script - Done.
Deleting JSon Script - Done.
SOME Operations failed.
This happens at the end of particular HDR10+ metadata conversion I have tried, after it extracts successfully and does reordering (which takes longer than usual seemingly). If it matters, this .json file turned out to be almost 160MB, and I can provide it if it that helps. If it matters, it happens in both v0.41a and v0.43. Below is the Mediainfo metadata for the input video file, for reference.
General
Format : Matroska
Format version : Version 4
File size : 12.5 GiB
Duration : 1 h 55 min
Overall bit rate : 15.5 Mb/s
Encoded date : UTC 2021-04-14 16:56:20
Writing application : mkvmerge v54.0.0 ('F Maj Pixie') 64-bit
Writing library : libebml v1.4.2 + libmatroska v1.6.3
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 1 h 55 min
Bit rate : 14.9 Mb/s
Width : 3 840 pixels
Height : 1 600 pixels
Display aspect ratio : 2.40:1
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.101
Stream size : 12.0 GiB (96%)
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0250 cd/m2, max: 20000 cd/m2
Maximum Content Light Level : 2238 cd/m2
Maximum Frame-Average Light Level : 236 cd/m2
Audio
ID : 2
Format : E-AC-3
Format/Info : Enhanced AC-3
Commercial name : Dolby Digital Plus
Codec ID : A_EAC3
Duration : 1 h 55 min
Bit rate mode : Constant
Bit rate : 640 kb/s
Channel(s) : 6 channels
Channel layout : L R C LFE Ls Rs
Sampling rate : 48.0 kHz
Frame rate : 31.250 FPS (1536 SPF)
Compression mode : Lossy
Stream size : 527 MiB (4%)
Language : Korean
Service kind : Complete Main
Default : Yes
Forced : No
Text
ID : 3
Format : UTF-8
Codec ID : S_TEXT/UTF8
Codec ID/Info : UTF-8 Plain Text
Duration : 1 h 54 min
Bit rate : 26 b/s
Count of elements : 948
Stream size : 22.0 KiB (0%)
Title : SDH
Language : English
Default : No
Forced : No
Menu
00:00:00.000 : Scene 1
00:00:08.000 : Scene 2
00:00:35.000 : Title Sequence
00:00:40.000 : Scene 4
00:08:10.000 : Scene 5
00:16:09.000 : Scene 6
00:23:12.000 : Scene 7
00:31:11.000 : Scene 8
00:37:58.000 : Scene 9
00:46:18.000 : Scene 10
00:54:08.000 : Scene 11
01:00:06.000 : Scene 12
01:07:18.000 : Scene 13
01:15:12.000 : Scene 14
01:22:14.000 : Scene 15
01:29:12.000 : Scene 16
01:36:58.000 : Scene 17
01:42:09.000 : Scene 18
01:51:35.000 : End Credits
Thank you kindly. :)
-QfG-
28th May 2022, 10:43
I never seen a 160 MB HDR JSon metadata file before. This "error" comes by some movies for me, too. In all cases it was a Profile B file. I have no solution for this yet.
quietvoid
28th May 2022, 12:54
@-QfG-
UPDATE: I am getting this same error even when I forgo the DDVT_DEMUXER.cmd completely and try to use quietvoid's tools manually. I reached out to them about this possible bug and provided the .json file. I'll let you know if I figure anything out, but I don't think it's DDVT scripts at this point. If you're curious, .json is available @ https://mega.nz/file/8t4G0KSK#pAZfekDaOAoltcLOIp1iR2-m8wO1QBnqKCVYJ5uvFFY
It's not a dovi_tool bug. Either user error or the script's fault.
To me it looks like the generate config JSON (not the HDR10+ one) has wrong L6 metadata, because all the values are supposed to be integers.
Your source file has weird mastering display metadata, and it's invalid.
Thanks for the replies guys. I suppose it must be just the embedded HDR10+ metadata values in this particular input file (source) caused a bad companion config .json to be generated, but the actual HDR10+ .json may be fine. You are right @quietvoid: I did create the config .json file myself, using values derived from the MediaInfo metadata (similar to DDVT script) and can now see the integer error comes from the use of Mastering display luminance: min: 0.0250 cd/m2, max: 20000 cd/m2 in. Now when I set minimum to 0, it gave different error that max value was 20000 but should be 10000 max, so that one seems invalid too.
In the end, I just tried changing the config .json file to have min as 0 and max as 10000 and the new RPU.bin generated okay. I now re-injected that back into the original file and it plays great on my Shield Pro 2019 and TV displays the Dolby Vision metadata! :D Looking at DDVT_DEMUXER script, I guess 0.0250 should actually be converted to MinDML of 250? I re-did my final file with that value now, although wondering why the math is done that way for MinDML but MaxDML is kept as is?
@-QfG-, maybe you could consider modifying DDVT_DEMUXER.cmd to detect the 0.0250 'floating point' value for min luminance also and convert to correct integer value (I think you already have similar code for 3 values like below) and also keep the maximum luminance from going over 10000? I think that might solve this issue for those few, pesky source files.
if "%MinDML%"=="0.0250" set "MinDML=250" ???
if "%MinDML%"=="0.0050" set "MinDML=50"
if "%MinDML%"=="0.0010" set "MinDML=10"
if "%MinDML%"=="0.0001" set "MinDML=1"
-QfG-
29th May 2022, 22:06
and can now see the integer error comes from the use of Mastering display luminance: min: 0.0250 cd/m2, max: 20000 cd/m2 in. Now when I set minimum to 0, it gave different error that max value was 20000 but should be 10000 max, so that one seems invalid too.
Ah, the Master luminances forced in the batch file, because i can't read them correctly, i will add these settings in the next update. I will take a look for a solution for cutting the string correctly.
Ah, the Master luminances forced in the batch file, because i can't read them correctly, i will add these settings in the next update. I will take a look for a solution for cutting the string correctly.
Sounds great! Thanks for the continued hard work on this tool and your scripts. Glad we were able to figure out this issue I had, and thanks to quietvoid for guidance there too. Respect from Canada! :)
-QfG-
31st May 2022, 20:57
-v0.44
*Fixed wrong Min Luminance Bug in DEMUXER by HDR10+ to DV Conversion.
I hope now all works correctly.
-v0.44
*Fixed wrong Min Luminance Bug in DEMUXER by HDR10+ to DV Conversion.
I hope now all works correctly.
I think a small typo in the new DEMUXER.cmd
if "%MaxDML%"=="" set "MinDML=1"
I think supposed to be MinDML in that line in both cases?
Cheers. :)
-QfG-
1st June 2022, 04:42
Correct, my fault. %MinDML% is correct.
Please redownload v0.44 is it fixed now. Thanks.
-QfG-
5th June 2022, 07:15
-v0.45
*Added DoVi Profile 8.4 HLG Conversion in DEMUXER
*Fixed bad Frame choice in FRAMEINFO
*Updated mkvtoolnix to v 68.0.0.0.
MoonKnight
6th June 2022, 22:27
Hello
thank u for DDVT
I have one question : How do I trim for an example the first 128 frames of an HDR10Plus.json ?? I need to do that for some resynch
-QfG-
7th June 2022, 04:12
I think you must edit the Json manually. There is no option in the hdr10plus_tool from quietvoid. The only solution ist to change hdr10+ to DV, than you can edit the Delay of the RPU.
panni
7th June 2022, 11:47
Hey, thank you for this great tool. Do you have any plans to support smart batch operations (multiple operations at a time, multiple files at a time)?
BTW, typo in line 342 of DDVT_INJECTOR.cmd: `if "%P4Extract%%MUXINMP4%%HDR10P_exist%"` should be `if "%MP4Extract%%MUXINMP4%%HDR10P_exist%"`.
-QfG-
7th June 2022, 16:41
you can use multiple instances, you must only choose different source directories for each operation.
-QfG-
13th June 2022, 18:53
-v0.46
*Shows RPU/EL Layer Information in Injector (Profile, CM Version, Frames)
*Updated dovi_tool to v1.5.4.
fkid
14th June 2022, 14:32
-v0.46
*Shows RPU/EL Layer Information in Injector (Profile, CM Version, Frames)
*Updated dovi_tool to v1.5.4.
Thank you for continued development. Still see the minor typo on line 371 of INJECTOR.cmd
if "%P4Extract%%MUXINMP4%%HDR10P_exist%"=="TRUEYESYES" set "HEADER_FILENAME=%~n1_[HDR10+ INJECTED].mp4"
should be this I think?
if "%MP4Extract%%MUXINMP4%%HDR10P_exist%"=="TRUEYESYES" set "HEADER_FILENAME=%~n1_[HDR10+ INJECTED].mp4"
SlimSwan
14th June 2022, 20:21
Delete this post, my mistake.
-QfG-
15th June 2022, 19:16
if "%MP4Extract%%MUXINMP4%%HDR10P_exist%"=="TRUEYESYES" set "HEADER_FILENAME=%~n1_[HDR10+ INJECTED].mp4"
Thank you, i will fix it in the next update.
Original time is 1 h 5 min.
I use latest script.
FPS of video go to 25 I"dont know why?
Have you set "Mux in mkv" to "yes", or have you muxed the file by yourself?
In the last case, in mkvtoolnix by Video in the middle right box set the framerate manually to 24000/1001 and check the "Also Fix Bitstream" Button.
Or simply use the "Mux in MKV" Function from the tool.
EDIT:
-v0.46 Fixed
*Bugfixes
Blue_MiSfit
15th June 2022, 21:44
The above is clearly pirated content, and the post has been removed. You must not discuss pirated content on doom9.
Bioba
21st June 2022, 12:50
Hello,
I am writing to better understand what this tool does.
I read that it extracts and injects metadata for Dolby Vision, so I could extract the metadata from an untouched video file and then inject it into the same compressed video file?
Thanks to everyone who will explain me better :-)
Rozin
21st June 2022, 18:31
How can i replace a profile 5 dolby with its profile 8.1 version. Profile 5 video plays with pink green tint. That's why I'm trying to convert the profile version. Or someone could help me to play profile 5 files without any tints on a dolby profile 5 support less device
nevcairiel
21st June 2022, 19:07
You can't really convert profile 5 to profile 8.1, since it has no compatible base layer.
-QfG-
21st June 2022, 19:58
DV Profile 5 files uses the ITP Colorange instead of BT.2020. You can't edit this.
Rozin
21st June 2022, 21:44
Ok got it.But Is there any way to play profile 5 files on pc. Like tweaking potplayer settings or using madvr. They show pink, green shaded all over. Or do i have to buy $1000 oled tv to play a profile 5?
quietvoid
21st June 2022, 22:06
Ok got it.But Is there any way to play profile 5 files on pc. Like tweaking potplayer settings or using madvr. They show pink, green shaded all over. Or do i have to buy $1000 oled tv to play a profile 5?
Use mpv with --vo=gpu-next.
Rozin
21st June 2022, 22:17
Use mpv with --vo=gpu-next.
What does this do? Passthrough profile 5 data or dropping it ? Please explain kind sir for I'm noob
Rozin
22nd June 2022, 10:13
You can't really convert profile 5 to profile 8.1, since it has no compatible base layer.
Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU. This is the dolby encoded into the file . I can't do anything to convert to 8.1? BL means base layer ryt?
rwill
23rd June 2022, 07:31
Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU. This is the dolby encoded into the file . I can't do anything to convert to 8.1? BL means base layer ryt?
I you manage to decode the Profile 5 to HDR10 and then convert the RPU to match that you could create a Profile 8.1 stream in theory. But chances are high that if your device does not support Profile 5 it also does not support Profile 8.1.
Bioba
23rd June 2022, 08:29
Hi,
I did a test with a film, I extracted the RPU.bin file with the demuxer, compressed the film, I put the RPU file in the correct folder.
I tried to inject the DV but I get an error and the script closes immediately.
I took a screenshot.
Rozin
23rd June 2022, 12:48
I you manage to decode the Profile 5 to HDR10 and then convert the RPU to match that you could create a Profile 8.1 stream in theory. But chances are high that if your device does not support Profile 5 it also does not support Profile 8.1.
Actually my laptop is Legion 5 pro which has dolby vision specified in the lenovo website and the lap came with dolby app preinstalled with dolby video extensions. I know the display is lcd (But 10bit) and its not the right hardware for dovi, but a license is a license. i dont understand why profile5 is not being decoded. is lenovo selling a 'pseudo' dolby vision license. ?
fkid
23rd June 2022, 18:58
Hi,
I did a test with a film, I extracted the RPU.bin file with the demuxer, compressed the film, I put the RPU file in the correct folder.
I tried to inject the DV but I get an error and the script closes immediately.
I took a screenshot.
This happens to me from time to time when file or folder has [] or () or some other characters in the path. It may be a limitation of running using explorer context menu? Any idea @-QfG-? I just temporarily rename the video file and/or folder to something short and simple, do the DEMUX/INJECT, then rename file/folder back. :)
Bioba
24th June 2022, 20:38
This happens to me from time to time when file or folder has [] or () or some other characters in the path. It may be a limitation of running using explorer context menu? Any idea @-QfG-? I just temporarily rename the video file and/or folder to something short and simple, do the DEMUX/INJECT, then rename file/folder back. :)
Thanks!:D
-QfG-
25th June 2022, 05:45
This happens to me from time to time when file or folder has [] or () or some other characters in the path. It may be a limitation of running using explorer context menu? Any idea @-QfG-? I just temporarily rename the video file and/or folder to something short and simple, do the DEMUX/INJECT, then rename file/folder back. :)
The problem by this solution is, if the tool renames anything and you close the tool during process, or there is any error during process, the tool don't renamed the folder / Files back.
EDIT:
-v0.47
*INJECTOR supports custom.json files (copy edited custom.json to video source dir).
custom json scripts processed first!
*INJECTOR New function "Match L6 Metadata".
L6 Metadata will be edited for matching HDR stream Metadata.
*INJECTOR creates now a small Logfile by muxing.
*FRAMEINFO shows more informations about the RPU.
*Updated dovi_tool to v1.5.5.
fkid
26th June 2022, 03:36
The problem by this solution is, if the tool renames anything and you close the tool during process, or there is any error during process, the tool don't renamed the folder / Files back.
EDIT:
-v0.47
*INJECTOR supports custom.json files (copy edited custom.json to video source dir).
custom json scripts processed first!
*INJECTOR New function "Match L6 Metadata".
L6 Metadata will be edited for matching HDR stream Metadata.
*INJECTOR creates now a small Logfile by muxing.
*FRAMEINFO shows more informations about the RPU.
*Updated dovi_tool to v1.5.5.
Thank you for the update! Just curious, under what scenario is the new feature used? *INJECTOR New function "Match L6 Metadata".
-QfG-
26th June 2022, 17:58
Some releases have a RPU with l6 metadata over 10.000. The tool will not mux them, because 10.000 is the max value there. If you have this problem simply set L6 Metadata to the same values how the HDR stream have.
fkid
27th June 2022, 13:51
Some releases have a RPU with l6 metadata over 10.000. The tool will not mux them, because 10.000 is the max value there. If you have this problem simply set L6 Metadata to the same values how the HDR stream have.
That's a great idea. Thanks for clarifying. :)
-QfG-
10th July 2022, 10:04
-v0.47a
*Updated hdr10plus_tool to v1.3.1.
*DEMUXER Added feature to disable validation of HDR10+ extraction.
Meow
22nd July 2022, 21:10
Firstly, thanks for the script, it's really nice how it simplifies the usage of the underlying tools.
I have a problem with some videos though.
Sometimes it works perfectly fine, but sometimes, I try to convert HDR10+ to DolbyVision but something goes wrong. I notice the brightness changing at clearly the wrong times.
Here's an example the error happened with.
Firstly I open ddvt_demuxer and continue with these settings:
https://i.imgur.com/iFo7yNX.png
I get my RPU.bin and then I run ddvt_injector. I get warnings about the video and RPU borders not being a match, I really don't know what to do about that.
I have been able to get a working end results even with those warning popping up.
I continue with the following settings:
https://i.imgur.com/HuOAT69.png
Should I do something about the borders? I wonder if the borders are saying they're a mismatch because the video has a fullscreen logo at the very start, but after that it's just the TV show with black bars.
Or maybe I should change the timings by adding/removing delay? But the tools tells to me that the video and RPU have same length (1 frame difference) so I really don't know how much I should adjust the delay then.
Any help would be appreciated, thanks.
-QfG-
28th July 2022, 00:59
You must do nothing, the tool set the video borders correctly by himself. Yo see under "VIDEO INPUT" the Borders of the HEVC Base Layer. Under "FILE OUTPUT" you see the Borders set in the RPU during muxing.
Match L6 Metadata can be turned off, this function is only necessary if you have errors during muxing (Error Message is "RPU can't mux into stream, because 10000 is the max value for ...").
Meow
28th July 2022, 11:35
You must do nothing, the tool set the video borders correctly by himself. Yo see under "VIDEO INPUT" the Borders of the HEVC Base Layer. Under "FILE OUTPUT" you see the Borders set in the RPU during muxing.
Match L6 Metadata can be turned off, this function is only necessary if you have errors during muxing (Error Message is "RPU can't mux into stream, because 10000 is the max value for ...").
Thanks for the answer. And I didn't touch the borders or the delay timing, I continued with the settings shown in the screenshots. But still, I get brightness changes at the wrong times. So I guess something else goes wrong, or could this be caused by the L6 metadata option? I'll try without the L6 metadata option when I have time and edit this post saying what happened.
-QfG-
29th July 2022, 11:21
No, the Delay you must set manually, there is no function for this. Here is a little Video from me how you can find out the delay.
https://www.youtube.com/watch?v=gVZL1vwXFAg
von Suppé
29th July 2022, 11:58
I read an interesting question somewhere about RPU and framerate.
Can RPU from a 23.976 video be used for 24 fps target video (and vice versa)? It seems RPU works with framenumbers. Or is there more to it?
quietvoid
29th July 2022, 18:39
Can RPU from a 23.976 video be used for 24 fps target video (and vice versa)? It seems RPU works with framenumbers. Or is there more to it?It only works with frame numbers.
The content frame rate doesn't matter.
von Suppé
30th July 2022, 06:45
Very nice to know. Thanks, quietvoid.
NeverExists
1st August 2022, 00:52
No, the Delay you must set manually, there is no function for this. Here is a little Video from me how you can find out the delay.
https://www.youtube.com/watch?v=gVZL1vwXFAg
is there any other tool we can use to find out the delay? This tool in your video does not work at all for me. In your video, it takes a few seconds for the file to load and the video to pop up for editing, but I wait 1 hour and it still does not pop up. I did everything exactly like your video but it counts the file size very slowly after I press Queue.
von Suppé
2nd August 2022, 12:10
Maybe it's easier to just load the two videos in another player.
For identifying same frames and determining difference in framecount, I often use two simultaneous instances of Virtualdub. Works like a charm.
Meow
2nd August 2022, 15:38
No, the Delay you must set manually, there is no function for this. Here is a little Video from me how you can find out the delay.
https://www.youtube.com/watch?v=gVZL1vwXFAg
In that video you are getting matching frames from two different video files and seeing what their different in frames is? Yes, that's easy with any video player. But I was asking about something different.
In my case I have just the one video file. It's HDR10+, I try to convert it to DV with the steps shows in my previous post, but I get brightness changes at the wrong times.
I guess I should use the tool to set a delay? But I don't know how I could get the delay right without trial and error, and well that would take forever.
Or could something else be going wrong? I could send you the video file I'm having problems converting, but I understand if you don't want to spend time testing for me.
Balling
4th August 2022, 23:53
I read an interesting question somewhere about RPU and framerate.
Can RPU from a 23.976 video be used for 24 fps target video (and vice versa)? It seems RPU works with framenumbers. Or is there more to it?
It depends on how the convertion was done. Where did you find that? All modern releases from Disney/Marvel are 24.000 going forward from Disney+. On Blu-ray in many cases 24.000 is also used. ALL production of real Hollywood is done in integer framerate anyway. 24/1.001 is a thing of old old past, many people fight to rule it out.
You would think 1 dropped frame every 41 seconds is not that important, but it accumulates. If it done with optic flow, it may be even worse.
AgentXXL
5th August 2022, 03:14
No, the Delay you must set manually, there is no function for this. Here is a little Video from me how you can find out the delay.
https://www.youtube.com/watch?v=gVZL1vwXFAg
UPDATE: I'm blind... didn't see the 'Mux in mkv stream' option in Injector... just tried one of the titles that were failing and it looks succssful! Thanks again for all the efforts you and others have put into these tools and scripts. Ignore the rest of this message, left for posterity to show my impatience and not learning to read what's on screen. :D
Thank you for these scripts! I had stumbled across dovi_tool (thanks @quietvoid!) and was doing it manually with ffmpeg and it. Alas with both the manual method or your scripts, I still am encountering a problem with around 75% of the titles I try this with.
I'm probably overlooking something obvious but I'm having lots of failed attempts to create hybrids with both HDR and DV playback. The extraction/injection seems to work perfectly, but when I try to remux the output.hevc file with audio and subtitles, they are often way out of sync.
This happens even when the source HDR and DV files have the exact same frame count and audio. After extraction and injection of the DV RPU into the HDR.HEVC, I've tried remuxing with audio and subtitles from either of the source files, or sometimes from a Blu-ray source with the same runtime.
I'm remuxing using MKVToolnix GUI and just can't seem to figure out what I'm missing. I noticed the frame delay option so took a look at your video. While that may help with videos with different frame numbering, it doesn't when both source files have the same frame numbering and count.
Suggestions? Has anyone done a guide or video walkthrough of the process? My Google-fu is weak on this topic so any pointers would be appreciated.Thanks!
von Suppé
5th August 2022, 11:59
It depends on how the convertion was done.
First off, I did not mention conversion. It's simply possible to have same program from two different framerate sources.
You would think 1 dropped frame every 41 seconds is not that important...
Even when changing 23.976 <--> 24 framerate, I don't understand why framedropping would come into play. Where would they be dropped? Just rewriting timestamps would keep native frames and same framecount.
Framedropping as I understand it, is skipping certain SMPTE timecodes to keep up with time. Since they merely refer to frames, skipping them will not skip the frames themselves.
But maybe I'm hugely misinterpreting your post and/or missing something.
von Suppé
5th August 2022, 12:35
...but when I try to remux the output.hevc file with audio and subtitles, they are often way out of sync.
This happens even when the source HDR and DV files have the exact same frame count and audio.
Other than having the same framecount, have you checked in all cases that they also have the same framerate? I don't know what exactly you're crossmuxing but audio and video from different framerate sources will go out of sync. Possibly subs too.
About MKVToolNix GUI. Should you run Windows 8.1 or lower, don't use latest version https://forum.doom9.org/showthread.php?t=184092
GodzilaAvenger
6th August 2022, 00:45
Can DDVT add FEL to a re-encoded BL?
To be more specific, I have two mkvs, one remux (DV 07.06) and another re-encoded HDR10 BL. I was wondering if I could use DDVT to grab the FEL from the remux and add it to the BL of the re-encode, or would this just produced messed-up results?
fkid
6th August 2022, 00:45
UPDATE: I'm blind... didn't see the 'Mux in mkv stream' option in Injector... just tried one of the titles that were failing and it looks succssful! Thanks again for all the efforts you and others have put into these tools and scripts. Ignore the rest of this message, left for posterity to show my impatience and not learning to read what's on screen. :D
Thank you for these scripts! I had stumbled across dovi_tool (thanks @quietvoid!) and was doing it manually with ffmpeg and it. Alas with both the manual method or your scripts, I still am encountering a problem with around 75% of the titles I try this with.
I'm probably overlooking something obvious but I'm having lots of failed attempts to create hybrids with both HDR and DV playback. The extraction/injection seems to work perfectly, but when I try to remux the output.hevc file with audio and subtitles, they are often way out of sync.
This happens even when the source HDR and DV files have the exact same frame count and audio. After extraction and injection of the DV RPU into the HDR.HEVC, I've tried remuxing with audio and subtitles from either of the source files, or sometimes from a Blu-ray source with the same runtime.
I'm remuxing using MKVToolnix GUI and just can't seem to figure out what I'm missing. I noticed the frame delay option so took a look at your video. While that may help with videos with different frame numbering, it doesn't when both source files have the same frame numbering and count.
Suggestions? Has anyone done a guide or video walkthrough of the process? My Google-fu is weak on this topic so any pointers would be appreciated.Thanks!
I also had seemingly random AV sync issues when doing manual muxing using MKVToolNix myself, even after troubleshooting, so started always using the built-in 'Mux in mkv stream' option and always works fine for me. Tricky to figure out why, but I'd say just use that. :)
von Suppé
6th August 2022, 06:56
Can DDVT add FEL to a re-encoded BL?
Adding FEL to recoded BL won't work. EL frame-types and order must exactly match those of BL. Recoding BL will destroy that.
@AgentXXL, @fkid
Don't know anymore where I've read it, but when muxing DV elementary streams with MKVToolNix GUI, I've learned to always set "Default duration/FPS" with proper value. Hope this is of any help.
GodzilaAvenger
6th August 2022, 08:49
Adding FEL to recoded BL won't work. EL frame-types and order must exactly match those of BL. Recoding BL will destroy that.
Thanks, I'm still learning about DV so could you please explain why the EL frame type and order must match the BL? My understanding is that when playing back a dual-layer track (BL+EL+RPU) separate HEVC decoders are launched for BL and EL, so if a re-encoded BL decodes to something nearly identical to what the original BL would decode to, shouldn't the new BL work with the EL? Is there any other way to re-encode the original file and keep the EL?
I saw this post (https://forum.makemkv.com/forum/viewtopic.php?p=113419#p113419) over at the MakeMKV forum and got curious about whether DDVT can be used to achieve the same result, or if a more involved process is needed.
von Suppé
6th August 2022, 10:27
Yeah, learning about DV seems endless. I can't tell you why the frametypes must match. Other than that, I also remember MakeMKV popping up a huge amount of sync errors. I don't know if the two issues are related or should be assessed separately.
Reading your link
You have to edit the FEL (has the nal unit) in the Rpu to reflect the hevc bl encode and that’s it.
sounds promisng, but I wouldn't know what's meant here. Maybe quietvoid cares to comment.
AgentXXL
6th August 2022, 23:08
Other than having the same framecount, have you checked in all cases that they also have the same framerate? I don't know what exactly you're crossmuxing but audio and video from different framerate sources will go out of sync. Possibly subs too.
About MKVToolNix GUI. Should you run Windows 8.1 or lower, don't use latest version https://forum.doom9.org/showthread.php?t=184092
So far using the 'Mux stream in mkv' option of injector has worked for every title I've tried. If the content has a Blu-ray release with DTS-HD or TrueHD, I try muxing their audio (and subtitles).
I've been successful doing that when the hybrid DV-HDR and the Blu-ray have the same runtime. If they are different runtimes, I use the delay options in MKVToolnix and have been successful so far.
I mainly use MKVToolnix from Linux, but also have it on my Win11 Pro system, the only Windows box I use. I primarily use Windows for gaming and HTPC, but occasionally for video editing when the tools/scripts are only made for it (like these scripts). It would be preferable to use scripts on Linux but converting these so they would work is beyond my skill level at the moment.
I note that injector uses MKVToolnix (mkvmerge) when asked to 'mux stream in mkv'. I'd like to learn more of the advanced functions available so I could do it manually on Linux if needed. I'll have to take a look through the injector script and see if I can decipher the mkvmerge options that it uses.
Regardless, thanks for the feedback.
GodzilaAvenger
6th August 2022, 23:57
Yeah, learning about DV seems endless. I can't tell you why the frametypes must match. Other than that, I also remember MakeMKV popping up a huge amount of sync errors. I don't know if the two issues are related or should be assessed separately.
Reading your link
sounds promisng, but I wouldn't know what's meant here. Maybe quietvoid cares to comment.
I went ahead and tried it out on one of my disks using DDVT, demuxing the FEL and injecting it into a re-encoded BL. My player apparently doesn't playback DV from a file (falls back on HDR10 which seems ok) so if anyone has a proper setup please use the sample below and let me know if this frankenstein's monster works, or if you see weird image artifacts or flashing.
Sample (https://drive.google.com/file/d/1Zw5TLEqVNgbQhePEHqWVyVYd9CsnGwCq/view?usp=sharing)
NeverExists
7th August 2022, 03:39
Maybe it's easier to just load the two videos in another player.
For identifying same frames and determining difference in framecount, I often use two simultaneous instances of Virtualdub. Works like a charm.
Also, I just realized that a lot of the movies I want to do a hybrid of have the Bluray video start a few seconds before the Web video file. I don't know how to go about merging them for a hybrid. Do I first trim the Bluray video so they match? If so how would I do that?
GodzilaAvenger
7th August 2022, 05:34
Also, I just realized that a lot of the movies I want to do a hybrid of have the Bluray video start a few seconds before the Web video file. I don't know how to go about merging them for a hybrid. Do I first trim the Bluray video so they match? If so how would I do that?
Do you want to get the RPU from a WEB-DL source and inject it into a BluRay? If that's what you want to do I'd recommend using djv, which can show a video frame-by-frame. What I do is open one file in djv, find a scene transition and note the frame number, then open the other file and find the corresponding frame number. This gives me the delay, which I then use in the DDVT injector tool.
von Suppé
7th August 2022, 10:35
@AgentXXL
Did you read & try this?
@AgentXXL, @fkid
Don't know anymore where I've read it, but when muxing DV elementary streams with MKVToolNix GUI, I've learned to always set "Default duration/FPS" with proper value. Hope this is of any help.
von Suppé
7th August 2022, 11:57
I went ahead and tried it out on one of my disks using DDVT, demuxing the FEL and injecting it into a re-encoded BL. My player apparently doesn't playback DV from a file (falls back on HDR10 which seems ok) so if anyone has a proper setup please use the sample below and let me know if this frankenstein's monster works, or if you see weird image artifacts or flashing.
Sample (https://drive.google.com/file/d/1Zw5TLEqVNgbQhePEHqWVyVYd9CsnGwCq/view?usp=sharing)
Not sure what you mean with "inject a FEL into recoded BL". I'd guess you mean interleaving BL and FEL+RPU into one videostream with dovitool's mux option (something like "dovi_tool mux --bl BL.hevc --el FEL.hevc")?
It's basically what MakeMKV does too. Please inform me if you did something else.
As for your sample, it does not trigger DV on my player either. HDR10 is all I got. No flickering though, playback is okay.
But I'm somewhat confused about the mkv. Is combining a recoded BL with native FEL+RPU all you did?
Reason I ask is I found something odd. First thing obviously is BL being cropped where native FEL is not. I doubt that cropped BL with uncropped FEL (and RPU, for that matter) would be possible for proper DV playback in the first place. Recoding BL doesn't mean you have to crop it.
Also, I demuxed your mkv into the elementary videostream, which still contains BL, FEL and RPU. With dovitool I extracted RPU.
Using dovitool, I then demuxed the demuxed elementary stream into BL and FEL. Extracted RPU from FEL. Did a hasnumbercheck on both RPU's. They don't match, where they usually do. I'm curious if/what you did with the RPU?
GodzilaAvenger
7th August 2022, 19:08
Not sure what you mean with "inject a FEL into recoded BL". I'd guess you mean interleaving BL and FEL+RPU into one videostream with dovitool's mux option (something like "dovi_tool mux --bl BL.hevc --el FEL.hevc")?
It's basically what MakeMKV does too. Please inform me if you did something else.
As for your sample, it does not trigger DV on my player either. HDR10 is all I got. No flickering though, playback is okay.
But I'm somewhat confused about the mkv. Is combining a recoded BL with native FEL+RPU all you did?
Reason I ask is I found something odd. First thing obviously is BL being cropped where native FEL is not. I doubt that cropped BL with uncropped FEL (and RPU, for that matter) would be possible for proper DV playback in the first place. Recoding BL doesn't mean you have to crop it.
Also, I demuxed your mkv into the elementary videostream, which still contains BL, FEL and RPU. With dovitool I extracted RPU.
Using dovitool, I then demuxed the demuxed elementary stream into BL and FEL. Extracted RPU from FEL. Did a hasnumbercheck on both RPU's. They don't match, where they usually do. I'm curious if/what you did with the RPU?
That's quite interesting, thanks for the feedback.
Here's what I did: I used DDVT_DEMUXER with the remux mkv, and used it to only extract the EL (option 2), but not the BL or the RPU, and I got a EL.hevc file. I then used DDVT_INJECTOR to add that EL.hevc to the re-encoded mkv, which I think is the same as what you said (interleaving BL and EL+RPU and then muxing into an mkv, for muxing the options where Standard and MakeMKV, I wasn't sure what the difference was so I went with Standard). I didn't do anything directly to the RPU, DDVT may have changed some things in the process because of the cropped BL.
I wonder if the cropped BL is the reason DV is not triggered on your player. Following @-QfG-'s directions in the next post, I took the following steps using one of my uncropped re-encodes:
1. Used DDVT_DEMUXER to extract EL.hevc (1920x1080) from the remux mkv, then put it next to BL.hevc (3840x2160).
2. Gave DDVT_INJECTOR the BL.hevc file as input, which then recognized the EL.
3. Started the injecting (interleaving of EL and RPU NALUs) process, which resulted in a BL_[BL+EL+RPU].hevc file. Finally, used MKVToolNix to create a mkv.
The file below contains a sample of both the source (remux) and re-encode files. Please let me know if either triggers DV on your player, thanks!
Source&Encode (https://drive.google.com/file/d/1qP31OaDYGo4JeMtwFyzL5ZElwX6Caxmb/view?usp=sharing)
-QfG-
7th August 2022, 19:08
Steps for Building a Profile 7 Single Layer MKV:
1. Extract with Extractor the Enhanced Layer. Copy the hevc file nearly the Base Layer File (Base Layer WITHOUT DoVi RPU or EL Stream!) and save this File as EL.hevc.
2. Open Base Layer file/Container with the Injector. If the Injector found the EL.hevc file you have a new option to mux the MEL/FEL Layer into your Base Layer Stream.
Differences between Standard and makeMKV:
--eos-before-el Write the EOS/EOB NALUs before the EL. Defaults to false.
This flag enables the same behaviour as MakeMKV and yusesope's mux script.
Enabling this therefore results in identical output using dovi_tool.
AgentXXL
7th August 2022, 20:52
@AgentXXL
Did you read & try this?
No, so far almost all titles I've tried have worked using the 'mux stream to mkv' option of Injector. I have encountered one title where the RPU.bin was extracted but Injector wouldn't recognize it. It also reported that there was a max luminance value over 10000 - when that happens I've read to try using the 'change L6 metadata to match q=with video' in Injector.
Alas that doesn't work as Injector doesn't recognize the RPU.bin file:
== RPU INPUT ===========================================================================================================
Filename = [RPU.bin]
RPU Info = [DV Profile = n.a.] [CM Version = n.a.] [Frames = n.a.]
I'll give the manual method a try using the Default duration/FPS setting at some point. Right now I'm working on a backlog of titles where I currently have both a HDR and DV copy of each title in my media folders. Trying to convert as many as possible so I can free up some storage space.
Thanks for the assistance - I'll let you know if I'm successful when I try the manual method again.
Balling
8th August 2022, 00:12
First off, I did not mention conversion. It's simply possible to have same program from two different framerate sources.
Even when changing 23.976 <--> 24 framerate, I don't understand why framedropping would come into play. Where would they be dropped? Just rewriting timestamps would keep native frames and same framecount.
Framedropping as I understand it, is skipping certain SMPTE timecodes to keep up with time. Since they merely refer to frames, skipping them will not skip the frames themselves.
But maybe I'm hugely misinterpreting your post and/or missing something.
You are thinking about drop-frame timecode (DF), no one uses it anymore, because it is inaccurate and accumulates one frame every 9 hours 15 minutes. Not quite like 41 seconds, but still, so timecodes are not the only thing being dropped. https://en.wikipedia.org/wiki/SMPTE_timecode It happens because it assumes 29.97 instead of 30/1.001.
"why framedropping would come into play" you need to drop actual video frames because there is no simple way to convert between /1.001 and not without a GPU farm. Imagine a display that is 24.000/1.001 and your display 24.000 on it. In fact it was a crazy problem in Apple 4K TV (that was fixed, every display supports both, it is mandated). You can read about it here: https://en.wikipedia.org/wiki/24p
"Just rewriting timestamps would keep native frames and same framecount"
That would desync audio and subtitles that is why it is not done. Hollywood converts by using smearing on 10 frames. Also, as I said there is still only one true framerate (24.000) that is synced to real clock out there. Imagine a video scene with a ticking clock. Haha.
NeverExists
8th August 2022, 04:20
Do you want to get the RPU from a WEB-DL source and inject it into a BluRay? If that's what you want to do I'd recommend using djv, which can show a video frame-by-frame. What I do is open one file in djv, find a scene transition and note the frame number, then open the other file and find the corresponding frame number. This gives me the delay, which I then use in the DDVT injector tool.
DJV is?
GodzilaAvenger
8th August 2022, 05:04
DJV (https://darbyjohnston.github.io/DJV/)
von Suppé
8th August 2022, 09:42
@GodzilaAvenger
Clear. Thanks for explaining.
The file below contains a sample of both the source (remux) and re-encode files. Please let me know if either triggers DV on your player, thanks!
Will do and let you know. Thanks.
von Suppé
8th August 2022, 10:05
@Balling
I think you're missing the point. Note what my initial question was: is cross-using 23.976 RPU for 24 fps video and vice versa possible? Answer: RPU works with framenumbers, so yes. So no need to change framerate.
As for your introduction to conversion and the framedropping:
"why framedropping would come into play" you need to drop actual video frames
I disagree, it isn't needed at all. Eventhough dropping/doubling videoframes can be applied to change framerate, it is not necessary in many cases.
And in the light of my initial question, this way would even defy its own purpose; RPU and video would grow out of sync.
because there is no simple way to convert between /1.001
Yes, there is: rewriting timestamps :)
"Just rewriting timestamps would keep native frames and same framecount"
That would desync audio and subtitles that is why it is not done.
Actually, "sync" is the exact reason why it is done. A lot of people convert video 24 <--> 23.976 by rewriting timestamps. Not to get out of sync with its native audio, but to get in sync with other.
As an example, imagine having a TrueHD + Atmos track from a 24 fps source and a desired videotrack from a 23.976 source. No way you can speed-down Atmos while keeping Atmos format (with freeware, that is). But if you'd instead speed-up the video by rewriting timestamps, it can sync to the native Atmos track.
As for subs, that's a no-brainer. They can be resynced in the blink of an eye.
If you introduce framerate conversion; for RPU there's no need. You might have considered the reason why anybody would do such anyway.
von Suppé
8th August 2022, 10:14
Open Base Layer file/Container with the Injector. If the Injector found the EL.hevc file you have a new option to mux the MEL/FEL Layer into your Base Layer Stream.
Didn't know this. New to me. Interleaving BL and EL I always did manually with dovitool cli. Thanks for the heads-up.
Differences between Standard and makeMKV:
--eos-before-el Write the EOS/EOB NALUs before the EL. Defaults to false.
This flag enables the same behaviour as MakeMKV and yusesope's mux script.
Enabling this therefore results in identical output using dovi_tool.
What would be a specific reason to use either of the two? Can you give an example?
von Suppé
8th August 2022, 11:18
The file below contains a sample of both the source (remux) and re-encode files. Please let me know if either triggers DV on your player, thanks!
Both files don't trigger DV playback. Playback is jerky and displays dropouts.
MediaInfo shows variable framerate and weird framerate number. Maybe something went wrong?
GodzilaAvenger
8th August 2022, 14:33
Both files don't trigger DV playback. Playback is jerky and displays dropouts.
MediaInfo shows variable framerate and weird framerate number. Maybe something went wrong?
Thanks for checking them out. You are absolutely right, MediaInfo does show the frame rate for both variable and at 2000+. The original files (remux and encode) have constant 23.976 frame rate so I think this has something to do with LosslessCut that I used for making the clips.
Either way, I uploaded the entire encoded file below (remux was way too big), so check it out if you like, and thanks!
Encode (https://drive.google.com/file/d/1ti4XrwHpg-l_rJ7BZVl6p-B9VllFobdv/view?usp=sharing)
von Suppé
8th August 2022, 21:10
Your file does not trigger DV on my player. It falls back to HDR10, which playback is fine.
MediaInfo looks okay though. Weird.
GodzilaAvenger
8th August 2022, 21:30
Thanks for letting me know. Guess I'll just keep my remuxes until I can figure out how to properly encode both layers. Big waste of disk space though.
GodzilaAvenger
8th August 2022, 21:33
One more question, how should the RPU borders (top & bottom ones) be set on files where the aspect ratio changes (i.e. IMAX releases)? Is it the bigger margin (i.e. ~276px) or smaller one (i.e. ~42px)?
von Suppé
8th August 2022, 22:58
Interesting question. Since RPU is dynamic, you'd think L5 values would change throughout the movie.
I don't think I have a DV video with different aspect ratios. If you would have one, you can check & compare L5 data for different frame numbers with dovi_tool.
I wouldn't know how to edit L5 values for certain parts of video. Hopefully other users can explain how/if this can be done.
NeverExists
8th August 2022, 23:13
DJV (https://darbyjohnston.github.io/DJV/)
Thanks a lot that program works very well.
GodzilaAvenger
8th August 2022, 23:29
Interesting question. Since RPU is dynamic, you'd think L5 values would change throughout the movie.
I don't think I have a DV video with different aspect ratios. If you would have one, you can check & compare L5 data for different frame numbers with dovi_tool.
I wouldn't know how to edit L5 values for certain parts of video. Hopefully other users can explain how/if this can be done.
Thanks, I have a few that I can test on. DDVT asks for RPU cropping values when injecting an RPU.bin file and it always confused me what to do for these kinds of videos.
quietvoid
9th August 2022, 01:12
Thanks, I have a few that I can test on. DDVT asks for RPU cropping values when injecting an RPU.bin file and it always confused me what to do for these kinds of videos.
If you don't want to find every scene where the aspect ratio changes, use the smallest letterbox size.
GodzilaAvenger
9th August 2022, 01:21
So that's the same as the biggest aspect ratio (i.e. biggest border like ~276px), right? (sorry if it's a dumb question, just want to make sure)
quietvoid
9th August 2022, 01:34
So that's the same as the biggest aspect ratio (i.e. biggest border like ~276px), right? (sorry if it's a dumb question, just want to make sure)
No, the opposite. The smallest border.
NeverExists
9th August 2022, 01:39
Another Question. When I drop the Web-Dl on the demuxer, should I be converting it to 8.1? If so why does it say HDR if we are trying to make a hybrid? Wouldn't converting it to HDR lose some of the metadata? I'm trying to make Hybrids with the Web-dl rpu and Bluray release. I mean I've done a few and the end result has been 8.06 Dolby Vision which is what I want.
GodzilaAvenger
9th August 2022, 01:51
No, the opposite. The smallest border.
Got it, thanks! :)
GodzilaAvenger
9th August 2022, 07:09
Another Question. When I drop the Web-Dl on the demuxer, should I be converting it to 8.1? If so why does it say HDR if we are trying to make a hybrid? Wouldn't converting it to HDR lose some of the metadata? I'm trying to make Hybrids with the Web-dl rpu and Bluray release. I mean I've done a few and the end result has been 8.06 Dolby Vision which is what I want.
I think the HDR means that Profile 8.1 is backwards compatible with HDR10, same for 8.4 which is backwards compatible with HLG.
von Suppé
9th August 2022, 08:13
I have a few that I can test on.
Can you name the titles?
If you don't want to find every scene where the aspect ratio changes...
And what if I want to do just that? How to go further once having determined the frame-ranges and their proper offsets?
Is there a tutorial somewhere on how to edit L5 for parts of video?
-QfG-
9th August 2022, 08:36
What would be a specific reason to use either of the two? Can you give an example?
Ask quietvoid what happenend if you switch
--eos-before-el Write the EOS/EOB NALUs before the EL. Defaults to false.
to True. I have only build in this option in the DDVT tool and i never use this.
Do you want to get the RPU from a WEB-DL source and inject it into a BluRay? If that's what you want to do I'd recommend using djv, which can show a video frame-by-frame. What I do is open one file in djv, find a scene transition and note the frame number, then open the other file and find the corresponding frame number. This gives me the delay, which I then use in the DDVT injector tool.
Also you can use MeGui for this. You found MeGui here in the Forum. A little "how to do video" is here:
https://www.youtube.com/watch?v=gVZL1vwXFAg
Is there a tutorial somewhere on how to edit L5 for parts of video?
create a custom.json for this and copy this file near the video. If you start the INJECTOR, the Injector used this file BEFORE all inline settings will be set.
For example, you must delay a video 10 frames, but you will crop only few frames in the video and you use a custom.json for this (only for the crop function), the INJECTOR will first edit the frames from the custom.json and after this the delay will be set. A custom.json for crop frame 10 - 20* :
*Attention. In quietvoids tool is the first frame Frame 0! Some video editors tags first frame to frame 1. Check this before you set the frames here.
{
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 10,
"bottom": 10
}
],
"edits": {
"9-19": 0
}
}
}
Untestet, but i think it work so.
von Suppé
9th August 2022, 09:58
Nice, I'm gonna try things out. Conveniently VirtualDub also starts frame-count with 0.
As border-changes can take place several times,
can you tell up front if that specific code can be entered multiple times in one custom.json file?
Thanks a bunch anyways, -QfG- :)
quietvoid
9th August 2022, 13:32
What would be a specific reason to use either of the two? Can you give an example?
https://forum.makemkv.com/forum/viewtopic.php?f=12&t=18602&p=121961#p121961
tl;dr it only has an effect on the last frame, unless the title uses seamless branching.
Doesn't really matter but leaving the flag default is correct.
As border-changes can take place several times,
can you tell up front if that specific code can be entered multiple times in one custom.json file?
I don't really understand what you're asking. Preset IDs can be reused for multiple edits in the same JSON.
von Suppé
9th August 2022, 16:00
I don't really understand what you're asking. Preset IDs can be reused for multiple edits in the same JSON.
I think you answered my question partly --> "multiple edits in the same json file". But how to to that in code.
In -QfG-'s example L5 is set 10 bottom and 10 top for frames 9-19.
But how would that code look like, if I also want to set L5 offsets 280 top and 280 bottom for - let's say - frames 200-250?
GodzilaAvenger
9th August 2022, 16:01
Can you name the titles?
Off the top of my head Aquaman, The Dark Knight, The Dark Knight Rises, some older Marvel titles that aren't shot entirely in IMAX like Iron Man, Civil War, Black Widow, Eternals (as opposed to like Infinity War, Endgame, Shang-Chi, and Multiverse of Madness). If you want something truely challenging go with Everything Everywhere All at Once, the aspect ratio is just all over the place!
And what if I want to do just that? How to go further once having determined the frame-ranges and their proper offsets?
Is there a tutorial somewhere on how to edit L5 for parts of video?
I don't really understand what you're asking. Preset IDs can be reused for multiple edits in the same JSON.
So something like this?
{
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 10,
"bottom": 10
},
{
"id": 1,
"left": 0,
"right": 0,
"top": 276,
"bottom": 276
}
],
"edits": {
"9-19": 0,
"49-69": 1
}
}
}
BTW dovi_tool is amazing, thanks for creating it!
von Suppé
9th August 2022, 16:08
Ah, I was 3 seconds faster than you, GodzilaAvenger :-)
I have The Dark Night, so I can go check it out. Thanks for the script, it's getting more clear. I'm a total newbie to this.
Can you also provide an example for when there is more than one framerange that have same offsets?
GodzilaAvenger
9th August 2022, 16:35
Ah, I was 3 seconds faster than you, GodzilaAvenger :-)
:)
I have The Dark Night, so I can go check it out. Thanks for the script, it's getting more clear. I'm a total newbie to this.
Can you also provide an example for when there is more than one framerange that have same offsets?
I guess it would be something like this:
{
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 10,
"bottom": 10
},
{
"id": 1,
"left": 0,
"right": 0,
"top": 276,
"bottom": 276
}
],
"edits": {
"9-19": 0,
"49-69": 1,
"219-269": 0
}
}
}
I think overall the presets determine the L5 configs you want to use, the edits determine what frames each config applies to.
von Suppé
10th August 2022, 09:16
I think overall the presets determine the L5 configs you want to use, the edits determine what frames each config applies to.
Yeah, I think I'm getting it. Will play around and gonna try things out.
Thinking of it, I wonder how -QfG- injector would pipe this further. I assume that RPU itself wil be edited by the dovi_tool.exe.
In which case, do you perhaps know how dovitool's "RPU edit" basic commandline would look like? Say, with "RPU.bin" as input and using "custom.json" for the edits?
Thanks a bunch for your highly educating examples, GA.
GodzilaAvenger
10th August 2022, 14:42
Yeah, I think I'm getting it. Will play around and gonna try things out.
Thinking of it, I wonder how -QfG- injector would pipe this further. I assume that RPU itself wil be edited by the dovi_tool.exe.
In which case, do you perhaps know how dovitool's "RPU edit" basic commandline would look like? Say, with "RPU.bin" as input and using "custom.json" for the edits?
Thanks a bunch for your highly educating examples, GA.
You are very welcome! I have not tried this personally yet, but based on what @quietvoid and @-QfG have said and dovi_tool's documentation, I think this is how things work:
Let's say you have a file where most scenes have a standard AR (3840x1608), two have IMAX AR (3840x2076), and one is something in between (3840x1960). Then your "custom.json" file which is located next to your "RPU.bin" would look something like this:
{
"mode": 0,
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 276,
"bottom": 276
}
{
"id": 1,
"left": 0,
"right": 0,
"top": 42,
"bottom": 42
}
{
"id": 2,
"left": 0,
"right": 0,
"top": 100,
"bottom": 100
}
],
"edits": {
"all": 0,
"1000-1234": 1,
"2400-2468": 2,
"4800-4848": 1
}
}
}
You can then use the following command to edit your RPU:
dovi_tool editor -i RPU.bin -j custom.json -o Edited_RPU.bin
What this essentially does is to first assign the default AR L5 borders to all frames, then overwrite it for the frames specified. From what @-QfG- has said, I think if you have a "custom.json" file directly next to the "RPU.bin" file, when using DDVT_INJECTOR the tool first edits the RPU (using the dovi_tool command above) and then injects it into the mkv.
von Suppé
10th August 2022, 20:40
Very nice to learn the default for "all" and overwrite later.
Thanks again. I'm learning as I read and will try it all out. Have busy times ahead :)
I noticed "mode": 0, in the beginning. You know what it does? It's not in the earlier codes I read.
GodzilaAvenger
10th August 2022, 23:14
I noticed "mode": 0, in the beginning. You know what it does? It's not in the earlier codes I read.
Based on this (https://github.com/quietvoid/dovi_tool), it determines whether any conversion needs to be done, mode 0 parses the RPU and rewrites it untouched.
von Suppé
11th August 2022, 08:21
Could have rung a bell. Didn't realise it was meant as the same "mode" argument when extracting.
In the meantime I also "discovered" quietvoid's editor.md and the examples at GitHub. Never was aware. Terrible... :stupid:
Cheers, GA
Grimm
13th August 2022, 08:32
Please add the option to save the output file to another location
Lucius Snow
13th August 2022, 17:58
Hi -QfG- and thanks for this great tool.
As the HDR10+ contains tone mapping at 400 nits or 500 nits only, is your tool able to convert to Dolby Vision RPU with others profiles such as SDR 100 nits tone-mapping data?
quietvoid
13th August 2022, 19:31
As the HDR10+ contains tone mapping at 400 nits or 500 nits only, is your tool able to convert to Dolby Vision RPU with others profiles such as SDR 100 nits tone-mapping data?
Converting HDR10+ to Dolby Vision isn't supported.
-QfG-
13th August 2022, 20:52
Please add the option to save the output file to another location
Will add this in the next Update.
Lucius Snow
13th August 2022, 22:59
Converting HDR10+ to Dolby Vision isn't supported.
I was talking about the metadatas (JSON to RPU).
-Convert HDR10+ Metadata to DoVi Metadata (Experimental).
What about the tone mapping?
quietvoid
14th August 2022, 00:00
I was talking about the metadatas (JSON to RPU).
What about the tone mapping?
The HDR10+ tone mapping curve isn't mapped to Dolby Vision.
Only the frame brightness analysis is copied to the RPU.
Balling
14th August 2022, 13:30
@Balling
Actually, "sync" is the exact reason why it is done. A lot of people convert video 24 <--> 23.976 by rewriting timestamps. Not to get out of sync with its native audio, but to get in sync with other.
As an example, imagine having a TrueHD + Atmos track from a 24 fps source and a desired videotrack from a 23.976 source. No way you can speed-down Atmos while keeping Atmos format (with freeware, that is). But if you'd instead speed-up the video by rewriting timestamps, it can sync to the native Atmos track.
As for subs, that's a no-brainer. They can be resynced in the blink of an eye.
If you introduce framerate conversion; for RPU there's no need. You might have considered the reason why anybody would do such anyway.
Correct :)
Grimm
14th August 2022, 14:11
Will add this in the next Update.
Great thanks
von Suppé
15th August 2022, 15:16
Ok, think I managed to edit L5 to proper values for all frameranges of the movie "Interstellar". Wow, this sweety switches aspect ratio 125 times (!) if my count is right. Where a lot of switches happen after just a few seconds of each other. Quite some work...
Anyways, I had to apply a delay. Which of course went fine with -QfG- injector.
Reading the editor.md, am I right when assuming the "duplicate" and "remove" arguments are used for applying positive and negative delay?
Or is there a true "delay" argument? I couldn't find such at the editor examples.
quietvoid
15th August 2022, 15:25
Reading the editor.md, am I right when assuming the "duplicate" and "remove" arguments are used for applying positive and negative delay?
Or is there a true "delay" argument? I couldn't find such at the editor examples.
There's only duplicate and remove, so it's probably using them to delay.
von Suppé
15th August 2022, 15:44
Excellent. Thanks, quietvoid.
Fortune
15th August 2022, 16:06
Thanks for the great tool. I am very new to this and have a simple question.
How can i see all the frame info for the RPU for a particular movie?
Currently I use the DDVT_FRAMEINFO but this tool is only for a specific frame. Is there a way for it to ouput all frames?
Reason being I wish to see the active area for films that have changing active areas. Like for Aquaman.
Thanks in advance.
GodzilaAvenger
15th August 2022, 19:07
Ok, think I managed to edit L5 to proper values for all frameranges of the movie "Interstellar". Wow, this sweety switches aspect ratio 125 times (!) if my count is right. Where a lot of switches happen after just a few seconds of each other. Quite some work...
Anyways, I had to apply a delay. Which of course went fine with -QfG- injector.
Reading the editor.md, am I right when assuming the "duplicate" and "remove" arguments are used for applying positive and negative delay?
Or is there a true "delay" argument? I couldn't find such at the editor examples.
I did this for Civil War yesterday, which thankfully only had one IMAX scene so it was much much easier. My RPU was out of sync with the movie (it needed to be delayed by 2 frames). Here's what I did (for simplicity assume the IMAX frames where from 1000 to 2000):
1. Created a custom.json file with the L5 metadata next to the RPU.bin file, something like this:
{
"mode": 0,
"active_area": {
"crop": false,
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 280,
"bottom": 280
},
{
"id": 1,
"left": 0,
"right": 0,
"top": 69,
"bottom": 69
}
],
"edits": {
"all": 0,
"1000-2000": 0,
}
}
}
2. Since DDVT_INJECTOR first applies the custom.json file, then the delay, I shifted the frame range values by 2, so something like this:
{
"mode": 0,
"active_area": {
"crop": false,
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 280,
"bottom": 280
},
{
"id": 1,
"left": 0,
"right": 0,
"top": 69,
"bottom": 69
}
],
"edits": {
"all": 0,
"998-1998": 0,
}
}
}
Then, I used DDVT_INJECTOR and for delay entered 2. It did the rest of the work. I checked afterwards and everything was accurate, i.e. frames 1000 to 2000 had the IMAX L5 borders.
GodzilaAvenger
15th August 2022, 19:13
Thanks for the great tool. I am very new to this and have a simple question.
How can i see all the frame info for the RPU for a particular movie?
Currently I use the DDVT_FRAMEINFO but this tool is only for a specific frame. Is there a way for it to ouput all frames?
Reason being I wish to see the active area for films that have changing active areas. Like for Aquaman.
Thanks in advance.
Use DDVT_DEMUXER to extract the RPU.bin file, then go to the tools folder and use dovi_tool export, i.e.
cd tools
./dovi_tool export [args]
(populate [args] with the proper arguments). This will convert RPU.bin into a .json file which you can view in a text editor.
On a side note, DDVT_FRAMEINFO seems to extract RPU.bin from the .mkv file each time it is called, which can be time-consuming. Instead you can use DDVT_DEMUXER to extract the RPU.bin file once and then use dovi_tool info to get information about a specific frame.
von Suppé
16th August 2022, 08:19
2. Since DDVT_INJECTOR first applies the custom.json file, then the delay, I shifted the frame range values
Damn, I think this is where I went wrong. My end result doesn't look good. Border changes clearly aren't in sync. I applied 24 frames delay but the framerange edits were already from target video.
I extracted the endresult RPU and checked some frame-infos. Indeed they shifted 24 frames. Like 100-150 was adjusted to 124-174.
No way I'm gonna manually edit my json. Gonna figure out how dovitool.exe "duplicate" argument works and first try to only apply delay. After which I'll use the "delay-corrected RPU" as input for the json L5 edits. Learning as I get by...
Thanks, GodzilaAvenger. You saved the day once again! :)
GodzilaAvenger
16th August 2022, 09:05
Damn, I think this is where I went wrong. My end result doesn't look good. Border changes clearly aren't in sync. I applied 24 frames delay but the framerange edits were already from target video.
I extracted the endresult RPU and checked some frame-infos. Indeed they shifted 24 frames. Like 100-150 was adjusted to 124-174.
No way I'm gonna manually edit my json. Gonna figure out how dovitool.exe "duplicate" argument works and first try to only apply delay. After which I'll use the "delay-corrected RPU" as input for the json L5 edits. Learning as I get by...
Thanks, GodzilaAvenger. You saved the day once again! :)
Always a pleasure :)
One thing you could do is extract the RPU using the DEMUXER, apply the delay when using the INJECTOR to get it in sync with the movie (no custom.json for now, borders are set in the next step), extract the new RPU using the DEMUXER, this time using INJECTOR with 0 delay along with custom.json.
To get the RPU in sync with the movie, I usually use dovi_tool info on that RPU to look at values for "max_pq", i.e. something like this
dovi_tool.exe info -i RPU.bin -f 1000 | Select-String "max_pq"
"max_pq" is usually set scene-by-scene, so I look for two consecute frames where it changes, and correspond that with a cut (scene transition) in the film. This gives me the delay.
Finally, note that dovi_tool is 0-based, i.e. the first frame is numbered 0.
quietvoid
16th August 2022, 12:17
"max_pq" is usually set scene-by-scene, so I look for two consecute frames where it changes, and correspond that with a cut (scene transition) in the film.
Normally you can just look at if `scene_refresh_flag` is equal to 1, indicating a scene cut.
There's another script from someone at MakeMKV that can extract the scene cuts, as well.
von Suppé
16th August 2022, 13:39
One thing you could do is extract the RPU using the DEMUXER, apply the delay when using the INJECTOR to get it in sync with the movie (no custom.json for now, borders are set in the next step), extract the new RPU using the DEMUXER, this time using INJECTOR with 0 delay along with custom.json.
I also considered this way but I did not like the idea of having to extract RPU again after first injection. Too laborious. And I already wanted to know how to manually add delay with dovitool.exe. So I read and did some tryouts.
I got the "duplicate" function working, which wasn't so difficult actually. Set a sourceframe, where and how many duplicated frames you want and Bob's your uncle. It sure beats the hell out of manually editing a kazillion frameranges in json :)
BTW next to the delay function, I'm guessing QfG injector would also apply either "duplicate" or "remove" somewhere for the last frames, in order to match the total amount of actual frames in target-video.
Anyways, so I delayed the RPU first, and the resulting RPU I edited with the L5 edits json file.
Some quick & dirty frame-infos showed L5 edits in the correct place this time. Injecting and remuxing now, hoping on good end-result.
note that dovi_tool is 0-based, i.e. the first frame is numbered 0.
Yes, I know. For framenumber stuff and viewing I use VirtualDub, which also starts framecount at zero.
GodzilaAvenger
16th August 2022, 16:09
Normally you can just look at if `scene_refresh_flag` is equal to 1, indicating a scene cut.
There's another script from someone at MakeMKV that can extract the scene cuts, as well.
Thanks, I didn't know that. I'll look up the script.
I also considered this way but I did not like the idea of having to extract RPU again after first injection. Too laborious. And I already wanted to know how to manually add delay with dovitool.exe. So I read and did some tryouts.
I got the "duplicate" function working, which wasn't so difficult actually. Set a sourceframe, where and how many duplicated frames you want and Bob's your uncle. It sure beats the hell out of manually editing a kazillion frameranges in json :)
Glad to see you got it working. Demuxing and remuxing does take a lot of time, especially if you're using HDDs!
Fortune
16th August 2022, 18:39
Use DDVT_DEMUXER to extract the RPU.bin file, then go to the tools folder and use dovi_tool export, i.e.
cd tools
./dovi_tool export [args]
(populate [args] with the proper arguments). This will convert RPU.bin into a .json file which you can view in a text editor.
On a side note, DDVT_FRAMEINFO seems to extract RPU.bin from the .mkv file each time it is called, which can be time-consuming. Instead you can use DDVT_DEMUXER to extract the RPU.bin file once and then use dovi_tool info to get information about a specific frame.
Thanks Godzilla.
I have extracted the RPU.bin but I dont have dovi_tool_export application.
Sorry I dont really understand can you expand on your explation please if possible.
Would be real nice if possible we can add a script for novices like me lol
GodzilaAvenger
16th August 2022, 18:58
export is a functionality of dovi_tool, which comes with DDVT.
Open the DDVT folder, then go to tools. You'll see dovi_tool.exe there. Open a terminal in that folder and use
.\dovi_tool.exe export -i \path\to\RPU.bin -o \path\to\RPU_export.json
You can also use
.\dovi_tool.exe export --help
for more info.
NeverExists
17th August 2022, 00:25
Hi, Quick Question. What do I do if the Web-Dl and the RPU are 8 frames ahead of the Bluray release File? I know there is the rpu delay, but I don't want to delay the RPU. Is there a way to make it work?
GodzilaAvenger
17th August 2022, 03:02
The film and the RPU have to be in sync so the correct lighting is applied to each scene (which is pretty much the whole point of DV), otherwise you get weird flashes and lighting changes. So, I think your options are to either delay the RPU or cut some frames from the beginning of the film. Why don't you want to delay the RPU?
GodzilaAvenger
17th August 2022, 03:13
Normally you can just look at if `scene_refresh_flag` is equal to 1, indicating a scene cut.
There's another script from someone at MakeMKV that can extract the scene cuts, as well.
For anyone interested, I believe this (https://forum.makemkv.com/forum/viewtopic.php?p=123221#p123221) is the script quietvoid was referring to for getting all the scene cuts.
von Suppé
17th August 2022, 10:14
This may come in handy, gonna play around with it. Thanks for the link, GA.
Latest remux of Interstellar plays flawlessly. Being at it, atm I'm figuring out the "remove" function of dovitool.exe.
von Suppé
17th August 2022, 12:20
Dovi_tool's "demux" section at the online readme.me says RPU can be removed from hevc.
So I demuxed a "BL+RPU" hevc stream and the output gives me a BL and EL. The demuxed BL indeed holds no RPU data.
The size of the demuxed EL would suggest it holds the RPU. However, dropping the EL on DDVT_DEMUXER or DDVT_REMOVER both times shows no DV data.
First, I wonder if an extra option needs to be added after demux to properly remove RPU with dovitool.exe. The demux --help didn't provide with relevant info.
Secondly, what's up with this demuxed EL? Is there any use to it?
NeverExists
17th August 2022, 13:29
The film and the RPU have to be in sync so the correct lighting is applied to each scene (which is pretty much the whole point of DV), otherwise you get weird flashes and lighting changes. So, I think your options are to either delay the RPU or cut some frames from the beginning of the film. Why don't you want to delay the RPU?
Cause the RPU is from the film that is longer than the Bluray release. I want to make a hybrid. using the Bluray file's video. So how would delaying the rpu help if it's already too long?
-QfG-
17th August 2022, 16:38
New update coming soon. NEW* TMP Folder and Output Folder can be set. Also i creating a readme file for all functions.
von Suppé
17th August 2022, 17:38
Nice one, -QfG-. Looking forward to it.
Cause the RPU is from the film that is longer than the Bluray release.
With longer, you mean that the two versions are entirely different? Like one is a "theater release" and the other an "extended cut" or something? If so, you can't use the RPU. It's for totally different scenes and timings.
Chances are you have two versions that carry the exact same movie, but one has some extra frames at the end. Like in the same way one already has a few frames added at the beginning. Then you can use the RPU. The injector will see to it that the amount of frames will match at the end.
But you do have to set the delay to sync RPU to target video. If you don't, like GodzilaAvenger said, you'll experience flickering/flashes during the entire video.
Maybe you need to check first if the two versions of the movies are the same before proceeding.
-QfG-
17th August 2022, 18:11
-v0.48
*Updated mkvtoolnix to v 69.0.0.0.
*Add function to set TEMP and OUTPUT folder.
*Multi instances support (only for different releases!)
Many deep changes in the scripts for adding Folder Support. I hope all works bugfree.
NeverExists
17th August 2022, 19:53
Nice one, -QfG-. Looking forward to it.
With longer, you mean that the two versions are entirely different? Like one is a "theater release" and the other an "extended cut" or something? If so, you can't use the RPU. It's for totally different scenes and timings.
Chances are you have two versions that carry the exact same movie, but one has some extra frames at the end. Like in the same way one already has a few frames added at the beginning. Then you can use the RPU. The injector will see to it that the amount of frames will match at the end.
But you do have to set the delay to sync RPU to target video. If you don't, like GodzilaAvenger said, you'll experience flickering/flashes during the entire video.
Maybe you need to check first if the two versions of the movies are the same before proceeding.
I mean The Web download and RPU are 8 frames ahead of the Bluray from the beginning, not the end. That's why I don't understand why I would use a delay for the rpu when it's already ahead of the bluray release by 8 frames.
-QfG-
17th August 2022, 20:31
-v0.48a
*Updated FRAMEINFO Function. If you set Frames to ALL, all frames of
a RPU will be exported. Also a file with all scenecuts will be created.
Automatically formated in readable format.
*Minor Bugfixes.
I mean The Web download and RPU are 8 frames ahead of the Bluray from the beginning, not the end. That's why I don't understand why I would use a delay for the rpu when it's already ahead of the bluray release by 8 frames.
Example:
BluRay Frame 100 identical to RPU Frame 120 -> set Delay "-20"
BluRay Frame 120 identical to RPU Frame 100 -> set Delay "20"
GodzilaAvenger
17th August 2022, 20:36
I mean The Web download and RPU are 8 frames ahead of the Bluray from the beginning, not the end. That's why I don't understand why I would use a delay for the rpu when it's already ahead of the bluray release by 8 frames.
You can also set negative delay. If, for example, frame 8 of the RPU corresponds to frame 0 of BluRay, set a -8 delay, which tells DDVT to remove the first 8 frames of the RPU.
Edit: same as what -QfG- said!
von Suppé
17th August 2022, 22:04
@-QfG-
Thanks for implementing the "all scenecuts" output for DDVT_FRAMEINFO. Very nice.
When DDVT_FRAMEINFO has finished output for a single frame, can you make it return as to be ready to take another framenumber? Unless I'm missing something, now for every single frame the RPU needs to be dropped on the command.
Thanks
GodzilaAvenger
17th August 2022, 22:10
Dovi_tool's "demux" section at the online readme.me says RPU can be removed from hevc.
So I demuxed a "BL+RPU" hevc stream and the output gives me a BL and EL. The demuxed BL indeed holds no RPU data.
The size of the demuxed EL would suggest it holds the RPU. However, dropping the EL on DDVT_DEMUXER or DDVT_REMOVER both times shows no DV data.
First, I wonder if an extra option needs to be added after demux to properly remove RPU with dovitool.exe. The demux --help didn't provide with relevant info.
Secondly, what's up with this demuxed EL? Is there any use to it?
Have you tried the extract-rpu command of dovi_tool?
quietvoid can speak more to this, but my understanding is that for DV Profile 5 (which most streamers use) and Profile 8, the EL is essentially the RPU. For DV Profile 7 (which is used for UHD BluRays), the EL can be either the RPU alone (Minimum Enhancement Layer or MEL) or RPU plus a second 1080p track (Full Enhancement Layer or FEL). On compatible players, a second HEVC decoder is launched to decode the FEL, which when put together with the decoded BL should get very close to the 12-bit DV master of the movie.
The first post of this (https://forum.blu-ray.com/showthread.php?t=276448) topic has some good information, just make sure to click on the 'Show spoiler' links.
quietvoid
17th August 2022, 22:16
The EL file obtained from demuxing a non profile 7 single layer file cannot be reused, as it only contains the RPU with extra bytes.
GodzilaAvenger
18th August 2022, 03:03
-v0.48
*Updated mkvtoolnix to v 69.0.0.0.
*Add function to set TEMP and OUTPUT folder.
*Multi instances support (only for different releases!)
Many deep changes in the scripts for adding Folder Support. I hope all works bugfree.
It seems that in the new version, file paths that have a space in them don't work. When using such a file (e.g. D:\Path to\file location\file) DDVT creates empty folders in its directory (in this example it creates empty folders named "Path", "to", "file" "location", etc.). In previous versions a similar issue would occur if a parenthesis was in the file path.
Also, specifying ALL in FRAMEINFO returns empty .json files (both frame info .json and scene cut .json files are returned empty). The issue seems to be coming from jq, because when I replaced the jq.exe in the tools folder with the jq-win64.exe file I downloaded the issue was resolved.
It would be great if when selecting ALL for FRAMEINFO, information about the video and RPU borders would be displayed as well, much like when inputting "C" on the DEMUXER, with the option to fix the borders.
Also, how do we set the output directory to be the same as the working directory, like it used to be?
NeverExists
18th August 2022, 04:33
You can also set negative delay. If, for example, frame 8 of the RPU corresponds to frame 0 of BluRay, set a -8 delay, which tells DDVT to remove the first 8 frames of the RPU.
Edit: same as what -QfG- said!
Thanks, Guys!
von Suppé
18th August 2022, 08:59
Have you tried the extract-rpu command of dovi_tool?
Yes, I extract RPU with the dovitool command many times. But this leaves the sourcestream untouched and outputs a copy of RPU. My post was about removing RPU from a stream, which is a different thing.
my understanding is that for DV Profile 5 (which most streamers use) and Profile 8, the EL is essentially the RPU.
Well, to be exact, Profiles 5 and 8 don't carry any enhancement layer. They hold RPU and a single layer video.
For DV Profile 7 (which is used for UHD BluRays), the EL can be either the RPU alone (Minimum Enhancement Layer or MEL) or RPU plus a second 1080p track (Full Enhancement Layer or FEL).
I am familiar with MEL and FEL and them carrying RPU on UHDBD. My post was about a single layer "BL+RPU" stream, so without any EL. Which demuxing surprised me because of EL being part of the output.
The EL file obtained from demuxing a non profile 7 single layer file cannot be reused, as it only contains the RPU with extra bytes.
Thanks for making that clear.
specifying ALL in FRAMEINFO returns empty .json files (both frame info .json and scene cut .json files are returned empty). The issue seems to be coming from jq, because when I replaced the jq.exe in the tools folder with the jq-win64.exe file I downloaded the issue was resolved.
Weird. It works here. Is it the Windows version? I'm on Windows 7 (I do have to replace mkvmerge and mkvextract with compatible versions)
GodzilaAvenger
18th August 2022, 09:35
Weird. It works here. Is it the Windows version? I'm on Windows 7 (I do have to replace mkvmerge and mkvextract with compatible versions)
I'm on Windows 11, so maybe?
Edit: seems to be a system architecture thing, the jq coming with DDVT seems to be the 32-bit version, the one I downloaded the 64-bit version. A solution may be to include both and use the appropriate one based on system architecture.
von Suppé
18th August 2022, 09:52
I'm on Windows 11, so maybe?
Edit: seems to be a system architecture thing, the jq coming with DDVT seems to be the 32-bit version, the one I downloaded the 64-bit version.
Well I'm running 64 bit Windows 7...
Is dropping "EL+RPU" on latest DDVT_DEMUXER working on your pc? I get error "No Dolby Vision Profile found".
alexflin
18th August 2022, 13:44
Hi,
I would like to create an iso image to burn into a bluray with the BL.hevc and EL.hevc but it doesn't work, any Idea? Should be because the mkv it has a profile 8?
https://i.ibb.co/c809j7f/image.png (https://ibb.co/C9gyfTC)
alexflin
18th August 2022, 13:46
Well I'm running 64 bit Windows 7...
Is dropping "EL+RPU" on latest DDVT_DEMUXER working on your pc? I get error "No Dolby Vision Profile found".
Try to rename the video without spaces. I had the same error and I fixed it by doing this.
von Suppé
18th August 2022, 15:23
Try to rename the video without spaces. I had the same error and I fixed it by doing this.
Thanks, but the filename is already EL.hevc. Version 47a works. Latest doesn't.
-QfG-
18th August 2022, 16:28
Working on a fix. Coming soon ...
GodzilaAvenger
18th August 2022, 18:02
Well I'm running 64 bit Windows 7...
Is dropping "EL+RPU" on latest DDVT_DEMUXER working on your pc? I get error "No Dolby Vision Profile found".
Thanks, but the filename is already EL.hevc. Version 47a works. Latest doesn't.
Weird...
It seems the whole file path should not have any spaces, not just the file name, so if any upstream folders have a space try changing those and see if that makes a difference.
Working on a fix. Coming soon ...
Thanks!
-QfG-
18th August 2022, 18:12
-v0.48b
*Updated mkvtoolnix to v 70.0.0.0.
*Fixed bugs with spaced names.
*Fixed FRAMEINFO function.
I hope everything works well.
EDIT Reuploaded, because one wrong script was inside.
GodzilaAvenger
19th August 2022, 00:24
I hope everything works well.
EDIT Reuploaded, because one wrong script was inside.
It all works now, thanks!
von Suppé
19th August 2022, 08:51
Thanks for the fix, -QfG-
Try to rename the video without spaces. I had the same error and I fixed it by doing this.
I didn't realise you meant the whole path without spaces. You were bang on.
NeverExists
20th August 2022, 00:43
Don't know if this is the right place to ask but I was wondering if anyone knew of a tool I could use to convert already owned 4k Dolby Vision Movies From my iTunes account to something I can use with this tool? I have some movies I've bought on my iTunes account that I would like to make a higher-quality hybrid with. Sorry if this is the wrong place
GodzilaAvenger
20th August 2022, 18:00
I'm a bit out of my depth here but I think you should look up M4V converters.
von Suppé
21st August 2022, 10:41
I don't have any experience with iTunes products, M4V container and its possible contents.
I read they can be copy-protected. So I wonder if you wouldn't in the first place need a decryper?
GodzilaAvenger
24th August 2022, 07:18
It seems the HDR10+ injector tool doesn't work, saying it cannot find the input file after extracting the video layer from the mkv. Probably some bug with the new temp and output folder structure.
von Suppé
24th August 2022, 09:07
Thanks for the headsup, GA. I have a similar issue for DDVT_REMOVER.
Having checked for both HDR10+ and RPU, I get same error:
<
== COPYING ====================================
Please wait. Copy Stream to Temp folder...
The system cannot find the path specified.
Error.
>
GodzilaAvenger
24th August 2022, 18:00
For the time being my workaround is to grab the temp.hevc file and work with that.
-QfG-
25th August 2022, 19:46
-v0.48c
*REMOVER - Fixed Bug with wrong temp directory.
*INJECTOR - Fixed Bug with HDR10+ Injection.
*INJECTOR - Support for DV Profile 5 Video Streams.
*Updated hdr10plus_tool to v1.3.2.
*Updated dovi_tool to v1.5.6.
von Suppé
26th August 2022, 08:31
Injector and remover work again. Tested with no temp folder set.
Thanks for fixing :-)
DiscoD
26th August 2022, 22:11
Long Time user of the tool but i just wanted to make sure i am using and understanding the crop feature correctly...
i have always extracted and injected my RPU untouched from the source because i never cropped them i just left the black bars included while encoding.
more recently i have started to crop the encodes but i think i may be a bit confused on the crop/borders function.
in the picture included i cropped the encode and its my understanding(this is where i may be wrong) that cropping the rpu is just changing the Active area L5,Well obviously when i crop the video the TV will still have black bars since the video resolution is 3840x1600...
So the active area of the RPU should still be cropped to 280px on top and bottom to match the active area of the actual video file...
but when i extracted my RPU i cropped it since i was cropping the video as well and DDVT says its correct but i believe i may be confused
https://i.ibb.co/5hp7PNQ/rightorwrong.png (https://ibb.co/5hp7PNQ)
Just want to make sure im understanding and using this correctly,
Thanks!
-QfG-
26th August 2022, 23:08
If you crop your video you have letterbars on the TV, right (if you not change the Aspect Ratio). But the letterbars you see on your tv are not active pixels, that are "dead pixel".
Your TV will playback the video in the resolution 3840x1600 and set this in the middle of the display.
For cropped encodes with no black borders included, you must set the active area to 0,0,0,0.
DiscoD
27th August 2022, 00:20
If you crop your video you have letterbars on the TV, right (if you not change the Aspect Ratio). But the letterbars you see on your tv are not active pixels, that are "dead pixel".
Your TV will playback the video in the resolution 3840x1600 and set this in the middle of the display.
For cropped encodes with no black borders included, you must set the active area to 0,0,0,0.
I understand now thank you,
since the black bars on a cropped encode are seen essentially as inactive pixels, the RPU must match the active pixels on screen..
Keep up the great work!!!
speedy
28th August 2022, 18:13
I'm trying to create DoVi files that are compatible with Apple TV which means I need to use either Profile 5 or 8.4.
I want to use Profile 8.4 though so I can retain backwards compatibility with non-DoVi HDR displays.
I tried to convert a Profile 7 MEL file to DoVi Profile 8.4 using DDVT Tool but Infuse on Apple TV didn't detect it as DoVi and just played it back as HDR10.
Does anyone know how I can reliably convert both Profile 7 and 8.1 DoVi files to Profile 8.4 for Apple TV compatibility?
Thank you!
DiscoD
28th August 2022, 19:36
I'm trying to create DoVi files that are compatible with Apple TV which means I need to use either Profile 5 or 8.4.
I want to use Profile 8.4 though so I can retain backwards compatibility with non-DoVi HDR displays.
I tried to convert a Profile 7 MEL file to DoVi Profile 8.4 using DDVT Tool but Infuse on Apple TV didn't detect it as DoVi and just played it back as HDR10.
Does anyone know how I can reliably convert both Profile 7 and 8.1 DoVi files to Profile 8.4 for Apple TV compatibility?
Thank you!
I'm not sure of the process surrounding 8.4 but here is a good list put together about playback device compatibility...
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit#gid=427220017
maybe 8.4 is working for people more recently if but this list is updated pretty often.
-QfG-
28th August 2022, 21:18
The RPU is not Profile 8.1,8.2 or 8.4 the RPU is every times Profile 8. If you mux the RPU now in:
HDR Stream you have Profile 8.1
SDR Stream you have Profile 8.2
HLG Stream you have Profile 8.4
So you need an HLG Base layer and mux the Profile 8 RPU in it. I think this works.
Profile 5 is another thing, you have the IPT (IPTPQc2 (https://en.wikipedia.org/wiki/ICtCp#IPTPQc2)) colorspace not the BT.2020 there.
Therefore, no fallback to HDR with Profile 5, because no BT.2020 colorspace are used.
AgentXXL
28th August 2022, 22:49
Some releases have a RPU with l6 metadata over 10.000. The tool will not mux them, because 10.000 is the max value there. If you have this problem simply set L6 Metadata to the same values how the HDR stream have.
I've been having great success with the scripts - so far I've saved about 4TB of space making hybrid DV-HDR versions instead of having to keep a copy of each.
I do have an issue with a couple of releases - the Demuxer script and dovi_tool itself complain with this message:
`self.max_display_mastering_luminance <= MAX_PQ_LUMINANCE`
It then exits the script with a zero byte RPU.bin. I see the mention of matching L6 metadata but I can't get that far as I have no RPU.bin to use with Injector.
I've done some searching online but my Google-fu is failing me. Is there a workaround/fix for DV files that have this issue?
And once again: thank you QfG, quietvoid and many others for your efforts! Truly impressive to see what this helpful community offers.
GodzilaAvenger
28th August 2022, 23:10
Profile 5 is another thing, you have the IPT (IPTPQc2 (https://en.wikipedia.org/wiki/ICtCp#IPTPQc2)) colorspace not the BT.2020 there.
Therefore, no fallback to HDR with Profile 5, because no BT.2020 colorspace are used.
Interesting... I once injected a Profile 5 RPU into an HDR BL and the result showed up as "Dolby Vision / HDR10" in MediaInfo, and played back as HDR on my TVs internal player (which doesn't support DV). Does this mean it won't trigger DV on a compatible player?
-QfG-
29th August 2022, 01:50
Maybe DV will be triggered with a HDR BL and a P5 RPU, but i'm sure you have some display errors on screen. I can test this in the next time :)
I've done some searching online but my Google-fu is failing me. Is there a workaround/fix for DV files that have this issue?
Yes there is, but I never wanted to make this script public.
I called this L6 Demuxer and can extract these RPUs. I post the script here, just create a cmd, save the content there and use this script just like the others.
@echo off & setlocal
mode con cols=122 lines=57
TITLE DDVT L6DEMUXER [DonaldFaQ] v0.48b beta
set RAW_FILE=FALSE
SET MaxDML=1000
SET MinDML=1
SET MaxCLL=0
SET MaxFall=0
set "sfkpath=%~dp0tools\sfk.exe" rem Path to sfk.exe
set "FFMPEGpath=%~dp0tools\ffmpeg.exe" rem Path to ffmpeg.exe
set "MKVEXTRACTpath=%~dp0tools\mkvextract.exe" rem Path to mkvextract.exe
set "MKVMERGEpath=%~dp0tools\mkvmerge.exe" rem Path to mkvmerge.exe
set "MP4BOXpath=%~dp0tools\mp4box.exe" rem Path to mp4box.exe
set "MP4FPSMODpath=%~dp0tools\mp4fpsmod.exe" rem Path to mp4fpsmod.exe
set "MEDIAINFOpath=%~dp0tools\mediainfo.exe" rem Path to mediainfo.exe
set "DO_VI_TOOLpath=%~dp0tools\dovi_tool.exe" rem Path to dovi_tool.exe
set "HDR10P_TOOLpath=%~dp0tools\hdr10plus_tool.exe" rem Path to hdr10plus_tool.exe
rem --- Hardcoded settings. Cannot be changed ---
set "TMP_FOLDER=SAME AS SOURCE\%~n1_[TEMP]"
set "TARGET_FOLDER=SAME AS SOURCE\%~n1_[L6 DEMUXED]"
set HDR=No HDR Infos found
set DV=FALSE
set HDR10P=FALSE
set REMHDR10PString=
set EXTSTRING=
set RESOLUTION=n.a.
set HDR=n.a.
set CODEC_NAME=n.a.
set FRAMERATE=n.a.
set FRAMES=n.a.
set INPUTFILENAME=%~nx1
set RAW_FILE=FALSE
set WAIT="%sfkpath%" sleep
set GREEN="%sfkpath%" color green
set RED="%sfkpath%" color red
set YELLOW="%sfkpath%" color yellow
set WHITE="%sfkpath%" color white
set CYAN="%sfkpath%" color cyan
set MAGENTA="%sfkpath%" color magenta
set GREY="%sfkpath%" color grey
set ERRORCOUNT=0
::Check for INI and Load Settings
setlocal EnableDelayedExpansion
IF EXIST "%~dp0DDVT_OPTIONS.ini" (
FOR /F "delims=" %%A IN ('findstr /C:"TEMP Folder=" "%~dp0DDVT_OPTIONS.ini"') DO (
set "TMP_FOLDER=%%A"
set "TMP_FOLDER=!TMP_FOLDER:~12!\%~n1_[TEMP]"
)
FOR /F "delims=" %%A IN ('findstr /C:"TARGET Folder=" "%~dp0DDVT_OPTIONS.ini"') DO (
set "TARGET_FOLDER=%%A"
set "TARGET_FOLDER=!TARGET_FOLDER:~14!\%~n1_[L6 DEMUXED]"
)
)
setlocal DisableDelayedExpansion
if "%TMP_FOLDER%"=="SAME AS SOURCE\%~n1_[TEMP]" set "TMP_FOLDER=%~dpn1_[TEMP]"
if "%TARGET_FOLDER%"=="SAME AS SOURCE\%~n1_[L6 DEMUXED]" set "TARGET_FOLDER=%~dpn1_[L6 DEMUXED]"
%GREEN%
echo powered by quietvoids tools Copyright (c) 2021 DonaldFaQ
echo.
%WHITE%
echo ====================================
%GREEN%
echo Dolby Vision Tool L6 DEMUXER
%WHITE%
echo ====================================
echo.
%WHITE%
echo.
echo.
echo == CHECK INPUT FILE ====================================================================================================
if "%~1"=="" (
%yellow%
echo.
echo No Input File. Use DDVT_DEMUXER.cmd "YourFilename.hevc/h265/mkv/mp4"
goto EXIT
)
if /i "%~x1"==".hevc" set "RAW_FILE=TRUE" & goto CHECK
if /i "%~x1"==".h265" set "RAW_FILE=TRUE" & goto CHECK
if /i "%~x1"==".mkv" set "MKVExtract=TRUE" & goto CHECK
if /i "%~x1"==".mp4" set "MP4Extract=TRUE" & goto CHECK
%yellow%
echo.
echo File not Supported^! Only HEVC^/h265^/MP4^/MKV files supported.
goto EXIT
:CHECK
set "VIDEOSTREAM=%~1"
if not exist "%TMP_FOLDER%" MD "%TMP_FOLDER%">nul
if not exist "%TARGET_FOLDER%" MD "%TARGET_FOLDER%">nul
if "%RAW_FILE%"=="TRUE" "%MKVMERGEpath%" --priority higher --output ^"%TEMP%\Info.mkv^" --language 0:und --compression 0:none ^"^(^" ^"%~1^" ^"^)^" --split parts:00:00:00-00:00:01 -q
"%MEDIAINFOpath%" --output=Video;%%Width%%x%%Height%% %1>"%TEMP%\Info.txt"
set /p RESOLUTION=<"%TEMP%\Info.txt"
if "%RESOLUTION%"=="3840x21601920x1080" set "RESOLUTION=3840x2160 DL"
if "%RAW_FILE%"=="TRUE" (
pushd %tmp%
"%MEDIAINFOpath%" --output=Video;%%HDR_Format/String%% Info.mkv>"%TEMP%\Info.txt"
popd
) else (
"%MEDIAINFOpath%" --output=Video;%%HDR_Format/String%% %1>"%TEMP%\Info.txt"
)
set /p HDR=<"%TEMP%\Info.txt"
"%MEDIAINFOpath%" --output=Video;%%Format%%^-%%BitDepth%%Bit^-%%ColorSpace%%^-%%ChromaSubsampling%% %1>"%TEMP%\Info.txt"
set /p CODEC_NAME=<"%TEMP%\Info.txt"
if "%CODEC_NAME%"=="HEVC-10Bit-YUV-4:2:0HEVC-10Bit-YUV-4:2:0" set "CODEC_NAME=HEVC-10Bit-YUV-4:2:0"
"%MEDIAINFOpath%" --output=Video;%%FrameRate%% %1>"%TEMP%\Info.txt"
set /p FRAMERATE=<"%TEMP%\Info.txt"
if "%FRAMERATE%"=="23.97623.976" set "FRAMERATE=23.976"
if "%FRAMERATE%"=="24.00024.000" set "FRAMERATE=24.000"
"%MEDIAINFOpath%" --output=Video;%%FrameCount%% %1>"%TEMP%\Info.txt"
set /p FRAMES=<"%TEMP%\Info.txt"
if exist "%TEMP%\Info.txt" del "%TEMP%\Info.txt">nul
if exist "%TEMP%\Info.mkv" del "%TEMP%\Info.mkv">nul
:START
cls
%GREEN%
echo powered by quietvoids tools Copyright (c) 2021 DonaldFaQ
echo.
%WHITE%
echo ====================================
%GREEN%
echo Dolby Vision Tool L6 DEMUXER
%WHITE%
echo ====================================
echo.
echo.
echo == VIDEO INPUT =========================================================================================================
echo.
%CYAN%
echo Filename = [%INPUTFILENAME%]
echo Video Info = [Resolution = %RESOLUTION%] [Codec = %CODEC_NAME%] [Frames = %FRAMES%] [FPS = %FRAMERATE%]
echo HDR Info = [%HDR%]
echo.
if "%RAW_FILE%"=="FALSE" (
echo.
%WHITE%
echo == DEMUXING ============================================================================================================
echo.
%YELLOW%
echo ATTENTION^! You need many HDD Space for this operation.
echo.
%CYAN%
echo Please wait. Extracting the Video Layer ...
if "%MKVExtract%"=="TRUE" "%MKVEXTRACTpath%" "%~1" tracks 0:"%TMP_FOLDER%\TEMP.hevc"
if "%MP4Extract%"=="TRUE" "%MP4BOXpath%" -raw 1 -out "%TMP_FOLDER%\TEMP.hevc" "%~1"
set "VIDEOSTREAM=%TMP_FOLDER%\TEMP.hevc"
if "%ERRORLEVEL%"=="0" (
%GREEN%
echo Done.
echo.
) else (
%RED%
echo Error.
set "ERRORCOUNT=1"
echo.
)
)
%CYAN%
echo Please wait. Prefetching DV Metadata...
echo {>"%TEMP%\Extra.json"
echo "level6": {>>"%TEMP%\Extra.json"
echo "max_display_mastering_luminance": %MaxDML%,>>"%TEMP%\Extra.json"
echo "min_display_mastering_luminance": %MinDML%,>>"%TEMP%\Extra.json"
echo "max_content_light_level": %MaxCLL%,>>"%TEMP%\Extra.json"
echo "max_frame_average_light_level": %MaxFall% >>"%TEMP%\Extra.json"
echo }>>"%TEMP%\Extra.json"
echo }>>"%TEMP%\Extra.json"
"%DO_VI_TOOLpath%" --edit-config "%TEMP%\Extra.json" convert "%VIDEOSTREAM%" -o "%TMP_FOLDER%\TEMP_L6.hevc"
"%DO_VI_TOOLpath%" -m 2 extract-rpu "%TMP_FOLDER%\TEMP_L6.hevc" -o "%TARGET_FOLDER%\RPU.bin"
echo.
echo Please wait. Cleaning and Moving files ...
if exist "%TMP_FOLDER%" (
RD /S /Q "%TMP_FOLDER%">nul
if "%ERRORLEVEL%"=="0" (
%GREEN%
echo Deleting Temp Folder - Done.
) else (
%RED%
echo Deleting Temp Folder - Error.
set "ERRORCOUNT=1"
echo.
)
)
:EXIT
%WHITE%
echo.
echo == EXIT ================================================================================================================
echo.
TIMEOUT 30
exit
It is recommended to mux this RPU with L6 Function in INJECTOR.
GodzilaAvenger
29th August 2022, 02:54
Maybe DV will be triggered with a HDR BL and a P5 RPU, but i'm sure you have some display errors on screen. I can test this in the next time :)
You can use this file (https://drive.google.com/file/d/1Dop-5nwyXUHfCjPMtf5r-IbpHbTwVf11/view?usp=sharing) I've made for your test.
terrorindeed
29th August 2022, 03:04
Hey everyone. I’m new to using the tool. I’ve completed about 7 hybrids from various films and episodes.
Several of the files have the flickering issue. I began to investigate, and found that the frames do not match. One example is
Jungle Cruise 2021 HDR EVO 183377 frames (2 hrs 7 min)
Jungle Cruise 2021 DV FLUX 125474 frames (2 hrs 7 min).
What am I supposed to do here to make them match and have error free DV/HDR10 fallback? Thank you !! Awesome tool by the way :)
GodzilaAvenger
29th August 2022, 03:20
You have to make sure the frames in your RPU match the frames in your BL by setting a positive or negative delay in the injector tool. To find out what the delay should be either compare the frame numbers of one particular frame in the two sources using a tool like djv, or use the frameinfo tool on the RPU file and enter "ALL" to get all the scene cuts, then match those to the corresponding scene cuts in the film. This only affects DV, your HDR playback should be fine either way since that only concerns the base layer.
BTW are you sure about those frame numbers? The second one is 60000 frames less than the first!
DiscoD
29th August 2022, 04:34
You can use this (https://drive.google.com/file/d/1Dop-5nwyXUHfCjPMtf5r-IbpHbTwVf11/view?usp=sharing) one I've made for your test.
even if it fallback on some players to HDR10 compatibility is compromised because DV5 should not fallback to HDR as noted by this chart with the base layer...
https://pbs.twimg.com/media/DvkzVMBWkAAo2fM.jpg
AgentXXL
29th August 2022, 04:47
Yes there is, but I never wanted to make this script public.
I called this L6 Demuxer and can extract these RPUs. I post the script here, just create a cmd, save the content there and use this script just like the others.
It is recommended to mux this RPU with L6 Function in INJECTOR.
You're a god at script making! Thank you so much. If you accept donations via Paypal, DM me.
von Suppé
29th August 2022, 08:16
You can use this file (https://drive.google.com/file/d/1Dop-5nwyXUHfCjPMtf5r-IbpHbTwVf11/view?usp=sharing) I've made for your test.
Quite some file you conjured up, GA :)
FYI Dolby Vision playback is triggered on my player, but the picture is buggered up. The colors show purple/green. Same like when you try to playback "genuine" P5 on a pc. Like it can't deal with the specific colorspace. Even if I disable DV playback and force my player to HDR output, purple/green remains.
I tried to strip RPU. When dropping the file on DDVT_REMOVER I get "Profile 5 cannot be removed!"
-QfG-
29th August 2022, 11:31
I tried to strip RPU. When dropping the file on DDVT_REMOVER I get "Profile 5 cannot be removed!"
The remover doesn't check, that this RPU is muxed in a HDR BT.2020 Bitstream. You can't remove RPUs from P5 Base Layers, it's a security feature from me ;).
If you accept donations via Paypal, DM me.
If you will donate this work, make a donation to quietvoid. Without him this scripts here never exists.
terrorindeed
29th August 2022, 16:37
You have to make sure the frames in your RPU match the frames in your BL by setting a positive or negative delay in the injector tool. To find out what the delay should be either compare the frame numbers of one particular frame in the two sources using a tool like djv, or use the frameinfo tool on the RPU file and enter "ALL" to get all the scene cuts, then match those to the corresponding scene cuts in the film. This only affects DV, your HDR playback should be fine either way since that only concerns the base layer.
BTW are you sure about those frame numbers? The second one is 60000 frames less than the first!
Im an idiot. I was using the wrong rpu.bin, as far as I can tell. Do you guys delete the rpu.bin after each use? I've been leaving it in the BL-RPU extracted folder, very weird.
von Suppé
29th August 2022, 16:38
The remover doesn't check, that this RPU is muxed in a HDR BT.2020 Bitstream. You can't remove RPUs from P5 Base Layers, it's a security feature from me ;).
Ah, ok.
So I removed RPU with dovitool and the result played with proper colors, like expected.
Of course I also wanted to see what removing RPU from "real" P5 IPTPQc2 video would yield. Playback showed purple/green colors.
I think that Dolby Vision hardware only accepts proper, spec-compliant DV videos. Which makes sense of course.
von Suppé
29th August 2022, 16:51
Do you guys delete the rpu.bin after each use?.
I do. But not before I'm satisfied with my end-result playing as it should.
RPU can always be extracted/edited again, if need be in the future.
GodzilaAvenger
29th August 2022, 17:19
Quite some file you conjured up, GA :)
FYI Dolby Vision playback is triggered on my player, but the picture is buggered up. The colors show purple/green. Same like when you try to playback "genuine" P5 on a pc. Like it can't deal with the specific colorspace. Even if I disable DV playback and force my player to HDR output, purple/green remains.
I tried to strip RPU. When dropping the file on DDVT_REMOVER I get "Profile 5 cannot be removed!"
It was the shortest I had on hand :)
Interesting, so it seems that my TV completely ignores the RPU and just plays back the BL, but your player recognizes the RPU and tries to interpret the BT.2020 colorspace as Profile 5, which results in those weird colors. Thanks for checking it out!
AgentXXL
29th August 2022, 23:43
If you will donate this work, make a donation to quietvoid. Without him this scripts here never exists.
I'd be more than happy to donate to both of you. Just haven't seen a donation link anywhere.
And again, thank you for the L6 Demuxer script. Works as expected, and I am using the Match L6 option in Injector with successful hybrids as a result.
speedy
30th August 2022, 00:49
I'm not sure of the process surrounding 8.4 but here is a good list put together about playback device compatibility...
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit#gid=427220017
maybe 8.4 is working for people more recently if but this list is updated pretty often.
The RPU is not Profile 8.1,8.2 or 8.4 the RPU is every times Profile 8. If you mux the RPU now in:
HDR Stream you have Profile 8.1
SDR Stream you have Profile 8.2
HLG Stream you have Profile 8.4
So you need an HLG Base layer and mux the Profile 8 RPU in it. I think this works.
Profile 5 is another thing, you have the IPT (IPTPQc2 (https://en.wikipedia.org/wiki/ICtCp#IPTPQc2)) colorspace not the BT.2020 there.
Therefore, no fallback to HDR with Profile 5, because no BT.2020 colorspace are used.
Does that mean I would need to use something like wswartzendruber/hlg-tools (https://forum.doom9.org/showthread.php?t=182499) to convert to convert the HDR10 base stream to an HLG base stream?
Would I then convert the Profile 7 8.1 RPU to 8.4?
-QfG-
31st August 2022, 08:52
Yes, i think this works, you must simply test this. Simply mux the P8 RPU frum the 8.1 video int the HLG Stream.
quietvoid
31st August 2022, 11:49
There's no point in attempting to convert to profile 8.4 as Apple devices don't support the dynamic metadata.
The only way seems to be tricking the device into thinking the file is profile 5, there's some script on MakeMKV for that.
speedy
1st September 2022, 06:26
There's no point in attempting to convert to profile 8.4 as Apple devices don't support the dynamic metadata.
The only way seems to be tricking the device into thinking the file is profile 5, there's some script on MakeMKV for that.
Does that work with MKV files too?
Link?
von Suppé
1st September 2022, 10:26
Unless I'm mistaken, quietvoid is refering to the scripts created by RESET_9999. You'll find the link "DoVi Scripts" in his signature.
Major Dolby Vision thread at MakeMKV: https://forum.makemkv.com/forum/viewtopic.php?f=12&t=18602&start=7290
quietvoid
1st September 2022, 12:50
A more in-depth guide also exists: https://www.avsforum.com/threads/apple-dolby-vision.3252865/
I think it requires MP4 files as final video.
alexflin
1st September 2022, 13:47
It's possible to extract the DoVi layer from a mkv to burn a bluray? I don't see the option in the script
-QfG-
2nd September 2022, 10:44
It's possible to extract the DoVi layer from a mkv to burn a bluray? I don't see the option in the script
Yes it is. But only if the MKV includes a profile 7 single layer HEVC file.
if you have a "REMUX" of an UHD, simply use the Demuxer and check the Options for Saving BL and EL (you can turn off RPU extracting, not needed for this operation). now you can Build a UHD with this, for example with TS-Muxer.
There's no point in attempting to convert to profile 8.4 as Apple devices don't support the dynamic metadata.
Thanks for this info quietvoid :goodpost:
I can add Apple DoVi Injection in future Updates.
alexflin
2nd September 2022, 11:34
Yes it is. But only if the MKV includes a profile 7 single layer HEVC file.
if you have a "REMUX" of an UHD, simply use the Demuxer and check the Options for Saving BL and EL (you can turn off RPU extracting, not needed for this operation). now you can Build a UHD with this, for example with TS-Muxer.
Thanks for this info quietvoid :goodpost:
I can add Apple DoVi Injection in future Updates.
Ok, thanks for the answer, I thought that it was possible to build a Bluray from a profile 8 or 5 also, but now I see that is not possible.
speedy
2nd September 2022, 19:02
I can add Apple DoVi Injection in future Updates.
That would be awesome!
Could you do this for both MKV and MP4 containers so we can test both and use MKV in the future if that ends up working?
Thank you!
speedy
4th September 2022, 21:02
There's no point in attempting to convert to profile 8.4 as Apple devices don't support the dynamic metadata.
The only way seems to be tricking the device into thinking the file is profile 5, there's some script on MakeMKV for that.
Unless I'm mistaken, quietvoid is refering to the scripts created by RESET_9999. You'll find the link "DoVi Scripts" in his signature.
Major Dolby Vision thread at MakeMKV: https://forum.makemkv.com/forum/viewtopic.php?f=12&t=18602&start=7290
A more in-depth guide also exists: https://www.avsforum.com/threads/apple-dolby-vision.3252865/
I think it requires MP4 files as final video.
I just read through those posts and RESET_9999's scripts but I still don't understand.
Could someone clarify how I'd get started converting either a Profile 7 or Profile 8.1 file to this fake Profile 5?
Also, am I correct in understanding that these Profile 5 files are essentially using Rec2020 colorspace and the same RPU metadata as a Profile 8.1 file?
Thanks
von Suppé
5th September 2022, 17:45
Could someone clarify how I'd get started converting either a Profile 7 or Profile 8.1 file to this fake Profile 5?
Why don't you just give it a go? I'm not familiar with Apple devices, but seeing the script, I suggest trying to start with 7 (MP4_MUXER Workflows). Followed by 4 (Apple iOS compatible MP4).
From there choose further, depending on what kind of source-file, and output wishes.
Balling
7th September 2022, 11:21
https://forum.makemkv.com/forum/viewtopic.php?p=122442#p122442
https://1drv.ms/v/s!Ahh4FiB9hIuT-EK3sg5uA-Ab3amj?e=RKiQG4
How was this created? Was it some real Dolby Vision HLG show and someone just delayed RPU to check the applying of it?
Does BBC already Dopby vision hlg on satellites?
panni
7th September 2022, 22:43
Hey, I'm trying to inject an RPU into a HDR file which has a VBR video stream. After injecting, the resulting MKV file has the video stream as CBR and the audio and video is super async.
Any ideas on how to fix this? Thanks!
GodzilaAvenger
7th September 2022, 23:39
Is there a way to add delay (positive or negative) to HDR10+ metadata, similar to what can be done for DV?
Balling
8th September 2022, 02:43
Hey, I'm trying to inject an RPU into a HDR file which has a VBR video stream. After injecting, the resulting MKV file has the video stream as CBR and the audio and video is super async.
Any ideas on how to fix this? Thanks!
VBR? Maybe you mean VFR? It does not matter that it is VFR, RPU is frame numbers based.
panni
8th September 2022, 03:33
Yeah, VFR. Results in a CBR file with desync A/V.
-QfG-
8th September 2022, 12:19
Hey, I'm trying to inject an RPU into a HDR file which has a VBR video stream. After injecting, the resulting MKV file has the video stream as CBR and the audio and video is super async.
Any ideas on how to fix this? Thanks!
Check the FPS on the MKV File. It's recommended to use the "Mux in Container" function. I think mediainfo shows you 25 FPS instead of 23,976.
Apple:
Many of my P8 Mixes tested succesfully with an Apple TV 4K and Infuse Player.
panni
8th September 2022, 14:06
This is how the source HDR MKV looks:
Frame rate mode : VFR
Frame rate : 23.951 fps
This is after injecting the RPU (with mux in MKV):
Frame rate mode : CFR
Frame rate : 25.000 fps
von Suppé
8th September 2022, 15:32
Mkv container doesn't really carry a header for "FPS", but for "default duration" instead. Therefore, "VFR 23.951 fps" could indeed be MediaInfo's misinterpretation of "regular CFR 23.976 fps" video. Which could be caused by some flawed timestamps.
Maybe a two-step is worth a try here. First remux the source HDR video (without RPU) using MKVToolNix with "Default duration/FPS" set to 24000/1001p. Drop that result on the DDVT_INJECTOR.
panni
8th September 2022, 22:07
Mkv container doesn't really carry a header for "FPS", but for "default duration" instead. Therefore, "VFR 23.951 fps" could indeed be MediaInfo's misinterpretation of "regular CFR 23.976 fps" video. Which could be caused by some flawed timestamps.
Maybe a two-step is worth a try here. First remux the source HDR video (without RPU) using MKVToolNix with "Default duration/FPS" set to 24000/1001p. Drop that result on the DDVT_INJECTOR.
That worked, thank you so much!
GodzilaAvenger
9th September 2022, 04:36
Is there a way to add delay (positive or negative) to HDR10+ metadata, similar to what can be done for DV?
I wrote the following Python script for adding positive or negative delay to HDR10+ metadata. Let me know if I missed anything, or if there is a better way of doing this.
@-QfG-: when injecting HDR10+ metadata into a file that already has one, is the previous one completely overwritten? Or should I first remove the previous one, then inject the new one?
import argparse
import json
import copy
# Parse the input arguments.
parser = argparse.ArgumentParser()
parser.add_argument('-i', '--input', nargs = '?', default = 'HDR10Plus.json', help = 'input HDR10+ JSON file')
parser.add_argument('-d', '--delay', nargs = '?', type = int, default = 0, help = 'desired delay (in number of frames)')
parser.add_argument('-o', '--output', nargs = '?', default = 'HDR10PlusEdited.json', help = 'output HDR10+ JSON file')
args = parser.parse_args()
with open(args.input, 'r') as hdr10plus:
# Load the input file data.
print("Reading the input file...")
data = json.load(hdr10plus)
print("Done!\n")
if args.delay > 0:
print("Applying delay...")
# Add delay to SceneFrameIndex for each frame of the first scene.
for i in range(data["SceneInfoSummary"]["SceneFrameNumbers"][0]):
data["SceneInfo"][i]["SceneFrameIndex"] += args.delay
# Add delay to SequenceFrameIndex of each frame.
for frame in data["SceneInfo"]:
frame["SequenceFrameIndex"] += args.delay
# Duplicate the first frame, then correct SceneFrameIndex and SequenceFrameIndex.
for i in range(args.delay):
data["SceneInfo"].insert(0, copy.deepcopy(data["SceneInfo"][0]))
data["SceneInfo"][0]["SceneFrameIndex"] -= 1
data["SceneInfo"][0]["SequenceFrameIndex"] -= 1
# Add delay to SceneFrameNumbers for the first scene.
data["SceneInfoSummary"]["SceneFrameNumbers"][0] += args.delay
# Add delay to SceneFirstFrameIndex of every scene apart from the first one.
for i in range(1, len(data["SceneInfoSummary"]["SceneFirstFrameIndex"])):
data["SceneInfoSummary"]["SceneFirstFrameIndex"][i] += args.delay
print("Done!\n")
elif args.delay < 0:
print("Applying delay...")
# Remove frames from the beginning. Note the SceneId and SceneFrameIndex of the first
# remaining frame.
del data["SceneInfo"][:-args.delay]
frameZero = data["SceneInfo"][0]["SceneFrameIndex"]
sceneZero = data["SceneInfo"][0]["SceneId"]
# Add delay to SequenceFrameIndex of each frame and correct SceneId.
for frame in data["SceneInfo"]:
frame["SceneId"] -= sceneZero
frame["SequenceFrameIndex"] += args.delay
# Correct SceneFrameIndex for each frame of the first scene.
for i in range(data["SceneInfoSummary"]["SceneFrameNumbers"][sceneZero] - frameZero):
data["SceneInfo"][i]["SceneFrameIndex"] -= frameZero
# Remove SceneFrameNumbers of any scene that has been removed, correct the value for the
# first remaining scene.
del data["SceneInfoSummary"]["SceneFrameNumbers"][:sceneZero]
data["SceneInfoSummary"]["SceneFrameNumbers"][0] -= frameZero
# Remove SceneFirstFrameIndex of any scene that has been removed, add delay to every
# remaining scene apart from the first one.
del data["SceneInfoSummary"]["SceneFirstFrameIndex"][1:sceneZero + 1]
for i in range(1, len(data["SceneInfoSummary"]["SceneFirstFrameIndex"])):
data["SceneInfoSummary"]["SceneFirstFrameIndex"][i] += args.delay
print("Done!\n")
with open(args.output, 'w') as edited:
# Write the output file data.
print("Writing the output file...")
json.dump(data, edited, indent = 2, separators=(", ", ": "))
print("Done!\n")
LV8
9th September 2022, 15:06
I wrote the following Python script for adding positive or negative delay to HDR10+ metadata. Let me know if I missed anything, or if there is a better way of doing this.
@-QfG-: when injecting HDR10+ metadata into a file that already has one, is the previous one completely overwritten? Or should I first remove the previous one, then inject the new one?
import argparse
import json
import copy
# Parse the input arguments.
parser = argparse.ArgumentParser()
parser.add_argument('-i', '--input', nargs = '?', default = 'HDR10Plus.json', help = 'input HDR10+ JSON file')
parser.add_argument('-d', '--delay', nargs = '?', type = int, default = 0, help = 'desired delay (in number of frames)')
parser.add_argument('-o', '--output', nargs = '?', default = 'HDR10PlusEdited.json', help = 'output HDR10+ JSON file')
args = parser.parse_args()
with open(args.input, 'r') as hdr10plus:
# Load the input file data.
print("Reading the input file...")
data = json.load(hdr10plus)
print("Done!\n")
if args.delay > 0:
print("Applying delay...")
# Add delay to SceneFrameIndex for each frame of the first scene.
for i in range(data["SceneInfoSummary"]["SceneFrameNumbers"][0]):
data["SceneInfo"][i]["SceneFrameIndex"] += args.delay
# Add delay to SequenceFrameIndex of each frame.
for frame in data["SceneInfo"]:
frame["SequenceFrameIndex"] += args.delay
# Duplicate the first frame, then correct SceneFrameIndex and SequenceFrameIndex.
for i in range(args.delay):
data["SceneInfo"].insert(0, copy.deepcopy(data["SceneInfo"][0]))
data["SceneInfo"][0]["SceneFrameIndex"] -= 1
data["SceneInfo"][0]["SequenceFrameIndex"] -= 1
# Add delay to SceneFrameNumbers for the first scene.
data["SceneInfoSummary"]["SceneFrameNumbers"][0] += args.delay
# Add delay to SceneFirstFrameIndex of every scene apart from the first one.
for i in range(1, len(data["SceneInfoSummary"]["SceneFirstFrameIndex"])):
data["SceneInfoSummary"]["SceneFirstFrameIndex"][i] += args.delay
print("Done!\n")
elif args.delay < 0:
print("Applying delay...")
# Remove frames from the beginning. Note the SceneId and SceneFrameIndex of the first
# remaining frame.
del data["SceneInfo"][:-args.delay]
frameZero = data["SceneInfo"][0]["SceneFrameIndex"]
sceneZero = data["SceneInfo"][0]["SceneId"]
# Add delay to SequenceFrameIndex of each frame and correct SceneId.
for frame in data["SceneInfo"]:
frame["SceneId"] -= sceneZero
frame["SequenceFrameIndex"] += args.delay
# Correct SceneFrameIndex for each frame of the first scene.
for i in range(data["SceneInfoSummary"]["SceneFrameNumbers"][sceneZero] - frameZero):
data["SceneInfo"][i]["SceneFrameIndex"] -= frameZero
# Remove SceneFrameNumbers of any scene that has been removed, correct the value for the
# first remaining scene.
del data["SceneInfoSummary"]["SceneFrameNumbers"][:sceneZero]
data["SceneInfoSummary"]["SceneFrameNumbers"][0] -= frameZero
# Remove SceneFirstFrameIndex of any scene that has been removed, add delay to every
# remaining scene apart from the first one.
del data["SceneInfoSummary"]["SceneFirstFrameIndex"][1:sceneZero + 1]
for i in range(1, len(data["SceneInfoSummary"]["SceneFirstFrameIndex"])):
data["SceneInfoSummary"]["SceneFirstFrameIndex"][i] += args.delay
print("Done!\n")
with open(args.output, 'w') as edited:
# Write the output file data.
print("Writing the output file...")
json.dump(data, edited, indent = 2, separators=(", ", ": "))
print("Done!\n")
Hi, I'm quite new to this DoVi hybrid world but would it be possible to implement this in the tool?
-QfG-
9th September 2022, 22:00
i test the script with any files, if it works well, i will add it.
von Suppé
11th September 2022, 11:48
@-QfG-
I've read back the recent issue @panni mentioned. Am I correct when I think that in your scripts, you don't force mkvmerge with setting --default-duration header to proper value?
If so, wouldn't it be a good idea to always do this?
-QfG-
11th September 2022, 18:02
set "duration="
SETLOCAL ENABLEDELAYEDEXPANSION
if "!FRAMERATE!"=="23.976" set "duration=--default-duration 0:24000/1001p --fix-bitstream-timing-information 0:1"
if "!FRAMERATE!"=="24.000" set "duration=--default-duration 0:24p --fix-bitstream-timing-information 0:1"
if "!FRAMERATE!"=="25.000" set "duration=--default-duration 0:25p --fix-bitstream-timing-information 0:1"
if "!FRAMERATE!"=="30.000" set "duration=--default-duration 0:30p --fix-bitstream-timing-information 0:1"
if "!FRAMERATE!"=="48.000" set "duration=--default-duration 0:48p --fix-bitstream-timing-information 0:1"
if "!FRAMERATE!"=="50.000" set "duration=--default-duration 0:50p --fix-bitstream-timing-information 0:1"
if "!FRAMERATE!"=="60.000" set "duration=--default-duration 0:60p --fix-bitstream-timing-information 0:1"
%MKVMERGEpath%" --output ^"%TARGET_FOLDER%\%HEADER_FILENAME%.mkv^" --no-video ^"^(^" ^"%~1^" ^"^)^" --language 0:und --compression 0:none !duration! ^"^(^" ^"%TARGET_FOLDER%\%HEADER_FILENAME%.hevc^" ^"^)^" --track-order 1:0
Of course i do this.
VFR 23.951 fps
is not a valid framerate, for exotic framerates you must set this manually.
Sergio
12th September 2022, 19:28
Hello,
Thank you very much for your tools, it will save me a lot of time,
i used to do everything manually with dovi tool from quietvoid,
i mainly use for a little more than 1 year the p5_to_p81.json to make
a dv-hdr compatible for my Lg tv, I then used mp4muxer and
ffmpeg to convert to mp4 and add the subtitles.
I wanted to test by curiosity the conversion mkv to mp4 (DDVT Tool-v0.48c),
it works very well but just for information, the country of the secondary languages
as well as the subtitles do not correspond any more to the country of the mkv and are put in English,
as if it were by default.
NeverExists
13th September 2022, 22:56
Yes it is. But only if the MKV includes a profile 7 single layer HEVC file.
if you have a "REMUX" of an UHD, simply use the Demuxer and check the Options for Saving BL and EL (you can turn off RPU extracting, not needed for this operation). now you can Build a UHD with this, for example with TS-Muxer.
Thanks for this info quietvoid :goodpost:
I can add Apple DoVi Injection in future Updates.
How is the Apple Dovi injection coming along? Would love to see this as well.
NeverExists
19th September 2022, 08:43
Any word?
NeverExists
24th September 2022, 02:49
Has this been abandoned?
GodzilaAvenger
24th September 2022, 06:31
Dude, chill... it's volunteer work so it's done when it's done. The project is open source (https://github.com/SASUKE-DUCK/Dolby_Vision_Tool) (though not updated in a few months) so feel free to fork it and make the changes you need.
RanmaCanada
2nd October 2022, 17:38
Any word?
The author said they CAN, not they will.
If you want something specific done by them, donate to their cause if they have a link on their github. All open source projects are done in the author's "spare" time, and money always helps to ensure they have more "spare: time as they can then dedicate more time to the project instead of real life things.
benwaggoner
3rd October 2022, 01:06
The Apple DoVi HLG + dynamic metadata profile was largely created by Apple, not Dolby. I imagine it could be harder to find documentation or reference code. Plus it's only testable on Apple devices AFAIK.
Lucius Snow
4th October 2022, 21:11
I'm back on this topic. Thank you for the XML -> RPU conversion support!
I'm trying to make a Blu-Ray with a Dolby Vision stream. Profile 7 is required for this. However, when converting the XML generated by DaVinci to the RPU binary, the software mentions it as a Profile 8.1. That's the same whatever the CMU I use (2.9 or 4.0).
DDVT Tools converts from 7 to 8.1 but not the opposite. What should I do?
At the moment, I can only achieve Blu-Ray UHD HDR authoring with HDR10.
Thanks.
quietvoid
4th October 2022, 21:53
I'm trying to make a Blu-Ray with a Dolby Vision stream. Profile 7 is required for this.
There currently isn't a public/free solution for authoring UHD Blu-ray compatible profile 7, as it requires a second HEVC stream aligned with the base HDR10 video.
rwill
4th October 2022, 22:15
There currently isn't a public/free solution for authoring UHD Blu-ray compatible profile 7, as it requires a second HEVC stream aligned with the base HDR10 video.
Well if one uses x265 one could disable scenecut detection and adaptive B-Frames, like run a fixed GOP structure, and 2 streams with the same picture count will be aligned? Am I missing something?
quietvoid
4th October 2022, 22:43
Well if one uses x265 one could disable scenecut detection and adaptive B-Frames, like run a fixed GOP structure, and 2 streams with the same picture count will be aligned? Am I missing something?
It's probably possible that way, but suboptimal.
Lucius Snow
4th October 2022, 23:04
I wonder how a profile 7 can be generated if the color grading softwares themselves deliver 8.X profiles. There might exist a 8.X to 7 converter somewhere, no? Maybe in DEE which costs $500 per year?
quietvoid
4th October 2022, 23:25
I wonder how a profile 7 can be generated if the color grading softwares themselves deliver 8.X profiles. There might exist a 8.X to 7 converter somewhere, no? Maybe in DEE which costs $500 per year?
The encoded HEVC files you get from software like Resolve is not meant to be used as a deliverable.
Normally you would export a Dolby Vision master with XML metadata.
DEE seems to have a script allowing to encode both bitstreams from the master: https://professionalsupport.dolby.com/s/article/Download-DEE-Quick-Start-Dolby-Vision-Profile-7?language=en_US
Though obviously it's better if you contact Dolby about it, you would have to for DEE anyways.
This is another guide from their documentation: https://professionalsupport.dolby.com/s/article/How-to-author-Dolby-Vision-UHD-Blu-ray-disc?language=en_US
Blue_MiSfit
5th October 2022, 00:59
Right, DEE can make any current flavor of DoVi, HDR10, and SDR from a DoVi master (Typically J2K or ProRes) - provided you're cool with having it do tone mapping in some of those cases e.g. SDR :)
Lucius Snow
5th October 2022, 11:33
Thanks for your feedback.
I'm trying to encode to HEVC sample using this command line:
ffmpeg.exe -probesize 100MB -i "E:\test.mov" -an -r 25 -pix_fmt yuv420p10le -f yuv4mpegpipe -strict -1 - | "x265.exe" --y4m - --dither --preset medium --level 6.1 --preset veryslow --no-high-tier --profile main10 --bitrate 80000 --vbv-maxrate 100000 --vbv-bufsize 60000 --deblock -1:-1 --hdr-opt --hrd --aud --min-luma 64 --max-luma 940 --range limited --videoformat component --colorprim bt2020 --transfer smpte2084 --colormatrix bt2020nc --dolby-vision-profile 8.1 --dolby-vision-rpu E:\test.bin --master-display "G(8500,39850)B(6550,2300)R(35400,14600)WP(15635,16450)L(10000000,500)" --max-cll "3279,223" --overscan show --no-open-gop --min-keyint 1 --keyint 25 --repeat-headers --rd 3 -o "E:\test.hevc"
The RPU was generated from the XML (Profile 8.1) coming from DaVinci by this command :
dovi_tool generate --xml E:\test.xml -o E:\test.bi
At the end of the encoding, I get several errors "Dolby Vision RPU not found for POC XXXX". What does it mean?
EDIT: A new test from another video sample worked without any error. The guilty was probably my source.
quietvoid
5th October 2022, 15:32
I get several errors "Dolby Vision RPU not found for POC XXXX". What does it mean?
It means the video and the metadata are not the same frame count, so probably that the video being encoded has less frames.
GodzilaAvenger
5th October 2022, 17:36
Talking about Profile 7, I've always converted the RPU of my BluRay re-encods to Profile 8.1 and then added them to the stream. Would it work (i.e. trigger DV on the player) if I just inject the original Profile 7? Does it matter if the Profile 7 is MEL or FEL?
quietvoid
5th October 2022, 19:07
Talking about Profile 7, I've always converted the RPU of my BluRay re-encods to Profile 8.1 and then added them to the stream. Would it work (i.e. trigger DV on the player) if I just inject the original Profile 7? Does it matter if the Profile 7 is MEL or FEL?
It would probably trigger Dolby Vision on your display but the EL will probably not be aligned.
There's no point in keeping the original MEL, it's equivalent to profile 8.
For FEL, the processing probably wouldn't work correctly on a reencoded base layer and it might lead to incorrect rendered image.
The only correct method is to process the FEL before reencoding (see https://github.com/erazortt/DoViBaker), and use a profile 8 RPU with the mapping metadata removed.
GodzilaAvenger
5th October 2022, 23:31
Thanks!
DoViBaker is interesting, from what I could gather it seems to process the BL and FEL to get the original 12-bit stream, then use the RPU to tonemap it back down to a 10-bit stream. Is that correct?
quietvoid
5th October 2022, 23:40
Thanks!
DoViBaker is interesting, from what I could gather it seems to process the BL and FEL to get the original 12-bit stream, then use the RPU to tonemap it back down to a 10-bit stream. Is that correct?
I've never used it but it should output 16 bit, which you can convert back to 10 bit and encode.
I don't think it does anything else with the RPU.
rco133
7th October 2022, 06:20
Hi.
Got a question regarding dovi_tool.
dovi_tool.exe -c -m 2 mux -b encoded_bl.h265 -d -e demuxed_el -o output_with_dv.265
Should that not give the same output file as this:
dovi_tool.exe -m 2 -c extract-rpu demuxed_el
dovi_tool.exe inject-rpu --rpu-in RPU.bin --input encoded_bl.h265
Should the two command lines not do the same thing?
Except the first one doesn't extract the RPU file.
Or am I misunderstanding something?
When I do a binary compare of the two files, they are not identical at all.
Thanks in advance.
rco133
quietvoid
7th October 2022, 13:41
Hi.
Should the two command lines not do the same thing?
Except the first one doesn't extract the RPU file.
Or am I misunderstanding something?
When I do a binary compare of the two files, they are not identical at all.
Totally normal, the RPU is smaller than the EL.
While the EL also contains RPU, it's a regular HEVC bitstream otherwise.
rco133
7th October 2022, 15:30
Totally normal, the RPU is smaller than the EL.
While the EL also contains RPU, it's a regular HEVC bitstream otherwise.
Ok.
The EL is a lot bigger than the RPU. But shouldn't the first command ignore the EL video, and just mux in the RPU into the bl since I am using the -d switch?
The file size of the two resulting files are exactly the same down to the byte. But when I do a "fc /B file1 file2" it lists a ton of differences between the two files.
I thought that using -d in the mux command line, would do the same as extracting the RPU from the EL and injecting it into the bl.
So I guess my quation really is, why does using the -d switch in the mux command, not give the same result as extracting the RPU and injecting the RPU into the bl?
In both cases I am using -m 2 to convert to Profile 8.
rco133
quietvoid
7th October 2022, 15:43
So I guess my quation really is, why does using the -d switch in the mux command, not give the same result as extracting the RPU and injecting the RPU into the bl?
mux with --discard works, since you said the files are the exact same size.
The difference is that extracting the RPU reorders according to the source video file, while muxing the EL directly doesn't reorder anything.
Now it should only make a difference if the BL you reinject into is different from the source.
In your first post you said that the RPU is injected into a reencoded video, so everything seems to work as expected.
When you mux the original EL, the RPU is going to be out of order with the reencoded video.
rco133
7th October 2022, 17:04
mux with --discard works, since you said the files are the exact same size.
The difference is that extracting the RPU reorders according to the source video file, while muxing the EL directly doesn't reorder anything.
Now it should only make a difference if the BL you reinject into is different from the source.
In your first post you said that the RPU is injected into a reencoded video, so everything seems to work as expected.
When you mux the original EL, the RPU is going to be out of order with the reencoded video.
Yes, I am working with an encoded BL in both cases, and the EL has just been demuxed using dgdemux.
Both output files say they contain:
Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
So i guess even though they are not binary identical, they both should play back fine?
The only difference between the two output files is that one is made with the mux -d command line, and the other file is made by extracting the RPU manually and then injection it manually. In both cases the BL (input file) is the same encoded BL.
Just want to be sure that I am not messing something up, by using the mux -d line, since that saves me from actually extracting the RPU.
rco133
quietvoid
7th October 2022, 22:51
The only difference between the two output files is that one is made with the mux -d command line, and the other file is made by extracting the RPU manually and then injection it manually. In both cases the BL (input file) is the same encoded BL.
Just want to be sure that I am not messing something up, by using the mux -d line, since that saves me from actually extracting the RPU.You are messing something up by using the original EL with mux.
The metadata will most definitely be in the wrong order, so playback will show noticeable brightness changes.
You should be extracting the RPU and encoding with x265/ffmpeg directly with --dolby-vision-rpu, that way you don't need to inject.
rco133
8th October 2022, 07:00
You are messing something up by using the original EL with mux.
The metadata will most definitely be in the wrong order, so playback will show noticeable brightness changes.
You should be extracting the RPU and encoding with x265/ffmpeg directly with --dolby-vision-rpu, that way you don't need to inject.
Ok.
I don't understand that, and that is why I am asking, and really appreciate your expertise on this matter.
I thought that when using the RPU only, I could mux or inject it into the original BL or the encoded BL without problems.
I convert the RPU from Profile 7 to Profile 8 and then use just the RPU. I am not using the rest of the EL. Just the RPU.
That way I thought that all would be good. But maybe that is not the case?
rco133
rco133
8th October 2022, 08:12
Ok.
I don't understand that, and that is why I am asking, and really appreciate your expertise on this matter.
I thought that when using the RPU only, I could mux or inject it into the original BL or the encoded BL without problems.
I convert the RPU from Profile 7 to Profile 8 and then use just the RPU. I am not using the rest of the EL. Just the RPU.
That way I thought that all would be good. But maybe that is not the case?
rco133
What if I do the following:
dovi_tool.exe -m 2 -c extract-rpu -i demuxed_EL.h265 -o RPU.bin
After this I should have a profile 8 RPU with no crop.
dovi_tool.exe inject-rpu -i x265_encoded_BL.h265 -r RPU.bin -o output_wit_dv.h265
Will that work, or will there still be issues if I do that?
rco133
-QfG-
8th October 2022, 09:33
-v0.49
*INJECTOR-Support for HDR10+ JSON Data delaying.
*Updated hdr10plus_tool to v1.4.0.
*Updated dovi_tool to v1.5.7.
von Suppé
9th October 2022, 08:09
Thanks for the update, -QfG-.
Has an old bug sneaked in? The injector doesn't work when there is spaces in the path name
-QfG-
9th October 2022, 13:34
Thanks for the update, -QfG-.
Has an old bug sneaked in? The injector doesn't work when there is spaces in the path name
Really? :angry:
No changes in functions lines, only reworked menu and adding the new feature in the hdr10+ area.
Maybe you have () in your filenames? I tested succesfully with a spaced foldername.
von Suppé
9th October 2022, 14:07
Maybe you have () in your filenames?
Yes, indeed that was the culprit. Thank you.
von Suppé
12th October 2022, 10:28
FYI I had a mkv with videostream having ID 2 and audiostream having ID 1. The file plays fine, but the injector doesn't work with this. During demux stage, the TEMP folder seems to be filled with the audiostream, instead of video. After which the script ends within seconds; the resulting "injected hevc" ending up 0 in size.
Manually demuxing first and using video elementary stream of course solves this. Or using a remux where video is "on top".
I haven't seen much of such muxed mkv's but I reckon they'd be within matroska specification. Maybe the script can use improved videostream detection?
karbre
14th October 2022, 11:52
I'm thinking about editing out a section (a company logo which does not belong to the movie) of a FEL UHD BD Remux done with MakeMKV. Unfortunately, the edit is not along keyframes (in that case it would be a simple MKVToolnix job).
I thought of the following procedure to edit out the section and keep a valid FEL file (I know FEL MKV playback is not yet supported.)
1. Demux file into BL, EL and RPU with DDVT Tool.
2. Edit out the section from the BL with TMPGEnc MPEG Smart Renderer 6 (only minimal reencode, if at all (in case the to-be-removed section is at the end of the file, then sometimes no encoding at all is needed)).
3. Perform the exact same smart render operation on the EL (probably losing the RPU here).
4. Edit the RPU accordingly with dovi_tool editor (remove same frames as in the video tracks).
5. Re-inject edited RPU into edited EL (HOW?).
6. Re-inject combined EL+RPU into edited BL (HOW?).
Is this approach possible? If yes, what are the correct commands for steps 5 and 6?
-QfG-
15th October 2022, 12:04
Step5: Rename EL.hevc to ELisBL.hevc and copy the RPU.bin file in the same directory. Start INJECTOR and mux the RPU into this stream.
Step6: Rename the final stream from above to EL.hevc and copy this stream near the BL.hevc. Start INJECTOR and mux the EL Layer with included RPU into the BL.hevc Stream.
karbre
20th October 2022, 00:14
Great, thanks for the feedback!
MoonKnight
23rd October 2022, 07:47
Hey guys,
a quick question, do we need to set the borders for the RPU when muxing an EL.hevc (FEL) with the BL ?
Because I see that the RPU inside the EL.hevc has this :
{
"Level5": {
"active_area_left_offset": 0,
"active_area_right_offset": 0,
"active_area_top_offset": 0,
"active_area_bottom_offset": 0
}
it seems to be like this by defaut so better to not mess with it, right ? It's only RPU 8.1 that needs to have borders correctly set ?
von Suppé
23rd October 2022, 08:49
To my knowledge, borders always have to be set correctly. Values being 0 would mean video has no black borders.
Why does "it seems to be like this by default" to you?
MoonKnight
23rd October 2022, 19:08
To my knowledge, borders always have to be set correctly. Values being 0 would mean video has no black borders.
Why does "it seems to be like this by default" to you?
because it's the RPU that I extracted from a retail 4K Bluray with a FEL Layer
I looked inside the RPU, and borders are not set,
von Suppé
24th October 2022, 09:26
Then the video should have no black borders. Of course you can check this, to see if RPU is correct with the values.
-QfG-
31st October 2022, 14:38
-v0.50
*Works now correct with all symbols in filenames.
*Updated mkvtoolnix to v 71.1.1.0.
rushuna86
1st November 2022, 00:37
First time posting here, so sorry if this has been answered somewhere else? For BD Remux FEL MKV. BL+EL+RPU to make this into a FEL BDMV to play on Oppo Clone. Are these steps accurate?
1. Using Demuxer Strip BL + EL into 2 streams.
2. eac3to audio stream to get back core.
3. TSmuxer BL+EL+audio and mux.
RPU gets discarded for this right?
-QfG-
1st November 2022, 08:11
Right. You need only eac3to for TrueHD Atmos tracks, because you need a thd+ac3 track. RPU is included in the EL Layer, so you have a valid P7 Double Layer m2ts with tsmuxer. The OPPO or his clone will playback this file with FEL, if the DV Layer is FEL. Also you can create an ISO file, the OPPO will playback FEL DV, too.
rushuna86
1st November 2022, 09:11
Right. You need only eac3to for TrueHD Atmos tracks, because you need a thd+ac3 track. RPU is included in the EL Layer, so you have a valid P7 Double Layer m2ts with tsmuxer. The OPPO or his clone will playback this file with FEL, if the DV Layer is FEL. Also you can create an ISO file, the OPPO will playback FEL DV, too.
Thank you for answering and thank you for making this fantastic tool.
fkid
1st November 2022, 14:18
-v0.50
*Works now correct with all symbols in filenames.
*Updated mkvtoolnix to v 71.1.1.0.
Thank you so much for continuing to support these scripts. No longer have to move files or rename in any cases.
Unrelated question, but just want clarification and couldn't find clear answer online. If Level 6 metadata is "incorrect" or inconsistent between DV RPU and HDR base file, but reasonable, does it matter if the HDR file it is injected to already has the MaxCLL/FALL? For example, I have a WEB-source converted Profile 5 to Profile 8 DV RPU, and it shows Level 6 as this:
"Level6": {
"max_display_mastering_luminance": 4000,
"min_display_mastering_luminance": 50,
"max_content_light_level": 0,
"max_frame_average_light_level": 0
And the original HDR file I inject it into shows in MediaInfo:
Mastering display luminance : min: 0.0010 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 1000 cd/m2
Maximum Frame-Average Light Level : 410 cd/m2
If I already injected, and noticed later, do I have to go back and demux the DV RPU, adjust the Level 6 numbers to match and re-inject? Or does it not really matter if the source video already has these numbers? @quietvoid, do you know when the Level 6 metadata gets used/parsed as it is stored in the DV layer, if it is only really meant for HDR fallback, where the DV Level 6s presumably are ignored anyway by the TV/video player? It doesn't really explain it in the Dolby documentation either, other than to say "L6 metadata is required for HDR10 content and includes two numbers namely, MAXCLL and MAXFALL. These values are not normally calculated as part of the Dolby Vision analysis and will usually have to be calculated separately" (https://professionalsupport.dolby.com/s/article/Dolby-Vision-Metadata-Levels?language=en_US). Is this meant for pro workflows only or industry implementation, whereas most of us use .mkv or .mp4 containers and the HDR metadata is already present? It's a little confusing, no?
Ultimately, I am just wondering if I have to go back and fix a bunch of previous files I have where the Level 6 in the DV doesn't match the underlying HDR file MDL/MaxCLL/MaxFALL?
@-QfG-, should the script maybe default to always match Level 6 metadata with the source video file to avoid these inconsistencies? Or at least show the Level 6 metadata on screen DV RPU vs. HDR file when about to inject DV RPU? This way, user has chance to decide if to match/change in case it's not same as HDR source video? Why not always match to HDR source?
Thank you kindly!!
quietvoid
1st November 2022, 15:57
Ultimately, I am just wondering if I have to go back and fix a bunch of previous files I have where the Level 6 in the DV doesn't match the underlying HDR file MDL/MaxCLL/MaxFALL?
It doesn't really matter. I haven't found a case where the L6 metadata is used.
fkid
1st November 2022, 16:30
It doesn't really matter. I haven't found a case where the L6 metadata is used.
Thank you so much for quick reply!
-QfG-
1st November 2022, 17:15
should the script maybe default to always match Level 6 metadata with the source video file to avoid these inconsistencies?
No, L6 Metadata will be untouched in Standard settings. in few cases i have RPUs with abstract L6 Metadata and the tool will not inject this RPUs. Only for this cases i have implant this feature.
fkid
1st November 2022, 17:29
No, L6 Metadata will be untouched in Standard settings. in few cases i have RPUs with abstract L6 Metadata and the tool will not inject this RPUs. Only for this cases i have implant this feature.
Makes sense, given quietvoid's confirmation too. FYI, I noticed small bugs in latest DDVT_INJECTOR.cmd,
1st bug with FPS:
"!MEDIAINFOpath!" --output=Video;%%FRAMERATE%% "%~1">"%TEMP%\Info.txt"
should be
"!MEDIAINFOpath!" --output=Video;%%FrameRate%% "%~1">"%TEMP%\Info.txt"
Otherwise, it shows FPS as "n.a." as it is now, not sure if it impacts actual injection process, but confirmed this was working in previous version and when I modify that line, it works again.
2nd bug with borders matching: No longer showing Borders = lines for VIDEO INPUT/RPU INPUT sections. Tested file with v0.49 beta working and v0.50 not showing at all.
P.S. I am guessing you already know this but with video files with changing AR, such as Tenet (IMAX scenes), the automatic border detection is flawed, as it uses largest borders found, when it should be set to 0,0,0,0 in final injection and needs manual override sometimes. Just something I noticed.
Cheers. :)
-QfG-
1st November 2022, 20:56
"!MEDIAINFOpath!" --output=Video;%%FRAMERATE%% "%~1">"%TEMP%\Info.txt"
will fix this soon...
EDIT :
v0.50-FIXED Online. Fixed some major bugs in the injector script. THX for response!
fkid
2nd November 2022, 04:57
will fix this soon...
EDIT :
v0.50-FIXED Online. Fixed some major bugs in the injector script. THX for response!
Thank you!!
DoomFan
8th November 2022, 06:43
I'm still having an issue with DDVT_INJECTOR.cmd. Seems to have started about a month ago when a big Windows 11 update came out. It's been an issue on every version from 47 to 50-Fixed.
When I run DDVT_INJECTOR.cmd I get an error that says Missing input file! File does not exist! *filepath* but the file is 100% there. I've even renamed it to something simple, in case "." or "-" in the filename was an issue.
Then after I click "OK" on that error, the DDVT_INJECTOR.cmd window says:
Analysing Video Borders. Please wait ...
The system cannot find the file C:\Users\me\AppData\Local\Temp\Crop.txt.
Analysing failed.
Analysing DV RPU.bin. Please wait ...
Something's not right. I've been using this tool without issue for months. Within the last month or so it keeps failing, on every version I try. Any ideas?
zzreel
14th November 2022, 07:27
Tool's been working for everything I throw at it except this one specific file.. I'm trying to extract RPU (version 8) and the file itself has a real working DV but the tool gives me this error:
Warning: Unexpected RPU NALU found for frame 15898. Discarding.
It shows that per each frame, completing the extract process with a 0kb RPU file.
Reordering metadata... thread 'main' panicked at 'Missing frame/slices for metadata! Decoded index 224929', src\dovi\general_read_write.rs:311:21
Is there something special about this file or something? The DV was already taken from another source for this file, thence dv hybrid, but I was able to extract others like it without issue.
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@High
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 2 h 36 min
Bit rate : 37.0 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 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.186
Stream size : 40.4 GiB (89%)
Title : DV HYBRID
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0000 cd/m2, max: 1000 cd/m2
quietvoid
14th November 2022, 14:24
Sounds like the file was possibly injected in twice before the tool ignored existing RPU NALUs.
zzreel
15th November 2022, 16:21
Sounds like the file was possibly injected in twice before the tool ignored existing RPU NALUs.
Interesting. Any way I could still extract it?
quietvoid
15th November 2022, 16:36
I'm not sure, the current workaround is best-effort when it comes to invalid/duplicate RPUs.
If you can reproduce the error with a smaller sample (which you can share), then I can look into it.
bitspyer
19th November 2022, 15:42
How does DDVT get the Border-Info for Movie and RPU?
Does the rpu Binary has Border-Info in its Meta-Data?
Or get DDVT this Information with DetectBorder.exe ?
The Reason for my Question is, I have a Source, with mixed IMax and normal Widescreen Content, which means, the Borders has diffrent sizes....
Will DDVT change the crop Bars or leave DDVT the RPU Crop untouched?
Thnx 4 answers....
18250
The shown Bordes are for Widescreen Content, 68px Top / Bottom will be the correct Bordes for the IMAX Content.
GodzilaAvenger
19th November 2022, 19:39
This was discussed a while ago in this thread, so take a look a few pages back. The short answer is that no, DDVT on its own does not automatically change the L5 metadata (frame borders) per frame, and it usually only detects the largest aspect ratio (smallest borders). You can put a custom.json file next to the RPU.bin file to tell DDVT injector what borders to use for which frames.
von Suppé
20th November 2022, 11:26
Does the rpu Binary has Border-Info in its Meta-Data?
Yes. Like GodzilaAvenger said, it's in RPU's so-called L5 metadata.
In case of varying borders, I don't know what to think of detecting them. I may be dead wrong (please anyone correct me if so), but I imagine DDVT parses an amount of frames at the beginning. Both for video and RPU data, my guess. BTW even if all L5 would match the varying borders, it isn't always so that DDVT would show the same values. When I drop a certain movie, of which I know RPU is 100% correct, the border values for video differs from those of RPU. I guess this is because video shows almost all black frames at the beginning.
Main question is if L5 values match the actual border sizes of the video, at any point. In other words, do you trust the RPU. Should you have extracted it from the same source where BL comes from, chances are it's ok. If you like, you can check for yourself by comparing L5 values to the actually displayed borders of several cherry-picked frames. FYI if you drop RPU on DDVT_FRAMEINFO, you can check values for any frame number you put in.
Once you know RPU is ok you obviously want to [LEAVE UNTOUCHED] whilst injecting. Actually, for such videos I'd never change L5, because ALL frames would end up with the same value.
Should RPU values not match video, there's several things you can do. For a proper job, you have to edit the RPU the way GodzilaAvenger mentioned.
If that be too much, you can try setting L5 to the value of the smallest border. Or, set all to zero (crop). It depends a bit on how your player behaves on black when it's part of the active area. Chances are that you'll experience some "grey" issues.
LazyNcoder
22nd November 2022, 18:15
Hello guys,
Today I bumped into a hybrid DV/HDR+ video which had the combination of DV and HDR+ metadata from two different sources.
The author stated that he/she has edited the L6 metadata of the DV to match the HDR+
it's like:
blah.blah.DV.mkv
blah.blah.HDR.mkv
and
blah.blah.hybrid.DV.HDR.mkv
I extracted the DV and HDR+ metadata from the original different sources and used both of them in x265.exe to re-encode it with given MAXCLL/MAXFALL options. But the DV metadata from the final .hevc file was untouched, same as source(obviously).
Now I want to ask, if the L6 editing part is required and how to do that. How can I get the correct MAXCLL/MAXFALL and add it to the DV to use it when I want to include both DV and HDR in my encode.
OR can I just extract the metadata of the different DV and HDR+ and use them without editing in my encode, without editing the L6 metadata.
Thanks
GodzilaAvenger
23rd November 2022, 18:51
As quietvoid mentioned previously (Post #434) those L6 values don't seem to be used anywhere, and I've seen them be set to 0 in a lot of my BluRays so I don't have any reason to think otherwise. I'd say don't waste your time on L6 because it will likely won't matter in the end.
bitspyer
24th November 2022, 12:53
Thnx for the answers.
In the meantime I got myself the answer too. I used dovi_tool to get the JSON from RPU and saw the diffrent borders for the IMAX Frames.
fkid
8th December 2022, 21:22
@quietvoid @-QfG- Quick question, I noticed that sometimes if you convert Profile 5 DV RPU to Profile 8, the Level 5 metadata for cropping values is not set or set to all 0. I know the DDVT script tries to catch this by detecting borders and suggesting to match video when injecting RPU, but if I already have some files with 0,0,0,0 set for Level 5 but the video itself has borders (uncropped), will it cause issues when viewing with Shield Pro 2019? I will run a test on my TV later, but just wanted to ask before fixing all of the possible video files I have that could have this issue. It seems that some users around the WEB are not aware of the Level 5 border values when they are injecting WEB-source DV into HDR (i.e. combining Profile 5 DV with HDR video from NF to make a hybrid file), so I thought I'd ask about it. Thank you kindly!
GodzilaAvenger
8th December 2022, 22:07
Let's say you have a DV P5 3840x1600 Web source and you want to inject the metadata into a HDR10 3840x2160 BluRay. You can demux the RPU from the Web source and convert to P8 without applying any cropping, and then when injecting that RPU set the top and bottom borders to 280 (DDVT usually does that automatically).
What happens if you set the top and bottom borders to 0 instead of 280? My understanding is that those values define the active area where things such as L1 metadata (min, avg, max pq or brightness values) are applied. So if e.g. your min_pq is 30, instead of having that apply only to the image area, it applies to the whole screen, meaning the top and bottom black bars are no longer black, but slightly greyish. In the same way, because e.g. average pq is now applied to the whole screen, you'll end up with an image that is considerably brighter to compensate for the black bars at the top and bottom.
-QfG- and quietvoid feel free to correct me if I'm wrong or missed anything.
fkid
8th December 2022, 22:15
Let's say you have a DV P5 3840x1600 Web source and you want to inject the metadata into a HDR10 3840x2160 BluRay. You can demux the RPU from the Web source and convert to P8 without applying any cropping, and then when injecting that RPU set the top and bottom borders to 280 (DDVT usually does that automatically).
What happens if you set the top and bottom borders to 0 instead of 280? My understanding is that those values define the active area where things such as L1 metadata (min, avg, max pq or brightness values) are applied. So if e.g. your min_pq is 30, instead of having that apply only to the image area, it applies to the whole screen, meaning the top and bottom black bars are no longer black, but slightly greyish. In the same way, because e.g. average pq is now applied to the whole screen, you'll end up with an image that is considerably brighter to compensate for the black bars at the top and bottom.
-QfG- and quietvoid feel free to correct me if I'm wrong or missed anything.
That sounds right, and I understand that Hybrid use case. My question applies more to combining DV Profile 5 WEB (convert to Profile 8 and inject) with HDR WEB for the same video (identical frames, source). Do all DV Profile 5 RPUs contain/maintain Level 5 metadata when converted to Profile 8? If so, that must mean the only way Level 5 metadata gets lost/reset to 0 is someone sets -crop flag when demuxing/converting? Basically, some files I have found have dynamic offsets in the RPU if the aspect ratio changes in the film (e.g. Blonde from NF), but others seem to just have 0,0,0,0 for entire runtime set despite the file having top and bottom borders of 278px for example.
TEST UPDATE: I just compared a video with all borders set to 0 in DV metadata but the actual video is uncropped and has black bars of about 278pixels on top and bottom VS. same fixed file with the correct offsets set in the DV Level 5 metadata of 278px top and bottom. To my surprise, I see no difference whatsoever when viewed on LG OLED C2 with Shield Pro 2019 in Plex app. These are normal .mkv files with dvhe.08.06. I totally expected to see the grey black bars and higher brightness as others have mentioned in discussions before.
UPDATE 2: @quietvoid let me know that it's because I am using an HDMI playback device, so Level 5 metadata is ignored in this case. Saves me a lot of time going forward, not having to always check and fix L5 data in encodes. Cheers! I suspect I will have issues if trying to play back on the TV built-in apps, although LG OLED C2 doesn't even play DoVi through an MKV in Plex, so I'll try with my other Hisense model later.
FINAL UPDATE: Sooo, it looks like L5 Metadata is taken into account by my Hisense TV (low end 2022 model), but oddly, it's not noticeable when the L5 offsets are all set to 0,0,0,0 (AKA cropped) but video is uncropped with black bars, or maybe this TV just doesn't output enough nits to show the effect. Either way, it seems far less of a problem and this is more common case when taking DV RPU from one source (cropped) and injecting into another (uncropped). On the other hand, when L5 Active Area is incorrectly set with borders (offsets from uncropped source) and injected into a file that is re-encoded and cropped, the TV actually cuts off parts of the image corresponding to the L5 offsets! It didn't just mess with brightness of the borders, this is much worse! I confirmed this by re-injecting the DV RPU with corrected L5 offsets for the same encoded video file. Here is before vs. after comparison: https://imgsli.com/MTM4Nzgz
This was unexpected and goes to show that a TV can interpret DV metadata in unexpected ways. In conclusion, if you play your files on your TV's internal player (especially Hisense), I recommend always verifying (and if needed, correcting), L5 metadata, even if you are playing back a file that you think is created by a 'reliable' encoder. Or consider getting a dedicated player like Shield Pro 2019 for example to avoid L5 issues altogether. Thanks again @quietvoid, @GodzillaAvenger and @-QfG- for the advice and tools that made this testing easier for me.
GodzilaAvenger
9th December 2022, 05:59
As far as I know no L5 data is changed during the conversion process unless the crop is specifically set during demuxing, so whatever L5 you have on P5 will appear on P8.
Dealing with files that have a varying aspect ratio is a bit tricky. I've seen both files where borders change to accomodate different aspect ratios, and those that borders are set to a constant value. I think in the latter ones the black bars are taken into account when computing the rest of the metadata (e.g. min_pq always seems to be 0). In general you have to be cognizant of the aspect ratio on both the source file and the target file (be it Web or BluRay). I recently wanted to add the RPU from a Web source with constant aspect ratio to a BluRay with IMAX scenes. I initially changed the borders for the IMAX scenes but then realized it was a mistake, because the rest of the metadata was calculated based on the fixed aspect ratio part of the image so the borders should correspond to those.
LV8
10th December 2022, 20:09
@quietvoid @-QfG- Quick question, I noticed that sometimes if you convert Profile 5 DV RPU to Profile 8, the Level 5 metadata for cropping values is not set or set to all 0. I know the DDVT script tries to catch this by detecting borders and suggesting to match video when injecting RPU, but if I already have some files with 0,0,0,0 set for Level 5 but the video itself has borders (uncropped), will it cause issues when viewing with Shield Pro 2019? I will run a test on my TV later, but just wanted to ask before fixing all of the possible video files I have that could have this issue. It seems that some users around the WEB are not aware of the Level 5 border values when they are injecting WEB-source DV into HDR (i.e. combining Profile 5 DV with HDR video from NF to make a hybrid file), so I thought I'd ask about it. Thank you kindly!
You should always use the correct L5 values as Dolby suggests, but there are a very few devices that actually use it (all HDMI devices don't, so in your case the Nvidia Shield won't care).
The only players that do are mostly internal TV players, such as LG ones.
von Suppé
12th December 2022, 12:01
...and those that borders are set to a constant value. I think in the latter ones the black bars are taken into account when computing the rest of the metadata
The thought that black borders would be taken into account does make sense. But it also confuses me. Unless I'm heavily mistaken or missing out on something, the L5 values would dictate the Dolby composer to apply the metadata only in the "active area". Which is the part between the black borders (given L5 values being correct). I mean, what other purpose would L5 values have?
...but then realized it was a mistake, because the rest of the metadata was calculated based on the fixed aspect ratio part of the image so the borders should correspond to those.
How did that mistake manifest in terms of viewing the video? You may remember I edited lots of L5 values for the movie Interstellar to match its varying black borders. Where the RPU came from constant AR video. I find the endresult playing back perfectly, where I experience no odd scenes showing artifacts or weird jumps in colors or brightness.
hidef_rec
12th December 2022, 18:42
Pardon the novice question. Just stumbled on this tool & can't wait to try it out. Have a DV profile 5 MKV that I want to convert to a profile 8.
Think my options saved correctly looking at the resulting ini file:
TEMP Folder=D\Temporary
TARGET Folder=I
I have my MKV in D\Temporary, but when I run DDVT_DEMUXER, it says no input file. What am I doing wrong? Thanks.
GodzilaAvenger
12th December 2022, 20:41
The thought that black borders would be taken into account does make sense. But it also confuses me. Unless I'm heavily mistaken or missing out on something, the L5 values would dictate the Dolby composer to apply the metadata only in the "active area". Which is the part between the black borders (given L5 values being correct). I mean, what other purpose would L5 values have?
I think what happens is that during the IMAX scenes the image fills up the active area, but in other scenes the active area consists of both the image and part of the black bars, as if it was an IMAX scene. I'm guessing when they produce the metadata they take that into account for the non-IMAX scenes (e.g. min_pq is pretty much always 0). E.g. Thor: Love and Thunder does this and sets the borders to 68 (in Disney+).
How did that mistake manifest in terms of viewing the video? You may remember I edited lots of L5 values for the movie Interstellar to match its varying black borders. Where the RPU came from constant AR video. I find the endresult playing back perfectly, where I experience no odd scenes showing artifacts or weird jumps in colors or brightness.
I did it based on the reasoning above mid creating the custom.json file for Nolan's last two Batmans, so I didn't get a chance to compare them. As mentioned above they don't seem to matter over HDMI so I'm not sure if I even can tell the difference.
GodzilaAvenger
12th December 2022, 20:45
Pardon the novice question. Just stumbled on this tool & can't wait to try it out. Have a DV profile 5 MKV that I want to convert to a profile 8.
Think my options saved correctly looking at the resulting ini file:
TEMP Folder=D\Temporary
TARGET Folder=I
I have my MKV in D\Temporary, but when I run DDVT_DEMUXER, it says no input file. What am I doing wrong? Thanks.
The TEMP folder is for storing temporary files created during the operation like e.g. temp.hevc extracted from the mkv during demuxing. You should go to the DDVT folder (where DDVT_DEMUXER is) and run
.\DDVT_DEMUXER 'path\to\file'
hidef_rec
12th December 2022, 21:42
Thanks, the process ran, but didn't get a new MKV that was profile 8. Doing something wrong; what I only end up with is a RPU.bin file in the output folder.
Here's the file I'm trying to convert to profile 8, which I believe has a HDR10 base layer. Right now, if my display only supports HDR10, I get pink/green picture.
General
Unique ID : 149613682865022055125766330203027420429 (0x708E8C14C60B5D36B87B68063A4E350D)
Complete name : C:\DDVT\test.mkv
Format : Matroska
Format version : Version 4
File size : 20.2 GiB
Duration : 1 h 35 min
Overall bit rate mode : Variable
Overall bit rate : 30.4 Mb/s
Movie name : Test Video
Encoded date : UTC 2022-01-03 00:13:27
Writing application : mkvmerge v64.0.0 ('Willows') 64-bit
Writing library : libebml v1.4.2 + libmatroska v1.6.4
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@High
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : V_MPEGH/ISO/HEVC
Duration : 1 h 35 min
Bit rate : 24.3 Mb/s
Width : 3 840 pixels
Original width : 3 838 pixels
Height : 2 072 pixels
Display aspect ratio : 1.85:1
Original display aspect ratio : 1.85:1
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.127
Stream size : 16.1 GiB (80%)
Language : English
Default : Yes
Forced : No
Audio
ID : 2
Format : MLP FBA 16-ch
Format/Info : Meridian Lossless Packing FBA with 16-channel presentation
Commercial name : Dolby TrueHD with Dolby Atmos
Codec ID : A_TRUEHD
Duration : 1 h 35 min
Bit rate mode : Variable
Bit rate : 6 071 kb/s
Maximum bit rate : 5 985 kb/s
Channel(s) : 8 channels
Channel layout : L R C LFE Ls Rs Lb Rb
Sampling rate : 48.0 kHz
Frame rate : 1 200.000 FPS (40 SPF)
Compression mode : Lossless
Delay relative to video : 40 ms
Stream size : 4.04 GiB (20%)
Title : Dolby ATMOS
Language : English
Default : Yes
Forced : No
Number of dynamic objects : 13
Bed channel count : 1 channel
Bed channel configuration : LFE
GodzilaAvenger
13th December 2022, 01:04
You can't convert a Profile 5 (P5) Dolby Vision (DV) mkv file into a Profile 8 (P8) one using DDVT because the Base Layer (BL) of P5 uses a different color space (IPTPQc2) from that of P8 (normal HDR10 or SMPTE 2086). Here's what you can do, if you have a P5 DV mkv and an HDR10 mkv.
1. Use the demuxer tool to extract the RPU (essentially the frame-by-frame metadata containing information about scene brightness and color) from the P5 mkv. Use the option to convert it to P8.1.
2. Use the injector tool to inject the RPU into the HDR10 mkv. Make sure they are in the same folder.
Now you have a P8 mkv. You can watch it on both HDR10-only displays and DV capable one.
von Suppé
13th December 2022, 13:08
...but in other scenes the active area consists of both the image and part of the black bars, as if it was an IMAX scene. I'm guessing when they produce the metadata they take that into account for the non-IMAX scenes (e.g. min_pq is pretty much always 0)
This would inspire for testing. As a first, how an image would come out when min-pq is not 0 with an active area that includes these partial black bars. I wonder if there'd be noticable "blackness" differences in them. When I have time, I'll do some.
As mentioned above they don't seem to matter over HDMI...
Sorry, but can you link to where this is said or implied? I must be overlooking.
Right now, if my display only supports HDR10, I get pink/green picture.
The pink/green picture is typical for when DV P5 is played back on non-compliant SW/HW.
P5 HW playback requires a DV capable player because of the proprietary colorspace GodzilaAvenger mentioned. Which makes P5 non backwards compatible - contrary to the likes of P7 and P8.
For playback on pc you can try MPV player. It handles P5 pretty good when you set VO to "gpu-next".
fkid
13th December 2022, 15:20
Sorry, but can you link to where this is said or implied? I must be overlooking.
https://forum.doom9.org/showthread.php?p=1979519#post1979519
https://forum.doom9.org/showthread.php?p=1979614#post1979614
I searched long and hard in official documentation and finally found some references to authoring for DV from Dolby and Davinci Resolve docs mentioning keeping min_pq below 0.25 or something like that (as close to 0 as possible) in order for HDMI playback devices not using L5 to not have issues with brightness/blacks, because they require the borders to be included in active area for subtitle display etc. This is why for most situations, the DV authoring is done so that if L5 is not being parsed or missing, then the DV still looks good through HDMI playback for uncropped video. Most of this is rendered moot for streaming services and retail UHD BR discs obviously. This is more of a case for us custom/Plex/tech savvy users and people who actually do their own DV grading and creation etc. In the end, conclusion is that L5 matters for (most) internal playback, as I mentioned in my test case for Hisense TV, but not HDMI playback devices.
hidef_rec
13th December 2022, 16:13
Awesome, thanks @GodzilaAvenger
Fuso
19th December 2022, 16:31
Hello! I've read the whole topic but I didn't get how to convert Double Layer P7 to Double or Single Layer P8. I was using LG B8 for watching DV through Plex. The method that I was using was one of the first ways (I think) to remux DV. Extract the BL + EL and audio with eac3toGUI and mux it to mp4. I've bought LG C2 and found that these files play as regulard HDR, probably LG updated something software-wise and made it not compatilble with Double Layer DV Profile 7 files.
So is it possible to make this one into something playable on the C2?
General
Complete name : G:\Филми\(2015) [4K] Mission Impossible Rogue Nation - Мисията невъзможна Престъпна нация.mp4
Format : MPEG-4
Format profile : Base Media / Version 2
Codec ID : mp42 (mp42/dby1/isom)
File size : 44.4 GiB
Duration : 2 h 11 min
Overall bit rate : 48.3 Mb/s
Encoded date : UTC 2021-08-25 06:38:12
Tagged date : UTC 2021-08-25 06:38:12
Video #1
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@High
HDR format : SMPTE ST 2086, HDR10 compatible
Codec ID : hev1
Codec ID/Info : High Efficiency Video Coding
Duration : 2 h 11 min
Bit rate : 42.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 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.215
Stream size : 39.4 GiB (89%)
Default : No
Encoded date : UTC 2021-08-25 06:38:12
Tagged date : UTC 2021-08-25 06:38:12
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color pri : Display P3
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Codec configuration box : hvcC
Video #2
ID : 2
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@High
HDR format : Dolby Vision, Version 1.0, dvhe.07.06, EL+RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible
Codec ID : dvhe
Codec ID/Info : High Efficiency Video Coding with Dolby Vision
Duration : 2 h 11 min
Bit rate : 4 836 kb/s
Width : 1 920 pixels
Height : 1 080 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 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.097
Stream size : 4.44 GiB (10%)
Default : No
Encoded date : UTC 2021-08-25 06:38:12
Tagged date : UTC 2021-08-25 06:38:12
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color pri : Display P3
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Codec configuration box : hvcC+dvcC
Audio
ID : 3
Format : AC-3
Format/Info : Audio Coding 3
Commercial name : Dolby Digital
Format settings : Dolby Surround EX
Codec ID : ac-3
Duration : 2 h 11 min
Bit rate mode : Constant
Bit rate : 640 kb/s
Channel(s) : 6 channels
Channel layout : L R C LFE Ls Rs
Sampling rate : 48.0 kHz
Frame rate : 31.250 FPS (1536 SPF)
Compression mode : Lossy
Stream size : 602 MiB (1%)
Language : English
Service kind : Complete Main
Default : No
Encoded date : UTC 2021-08-25 06:38:12
Tagged date : UTC 2021-08-25 06:38:12
When I try to open the file with DDVT it says that is not supporting Double Layer Profile 7
18271
speedy
24th December 2022, 19:24
Do we have any data on how accurate the HDR10+ to DoVi P8.1 conversion is?
What of the following would typically be more accurate and why?
1. Demux HDR10+, convert to DVp8.1 RPU and inject P8.1 RPU back into original ST2094 file.
2. Demux DVp5 RPU and inject into an ST2094 version that was likely mastered separately.
3. Demux DVp5 RPU and inject into an ST2086 version that was possibly mastered by the same colorist as the DVp5 version.
The HDR10+ tone mapping curve isn't mapped to Dolby Vision.
Only the frame brightness analysis is copied to the RPU.
Also, is this still the case?
Would demuxing the DVp5 RPU and injecting it into a ST2094 and/or ST2086 file ensure the tone mapping curve and frame brightness analysis are both preserved?
Chilly
25th December 2022, 11:07
Hi! I'm starting to study the topic of DV and I want to ask a couple of questions. Sorry for maybe stupid questions...
1. Please explain to me if Injector shows [NOT MATCH WITH RPU/VIDEO] is this normal? Will the output file be ok? The video has a borders of 278/278, while the RPU has a borders of 276/277. DDVT automatically saves borders 278/278.
2. I found BDRemux with DV P8 on the Internet, in MediaInfo displays information "ID in the original source m : 4113 (0x1011)" and "Original source medium : Blu-ray". Why is this information removed from my file after using DDVT? In the file from the Internet, the line "HDR format: Dolby Vision, Version 1.0, dvhe.08.06, BL + RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible" indicates exactly "Blu-ray compatible", while in my file after using DDVT, this information changes to "HDR10 compatible". What is the reason? Is it possible to keep the original information?
I'm from another country, so I'm sorry if I wrote something incomprehensibly ))
DiscoD
26th December 2022, 06:31
Love your tool use it almost daily,
attempting to convert hdr10+ to DV 8.1 to inject into an encode but im getting an error when its trying to create the RPU from the hdr10+ data
"error: expected ident at line 3 column 13"
added images below, i can say according to the source the HDR10+ data is pulled from an Amazon Rip.
https://i.ibb.co/PgP2bNn/error.png (https://ibb.co/PgP2bNn) https://i.ibb.co/NpyS64n/first.png (https://ibb.co/NpyS64n)
GodzilaAvenger
27th December 2022, 03:26
Do we have any data on how accurate the HDR10+ to DoVi P8.1 conversion is?
What of the following would typically be more accurate and why?
1. Demux HDR10+, convert to DVp8.1 RPU and inject P8.1 RPU back into original ST2094 file.
2. Demux DVp5 RPU and inject into an ST2094 version that was likely mastered separately.
3. Demux DVp5 RPU and inject into an ST2086 version that was possibly mastered by the same colorist as the DVp5 version.
You could try the three methods you mentioned and see if you notice any difference in the outcome. My guess is that they shouldn't differ much. Here's why: both HDR10+ and DV replace the static metadata of HDR10 (that tells your display how to best interpret the underlying video stream) with dynamic (i.e. scene-by-scene) metadata. In other words HDR10+ is ST 2084 with dynamic metadata (backwards compatible with HDR10), whereas HDR10 is ST 2084 with static metadata. Therefore, the base video stream in 2 and 3 would very likely be the same, and injecting a P8.1 RPU into each would yield a similar result during playback on a DV display. The difference is that 2 would also trigger HDR10+ on a compatible display, but 3 wouldn't.
I think converting between DV profiles (here P5 to P8.1) preserves the metadata (both tone mapping and brightness analysis), but as quietvoid said you'll only keep the brightness analysis during conversion from HDR10+ to P8.1, so 2 and 3 may give you a slightly better result than 1. I think it's generally better to use a native DV RPU than one obtained through conversion from HDR10+.
GodzilaAvenger
27th December 2022, 04:59
Hi! I'm starting to study the topic of DV and I want to ask a couple of questions. Sorry for maybe stupid questions...
1. Please explain to me if Injector shows [NOT MATCH WITH RPU/VIDEO] is this normal? Will the output file be ok? The video has a borders of 278/278, while the RPU has a borders of 276/277. DDVT automatically saves borders 278/278.
2. I found BDRemux with DV P8 on the Internet, in MediaInfo displays information "ID in the original source m : 4113 (0x1011)" and "Original source medium : Blu-ray". Why is this information removed from my file after using DDVT? In the file from the Internet, the line "HDR format: Dolby Vision, Version 1.0, dvhe.08.06, BL + RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible" indicates exactly "Blu-ray compatible", while in my file after using DDVT, this information changes to "HDR10 compatible". What is the reason? Is it possible to keep the original information?
I'm from another country, so I'm sorry if I wrote something incomprehensibly ))
1. That's ok. It's just warning you that the borders of the active area (where the image is) detected by DDVT is different from what is in the RPU. You can choose to keep the original borders, let DDVT change them, or manually set them altogether. Word of caution though, sometimes DDVT is off by 1 or 2 pixels when detecting borders, so you may want to manually verify the borders you get.
2. How exactly are you using DDVT? "dvhe.08.06, BL + RPU, Blu-ray compatible" is odd, I've seen both "dvhe.07.06, BL+EL+RPU, Blu-ray compatible" and "dvhe.08.06, BL+RPU, HDR10 compatible", but not what you said.
Side note: Since you said you found the BDRemux on the Internet, I hope you know that piracy is not ok, you should only use DDVT to add/modify metadata of the content you already own.
GodzilaAvenger
27th December 2022, 05:00
Love your tool use it almost daily,
attempting to convert hdr10+ to DV 8.1 to inject into an encode but im getting an error when its trying to create the RPU from the hdr10+ data
"error: expected ident at line 3 column 13"
added images below, i can say according to the source the HDR10+ data is pulled from an Amazon Rip.
Open the .json file in a text editor and see what's wrong with line 3. Probably a space or indent or something is missing/extra.
Chilly
27th December 2022, 14:26
1. That's ok. It's just warning you that the borders of the active area (where the image is) detected by DDVT is different from what is in the RPU. You can choose to keep the original borders, let DDVT change them, or manually set them altogether. Word of caution though, sometimes DDVT is off by 1 or 2 pixels when detecting borders, so you may want to manually verify the borders you get.
2. How exactly are you using DDVT? "dvhe.08.06, BL + RPU, Blu-ray compatible" is odd, I've seen both "dvhe.07.06, BL+EL+RPU, Blu-ray compatible" and "dvhe.08.06, BL+RPU, HDR10 compatible", but not what you said.
Side note: Since you said you found the BDRemux on the Internet, I hope you know that piracy is not ok, you should only use DDVT to add/modify metadata of the content you already own.
I don't do piracy. I have several Blu-rays that I want to save to my PC. So I decided to read this topic.
I created my BDRemux DV P7 with MakeMKV. Then I changed DV P7 to DV P8 using DDVT and compare my result with someone else's. Found differences:
1) the lines "ID in the original source m : 4113 (0x1011)" and "Original source medium : Blu-ray" are missing
2) line in my BDRemux: "HDR format: Dolby Vision, Version 1.0, dvhe.08.06, BL + RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible"; line in someone else's BDRemux: "HDR format: Dolby Vision, Version 1.0, dvhe.08.06, BL + RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible".
Therefore, I had a question, why do I not have these lines (point 1) and why is the information in the line different (point 2)?
Thanks for answers!
von Suppé
27th December 2022, 21:20
I wouldn't worry too much about the lines you mention. They are metadata written on container level by the muxing application. There are several mkv muxing tools, authored by different people. Where sometimes metadata is blindly copied or wrong metadata can be written.
FYI what makes a DV mkv (or any other DV file for that matter) "bluray compatible" isn't written in stone or specs, but depends on interpretation. Often a file is considered to be bluray compatible, if it contains everything (as for video, at least) that's also on disc. Dolby Vision on UHDBD is Profile 7. Which specific specs mandate two layers: a HEVC 10-bit HDR encoded baselayer (BL) and an enhancement layer (EL). Where El carries RPU.
P7-mkv carries these exact same layers. Where in this respect, like GodzilaAvenger already said, "dvhe.08.06, BL + RPU, Blu-ray compatible" is odd. This line already says it: P8 is single-layer ("BL+RPU"). Having no EL, RPU is interleaved in BL. There are other reasons why P8 may not be compliant. BL may have been cropped. Or recoded with encoding parameters beyond UHDBD specs.
The above should be read as is, and not be confused with the following. On many forums it's said that DV P8 is equivalent to "Dolby Vision MEL". Which can raise an eyebrow.
The enhancement layer is either MEL or FEL. FEL means "full enhancement layer", which carries RPU and differential 10-to-12 bit videodata.
A "minimum enhancement layer" (MEL) only carries RPU. Consequently, when you extract RPU from a MEL, convert it to P8 and inject it in BL, the file actually contains all video- and metadata that is on disc. As such, it's said to be "equivalent" to DV MEL.
GodzilaAvenger
27th December 2022, 21:33
I don't do piracy. I have several Blu-rays that I want to save to my PC. So I decided to read this topic.
I created my BDRemux DV P7 with MakeMKV. Then I changed DV P7 to DV P8 using DDVT and compare my result with someone else's. Found differences:
1) the lines "ID in the original source m : 4113 (0x1011)" and "Original source medium : Blu-ray" are missing
2) line in my BDRemux: "HDR format: Dolby Vision, Version 1.0, dvhe.08.06, BL + RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible"; line in someone else's BDRemux: "HDR format: Dolby Vision, Version 1.0, dvhe.08.06, BL + RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible".
Therefore, I had a question, why do I not have these lines (point 1) and why is the information in the line different (point 2)?
Thanks for answers!
Thanks for clarifying!
1) Since those tags are merely informational, my best guess is that DDVT just simply discards them, much like MKVToolNix did a few years ago (https://gitlab.com/mbunkus/mkvtoolnix/-/issues/2774).
2) Is there any difference between the files during playback? As far as I can tell MediaInfo is interpreting dv_bl_signal_compatibility_id (https://professional.dolby.com/siteassets/content-creation/dolby-vision-for-content-creators/dolby_vision_bitstreams_within_the_iso_base_media_file_format_dec2017.pdf) for that last part, so it is possible that either DDVT or the software used for that BDRemux are setting the wrong value for that field. Not sure if it really matters during playback though.
Chilly
28th December 2022, 05:47
I wouldn't worry too much about the lines you mention. They are metadata written on container level by the muxing application. There are several mkv muxing tools, authored by different people. Where sometimes metadata is blindly copied or wrong metadata can be written.
FYI what makes a DV mkv (or any other DV file for that matter) "bluray compatible" isn't written in stone or specs, but depends on interpretation. Often a file is considered to be bluray compatible, if it contains everything (as for video, at least) that's also on disc. Dolby Vision on UHDBD is Profile 7. Which specific specs mandate two layers: a HEVC 10-bit HDR encoded baselayer (BL) and an enhancement layer (EL). Where El carries RPU.
P7-mkv carries these exact same layers. Where in this respect, like GodzilaAvenger already said, "dvhe.08.06, BL + RPU, Blu-ray compatible" is odd. This line already says it: P8 is single-layer ("BL+RPU"). Having no EL, RPU is interleaved in BL. There are other reasons why P8 may not be compliant. BL may have been cropped. Or recoded with encoding parameters beyond UHDBD specs.
The above should be read as is, and not be confused with the following. On many forums it's said that DV P8 is equivalent to "Dolby Vision MEL". Which can raise an eyebrow.
The enhancement layer is either MEL or FEL. FEL means "full enhancement layer", which carries RPU and differential 10-to-12 bit videodata.
A "minimum enhancement layer" (MEL) only carries RPU. Consequently, when you extract RPU from a MEL, convert it to P8 and inject it in BL, the file actually contains all video- and metadata that is on disc. As such, it's said to be "equivalent" to DV MEL.
Thanks for clarifying!
1) Since those tags are merely informational, my best guess is that DDVT just simply discards them, much like MKVToolNix did a few years ago (https://gitlab.com/mbunkus/mkvtoolnix/-/issues/2774).
2) Is there any difference between the files during playback? As far as I can tell MediaInfo is interpreting dv_bl_signal_compatibility_id (https://professional.dolby.com/siteassets/content-creation/dolby-vision-for-content-creators/dolby_vision_bitstreams_within_the_iso_base_media_file_format_dec2017.pdf) for that last part, so it is possible that either DDVT or the software used for that BDRemux are setting the wrong value for that field. Not sure if it really matters during playback though.
Thank you very much for your explanations! Yes, I understand that this does not affect playback in any way. I'm just a perfectionist and when I saw the differences in the metadata of my file and some popular "pirate", I thought that I was doing something wrong :)
-QfG-
29th December 2022, 16:16
About cropping:
1. There are any Retail Untouched RPUs without cropping informations. The tool says in this case :NO CROPPING INFORMATIONS FOUND. You can leave this RPUs untouched, but it is recommended to set the valid Borders.
I think, that no cropping informations in the RPU is the same how 0 entries. But i have no proof for this statement.
2. IMAX Format: You can do 3 Things:
Set all borders to 0 (this is the way that i use)
Set all borders to the lowest entry (Example: IMAX Scenes Borders 42/42, Normal Scenes Borders 272,272 -> set Borders to 42/42
For Freaks xd - Create a custom.json file and set all borders manually for IMAX / Normal frames. Good Luck :) In this case, don't forget to turn off border manipulation via the tool himself.
3. BORDERLESS VIDEO: If the video is cropped or full 16:9 without Black Bars, set all boreder entries to 0!
In my Tests i have no problems with RPUs with borders entries of 0 with cropped content. BUT ! I have trouble with RPUs with Border entries other than 0 by cropped (borderless) content!
In all cases it is recommended to set the correct borders in the RPU for maximal compatibility with the hardware players.
hidef_rec
3rd January 2023, 20:58
Awesome tool, big thanks to you @-QfG-. Trying to do my first merge of a DV file w/a HDR10+ file to end up with a combi one. Before I start below w/the injector tool to inject the RPU into the HDR10+ mkv, how/where do I set borders to zero? This is borderless video. Thanks.
== VIDEO INPUT =========================================================================================================
Filename = [myvideohdr10plus.mkv]
Video Info = [Resolution = 3840x1634] [Codec = HEVC-10Bit-YUV-4:2:0] [Frames = 154104] [FPS = 23.976]
HDR Info = [SMPTE ST 2094 App 4, Version 1, HDR10+ Profile A compatible]
Borders = [LEFT=0 px], [TOP=0 px], [RIGHT=0 px], [BOTTOM=0 px] [NOT MATCH WITH RPU]
== RPU INPUT ===========================================================================================================
Filename = [RPU.bin]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 154104]
Borders = [BORDERS NOT SET IN RPU]
== FILE OUTPUT =========================================================================================================
Filename = [myvideohdr10plus_[BL+RPU]]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 154104]
Borders = [LEFT=0 px], [TOP=0 px], [RIGHT=0 px], [BOTTOM=0 px]
Delay = [0 FRAMES]
== MENU ================================================================================================================
1. DELAY : [0 FRAMES]
2. Match L6 Metadata : [NO]* *Change L6 Metadata to match with Video.
3. Remove HDR10+ : [NO]
4. MUX STREAM IN MKV : [NO]
6. EDIT ACTIVE AREA* *Setting Crop Values. DISCARD set Borders to [LEAVE UNTOUCHED].
S. START
Change Settings and press [S] to start Injecting
Select a Letter 1,2,3,4,6,[S]tart
Out of curiosity, is it (or will it at some point be) possible to convert DV to HDR10+?
GodzilaAvenger
4th January 2023, 07:41
Per what you've shown, DDVT will automatically set the borders to 0. You can edit the borders by pressing 6 and entering the Edit Active Area screen, where you can modify individual borders.
hidef_rec
4th January 2023, 21:38
Thanks for confirming what I was suspecting. Resulting file plays fine via Shield TV & Zidoo Z9X.
MrDover
4th January 2023, 23:34
I am trying to use DDVT_DEMUXER and it says:
"'findstr' is not recognized as an internal file or external command, operable program or batch file"
multiple times in place of where the 1, 2 and 5 options should be in the DUMUXER.
Options 3 and 4 still show normally and I am able to Save RPU and convert RPU but I can not use any of the other options.
Has any one else experienced this or know of a way to fix this? I have tried 2 separate versions (v0.50-fixed and v0.45) and both do the same
GodzilaAvenger
5th January 2023, 05:45
Mine works fine. Can you post a screenshot?
MrDover
6th January 2023, 00:50
Mine works fine. Can you post a screenshot?
https://ibb.co/vQ5vKqg
Image Link: https://ibb.co/vQ5vKqg
MrDover
6th January 2023, 00:51
https://ibb.co/vQ5vKqg
link: https://ibb.co/vQ5vKqg
GodzilaAvenger
6th January 2023, 02:43
It's a bit odd since the menu itself doesn't use 'findstr' per se, though one of the submenus does (you can open DDVT_DEMUXER in a text editor to see the code). Try this (https://stackoverflow.com/questions/10244181/findstr-is-not-recognized-as-an-internal-or-external-command) and see if it fixes the problem.
Chilly
6th January 2023, 16:32
Please tell me who used DDVT_MKVTOMP4, these MP4 files with DVP8 will play on DV capable TV?
And yet, after converting MKV to MP4, audio and subtitles are designated as "SoundHandler" and "SubtitleHandler" in Media Player Classic. Correct (other) titles are displayed in MediaInfo. How can this be fixed?
MrDover
6th January 2023, 19:51
It's a bit odd since the menu itself doesn't use 'findstr' per se, though one of the submenus does (you can open DDVT_DEMUXER in a text editor to see the code). Try this (https://stackoverflow.com/questions/10244181/findstr-is-not-recognized-as-an-internal-or-external-command) and see if it fixes the problem.
This seemed to work great thank you very much. I didn’t think to google that error as I thought it was maybe just a bug with the tool rather than something with my own computer
V_Amoleo
28th January 2023, 21:46
I've been using this set of tools to convert HDR10+ to Dolby Vision with great success but I've now come across two titles where I'm struggling.
I have a UK three UHD Blu-ray collection of Shaun of the Dead, Hot Fuzz and The World's End. Shaun of the Dead converted from HDR10+ to Dolby Vision no problem at all. But I've tried the other two and they both create broken Dolby Vision versions (messed up colours, brightness all over the place).
I noticed that Shaun of the Dead, after conversion is labelled in MediaInfo as "Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible" but Hot Fuzz and The World's End are labelled as "Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU, Blu-ray compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible"
I'm pretty sure I used these settings for all three:
DDVT DEMUXER
Save HDR BL: No, Default.
Save HDR10+ Metadata: No, Default.
Skip HDR10+ Validation: No, Default.
Remove HDR10+ Metadata from BL: No, Default.
Convert HDR10+ Metadata to DV: Yes, Default.
Content Mapping Version: 4.0.
DDVT INJECTOR
Delay: 0 Frames, Default.
Match L6 Metadata: No, Default.
Remove HDR10+: No, Default.
Mux Stream in MKV: Yes.
Edit Active Area: Left = 0, Top = 264, Right = 0, Bottom = 264. Automatically detected as the RPU didn't match the video.
Any ideas?
von Suppé
31st January 2023, 17:39
Injecting HDR10+ metadata has stopped working in the DDVT_INJECTOR.cmd. Pressing S for Start doesn't seem to launch anything. Injecting HDR10+ with hdr10plus_tool.exe cmd works.
RPU injecting goes properly with the script. Can you have a look please?
GodzilaAvenger
3rd February 2023, 19:52
I have a UK three UHD Blu-ray collection of Shaun of the Dead, Hot Fuzz and The World's End. Shaun of the Dead converted from HDR10+ to Dolby Vision no problem at all. But I've tried the other two and they both create broken Dolby Vision versions (messed up colours, brightness all over the place).
I noticed that Shaun of the Dead, after conversion is labelled in MediaInfo as "Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible" but Hot Fuzz and The World's End are labelled as "Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU, Blu-ray compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible"
Any ideas?
It's odd that you're getting a Profile 7 RPU, as far as I know you should be getting a Profile 8 one like Shaun of the Dead. You could use the FRAMEINFO tool on the RPUs of Hot Fuzz and Shaun of the Dead to get all the frame info in a .json file and then compare them and the two hdr10plus.json files to see if you can spot the difference. Apart from that, maybe try CM2.9, and also check your workflow to ensure you're not accidentally injecting the wrong RPU.
Injecting HDR10+ metadata has stopped working in the DDVT_INJECTOR.cmd. Pressing S for Start doesn't seem to launch anything. Injecting HDR10+ with hdr10plus_tool.exe cmd works.
RPU injecting goes properly with the script. Can you have a look please?
I tried the HDR10+ injector tool yesterday and it was working fine. Were you able to figure out what the problem was?
On that note, I don't think HDR10+ injection needs video border analysis, so maybe it can be skipped in future versions of the tool.
von Suppé
3rd February 2023, 21:15
I tried the HDR10+ injector tool yesterday and it was working fine. Were you able to figure out what the problem was?
Maybe. That is, tried with version 0.48c beta and injecting HDR10+ goes well. I reckon this version uses an older "hdr10plus_tool.exe" but I highly doubt if that makes the difference. Because latest hdr10plus_tool.exe works when run with cli.
Tried again on latest QfG version. Very short path, no weird characters in path & names. Still no dice. I think it's a bug in the script.
Or can I be unaware of usage change? Videosource is "video.hevc". HDR10+ metadata is "HDR10Plus.json".
Still works with 0.48c. Note I am on Windows 7.
GodzilaAvenger
3rd February 2023, 22:07
Maybe. That is, tried with version 0.48c beta and injecting HDR10+ goes well. I reckon this version uses an older "hdr10plus_tool.exe" but I highly doubt if that makes the difference. Because latest hdr10plus_tool.exe works when run with cli.
Tried again on latest QfG version. Very short path, no weird characters in path & names. Still no dice. I think it's a bug in the script.
Or can I be unaware of usage change? Videosource is "video.hevc". HDR10+ metadata is "HDR10Plus.json".
Still works with 0.48c. Note I am on Windows 7.
I think I figured out what the problem is. Injecting into .mp4 and .mkv works fine, but not into .hevc because of a bug. For a temporary fix, replace this line
CHOICE /C 1S /N /M "Select a Letter 1,[S]tart"
(should be line 433) with this line
CHOICE /C 1WS /N /M "Select a Letter 1,[S]tart"
Another, perhaps better fix would be to replace (line 436, without changing line 433)
if "%ERRORLEVEL%"=="2" (
if "%MUXINMP4%"=="NO" set "MUXINMP4=YES"
if "%MUXINMP4%"=="YES" set "MUXINMP4=NO"
if "%MUXINMKV%"=="NO" set "MUXINMKV=YES"
if "%MUXINMKV%"=="YES" set "MUXINMKV=NO"
)
with
if "%ERRORLEVEL%"=="2" (
if "!RAW_FILE!"=="TRUE" (
goto HDR10P_BEGIN
) else (
if "%MUXINMP4%"=="NO" set "MUXINMP4=YES"
if "%MUXINMP4%"=="YES" set "MUXINMP4=NO"
if "%MUXINMKV%"=="NO" set "MUXINMKV=YES"
if "%MUXINMKV%"=="YES" set "MUXINMKV=NO"
)
)
I think this bug was introduced when the HDR10+ delay functionality was added.
von Suppé
4th February 2023, 11:49
I think I figured out what the problem is. Injecting into .mp4 and .mkv works fine, but not into .hevc because of a bug. For a temporary fix, replace...
Your suggested script adjustment works like a charm.
:thanks: for the bug hunt, GA.
-QfG-
6th February 2023, 00:02
-v0.51 Online
*Updated dovi_tool to v2.0.1.
*Updated hdr10plus_tool to v1.5.2.
*Updated mkvtoolnix to v 73.0.0.0.
*Bugfix in Injector script for HDR10+ injecting (thx "von Suppé" for finding and "GodzilaAvenger" for fixing).
PoeBear
6th February 2023, 09:39
Is there any faster way to get an RPU from an m2ts? With DGDecNV, I index the HDR10 and Dolby Vision layers from a disc dump's m2ts, so nothing I manipulate in AviSynth is a raw HEVC. But to get an RPU I have to demux the EL HEVC, to then be able to extract the RPU? If there's no faster/direct way, is it possible to demux/extract from a m2t2 all within DDVT?
-QfG-
6th February 2023, 10:33
I know no way to demux the RPU without extracting the RAW stream from container.
von Suppé
6th February 2023, 10:38
HDR10+ injecting in hevc stream works again in version 0.51.
Thanks for the update @-QfG-
V_Amoleo
6th February 2023, 11:31
It's odd that you're getting a Profile 7 RPU, as far as I know you should be getting a Profile 8 one like Shaun of the Dead. You could use the FRAMEINFO tool on the RPUs of Hot Fuzz and Shaun of the Dead to get all the frame info in a .json file and then compare them and the two hdr10plus.json files to see if you can spot the difference. Apart from that, maybe try CM2.9, and also check your workflow to ensure you're not accidentally injecting the wrong RPU.
Thanks for this. I'll take a look at the FRAMEINFO tool.
I'd already tried CM2.9 unfortunately and I did double check it was the correct RPU I was using. Neither of those worked.
Update: Just tried with the latest version (0.5.1 vs 0.5.0) and it's converted fine. One of the tool updates must have fixed it.
MoonKnight
10th February 2023, 23:54
Hey guys, thanks to all the best that help noobs like us here, thank you really much for all the hard work around HDR10+/DOLBY VISION, you guys deserve the best.
Anyway, Anyone to help me fix my commandline with dovi_tool ?
dovi_tool generate -j RPU.json -o RPU_from_json.bin
gives me this error :
Reading generate config file...
Error: unknown variant `dovi_profile`, expected `V29` or `V40` at line 1 column 16
====
my RPU is cmv2.9 , how can I fix this ? conversion from json to .bin does not want to work...
quietvoid
11th February 2023, 00:52
It's not exactly clear what you're trying to do, but going from an exported JSON (using dovi_tool export) back to a .bin is not supported.
MoonKnight
11th February 2023, 01:41
It's not exactly clear what you're trying to do, but going from an exported JSON (using dovi_tool export) back to a .bin is not supported.
oh ok, my bad then, I thought the conversion was supported
and yes I used export
ckbro
19th February 2023, 05:15
It appears that when I crop the RPU, either during demux or injection, to match sed crops video stream the video stream will slightly speed up and become desynced from the audio track after injection. Any idea what could be going on here?
von Suppé
19th February 2023, 10:26
I wonder if cropping RPU has something to do with the the A/V sync issue. Can be wrong, but it sounds like container timestamps and/or default duration header not being properly written during (mkv) mux.
You can do a manual mux with proper FPS-value forced set in MTX-GUI/mkvmerge to confirm.
Gabu
19th February 2023, 23:55
I need to inject DV to a HDR10 file to make a hybrid.
Could you guys tell me how in steps, please?
Gabu
20th February 2023, 01:01
Moreover, I want to make a hybrid that isn't a UHD remux, but a web based file.
Is the only way to make the inject work converting the profile 5 to 8? Even both files are profiles 5? I tried making an inject but it didn't work; it was green on my TV.
von Suppé
20th February 2023, 08:30
If you mean green/purple colors, that's typical for when P5 colorspace isn't supported. Which is proprietary to Dolby. Are you sure your player can handle it?
Gabu
21st February 2023, 16:31
If you mean green/purple colors, that's typical for when P5 colorspace isn't supported. Which is proprietary to Dolby. Are you sure your player can handle it?
Yeah, I use a Nvidia Shield on a LG CX. The issue probably was that I was trying to leave the profile 5 as is. I learn now that you cannot have hybrids unless you convert to profile 8.
I know, I know I can't have everything handed to me, but does anyone have a tutorial? There's hybrids I wanna make for myself with copies I legally own.
I got close the other day, but it still didn't work just right..
I assume this hybriding method works the same for web dl hybrids and Blu ray hybrids?
GodzilaAvenger
21st February 2023, 19:26
To make a hybrid your base layer should not be Profile 5, since it uses a different color space that is not HDR10 compatible. If you have a base layer that is HDR10 compatible (e.g. from a BluRay) you can demux the RPU from a web source, convert it to Profile 8.1, and inject it into the base layer.
Fuso
23rd February 2023, 11:24
Is there a way to mux DV profile 8 that will work on both newer and older LG OLEDs, and also non-DV compatible tvs, like Samsung? I have LG C2, LG B8, Samsung AU9000. Currently when I mux a MKV profile 8 to MP4 with DDVT_MKVTOMP4 the result is DV playback on the LG C2 and HDR playback on both LG B8 and Samsung AU9000. The file plays on all of the tvs, but the problem is that is not triggering DV on the LG B8. The internal media players are different - B8 can play Proflie 7 mp4, but the C2 plays them in regular HDR. I was trying different methods with other tools and I think the main difference comes from the Coded ID:
LG C2 - DV
LG B8 - HDR
Samsung AU9000 - HDR
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
Codec ID : hev1
LG C2 - DV
LG B8 - DV
Samsung AU9000 - can't play
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
Codec ID : dvhe
LG C2 - DV
LG B8 - DV
Samsung AU9000 - purple and green picture
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : hev1
LG C2 - DV
LG B8 - DV
Samsung AU9000 - can't play
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
Codec ID : dvhe
The thing that bugs me is when P5 is set to hev1 the B8 plays them in DV, not in purple and green base layer colors. But when P8 is set to hev1 the B8 then plays the base HDR layer.
-QfG-
5th March 2023, 10:23
The Samsung support no DV. But in your case, the movies must fallback in the HDR mode (Profile 8). Profile 5 you can't watch. If you have trouble with the fallback feature, simple remove the DV RPU from the stream (REMOVER Script).
Fuso
6th March 2023, 10:33
I know that Samsung don't support DV and that Profile 5 can't be played on it. The thing that bugs me is why the B8 can't play Profile 8 in mp4 container when the Codec ID is hev1. I don't want to strip the DV metadata, I want a file that will play like this:
LG C2 - DV
LG B8 - DV
Samsung AU9000 - HDR
but... I don't think it's possible.
Dragon1981
6th March 2023, 15:24
I know that Samsung don't support DV and that Profile 5 can't be played on it. The thing that bugs me is why the B8 can't play Profile 8 in mp4 container when the Codec ID is hev1. I don't want to strip the DV metadata, I want a file that will play like this:
LG C2 - DV
LG B8 - DV
Samsung AU9000 - HDR
but... I don't think it's possible.
I am looking to get exactly same for my iPhone 12 videos shot in HLG (Dolby Vision).
I normally use Davinci Resolve Studio to get Dolby Vision profile 5.
speedy
8th March 2023, 19:48
Is this tool using the older Mode 5 or the new Mode 2?
Conversion modes
-m, --mode Sets the mode for RPU processing.
Default (no mode) - Copies the RPU untouched.
0 - Parses the RPU, rewrites it untouched.
1 - Converts the RPU to be MEL compatible.
2 - Converts the RPU to be profile 8.1 compatible.
Removes luma/chroma mapping for profile 7 FEL.
3 - Converts profile 5 to 8.1.
4 - Converts to profile 8.4.
5 - Converts to profile 8.1, preserving mapping.
Old mode 2.
Source: https://github.com/quietvoid/dovi_tool#conversion-modes
Also, is it possible to remove luma/chroma mapping for files that were previously converted to Profile 8.1 from Profile 7 FEL with Mode 5 (old Mode 2)? If so, how would I accomplish this?
I've noticed that Profile 7 FEL files that were converted to Profile 8.1 with Mode 5 (old Mode 2) fallback to HDR in the Infuse 7.5 betas (current 7.5.4370). I don't have access to all the original FELs (deleted to save space), but I have converted a few that I kept around with the new Mode 2 (removing luma/chroma mapping) and these seem to register as DoVi in Infuse 7.5.4370.
GodzilaAvenger
9th March 2023, 09:21
Looking at the demuxer code, it uses Mode 2 (-m 2) for conversion to P8.1, so whenever dovi_tool was updated with the new modes so was DDVT.
Have you tried feeding it a P8.1 RPU that was created with the old Mode 2 to see if it creates one that registers as DV in Infuse?
-QfG-
12th March 2023, 07:20
Here a little text from quietvoid itself:
Hey, I'm going to be changing dovi_tool's mode 2 to also do "remove_mapping" by default, for profile 7 FEL only.
By doing so I'll also be adding a new mode 5 for the old behaviour.
The problem with current mode 2 is that everyone's been using it but not necessarily along with remove_mapping.
I've also made it FEL only but AFAIK profile 7 MEL does not have any of the mapping metadata, so it should be the same.
The only cases where the profile 8.1 would be wrong is if someone did a FEL -> MEL -> 8.1 conversion.
I was just wondering if this is a change that would impact your DDVT script at all.
I don't think your scripts currently use `remove_mapping`, so this would impact all mode 2 conversions.
Thanks!
I understand it so, if you convert a P5 file into P8, you don't have Luma/Chroma Mapping inside. Only by converting P7 FEL to P8 you have the Luma/Chroma Mapping inside. But you don't need this, so Mode 2 erased this metadata from the RPU. If you use Mode 2 for P7 MEL or P5 it is the same how the old Mode 2 (new Mode 5).
I've noticed that Profile 7 FEL files that were converted to Profile 8.1 with Mode 5 (old Mode 2) fallback to HDR in the Infuse 7.5 betas (current 7.5.4370). I don't have access to all the original FELs (deleted to save space), but I have converted a few that I kept around with the new Mode 2 (removing luma/chroma mapping) and these seem to register as DoVi in Infuse 7.5.4370.
The infuse Player supports DV, so i think the new Mode 2 is correct and the old Mode 2 (without -remove_mapping switch) not. You can convert the old releases with the new mode 2, i think they will be correctly tagged as DV files.
-v0.52 Online
*Updated dovi_tool to v2.0.3.
*Updated hdr10plus_tool to v1.6.
MiloGNR
15th April 2023, 16:31
Hi. First post on this forum for me :)
I was wondering if someone could explain me how the "Removing Dolby Vision / HDR10+" process works. Recently I have found out that I need to use this tool to remove Dolby Vision from movies that have both Dolby Vision and HDR10+, because my Chromecast won't play said movie in HDR10+.
My poor knowledge on the matter is that Dolby Vision / HDR10+ are layers that go "below" the HDR layer of the file. So, I guess that when I use DDTV_REMOVER, the Dolby Vision layer gets removed from the MKV?
What I want to understand is if some kind of re-encoding to the movie is being done behind the scenes, or if it's just "disassembling" the MKV, removing the Dolby Vision layer and "reconstructing" the MKV again.
How does it work? Am I loosing quality by doing this? I would like to just remove the Dolby Vision layer and keep the HDR10+ one without touching the movie itself or reencoding (as I understand, they are different layers?).
Is this possible? Is there another method to achieve what I need to do?
Thanks!! :)
GodzilaAvenger
15th April 2023, 19:27
As far as I know DDVT_REMOVER only removes the DV Enhancement Layer, it won't touch or re-encode the HDR10 Base Layer or the HDR10+ metadata. Long way of saying DDVT does exactly what you need.
Irek_Ismaren
16th April 2023, 18:56
Hello,
First I'd like to say thank you so much for this tool. I've been having a lot of fun going back through my ripped blu-ray collection and adding Dolby Vision to all my personal encodes.
I do have a couple questions concerning cropping.
Can I always just set the option to crop in the demuxer to [YES]?
Will this affect sources that are perhaps already cropped or don't have black bars at all?
Also... Can you inject an uncropped RPU into a cropped encode?
I've done several where I've cropped the video but didn't crop the RPU. I didn't notice any issues upon playback but was wondering if I needed to go back and redo them.
GodzilaAvenger
16th April 2023, 21:04
Hi,
You may want to look at this discussion we had (https://forum.doom9.org/showthread.php?p=1979519#post1979519) a while back in this thread.
Irek_Ismaren
16th April 2023, 23:15
Thanks GodzilaAvenger,
That helps tremendously!
Sorry I didn't look back far enough. I've read most of this thread up until about 6 months ago, then forgot where I left off.
zomorf
17th April 2023, 06:43
Hi Guys,
Not sure anyone having issues with lockups? I'm running under Windows 10 was using 0.47a I think but just updated over the weekend... Demuxing seems OK but on a few attempts it's locking my system trying to inject the RPU...
At present trying tv shows web-dl DV to inject into HDR web-dl...
GodzilaAvenger
17th April 2023, 07:08
It seems to be working fine for me, though I'm on Windows 11. Can you provide more detail about the freezing? What step causes your system to freeze?
HD MOVIE SOURCE
21st April 2023, 19:40
Just wondering. If I encode something in HDR10 with no available metadata, could I use this program to trigger Dolby Vision with static metadata? So something could play in Dolby Vision with no metadata?
Can you add your own metadata?
I'm new to this, apologies if it's a nooby question.
GodzilaAvenger
22nd April 2023, 18:14
I'm not sure if you can trigger DV with static metadata, but you could use dovi_tool (https://github.com/quietvoid/dovi_tool) (which is the backbone of DDVT) to generate a binary RPU (i.e. metadata) and then use DDVT to inject it into your file. If you only have the static metadata you can set metadata values to be the same across all shots (or frames), though I'm not sure if there would be much (if any) improvement over HDR10.
ntropy
1st May 2023, 04:11
Could there be a checkbox to do a test injection -- ie, a portion of the first few minutes of an injection to see how it looks? My most recent injection applied delay of -7 frames on a 138317 frame mkv with "mux stream in mkv" set to yes and because I'm seeing a brightness timing issue on the transitions I'd like to try -6 or -8 frames just to see if it's better but am getting a bit impatient with the time and hard drive space it takes just to see if something will play with stable DV. Impatient because I've already done +14 and -14 frame passes before ditching MCP-HC and using VirtualDub2 to read the frame differences. What would be ideal if there was a preview mode to test these things in. In this case the 2nd last frame of the Pixar logo lamp appears in the demuxed source at frame 138252 and in the injection target at 138245, so I thought -7 would work. But I'm 12 minutes into watching the result and there are still (smaller but) noticeable brightness shifts around some (not all) transitions. So I'm getting closer on this third try. And maybe this is as close as I'll ever get and perfection is not attainable with my TV? Maybe it is working but my LG B7 isn't fast enough to keep up with injected MKVs on Plex on a Shield Pro? Maybe my LG B7 can only display stable DV from full ISOs played on the M9702 player?
Arkana
1st May 2023, 18:06
Hello, I have hundreds of DV video that need double checked for possibly wrong crop values. Some of them have correct values but many of them are wrong. Is there anything I can do to fix this and saving the time?
GodzilaAvenger
1st May 2023, 19:04
Could there be a checkbox to do a test injection -- ie, a portion of the first few minutes of an injection to see how it looks? My most recent injection applied delay of -7 frames on a 138317 frame mkv with "mux stream in mkv" set to yes and because I'm seeing a brightness timing issue on the transitions I'd like to try -6 or -8 frames just to see if it's better but am getting a bit impatient with the time and hard drive space it takes just to see if something will play with stable DV. Impatient because I've already done +14 and -14 frame passes before ditching MCP-HC and using VirtualDub2 to read the frame differences. What would be ideal if there was a preview mode to test these things in. In this case the 2nd last frame of the Pixar logo lamp appears in the demuxed source at frame 138252 and in the injection target at 138245, so I thought -7 would work. But I'm 12 minutes into watching the result and there are still (smaller but) noticeable brightness shifts around some (not all) transitions. So I'm getting closer on this third try. And maybe this is as close as I'll ever get and perfection is not attainable with my TV? Maybe it is working but my LG B7 isn't fast enough to keep up with injected MKVs on Plex on a Shield Pro? Maybe my LG B7 can only display stable DV from full ISOs played on the M9702 player?
Instead of this process of repeated trial and error, you can use the FRAMEINFO tool with the RPU and enter ALL to get a list of the scene cuts (list of the starting frame of new scenes). Then, use a software like DJV to see how much delay you need to apply to the RPU to align the RPU scene cuts with the video. If you use DJV the starting frame is 1 whereas in DDVT it's 0 so keep that in mind.
ntropy
2nd May 2023, 07:10
Instead of this process of repeated trial and error, you can use the FRAMEINFO tool with the RPU and enter ALL to get a list of the scene cuts (list of the starting frame of new scenes). Then, use a software like DJV to see how much delay you need to apply to the RPU to align the RPU scene cuts with the video. If you use DJV the starting frame is 1 whereas in DDVT it's 0 so keep that in mind.
I tried FRAMEINFO and it created a .json file but scrolling through the file I didn't see any frame ranges (like 0-100 or 101-2000) under each "header" key so I assumed that each header was representing 1 frame each and not representing the scene cuts I had hoped to find using the FRAMEINFO tool. There were a lot of of "header" keys, more than VSCode could enumerate on a Find query. I think it stopped at 19999, which seems like more like apporoaching a frame count than a scene count. I deleted the .json so I can't check now. I'll make another one but this is such a slow process.
GodzilaAvenger
2nd May 2023, 07:56
When you use FRAMEINFO and enter ALL it generates two files, one has the frame-by-frame DV metadata info (usually 1GB or more in size). The other (I think named [all scene cuts].json or something similar) is just a list of numbers, i.e. starting frame of each scene. You should use this latter file.
ntropy
2nd May 2023, 10:16
Instead of this process of repeated trial and error, you can use the FRAMEINFO tool with the RPU and enter ALL to get a list of the scene cuts (list of the starting frame of new scenes). Then, use a software like DJV to see how much delay you need to apply to the RPU to align the RPU scene cuts with the video. If you use DJV the starting frame is 1 whereas in DDVT it's 0 so keep that in mind.
When you use FRAMEINFO and enter ALL it generates two files, one has the frame-by-frame DV metadata info (usually 1GB or more in size). The other (I think named [all scene cuts].json or something similar) is just a list of numbers, i.e. starting frame of each scene. You should use this latter file.
I see. Looking at the RPU_[All Scene Cuts].json numbers on a different .mkv hybrid, the frames appear to be happening in the right places when I compare on VirtualDub2 (which starts on frame 0).
But here are two frame numbers which appear in the right place for the *start* of two scenes, but the playback has brightening artifacts on the outgoing and incoming frame of each cut.
5843 - starting frame of close up of actor
5864 - starting frame of medium wide shot of car
I've created a video only mkv of the first 5 minutes of the movie with MKVToolNix and I'll try applying a 1 frame positive delay on that.
Update: created both 1 frame positive and 1 frame negative delay mkvs of first 5 minute.
A) Original full length mkv still had brightness shifts at most cuts, but they seemed less severe now.
B) Five minute video only mkv (no injection applied) had milder brightness shifts on fewer cuts.
C) Five minute video only mkv with positive delay injection looked the same as B.
D) Five minute video only mkv with negative delay injection looked the worse and the brightness shifts looked dark instead of light at the cuts.
If the scene changes are happening on the correct frames, could the culprit be the HDMI cables connecting the Shield Pro -> Denon AVR -> LG B7? When Shield Pro DV mkv brightness shifts happened in the past on other mkvs, I swapped M9702 player HDMI cable with the Shield Pro cable without seeing any improvement, but maybe that was an mkv with bad scene change RPU. Or maybe the Shield Pro is more sensitive to HDMI cable quality than the M9702. I dunno. Or maybe this combo of AVR + TV can't lock reliably onto the Shield Pro's DV mkv playback as it can onto M9702 DV ISO playback.
Interesting that the RPU was pulled from the MKV and the Borders don't match.
== VIDEO INPUT =========================================================================================================
Borders = [LEFT=128 px], [TOP=0 px], [RIGHT=128 px], [BOTTOM=0 px] [NOT MATCH WITH RPU]
== RPU INPUT ===========================================================================================================
Filename = [RPU.bin]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 7199]
Borders = [LEFT=126 px], [TOP=0 px], [RIGHT=126 px], [BOTTOM=0 px] [NOT MATCH WITH VIDEO]
GodzilaAvenger
3rd May 2023, 06:58
Is B) just the HDR10 file? If so, the brightness shifts may be coming from the base layer and not the DV layer.
Aliging scene cuts with the RPU is necessary but may not be sufficient. If you want to make sure the problem is not coming from the RPU you can look at the RPU_[All Frame Info].json file for that frame range. Specifically, for those frames look at the min_pq, avg_pq, and max_pq values, AKA the L1 metadata (if you want to know more Google "Dolby Vision Metadata Levels") that define scene brightness. They should be identical for all frames of each scene. If they are not, then you may have a faulty RPU and that explains the brightness shifts. If they are, the problem is likely from something other than the RPU.
DDVT is sometimes a few pixels off when detecting borders, so it's not always reliable. I have a 4K monitor so I use the Screen Ruler of PowerToys on Windows to get the borders.
ntropy
3rd May 2023, 22:28
Is B) just the HDR10 file? If so, the brightness shifts may be coming from the base layer and not the DV layer.
Aliging scene cuts with the RPU is necessary but may not be sufficient. If you want to make sure the problem is not coming from the RPU you can look at the RPU_[All Frame Info].json file for that frame range. Specifically, for those frames look at the min_pq, avg_pq, and max_pq values, AKA the L1 metadata (if you want to know more Google "Dolby Vision Metadata Levels") that define scene brightness. They should be identical for all frames of each scene. If they are not, then you may have a faulty RPU and that explains the brightness shifts. If they are, the problem is likely from something other than the RPU.
DDVT is sometimes a few pixels off when detecting borders, so it's not always reliable. I have a 4K monitor so I use the Screen Ruler of PowerToys on Windows to get the borders.
B) is DV and when I tried playing using my B7's internal player it defaulted to HDR10 and there were no brightness jumps on the cuts so the HDR10 is fine.
The cut I'm examining is 5909 listed in [All Scene Cuts].json
So at the 5909th instance of "Level1" (and 5908th, 5907th) in [All Frames Info].json we have:
{
"Level1": {
"min_pq": 2,
"max_pq": 3311,
"avg_pq": 1674
}
At 5910th (and 5911th, 5912th) we have:
{
"Level1": {
"min_pq": 12,
"max_pq": 2817,
"avg_pq": 1636
}
So it looks like the RPU is fine?
GodzilaAvenger
4th May 2023, 02:54
No, the RPU seems faulty. The frame numbers listed in RPU_[All Scene Cuts].json are the starting frame numbers of each scene, which you can double check by looking at the scene_refresh_flag value (it should be 1 for frame 5909). In other words the pq values should be the same for frames 5909, 5910, 5911 etc. since they belong to the same scene, but different from 5908, 5907, etc.
I'm not sure how to fix this but the only tool that may help you is dovi_tool, which you can find in the tools folder of DDVT. You could make changes to the RPU_[All Frame Info].json file and generate a new RPU binary using it. Alternatively, you could use dovi_tool's editor functionality. You may also want to look at a different source for the RPU.
ntropy
4th May 2023, 04:40
No, the RPU seems faulty. The frame numbers listed in RPU_[All Scene Cuts].json are the starting frame numbers of each scene, which you can double check by looking at the scene_refresh_flag value (it should be 1 for frame 5909). In other words the pq values should be the same for frames 5909, 5910, 5911 etc. since they belong to the same scene, but different from 5908, 5907, etc.
I'm not sure how to fix this but the only tool that may help you is dovi_tool, which you can find in the tools folder of DDVT. You could make changes to the RPU_[All Frame Info].json file and generate a new RPU binary using it. Alternatively, you could use dovi_tool's editor functionality. You may also want to look at a different source for the RPU.
The 5910th instance of "scene_refresh_flag" is:
"scene_refresh_flag": 1,
Which I think means it is working, because the 1st instance of "scene_refresh_flag" would be frame 0 -- you have to subtract 1, right? So the 5910th instance in the document is frame 5909. This would be much more straighforward if they put the frame number in the .json.
GodzilaAvenger
4th May 2023, 06:01
Yeah, right. I thought it was frame 5910. In that case the RPU seems fine to me. The problem is likely coming from your setup then.
-v0.53 Online.
*Updated FFMPEG to N-110509-g722ff74055-20230506
*Updated MP4Box to 2.2-rev0-gab012bbfb
*Updated mkvtoolnix to v 75.0.0.0.
von Suppé
8th May 2023, 08:04
Thanks for the new release :)
Amateur
12th May 2023, 00:51
I got this error when trying to create an RPU. "Please wait. Extracting the Video Layer ...
Exporting HEVC Video - Size 3840x2160
[IsoMedia] Track #1 fail to fetch sample 45927 / 151622: Invalid IsoMedia File== | (23/100)
Done." The whole file can play just fine so I don't know why there is an error.
You can also set negative delay. If, for example, frame 8 of the RPU corresponds to frame 0 of BluRay, set a -8 delay, which tells DDVT to remove the first 8 frames of the RPU.
Edit: same as what -QfG- said!
To piggy back onto this, I just want to make sure I'm understanding it correctly.
HDR frame 2525 = DV frame 2527
So for the delay I would set it to -2?
hidef_rec
12th May 2023, 18:06
-v0.53 Online.
*Updated FFMPEG to N-110509-g722ff74055-20230506
*Updated MP4Box to 2.2-rev0-gab012bbfb
*Updated mkvtoolnix to v 75.0.0.0.
Thank you @-QfG-, your tool is invaluable. I use it at least weekly, if not more.
GodzilaAvenger
12th May 2023, 18:12
To piggy back onto this, I just want to make sure I'm understanding it correctly.
HDR frame 2525 = DV frame 2527
So for the delay I would set it to -2?
Yes...
GHOSTWRiTAZ
14th May 2023, 17:54
Hi all,
Thanks for this amazing batch scripts of DDVT Tools, much appreciated!
I do have question regarding the correct setting to add borders.
I'm using DDVT_DEMUXER.cmd to extract the RPU.bin from the video file.
Below the video details, the main goal is to add borders from source video resolution 3840 x 1600 pixels to 3840 x 2160 pixels, meaning I will have to add 280x pixels top and bottom for proper playback otherwise the cropped borders of resolution 1600 pixels will cause dark grey borders on top and bottom due to DV stream enabled.
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 2 h 3 min
Bit rate : 14.7 Mb/s
Width : 3 840 pixels
Height : 1 600 pixels
Display aspect ratio : 2.40:1
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.100
Stream size : 12.7 GiB (95%)
Language : English (US)
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 1000 cd/m2
Maximum Frame-Average Light Level : 142 cd/m2
for custom.json I'm using the following code:
{
"mode": 0,
"active_area": {
"crop": true,
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 280,
"bottom": 280
}
],
"edits": {
"0-40": 0
}
}
}
The custom.json file is located in the same folder as the video.mkv and RPU.bin
after the DDVT_INJECTOR.cmd process I'm still getting the same results 3840x1600 ?
Am I missing some steps here or what am I doing wrong. Any help on the matter is greatly appreciated. Thanks.
GodzilaAvenger
14th May 2023, 18:06
Hi,
With this custom.json file you are only applying the edits to the first 40 frames.
If the film's aspect ratio does not change you don't need a custom.json file, delete it and just use the INJECTOR script with the RPU and set the borders in the DDVT interface.
GHOSTWRiTAZ
15th May 2023, 19:49
Hi GodzilaAvenger,
Thank you for the swift reply.
Unfortunately I already tried that, the results are the same :(
Below the settings that I used:
Step 1:
https://thumbs4.imagebam.com/92/2d/cd/MEKVCKN_t.png (https://www.imagebam.com/view/MEKVCKN)
Step 2:
https://thumbs4.imagebam.com/4d/b3/ce/MEKVCN6_t.png (https://www.imagebam.com/view/MEKVCN6)
Step 3:
https://thumbs4.imagebam.com/d4/4c/9d/MEKVCQK_t.png (https://www.imagebam.com/view/MEKVCQK)
Step 4:
https://thumbs4.imagebam.com/f7/b1/17/MEKVCR8_t.png (https://www.imagebam.com/view/MEKVCR8)
Result remains the same 3840x1600 pixels (cropped/same as source without cinematic black bars/borders)
https://thumbs4.imagebam.com/a1/0e/66/MEKVCTL_t.jpg (https://www.imagebam.com/view/MEKVCTL)
What I wish to achieve is 3840x2160 pixels (aspect ratio remains the same but cinematic black bars/borders are added during the DDVT Injector process)
https://thumbs4.imagebam.com/c6/71/6b/MEKVCVF_t.jpg (https://www.imagebam.com/view/MEKVCVF)
Again any help on the matter is greatly appreciated. Thanks
GodzilaAvenger
16th May 2023, 02:56
Ok, got it. DDVT can't letterbox a cropped .mkv file (add top and bottom black bars). It is only meant for handling dynamic metadata (Dolby Vision/HDR10+). If your .mkv file is 3840x1600, you should set the borders in the RPU to 0, as it originally was.
If you want to letterbox a video you need to use FFmpeg. For instance, see this (https://video.stackexchange.com/questions/25960/ffmpeg-how-can-i-add-black-bars-to-top-and-bottom-of-my-video) and this (https://stackoverflow.com/questions/61703587/proper-way-to-letterbox-with-ffmpeg) on how to do it. If you do this and get a 3840x2160 .mkv, then you have to adjust the RPU borders as well (set top and bottom to 280).
GHOSTWRiTAZ
21st May 2023, 18:26
Ok, got it. DDVT can't letterbox a cropped .mkv file (add top and bottom black bars). It is only meant for handling dynamic metadata (Dolby Vision/HDR10+). If your .mkv file is 3840x1600, you should set the borders in the RPU to 0, as it originally was.
If you want to letterbox a video you need to use FFmpeg. For instance, see this (https://video.stackexchange.com/questions/25960/ffmpeg-how-can-i-add-black-bars-to-top-and-bottom-of-my-video) and this (https://stackoverflow.com/questions/61703587/proper-way-to-letterbox-with-ffmpeg) on how to do it. If you do this and get a 3840x2160 .mkv, then you have to adjust the RPU borders as well (set top and bottom to 280).
Hi GodzilaAvenger,
I was under the assumption that it actually was possible, so I misunderstood/misread post #281 (https://forum.doom9.org/showpost.php?p=1972998&postcount=281) and #297 (https://forum.doom9.org/showpost.php?p=1973230&postcount=297)
Meaning what I want to achieve is simply not possible without ffmpeg processing if the source is cropped 3840x1600 I will have to transcode it using ffmpeg filter to 3840x2160 pixels, which may result in loss of quality. Thanks for clarifying
GodzilaAvenger
21st May 2023, 23:22
I highly doubt letterboxing using FFmpeg would result in loss of quality. Even if it did, the loss would be imperceptible.
guest
22nd May 2023, 06:48
As the title suggests ???
-QfG-
22nd May 2023, 20:47
-v0.54
*NEW New Script included (DDVT_Hybrid) for fast creating DV Profile 8.1 Hybrid Releases.
*INJECTOR-Function to change correctly the video framerate. Also included in HYBRID Script.
*Updated mkvtoolnix to v 76.0.0.0.
- SCRIPT <DDVT_HYBRID.cmd>
DESCRIPTION:
------------
Simple quick script to create a DV Profile 8 Hybrid Release. Only add HDR
and DV File (No RAW file Support, only MKV/MP4 Container) set the options
and Go. Completely simplified and the fastest script to Build P 8.1 Files.
Also you can Input only a HDR10+ file without DV Input file and you create
a Profile 8.1 DV file based on the HDR10+ Metadata.
USAGE:
------
DDVT_HYBRID
guest
24th May 2023, 04:39
I have just asked this question on the x265 thread
https://forum.doom9.org/showthread.php?p=1987516#post1987516
Does this make any sense to anyone here ??
Is there still and option to remove the HDR10 metadata ?? I could only see how to remove the DV metadata.
von Suppé
24th May 2023, 09:39
As TDS described in your linked thread, removing HDR metadata can render a device to not play the baselayer correctly. May I ask why you want to remove HDR metadata when video is HDR encoded?
guest
24th May 2023, 12:10
As TDS described in your linked thread, removing HDR metadata can render a device to not play the baselayer correctly. May I ask why you want to remove HDR metadata when video is HDR encoded?
TBH, I don't know if I need to be removing it, it's just that I am trying to figure out how to encode Dolby Vision, seems that most are Hybrid's.
Go here:- https://forum.doom9.org/showthread.php?p=1987477#post1987477 to see what I have been trying.
The difference between HDR Hybrid & and DV seems to be this :-
Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
and
Dolby Vision, Version 1.0, dvhe.08.06
SeeMoreDigital
24th May 2023, 12:48
Is there still and option to remove the HDR10 metadata ?? I could only see how to remove the DV metadata...May I ask why you want to remove HDR metadata when video is HDR encoded?
If nothing else it would make an interesting addition for the completists!
dawid1991
24th May 2023, 18:08
hi how to convert dolby vision to hdr10+? i have a samsung and i would really need it?
hidef_rec
24th May 2023, 18:23
Had asked that before; don't believe it's doable.
----------
Thanks @-QfG- for the new version. Just tried DDVT_HYBRID, but when I drag-and-drop a HDR file (my sample is HDR10+ w/o DV) or any HDR file, nothing happens, it doesn't drop in. Am I doing something wrong?
https://i.imgur.com/s2j15zX.jpg
GodzilaAvenger
24th May 2023, 19:25
TBH, I don't know if I need to be removing it, it's just that I am trying to figure out how to encode Dolby Vision, seems that most are Hybrid's.
Go here:- https://forum.doom9.org/showthread.php?p=1987477#post1987477 to see what I have been trying.
The difference between HDR Hybrid & and DV seems to be this :-
Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
and
Dolby Vision, Version 1.0, dvhe.08.06
Triggering DV also depends on the playback device and video container. For example if I remember correctly DV playback on an LG TV's internal media player using .mkv is not possible and it has to be .mp4.
SeeMoreDigital
24th May 2023, 19:33
For example if I remember correctly DV playback on an LG TV's internal media player using .mkv is not possible and it has to be .mp4.Correct. Although some people have had some level of success muxing Dolby Vision encoded content into .ts/.m2ts ;)
-QfG-
24th May 2023, 19:50
Is there still and option to remove the HDR10 metadata ?? I could only see how to remove the DV metadata.
You can not Remove "HDR Metadata" because they don't exist. HDR is a fixed included colorrange, you can remove only HDR10+ Metadata.
-QfG-
24th May 2023, 19:53
Thanks @-QfG- for the new version. Just tried DDVT_HYBRID, but when I drag-and-drop a HDR file (my sample is HDR10+ w/o DV) or any HDR file, nothing happens, it doesn't drop in. Am I doing something wrong?
it looks so, that W11 don't support drag and drop :( I use W10 and have no problems with drag and drop. Will search for a solution.
-QfG-
24th May 2023, 19:56
hi how to convert dolby vision to hdr10+? i have a samsung and i would really need it?
There is no solution yet to doing this.
dawid1991
24th May 2023, 21:40
Does anyone know if there is any bluray player 4k that plays 100gb r/rw discs?
SeeMoreDigital
24th May 2023, 21:49
Does anyone know if there is any bluray player 4k that plays 100gb r/rw discs?Out of interest...
Which 100GB (triple layer BDXL) 4K UHD disc movies do you have?
GHOSTWRiTAZ
24th May 2023, 22:44
Out of interest...
Which 100GB (triple layer BDXL) 4K UHD disc movies do you have?
List of 4K UHDs BD-100 Link (https://forum.blu-ray.com/showthread.php?t=294596)
GHOSTWRiTAZ
24th May 2023, 22:46
Does anyone know if there is any bluray player 4k that plays 100gb r/rw discs?
Panasonic DP-UB9000/UB9004
Oppo UDP-203/205
Magnetar UDP800 (a.k.a. Oppo clones)
Reavon UBR-X100/X200 (a.k.a. Oppo clones)
Emulgator
24th May 2023, 23:47
Oppo UDP-203/205: Can not confirm. I tried and had no success.
But I will repeat that sooner or later.
guest
25th May 2023, 04:58
Triggering DV also depends on the playback device and video container. For example if I remember correctly DV playback on an LG TV's internal media player using .mkv is not possible and it has to be .mp4.
Thanks for that info, I had read somewhere that mkv didn't carry it..
The app I used to encode only output's x265 as an .mkv :(, I might have to run it thru DDVT to convert to mp4. Is there another way ??
Interesting side note, the couple of DV test samples I downloaded for an LG TV, where .ts files...(they display the Dolby Vision banner).
Cheers
GodzilaAvenger
25th May 2023, 05:29
DDVT_MKVTOMP4 is probably your best bet, it uses FFmpeg under the hood but is a lot more intuitive.
GodzilaAvenger
25th May 2023, 05:40
hi how to convert dolby vision to hdr10+? i have a samsung and i would really need it?
Since DV is proprietary there is currently no (free) way of doing this.
I don't condone piracy but if you have bought a DV Blu-ray, especially if it's of a newer film, you can probably find a WEB-DL release of that film with HDR10+ metadata (look at the MediaInfo). Demux that metadata from the WEB-DL source and inject it into the Blu-ray file, just make sure the metadata frame numbers are aligned with the film (they're usually not, you have to look at the scene cut frame numbers and their corresponding value in the metadata to figure out how much (positive or negative) delay to use).
guest
25th May 2023, 07:20
DDVT_MKVTOMP4 is probably your best bet, it uses FFmpeg under the hood but is a lot more intuitive.
:thanks: I will definitely give that a try, once I've done a bit more homework with the actual encoding side of things..got lots of different settings to try :)
dawid1991
25th May 2023, 08:20
Oppo UDP-203/205: Can not confirm. I tried and had no success.
But I will repeat that sooner or later.
on my ub9000 too no support bd xl...
-QfG-
25th May 2023, 21:18
Hello, I have hundreds of DV video that need double checked for possibly wrong crop values. Some of them have correct values but many of them are wrong. Is there anything I can do to fix this and saving the time?
Simply use DDVT_DEMUXER. If you open a DV P8 with the Demuxer, you have a "CHECK RELEASE" option. With this option you can fix bad borders.
https://i.imgur.com/ni32q8t.png
https://i.imgur.com/V86Inry.png
guest
26th May 2023, 06:07
@ -QfG-,
As the risk of repeating myself (from back on the RipBot thread),
here (https://forum.doom9.org/showthread.php?p=1987445#post1987445)
and this thread:-
and here (https://forum.doom9.org/showthread.php?p=1987538#post1987538)
I have a few "Hybrid" DV clips that will not play via USB on my LG TV, and 1 clip that does.
See examples (MediaInfo info)
John Wick (mkv)
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@High
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 2 h 49 min
Bit rate : 23.7 Mb/s
Width : 3 828 pixels
Height : 1 592 pixels
Display aspect ratio : 2.40:1
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.162
Stream size : 28.1 GiB (95%)
Language : English
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : BT.2020
Mastering display luminance : min: 0.0050 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 2458 cd/m2
Maximum Frame-Average Light Level : 636 cd/m2
The Lord of the Rings.The Rings of Power (mkv)
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 1 h 5 min
Bit rate : 3 231 kb/s
Width : 3 840 pixels
Height : 1 600 pixels
Display aspect ratio : 2.40:1
Frame rate mode : Constant
Frame rate : 24.000 FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.022
Stream size : 1.48 GiB (94%)
Language : English
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 173 cd/m2
Maximum Frame-Average Light Level : 171 cd/m2
The Old Guard (mkv)
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 2 h 5 min
Bit rate : 15.1 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 24.000 FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.076
Stream size : 13.3 GiB (93%)
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 738 cd/m2
Maximum Frame-Average Light Level : 287 cd/m2
LG Dolby Vision test sample (.ts format)
Video
ID : 33 (0x21)
Menu ID : 2 (0x2)
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : Dolby Vision, Version 1.0, dvhe.04.06, BL+EL+RPU
Codec ID : 36
Duration : 1 min 19 s
Bit rate : 29.6 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio : 16:9
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.149
Stream size : 282 MiB (92%)
So if you can't guess which one is the clip's plays & displays the Dolby Vision logo in the top right corner of the screen, it's the bottom one.
Surely there has to be a way to "transform" this :-
Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible which falls back to HDR10 on playback.
to this, which DOES display Dolby Vision on playback :-
Dolby Vision, Version 1.0, dvhe.04.06, BL+EL+RPU
If DDVT could remove that HDR10 compatibility "function", I think the job's done :)
What do you think, is that something that could be done ??
Apologies if this has been explained before :(
GodzilaAvenger
26th May 2023, 08:21
I don't know why I have to repeat this but .mkv files don't trigger Dolby Vision on LG TVs, but .mp4, .ts, and .m2ts do (https://www.reddit.com/r/LGOLED/comments/r3iczk/lg_c1_55_dolby_vision_mkv_versus_mp4_files/). Converting the Rings of Power file to .mp4 will only take minutes even on a laptop (don't pirate BTW). It almost certainly has nothing to do with the DV profile or HDR10 backwards compatibility.
I look forward to -QfG-'s response, but as far as I know, the answer is no. In dovi_tool (https://github.com/quietvoid/dovi_tool) (which is the backbone of DDVT) conversion to Profile 4 is not possible. I encourage you to read up on HDR10 and Dolby Vision Profiles and Levels (https://professionalsupport.dolby.com/s/article/What-is-Dolby-Vision-Profile?language=en_US), that should clarify a lot of things.
SeeMoreDigital
26th May 2023, 09:43
I don't know why I have to repeat this but .mkv files don't trigger Dolby Vision on LG TVs, but .mp4, .ts, and .m2ts do (https://www.reddit.com/r/LGOLED/comments/r3iczk/lg_c1_55_dolby_vision_mkv_versus_mp4_files/).
It really is like banging your head against a brick wall :eek:
Essentially, Matroska will need to develop an entirely new file parser to handle Dolby Vision.mkv muxes as the current parser (built into all our televisions and many other playback devices) doesn't understand them!
guest
26th May 2023, 09:48
I don't know why I have to repeat this but .mkv files don't trigger Dolby Vision on LG TVs, but .mp4, .ts, and .m2ts do (https://www.reddit.com/r/LGOLED/comments/r3iczk/lg_c1_55_dolby_vision_mkv_versus_mp4_files/). Converting the Rings of Power file to .mp4 will only take minutes even on a laptop (don't pirate BTW). It almost certainly has nothing to do with the DV profile or HDR10 backwards compatibility.
I look forward to -QfG-'s response, but as far as I know, the answer is no. In dovi_tool (https://github.com/quietvoid/dovi_tool) (which is the backbone of DDVT) conversion to Profile 4 is not possible. I encourage you to read up on HDR10 and Dolby Vision Profiles and Levels (https://professionalsupport.dolby.com/s/article/What-is-Dolby-Vision-Profile?language=en_US), that should clarify a lot of things.
Well, you won't have to repeat yourself again (hopefully)
I am VERY, VERY new to this process, so don't be too harsh :)
I have learnt that LG's DO only work off the format's you mentioned, I have converted a couple of the "hybrid" types to .mp4, but instead of test playing them on the LG, I check the MediaInfo, and see the HDR Format is still unchanged, so I don't bother to go any further, and what confuses me more is the MediaInfo of the LG DV test file (despite it's low DV Profile).
So if I convert these .mkv's to .mp4 with DDVT, regardless of the HDR Format, if' it's .mp4 it should play & display the Dolby Vision logo on the LG TV...
I will definitely go that one more step after the conversion, to do a test play.
Thanks & sorry.
UPDATE:-
I just converted this one to .mp4 using DDVT, and guess what, it still plays in HDR10
John Wick (mkv)
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@High
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 2 h 49 min
Bit rate : 23.7 Mb/s
Width : 3 828 pixels
Height : 1 592 pixels
Display aspect ratio : 2.40:1
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.162
Stream size : 28.1 GiB (95%)
Language : English
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : BT.2020
Mastering display luminance : min: 0.0050 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 2458 cd/m2
Maximum Frame-Average Light Level : 636 cd/m2
After conversion..
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
I think it might need to be changed to DV Profile 5...
SORTED, (see below)
Thanks for your help.
guest
26th May 2023, 09:53
It really is like banging your head against a brick wall :eek:
Don't you mean like this .... https://www.cosgan.de/images/midi/boese/k035.gif
Give me a break, I'm new at this DV stuff...
And what, you didn't have to keep asking "dumb" questions when you started your doom9 journey some 20 years ago ??
I have both an HDR and DV file. DV has more bitrate than HDR, but frames, length are the same, same source.
Can anyone tell me how to put the HDR metadata into the DV file with bigger bitrate to make a hybrid?
-QfG-
26th May 2023, 15:24
Dolby Vision, Version 1.0, dvhe.04.06, BL+EL+RPU
Very exotic DV Profile. Recommended to convert this to profile 8 (BL+RPU) for maximum compatibility.
I think it might need to be changed to DV Profile 5...
You cannot Change Profile 4/7/8 to Profile 5, because the BL Colorspace of P5 is BT.2100 and P8 BT.2020.
I just converted this one to .mp4 using DDVT, and guess what, it still plays in HDR10
Remove HDR10+ Metadata with the remover. Some HDR10+ files dosn't work correctly (No Solution yet)
@TDS:
--level 6.2 --profile main10 --hdr10 --hdr-opt
Why using h265 level 6.2 instead of 5.1@High?
The line i used for UHD compatible Encodes is:
--crf 16 --preset veryslow --profile main10 --colorprim bt2020 --colormatrix bt2020nc --transfer smpte2084 --range limited --level-idc 5.1 --rd 6 --rd-refine --rdoq-level 1 --psy-rdoq 4 --psy-rd 2 --tu-intra 1 --tu-inter 1 --limit-tu 0 --sar 1 --aq-mode 1 --qcomp 0.7 --ref 4 --bframes 4 --selective-sao 0 --rskip 0 --no-open-gop --no-info --no-sao --no-rect --no-amp --hme-search umh,umh,star --hme --repeat-headers --aud --uhd-bd --min-keyint 1 --keyint 24 --hrd --vbv-bufsize 80000 --vbv-maxrate 90000 --hdr --output-depth 10 --hdr-opt
guest
26th May 2023, 15:31
Very exotic DV Profile. Recommended to convert this to profile 8 (BL+RPU) for maximum compatibility.
You cannot Change Profile 4/7/8 to Profile 5, because the BL Colorspace of P5 is BT.2100 and P8 BT.2020.
Remove HDR10+ Metadata with the remover. Some HDR10+ files dosn't work correctly (No Solution yet)
@TDS:
Why using h265 level 6.2 instead of 5.1@High?
The line i used for UHD compatible Encodes is:
I just cracked it, I simply (after days of fiddling) used tsmuxer, remuxed to .m2ts file, and it's displaying Dolby Vision the LG TV.
-QfG-
26th May 2023, 15:37
Nice that m2ts works correctly with HDR10+ Profile B Metadata. I know that any files with included HDR10+ metadata in mp4/mkv container will not work correctly.
But i never found out why, some files works other not. :(
guest
26th May 2023, 15:50
Nice that m2ts works correctly with HDR10+ Profile B Metadata. I know that any files with included HDR10+ metadata in mp4/mkv container will not work correctly.
But i never found out why, some files works other not. :(
Yes, I'm pretty happy that it worked...I just happened to stumble onto a thread ,(somewhere)..this guy said he'd tried everything, almost gave up, then tried good old tsmuxer......and he had an LG TV as well.
Is this something that could be incorporated into DDVT ?
guest
27th May 2023, 03:45
I'm sure this has been asked here or somewhere a LOT, but is there a way to convert HDR10 to HDR10+, and then use that "new" HDR10+ to create a Hybrid DV video ??
Also, are there any plans to have all the DDVT options as Drag 'n' Drop (like the new Hybrid option) ??, makes it SO much easier :)
Question about the Hybrid option, it asks for a HDR & DV file ???
What's that about ??
SeeMoreDigital
27th May 2023, 10:01
Nice that m2ts works correctly with HDR10+ Profile B Metadata. I know that any files with included HDR10+ metadata in mp4/mkv container will not work correctly.
But i never found out why, some files works other not. :(Yes, I'm pretty happy that it worked...I just happened to stumble onto a thread ,(somewhere)..this guy said he'd tried everything, almost gave up, then tried good old tsmuxer......and he had an LG TV as well.
Eh!? LG televisions don't support HDR10+ decoding. In much the same way, Samsung televisions don't support Dolby Vision decoding. They should both fall back to playing regular HDR10...
I have both an HDR and DV file. DV has more bitrate than HDR, but frames, length are the same, same source.
Can anyone tell me how to put the HDR metadata into the DV file with bigger bitrate to make a hybrid?
I know it's just one day and I know I insist, but if anyone could really help me out, I'd appreciate it. I know how to make a hybrid as in adding DV to HDR, but not the other way around. Is it not possible?
GodzilaAvenger
27th May 2023, 18:58
I'm assuming your DV file is Profile 5. Profile 5 color space is different from that of HDR (IPTPQc2 which is Dolby proprietary vs BT.2020), so I don't think there is an easy way for you to make a Profile 5 HDR compatible. BTW the difference in bitrate almost certainly won't be noticeable during playback, unless one is 50 Mbps and the other 2 Mbps.
GodzilaAvenger
27th May 2023, 19:10
I'm sure this has been asked here or somewhere a LOT, but is there a way to convert HDR10 to HDR10+, and then use that "new" HDR10+ to create a Hybrid DV video ??
HDR10+ (https://en.wikipedia.org/wiki/HDR10%2B)
HDR10+ signals the dynamic range and scene characteristics on a scene-by-scene or even frame-by-frame basis. The display device then uses the dynamic metadata to apply an appropriate tone map through the process of dynamic tone mapping. Dynamic tone mapping differs from static tone mapping by applying a different tone curve from scene-to-scene rather than use a single tone curve for an entire video.
For offline and video-on-demand (VOD) (e.g. ultra-high-definition Blu-ray, over-the-top (OTT), multi-channel video programming distributor (MVPD)), HDR10+ metadata may be created during the post-production, mastering process or during transcoding/encoding for distribution back-ends by HDR10+ content generation tools in two steps,
1. Identifying scene cuts, and
2. Performing an image analysis on each scene or frame to derive statistics
HDR10+ metadata is interchanged through a low complexity JSON-structured text file, which is then parsed and injected into video files.
Question about the Hybrid option, it asks for a HDR & DV file ???
What's that about ??
Dolby Vision Hybrids (https://forum.videohelp.com/threads/406498-Dolby-Vision-Hybrids?mode=hybrid)
I'm assuming your DV file is Profile 5. Profile 5 color space is different from that of HDR (IPTPQc2 which is Dolby proprietary vs BT.2020), so I don't think there is an easy way for you to make a Profile 5 HDR compatible. BTW the difference in bitrate almost certainly won't be noticeable during playback, unless one is 50 Mbps and the other 2 Mbps.
Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
GodzilaAvenger
27th May 2023, 20:19
Yep, it's Profile 5.
Yep, it's Profile 5.
Well, crap. Guess I'll have to keep two versions then.
Thanks for your help, by the way :)
GodzilaAvenger
28th May 2023, 00:05
You could extract the RPU from the DV, convert it to Profile 8.1 and inject it into the HDR to get a hybrid HDR10 DV, that way you won't have to keep both files. That's if you're OK with the lower bitrate of the HDR one.
-QfG-
28th May 2023, 20:44
Also, are there any plans to have all the DDVT options as Drag 'n' Drop (like the new Hybrid option) ??, makes it SO much easier
Yes. Working on an enhanced All in One Script. Takes only some time ...
guest
3rd June 2023, 02:57
I am having some interesting issues retaining the DV info during a remux from .mkv to .m2ts using FFMPEG.
So instead of doubling up posts, please see here :-
https://forum.doom9.org/showthread.php?p=1987967#post1987967
Any suggestions ?
Thanks
kallekill
8th June 2023, 18:22
I have a mkv-file with the following HDR info:
HDR Info = [Dolby Vision, Version 1.0, dvhe.08.07, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible]
Is it possible to remove the HDR10 data from the file, so that it only contains Dolby Vision HDR data?
GodzilaAvenger
8th June 2023, 18:45
AFAIK Profile 8 DV is by design backwards compatible with HDR10. Profile 5 isn't, but then you have to convert the RPU to Profile 5 and the color space of the video itself to Dolby proprietary IPTPQc2, and I don't think there's an easy way of doing so.
-QfG-
8th June 2023, 23:26
-v0.55 Online
*NEW Checking and repairing MKV Container during muxing.
*Updated mkvtoolnix to v 77.0.0.0.
*Major Bugfixes.
*Reworked Shell Extensions (Hybrid P8 Script now in Shell Background).
Is it possible to remove the HDR10 data from the file, so that it only contains Dolby Vision HDR data?
No, HDR10 is static colorspace and not metadata how HDR10+ is. DoVi Profiles 7/8 only Metadata for HDR10 based content.
cool advertise
9th June 2023, 09:47
-v0.55 Online
-v0.55
DDVT_DEMUXER is buggy. It does not extract the rpu.
My settings were:
SAVE HDR BL: NO
SAVE DoVI EL: NO
SAVE RPU: YES
CONVERT RPU: PROFILE 8.1 HDR
CROP RPU: YES
and also I had set my custom path in DDVT_OPTIONS.cmd
-QfG-
9th June 2023, 12:40
Some error messages during demuxing? And which DoVi Profile have the source file?
EDIT: You're right P7 will not demux correctly, will fix them.
EDIT2: Fixed in Dolby_Vision_Tool_v0.55_f01.rar. Also fixed the missing path in the extract diroctory.
cool advertise
9th June 2023, 16:06
Now 'DDVT_DEMUXER.cmd' works, but if you put an & in the folder name of the source file, or in the name of the source file, the rpu extraction fails (tested).
Perhaps also if other special characters are used, but I have not tested this thoroughly yet.
-QfG-
9th June 2023, 17:37
This is a "batch" problem, because the "&" is a command in Batch.
hidef_rec
10th June 2023, 16:03
@-QfG-, thanks much for enabling drag-and-drop use in Windows 11 w/the latest version for hybrid. A game-changer in making it so easy to create hybrid outputs.
Amateur
11th June 2023, 04:35
-v0.54
*NEW New Script included (DDVT_Hybrid) for fast creating DV Profile 8.1 Hybrid Releases.
*INJECTOR-Function to change correctly the video framerate. Also included in HYBRID Script.
*Updated mkvtoolnix to v 76.0.0.0.
Just saw these new functions. Is it possible to queue up multiple files to work overnight? Like if I have one folder of DV episodes and one folder of HDR episodes, how would I be able to do the Hybrid script and use the first file in each folder, then when complete do the second file in each folder, etc.? I won't need to change any FPS, add delays, nor do any border changes. Should be able to simply inject the DV into the HDR
Thanks for this tool. It's great
GodzilaAvenger
11th June 2023, 07:30
If you are familiar with PowerShell you can write a script that loops over the files and creates hybrids.
Amateur
11th June 2023, 15:17
If you are familiar with PowerShell you can write a script that loops over the files and creates hybrids.
I've used powershell a little bit for programs which require it, but have no idea how to make a script.
titomoi
11th June 2023, 17:44
great job!!
-QfG-
12th June 2023, 06:39
Just saw these new functions. Is it possible to queue up multiple files to work overnight? Like if I have one folder of DV episodes and one folder of HDR episodes, how would I be able to do the Hybrid script and use the first file in each folder, then when complete do the second file in each folder, etc.? I won't need to change any FPS, add delays, nor do any border changes. Should be able to simply inject the DV into the HDR
Thanks for this tool. It's great
You can edit the scripts and you can make a dir support, with a for command, so that every file in this folder will be called. The problem is the naming in this case, the tool must know which DV file is for the actually HDR file. But the tool supports completely multitasking, so you can mux more files at the same time.
Amateur
13th June 2023, 00:08
You can edit the scripts and you can make a dir support, with a for command, so that every file in this folder will be called. The problem is the naming in this case, the tool must know which DV file is for the actually HDR file. But the tool supports completely multitasking, so you can mux more files at the same time.
I did Right Click > Edit to see if your comment would make sense to me but not really. I have no coding experience. You're suggesting to edit the Hybrid.cmd file?
If the files have the exact same name (just in different folders) would that do the trick as far as lining up the correct files to be merged?
black_hunter
13th June 2023, 22:07
Thank you for the great tool. I have two questions.
Would it please be possible to add a script that converts the audio from DTS to AC3 but keeps the MKV and does not make it an MP4?
If I have an MKV with PGS subs, would it be possible that the script removes the PGS subs instead of having to remove the PGS subs itself with MKVToolNix?
-QfG-
16th June 2023, 14:45
-v0.56 Online
*NEW - Hybrid Script - If DV file contents DV and HDR10+ and the HDR file is only HDR
you can choice to mux HDR10+ metadata into target file. DV RPU
will always mux in HDR stream, HDR10+ is optional.
*Small Bugfixes.
Example: You have a UHD Remux only with HDR10 and a Hybrid WEB Release containing DV Profile 8 und HDR10+ Metadata. Choose UHD Remux as HDR File, the P8 Hybrid as DV file, type in the correct Delay and mux it.
You're suggesting to edit the Hybrid.cmd file?
Thats not so easy, but i will take a look, if i can add folder support in futere releases.
Would it please be possible to add a script that converts the audio from DTS to AC3 but keeps the MKV and does not make it an MP4?
Simple create a Batch file and copy paste this code in it:
@echo off & setlocal
mode con cols=122 lines=57
TITLE AUDIO TO AC3 Converter
setlocal EnableDelayedExpansion
set "FFMPEGpath=%~dp0tools\ffmpeg.exe" rem Path to ffmpeg.exe
set "AUDIOCODEC=-c:a ac3 -b:a 640k"
"!FFMPEGpath!" -drc_scale 0 -y -i "%~1" -strict experimental -loglevel error -stats -c:v copy !AUDIOCODEC! -c:s copy -strict -2 "%~dpn1_[AC3 CONVERTED]%~x1"
setlocal DisableDelayedExpansion
TIMEOUT 10
Simply Drag & Drop the MKV over this Script.
-QfG-
18th June 2023, 08:47
-v0.57 Online
*DEMUXER creates a directory in source file dir if a custom dir is set - Fixed.
*HYBRID Any bugfixes and overhauled layout. Live ticker if HDR and OUTPUT Borders matches.
-QfG-
19th June 2023, 09:22
-v0.58 Online
*Removes mkclean from all scripts because damage on some tracks inside mkv container.
Versions till v0.55 removed from drive for safety all our releases!
hidef_rec
23rd June 2023, 16:23
Thanks for the continued updates to this excellent toolset. A question on Apple DV Profile 8.4; searched this thread & found some discussion on converting to 8.4, but wondering if there's a way to convert videos shot on iPhone in DV 8.4 to a lower profile, namely 8.1?
Ritsuka
24th June 2023, 07:31
I wouldn't call 8.4 an higher profile, it's just different: it uses HLG instead of PQ, so to convert to 8.1 you would have to re-encode and convert to PQ.
Furthermore, Apple uses the ambient viewing environment metadata, I don't know if there is any player outside of Apple owns that honours it, but without that iPhone recorded DV 8.4 files look completely different.
dkangel
25th June 2023, 18:14
Thank you for your amazing script.
It was already easy with the demux-injector functions but now with the hybrid script it's even more easy.
It's the perfect tool to import dv web file into hdr br remux.
Cedvano
26th June 2023, 07:02
Hi,
I'm starting to get interested in the AV1 codec, and I would like to know if this codec is compatible for Dolby Vision and if this software accepts this codec?
Thanks
GodzilaAvenger
26th June 2023, 09:43
AFAIK Dolby Vision is not supported on AV1, at least officially.
-QfG-
26th June 2023, 19:46
-v0.59 Online
*Hybrid Scripts supports now HDR10+ files without DV for secondary input.
If the secondary stream contains DV and HDR10+ metadata, you can choose
which metadata will be used for RPU.
*Live ticker for Output file HDR infos.
No support for DV Profile 8.4 now, because i have no HLG files for testing.
Cedvano
27th June 2023, 07:13
AFAIK Dolby Vision is not supported on AV1, at least officially.
Thank you :thanks:
MadMonkey57
28th June 2023, 10:29
Hi,
Reporting an issue. I can work it around with another tool, so mostly reporting as an FYI to DDVT maintainer (thx for your tool BTW).
I have downloaded a large DoVi MKV movie for TESTING purposes on my LG OLED65C8 (2018).
I converted the MKV to MP4 with DDVT_MKVTOMP4 v0.58, and TV plays it as a regular HDR file.
Then I converted the MKV to MP4 with dvmkv2mp4 (https://github.com/gacopl/dvmkv2mp4), and TV plays it as a DoVi file.
For context, here are the "ffmpeg (https://github.com/BtbN/FFmpeg-Builds/releases) -i" output of all three files:
- MKV: https://pastebin.com/LvGW4PaA
- DDVT.mp4: https://pastebin.com/WBATZTkY
- dvmkv2mp4.mp4: https://pastebin.com/CbEACpbt
And the mediainfo of both converted files:
- DDVT.mp4: https://pastebin.com/MUPVR0Fw
- dvmkv2mp4.mp4: https://pastebin.com/7QnM3fwM
Hope it helps.
EDIT: Still experimenting. This time, I tried converting this DoVi MKV (https://mega.nz/file/DGJU1BzL#4jtSK9Kvx2N6WuNdnQXyOi4NFEqLIymLrmSK5R8WilY) and the resulting mp4 plays as a DoVi on my TV.
EDIT 2: Tried converting "FEL_test_for_AVS.mkv" available from HERE (https://mega.nz/folder/FSog3BhS#UzG3Mrrs_vuT1Qy-lZIhhg). This time, TV detects the resulting mp4 as a DoVi, but playback is stuck on the very first frame.
This is so weird.
Fuso
28th June 2023, 16:17
Hi,
Reporting an issue. I can work it around with another tool, so mostly reporting as an FYI to DDVT maintainer (thx for your tool BTW).
I have downloaded a large DoVi MKV movie for TESTING purposes on my LG OLED65C8 (2018).
I converted the MKV to MP4 with DDVT_MKVTOMP4 v0.58, and TV plays it as a regular HDR file.
My main tv is LG C2, but I also have a B8 as second tv and I watch movies sometimes on it but can't play DV converted with this tool. I will be very happy if it becomes possible to watch Profile 8 mkv2mp4 on the pre-2020 LG models.
Then I converted the MKV to MP4 with dvmkv2mp4 (https://github.com/gacopl/dvmkv2mp4), and TV plays it as a DoVi file.
I suppose this tool is only for Linux?
EDIT: Still experimenting. This time, I tried converting this DoVi MKV (https://mega.nz/file/DGJU1BzL#4jtSK9Kvx2N6WuNdnQXyOi4NFEqLIymLrmSK5R8WilY) and the resulting mp4 plays as a DoVi on my TV.
That is because the file is Profile 7 which plays fine on the pre-2020 LG models.
GodzilaAvenger
28th June 2023, 18:04
Can you add the MediaInfo of the converted files?
MadMonkey57
28th June 2023, 18:27
Can you add the MediaInfo of the converted files?
Sure. Updated the original post (https://forum.doom9.org/showthread.php?p=1988940#post1988940).
GodzilaAvenger
29th June 2023, 05:09
My guess is that the problem stems from the codec type, one is "hev1" while the other is "dvhe". It seems that the latter triggers DV on your TV while the former doesn't. Also the HDR format info of the second one is weird (Version 0 isn't exactly a thing).
If I were to guess again I'd say this is because dvmkv2mp4 uses "hevc_mp4toannexb" but DDVT doesn't, but I may be wrong.
guest
29th June 2023, 05:37
My main tv is LG C2, but I also have a B8 as second tv and I watch movies sometimes on it but can't play DV converted with this tool. I will be very happy if it becomes possible to watch Profile 8 mkv2mp4 on the pre-2020 LG models.
In my limited experience (so far) with all this, I have found that the ONLY DV file format that will play on my LG 4K TV is either .ts, or .m2ts !!!!
Neither .mp4 or .mkv will play as DV, only as HDR10.
The only playback issue I have is if I "bump" the playback forward or backwards by the default 15 sec's, it will stall the playback for a second or 2, other than that, it's fine.
MadMonkey57
29th June 2023, 12:04
I will be very happy if it becomes possible to watch Profile 8 mkv2mp4 on the pre-2020 LG models.
I've only made a few tests so far, but it seems Profile 8 are indeed not detected as DV once converted with DDVT_MKVTOMP4.
I suppose this tool is only for Linux?
Yes, I'm running the docker setup in Linux. You could maybe try WSL.
That is because the file is Profile 7 which plays fine on the pre-2020 LG models.
Again, I can only concur to this. The "Awaken Girl (https://mega.nz/file/DGJU1BzL#4jtSK9Kvx2N6WuNdnQXyOi4NFEqLIymLrmSK5R8WilY)" MKV sample converted with DDVT_MKVTOMP4 successfully plays as DV. And it is Profile 7.
MadMonkey57
29th June 2023, 12:11
My guess is that the problem stems from the codec type, one is "hev1" while the other is "dvhe". It seems that the latter triggers DV on your TV while the former doesn't.
Like I stated in my previous post, the converted "Awaken Girl " sample plays fine as DV although the codec is hev1 for reasons...
Also the HDR format info of the second one is weird (Version 0 isn't exactly a thing).
Yes, I noticed that as well. Weird.
If I were to guess again I'd say this is because dvmkv2mp4 uses "hevc_mp4toannexb" but DDVT doesn't, but I may be wrong.
That was also my first assumption, but considering the other MKV samples I have converted, I'm having second thoughts.
That LG player is a mess.
It's a pity I don't have more MKV samples (with different profiles, ...) to play with.
EDIT: I've managed to get my hands on another very large Profile 8 (dvhe.08.06) DV MKV file. Once again, converted to mp4 with DDVT is not detected as DV by LG TV, while it is with dvmkv2mp4. So under *some* circumstances, profile 8 can actually play as DV on the LG (2018).
SeeMoreDigital
29th June 2023, 12:22
What Dolby Vision profiles do media streaming services use?
GodzilaAvenger
29th June 2023, 18:50
5, sometimes 8. Blu-rays use 7.
hidef_rec
29th June 2023, 19:55
Hi,
I'm starting to get interested in the AV1 codec, and I would like to know if this codec is compatible for Dolby Vision and if this software accepts this codec?
Thanks
No DV as has been said, but there was talk last year of Google pushing for a new open, royalty-free HDR & object-based audio formats (https://www.protocol.com/entertainment/google-dolby-atmos-vision-project-caviar).
GodzilaAvenger
29th June 2023, 23:52
@-QfG- I'm using v0.58 and I noticed that when using the injector script, instead of creating a "_[TEMP]" folder in the directory where the ".mkv" file is, the script creates a "SAME AS SOURCE" folder in the "DDVT" directory and stores the files there. Could you look into this and see if there's a bug somewhere?
Also, it would be great if when entering ALL in the FRAMEINFO tool, the L1 plot that dovi_tool can create is also generated.
UPDATE. Changing lines 87 and 88 to
if "!TMP_FOLDER!"=="SAME AS SOURCE" set "TMP_FOLDER=%~dpn1_[TEMP]"
if "!TARGET_FOLDER!"=="SAME AS SOURCE\%~n1_[INJECTED]" set "TARGET_FOLDER=%~dpn1_[INJECTED]"
(same as the demuxer script) seems to resolve the issue.
fransalas
1st July 2023, 18:10
Good afternoon, thank you very much for the great tool you have created.
fransalas
3rd July 2023, 16:40
good afternoon, maybe my question is somewhat risky but there I throw it, there would be a possibility of incorporating a script that transforms the RPU to XML and vice versa? thank you again
GodzilaAvenger
3rd July 2023, 19:36
Here's a possible solution: use the FRAMEINFO tool and enter ALL to get a *.json file of all frame infos of the RPU binary. Then use a json to xml conversion tool (there are even some online tools available).
pandv2
3rd July 2023, 20:54
I am confused about removing and duplicating rpu frames at the same time.
If I want to remove the frame 10 and duplicate the frame 20. I need to do:
"remove": [
"10",
],
"duplicate": [
{
"source": 20,
"offset": 21,
"length": 1
}
]
}
Or I need to acount for the deleted frame:
"remove": [
"10",
],
"duplicate": [
{
"source": 19,
"offset": 20,
"length": 1
}
]
}
I am using DDVT injector with a custom.json.
I am suposing a delete doesn't changes the count for the next delete, and a duplicate doesn't change the count for the next duplicate. Is this true?
Thanks.
GodzilaAvenger
3rd July 2023, 21:46
dovi_tool editor instructions (https://github.com/quietvoid/dovi_tool/blob/main/docs/editor.md)
fransalas
3rd July 2023, 22:20
thanks for answering before, could you tell me if there is any possibility of knowing the scenes of an MKV in HDR10, is that I am doing a test reconstructing a movie.
pandv2
3rd July 2023, 23:22
dovi_tool editor instructions (https://github.com/quietvoid/dovi_tool/blob/main/docs/editor.md)
Thanks.
I have read that document before asking. Maybe, it is my understanding of english, but i am not sure what is the correct answer. I deducted:
1.- One remove doesn't affect the position of the next.
2.- One duplicate doesn't affect the position of the next.
3.- The remove's set affect the duplicates.
I am not sure if it's true. That's why I asked.
Note: It's correct. I tested as suggested by GodzilaAvenger.
GodzilaAvenger
4th July 2023, 02:17
I have the same understanding as you. To verify I recommend trying out dovi_tool (not the INJECTOR script) on the RPU and then using the FRAMEINFO tool on both the original and modified RPUs to see what has changed.
GodzilaAvenger
4th July 2023, 02:22
thanks for answering before, could you tell me if there is any possibility of knowing the scenes of an MKV in HDR10, is that I am doing a test reconstructing a movie.
I'm not sure if I understand your question correctly. Do you want to know if a .mkv file is HDR10? If so, you can use MediaInfo to find out.
I haven't heard of an .mkv being capable of having both SDR and HDR scenes at the same time, if that's what you mean. It's either one or the other AFAIK.
quietvoid
4th July 2023, 02:23
1.- One remove doesn't affect the position of the next.
2.- One duplicate doesn't affect the position of the next.
3.- The remove's set affect the duplicates.
I am not sure if it's true. That's why I asked.
Sounds correct to me.
EDIT: I've managed to get my hands on another very large Profile 8 (dvhe.08.06) DV MKV file. Once again, converted to mp4 with DDVT is not detected as DV by LG TV, while it is with dvmkv2mp4. So under *some* circumstances, profile 8 can actually play as DV on the LG (2018).
Can you test if this file plays fine in regulard HDR on non-DV capable tv... like Samsung for example? I think it will not play because the codec ID is dvhe.
If you can test and it works even on a non-DV capable tv, it will be perfect.
Strangely Profile 5 DV with codec ID set to hev1 plays fine on both LG B8 and LG C2, even on a Samsung but with purple and green tint (which is understandable).
The problem is that the older LG's have some issue with Profile 8 with Codec ID set to hev1.
Boulder
4th July 2023, 20:04
Does anyone have a proven DV profile 8.1 sample clip in MP4 to test on my Sony's media player? I can get a profile 5 sample to trigger DV mode, but the 8.1 ones I created using RPU injection while encoding in x265 or injecting afterwards and then converting the files to MP4 won't work. The Sony player can apparently understand DV only in MP4 files, and the links to samples at Dolby's developer site just error out.
MadMonkey57
5th July 2023, 14:45
Can you test if this file plays fine in regulard HDR on non-DV capable tv... like Samsung for example? I think it will not play because the codec ID is dvhe.
If you can test and it works even on a non-DV capable tv, it will be perfect.
Strangely Profile 5 DV with codec ID set to hev1 plays fine on both LG B8 and LG C2, even on a Samsung but with purple and green tint (which is understandable).
The problem is that the older LG's have some issue with Profile 8 with Codec ID set to hev1.
Sorry, the only TV I have access to is my LG C8.
guest
5th July 2023, 15:43
Does anyone have a proven DV profile 8.1 sample clip in MP4 to test on my Sony's media player? I can get a profile 5 sample to trigger DV mode, but the 8.1 ones I created using RPU injection while encoding in x265 or injecting afterwards and then converting the files to MP4 won't work. The Sony player can apparently understand DV only in MP4 files, and the links to samples at Dolby's developer site just error out.
Me again,
Have you tried converting them to either .ts or .m2ts ??
My LG TV won't play DV in either .mp4 or .mkv :(
I also mentioned this here :-
https://forum.doom9.org/showthread.php?p=1988970#post1988970
SeeMoreDigital
5th July 2023, 18:53
My LG TV won't play DV in either .mp4 or .mkv :(
Just so you know... Currently, no make/model of television is able to play Dolby Vision in .mkv (using it's built in media player app). As a new Matroska parser will need to be created...
benwaggoner
5th July 2023, 19:37
I've only made a few tests so far, but it seems Profile 8 are indeed not detected as DV once converted with DDVT_MKVTOMP4.
Profile 8 was a relatively recent addition to Dolby Vision, and isn't supported by older TVs, presumably including these pre-2020 LG models. I'd hope/expect they'd at least play back as native HDR-10 ignoring the dynamic metadata.
benwaggoner
5th July 2023, 19:40
Does anyone have a proven DV profile 8.1 sample clip in MP4 to test on my Sony's media player? I can get a profile 5 sample to trigger DV mode, but the 8.1 ones I created using RPU injection while encoding in x265 or injecting afterwards and then converting the files to MP4 won't work. The Sony player can apparently understand DV only in MP4 files, and the links to samples at Dolby's developer site just error out.
What model year Sony? DoVi TVs have supported Profile 5 since they launched, but only the last few years have supported Profile 8.
rwill
5th July 2023, 20:11
Does anyone have a proven DV profile 8.1 sample clip in MP4 to test on my Sony's media player? I can get a profile 5 sample to trigger DV mode, but the 8.1 ones I created using RPU injection while encoding in x265 or injecting afterwards and then converting the files to MP4 won't work. The Sony player can apparently understand DV only in MP4 files, and the links to samples at Dolby's developer site just error out.
Can you make your 8.1 .mp4 stream available somewhere so I can test it on my end ?
Boulder
5th July 2023, 20:30
What model year Sony? DoVi TVs have supported Profile 5 since they launched, but only the last few years have supported Profile 8.
It's an XF9005 (x900f in the USA?), so it's 2018 I think. Very hard to tell which profiles it supports as it doesn't seem to be any important information to Sony..
Can you make your 8.1 .mp4 stream available somewhere so I can test it on my end ?
Here are the two files I've tested. One with direct RPU input while encoding, the other with injection afterwards.
https://drive.google.com/file/d/15ewWr8v1x3xnanbS-TReWnVldIsu2YpA/view?usp=drive_link
https://drive.google.com/file/d/13wbvOYwJwHdxKON94jY4JCXfYARCBTws/view?usp=drive_link
SeeMoreDigital
5th July 2023, 20:59
https://drive.google.com/file/d/15ewWr8v1x3xnanbS-TReWnVldIsu2YpA/view?usp=drive_link[/url]
https://drive.google.com/file/d/13wbvOYwJwHdxKON94jY4JCXfYARCBTws/view?usp=drive_linkHave you created the meta-data for both of these 1920x1080 video files yourself?
Neither can display Dolby Vision on my 2016 LG television, only HDR...
Do 'known' profile 5 and/or profile 8 .mp4/.m2ts/.ts files display okay on your Sony KD-65XF9005?
Boulder
5th July 2023, 22:37
Have you created the meta-data for both of these 1920x1080 video files yourself?
Neither can display Dolby Vision on my 2016 LG television, only HDR...
Do 'known' profile 5 and/or profile 8 .mp4/.m2ts/.ts files display okay on your Sony KD-65XF9005?
Both files use the same RPU.bin file. I got it by turning a Dolby Vision sample track (m2ts with DoVi profile 7) to mkv using MakeMKV, then using the created file with the demuxer script.
The profile 5 one I have (not made by me) does play ok and switches on the Dolby Vision mode. The others fall back to HDR10, hence me asking if anyone has a verified sample clip to check.
quietvoid
5th July 2023, 23:32
The profile 5 one I have (not made by me) does play ok and switches on the Dolby Vision mode. The others fall back to HDR10, hence me asking if anyone has a verified sample clip to check.
My guess is that your TV might only play in Dolby Vision if the codec tag is dvhe/dvh1.
At least both of your samples are hev1.
One way is to use MP4Box to mux:
MP4Box.exe -add video.hevc:dvp=f8.hdr10:hdr=none:stype=dvhe -brand mp42isom -ab dby1 -new video-muxed.mp4
rwill
6th July 2023, 04:08
https://drive.google.com/file/d/15ewWr8v1x3xnanbS-TReWnVldIsu2YpA/view?usp=drive_link
https://drive.google.com/file/d/13wbvOYwJwHdxKON94jY4JCXfYARCBTws/view?usp=drive_link
Well, plays as Dolby Vision on my OLED48CX9LB LG TV...
guest
6th July 2023, 04:42
Well, plays as Dolby Vision on my OLED48CX9LB LG TV...
Neither of these would display DV on my LG SK8500PTA.
But, quickly running them thru tsmuxer to .m2ts, DID display DV :)
Just wondering. If I encode something in HDR10 with no available metadata, could I use this program to trigger Dolby Vision with static metadata? So something could play in Dolby Vision with no metadata?
Can you add your own metadata?
I'm new to this, apologies if it's a nooby question.
There's something even better you can do. In fact, you can use Davinci Resolve to automatically generate a custom RPU with completely dynamic metadata using the official Dolby's algorithm.
GodzilaAvenger
6th July 2023, 07:58
I was recently adding HDR10+ metadata from a web source to one of my Blu-rays and I noticed the difference in light level values between it and the Blu-ray's DV RPU, as shown in the attachments. Is this normal? DV FALL seems to be very static.
Boulder
6th July 2023, 08:16
My guess is that your TV might only play in Dolby Vision if the codec tag is dvhe/dvh1.
At least both of your samples are hev1.
One way is to use MP4Box to mux:
MP4Box.exe -add video.hevc:dvp=f8.hdr10:hdr=none:stype=dvhe -brand mp42isom -ab dby1 -new video-muxed.mp4
Thank you, I'll test it then. I just used the DDVT_MKVTOMP4 script to convert the files, so if this works, it's a feature request to -QfG- to allow setting the codec tag :D
Well, plays as Dolby Vision on my OLED48CX9LB LG TV...
Neither of these would display DV on my LG SK8500PTA.
But, quickly running them thru tsmuxer to .m2ts, DID display DV
Thank you for testing, good to hear that the methods themselves work :)
Boulder
6th July 2023, 12:54
Couldn't get the files to switch on the DV mode, so I have to ask Sony if they can tell me which profiles are supported. I'm not keeping my hopes up too high because the support people may see the same information I see on their pages :D
MadMonkey57
7th July 2023, 09:02
Profile 8 was a relatively recent addition to Dolby Vision, and isn't supported by older TVs, presumably including these pre-2020 LG models. I'd hope/expect they'd at least play back as native HDR-10 ignoring the dynamic metadata.
Yes indeed.
I made peace with it now. I might get a Shield some day.
SeeMoreDigital
7th July 2023, 11:48
My guess is that your TV might only play in Dolby Vision if the codec tag is dvhe/dvh1.
At least both of your samples are hev1.
One way is to use MP4Box to mux:
MP4Box.exe -add video.hevc:dvp=f8.hdr10:hdr=none:stype=dvhe -brand mp42isom -ab dby1 -new video-muxed.mp4
Bummer... Even after re-muxing Boulder's samples with MP4box, my 2016 LG television displays them in HDR10. However, the UI now displays 'DVHE' (which it didn't do before): -
https://i.ibb.co/F5YBsLc/P-20230707-113645-1.jpg
Cheers
quietvoid
7th July 2023, 12:10
Bummer... Even after re-muxing Boulder's samples with MP4box, my 2016 LG television displays them in HDR10.
Cheers
Older LG TVs don't like new MP4 files, and I still don't understand why.
With older MP4Box versions, my C8 would play them as Dolby VIsion but new versions didn't work.
You're more likely to get Dolby Vision with .TS files.
There's also Dolby's old MP4 muxer but it's slow and not very user friendly: https://github.com/DolbyLaboratories/dlb_mp4base/tree/ad46704703d2f558a61c2dba444ae43a8e3effff/bin
The new versions also didn't work on my C8.
guest
7th July 2023, 12:14
Bummer... Even after re-muxing Boulder's samples with MP4box, my 2016 LG television displays them in HDR10. However, the UI now displays 'DVHE' (which it didn't do before): -
https://i.ibb.co/F5YBsLc/P-20230707-113645-1.jpg
Cheers
I think you probably should try them in .m2ts, instead..
SeeMoreDigital
7th July 2023, 12:31
I think you probably should try them in .m2ts, instead..
Actually I just tried that and the .m2ts re-muxes (using TSmuxer GUI git-79b86ec) don't play at all... Which is most odd!
guest
7th July 2023, 12:47
Actually I just tried that and the .m2ts re-muxes (using TSmuxer GUI git-79b86ec) don't play at all... Which is most odd!
Yes, that IS odd.... it's the only way I can them to play in DV.
SeeMoreDigital
7th July 2023, 12:55
Yes, that IS odd.... it's the only way I can them to play in DV.What tools are you creating your 'transport' stream muxes?
Can you upload one of your working .m2ts muxes?
guest
7th July 2023, 13:47
What tools are you creating your 'transport' stream muxes?
Can you upload one of your working .m2ts muxes?
https://forum.doom9.org/showthread.php?p=1989214#post1989214
Tsmuxer nightly, same .mp4 clips....
Boulder
7th July 2023, 13:54
Yes indeed.
I made peace with it now. I might get a Shield some day.
But wouldn't the display device itself still need to support the profile even though you use an external player? That's why I'm trying to figure this stuff out since I'm going to upgrade my Odroid N2 at some point and Dune/Homatics R 4K Plus, RockTek G2 and Nokia 8010 now support Dolby Vision using Kodi in an alpha CoreELEC build.
rwill
7th July 2023, 15:31
Thank you for testing, good to hear that the methods themselves work :)
Can you please test this .mp4 on your device? I used a non-public muxer.
https://drive.google.com/file/d/1_XbzARCCV-iOqSpme_y3q3Sx2PnUsWu2/view?usp=sharing
Boulder
7th July 2023, 15:45
Can you please test this .mp4 on your device? I used a non-public muxer.
https://drive.google.com/file/d/1_XbzARCCV-iOqSpme_y3q3Sx2PnUsWu2/view?usp=sharing
Sorry, it only plays back as HDR only on the TV.
pandv2
7th July 2023, 21:23
A little, not very important, bug in 0.59 beta.
If I extract the dolby rpu, is extracted in outputdirectory, and not in outputdirectory\<FILENAME>_[<SCRIPTNAME>]. I am using the context menu.
SeeMoreDigital
7th July 2023, 22:32
Can you please test this .mp4 on your device? I used a non-public muxer.
https://drive.google.com/file/d/1_XbzARCCV-iOqSpme_y3q3Sx2PnUsWu2/view?usp=sharingSorry, it only plays back as HDR only on the TV.
Same here: -
https://i.ibb.co/4srWy87/test.jpg
guest
8th July 2023, 01:49
Can you please test this .mp4 on your device? I used a non-public muxer.
https://drive.google.com/file/d/1_XbzARCCV-iOqSpme_y3q3Sx2PnUsWu2/view?usp=sharing
& @ Boulder & @ SeeMoreDigital (SMD)
Well, I hate to say it, but this also played in DV, after re-muxing with tsmuxer to .m2ts...
SeeMoreDigital
8th July 2023, 09:53
& @ Boulder & @ SeeMoreDigital (SMD)
Well, I hate to say it, but this also played in DV, after re-muxing with tsmuxer to .m2ts...I tried re-muxing your 'dolby_test_rpu_xxx.mp4' sample to .ts and .m2ts using TSmuxer GUI (git-49a59c0) and just got coloured spinning balls followed by "unable to play"...
EDIT: My OPPO UDP-203 plays and displays the 'dolby_test_rpu_xxx.mp4' sample in HDR10 but outputs the video signal at 1080i50 and images bounce/flicker up and down. However, the OPPO is able to play and display the .ts and .m2ts re-muxes in Dolby Vision but outputs the video signal at 2160p25.
guest
8th July 2023, 11:58
I tried re-muxing your 'dolby_test_rpu_xxx.mp4' sample to .ts and .m2ts using TSmuxer GUI (git-49a59c0) and just got coloured spinning balls followed by "unable to play"...
EDIT: My OPPO UDP-203 plays and displays the 'dolby_test_rpu_xxx.mp4' sample in HDR10 but outputs the video signal at 1080i50 and images bounce/flicker up and down. However, the OPPO is able to play and display the .ts and .m2ts re-muxes in Dolby Vision but outputs the video signal at 2160p25.
Strange...
So just a little more info for you:-
Using TSmuxer GUI (git-7277259)
Also, only using the LG built in player, via a USB stick.
MadMonkey57
9th July 2023, 07:57
But wouldn't the display device itself still need to support the profile even though you use an external player? That's why I'm trying to figure this stuff out since I'm going to upgrade my Odroid N2 at some point and Dune/Homatics R 4K Plus, RockTek G2 and Nokia 8010 now support Dolby Vision using Kodi in an alpha CoreELEC build.
Well I might be wrong, but here's my reasoning.
The TV is able to play DV files under *some* circumstances. I was even able to play Profile 8 videos in an M2TS container (muxed with latest tsmuxer). But then I struggle with the limitations of M2TS (no TXT subtitles, no dolby atmos, ...).
It seems to me that LG's built in player struggles with the container, not the video stream.
guest
9th July 2023, 12:20
Well I might be wrong, but here's my reasoning.
The TV is able to play DV files under *some* circumstances. I was even able to play Profile 8 videos in an M2TS container (muxed with latest tsmuxer). But then I struggle with the limitations of M2TS (no TXT subtitles, no dolby atmos, ...).
It seems to me that LG's built in player struggles with the container, not the video stream.
What I do with subtitles with .m2ts is have the .srt named the same as the video file, and in the same directory.
It also supports Dolby Atmos 5.1, not sure about 7.1, but my system doesn't support 7.1 anything, but good 5.1 is plenty good enough.
Fuso
10th July 2023, 10:30
Strange...
So just a little more info for you:-
Using TSmuxer GUI (git-7277259)
Also, only using the LG built in player, via a USB stick.
I couldn't find this exact version. Can you give a link to it?
guest
10th July 2023, 12:36
I couldn't find this exact version. Can you give a link to it?
Well, it's probably a newer build, now...
Keep yourself up to date, here...
https://forum.doom9.org/showthread.php?t=176668
https://github.com/justdan96/tsMuxer/releases
ivanb
11th July 2023, 04:18
Can you please test this .mp4 on your device? I used a non-public muxer.
It seems that your muxer doesn't put HEVC sequence headers (VPS/SPS/PPS) into 'hvcC' sample entry:
https://i.ibb.co/CvpF1SZ/Screenshot-2023-07-11-at-10-09-39.png (https://ibb.co/zbWwntY)
Some players may not like it
MadMonkey57
11th July 2023, 10:21
What I do with subtitles with .m2ts is have the .srt named the same as the video file, and in the same directory.
It also supports Dolby Atmos 5.1, not sure about 7.1, but my system doesn't support 7.1 anything, but good 5.1 is plenty good enough.
I'll try that, thx.
But these are really tedious workarounds...
guest
13th July 2023, 13:55
I've got a new format displaying on my LG....
https://i.imgur.com/dEOkkiu.jpg
fransalas
14th July 2023, 20:04
maybe this is not from here but I would like to ask if there is any way to modify by hand the values of Luminance monitor mastering:
GodzilaAvenger
15th July 2023, 06:46
You can use the editor function of dovi_tool (https://github.com/quietvoid/dovi_tool).
puremind
24th July 2023, 17:09
i have created 2 little Batch scripts, one Demuxer and one Injector. With this scripts you can simply:
- Change DoVi Profile 7,5 to Profile 8
- Adding Delays (useful for Hybrid Releases)
- Convert HDR10+ Metadata to DoVi Profile 8 Metadata
- Delete HDR10+ Metadata from Videostream
https://workupload.com/file/GWpvx2dzvcs
quietvoid many thanks for this awesome tools.
Hello
In order to accelerate conversions from MKV to MP4 I customized your script so that you can pass a folder instead of a file path to allow for batch conversion of files.
18452
Changes include:
The script will now convert all files in the specified folder (C:\folder and C:\folder\ both work).
It will ask for the audio codec selection only for the first file and then apply those settings to all further files
It will summarize the output file name, FPS and audio codec while it is converting, not only the source characteristics
The converted files will go to the source folder instead of a custom folder for each conversion.
This allows the user to replace all of their MKV's with the MP4's without having to pull for multiple subfolders.
It will keep the MKV's until you have been able to check the files (user should delete the MKV's manually)
it will check if there is already an MP4 file with the output file name and skip the mkv conversion if there is
it will also convert any subfolder files, so be careful if you convert at root level, you may convert your entire mkv library at once :D
NOTE:
Only convert files that have the same characteristics using this script.
If you want to convert heterogeneous files, the loop would need to be tweaked so that each source file is analyzed (:CHECK is always performed) and only skipping the audio codec selection part.
I created this because I often have multiple files in one folder all waiting to be converted and it can be very tedious to do it one by one.
You should feel free to add this script to your rar release, either as a replacement of the DDVT_MKVTOMP4 script or as a separate command.
One thing that I wanted to ask you about. As you know, right now conversion fails if there is an image based subtitle track in the MKV. Should we just strip the subtitles when this is detected? It seems to me we could use something like this in the script so that no conversion would fail?
# remove all subtitles (copy none)
mkvmerge -o output.mkv --no-subtitles input.mkv
If you think it makes sense, I would appreciate if you could include in future versions of your scripts. :)
-QfG-
27th July 2023, 21:51
-v0.60 Online
*Minor Bugfixes
*Updated mkvtoolnix to v 78.0.0.0.
Boss 14
30th July 2023, 16:20
A new version, but DDVT INJECTOR is still v0.59beta - is that right?
Thank you.
-QfG-
30th July 2023, 17:23
Yes, changes only on the Hybrid script. Forget to change version in this script.
hidef_rec
30th July 2023, 19:47
With "Change DoVi Profile 7,5 to Profile 8"... I used Demuxer on a Profile 5 MKV & and now have a RPU. How do I use it to convert the MKV to a Profile 8? Or, is this not what the script was intended to do? Thanks.
TomDoom
31st July 2023, 15:56
Hi -QfG-
thanks for those nice scripts :)
I mostly use the MKV2MP4 Convert to have DV play on my LG TV. However, the MP4 File has the wrong audio language tag. Every track will become tagged as ENGLISH, unfortunately.
That even happens If you don't change/convert the audio track.
MKV:
Audio #1
ID : 2
[...]
Title : German
Language : German
After MP4 conversion:
Audio #1
ID : 2
[...]
Title : German
Language : English
Maybe you can fix that (or anyone else knows what's going wrong here and tell me what tou change)? That's happening since loooong time and I think you heard of it already.
Thanks!
Tom
sagor
3rd August 2023, 15:19
Excellent tools.Thanx for your hard work.
Anyone know here how to fix forwarding/rewarding issue on dolby vision video file.
When i merge audio or subtitle using with mkvmerge video won't forward or reward, it pause the video on Nova Video Player streaming via Jellyfin.
Also why the after crop factor issue video file size doesn't match with the original file?
Boss 14
5th August 2023, 16:07
I have a problem like this, I convert from P7 to P8 with the original video file, but after importing in the encodec file it says "CHECK RPU..."
https://thumbs4.imagebam.com/a5/fd/99/MEN7M1F_t.png (https://www.imagebam.com/view/MEN7M1F)https://thumbs4.imagebam.com/8d/f7/2c/MEN7M1I_t.png (https://www.imagebam.com/view/MEN7M1I)
And after "CHECK RPU..." it got like this, I don't know where did I go wrong? help me!
https://thumbs4.imagebam.com/55/1c/75/MEN7M1K_t.png (https://www.imagebam.com/view/MEN7M1K)
I also have this problem and do not know what to do?
von Suppé
8th August 2023, 09:57
Why don't you set check by typing C and then start checking cropping values by typing S ? See what happens.
Maybe RPU from 4K is used for HD? You can also manually check border values by opening a screenshot in an image editor.
von Suppé
31st August 2023, 11:26
I have no experience with crossinjecting P7 RPU into 2K encodes. I do wonder why one would do such. Perhaps it's because of your playback device/software capabilities. In case of a resize & HDR encode, I imagine P7 RPU can be used - probably with some adaptation.
If you need to convert to 2K SDR, a tonemap from HDR to SDR has to be applied prior to resizing & encoding. I guess then P7 metadata has no use whatsoever. But I can be dead wrong here and totally missing something.
In your 3rd screenshot at MOVIE INPUT, I don't know why the tool returns with "Failed px". Don't know what it would mean; maybe it can't determine the borders properly. I ALWAYS do this manually. By taking a screenshot whilst playing the file and have a look in an image editor.
Your target resolution being 1920x1012 I assume that you already determined the black bars and that they are cropped out in the encode. Then you have to "crop" RPU, which resets the L5 values to zero. L5 values represent the number of source-pixels of the widths/heights of surrounding black borders (which in your case are all zero, if my assumption is correct).
It may help when you'd explain why you want to do this.
Boulder
1st September 2023, 15:01
I have no experience with crossinjecting P7 RPU into 2K encodes. I do wonder why one would do such. Perhaps it's because of your playback device/software capabilities. In case of a resize & HDR encode, I imagine P7 RPU can be used - probably with some adaptation.
Since it's all just metadata, wouldn't it be okay to just crop the borders and downscale and then inject the RPU which is also marked as cropped? Of course, the metadata is not 100% correct due to the changes the downscales causes in the video, but the same applies to regular HDR10 as well.
von Suppé
2nd September 2023, 10:27
Since it's all just metadata, wouldn't it be okay to just crop the borders and downscale and then inject the RPU which is also marked as cropped? Of course, the metadata is not 100% correct due to the changes the downscales causes in the video, but the same applies to regular HDR10 as well.
My idea also.
What's tickling me is why the downscale. I know DV can be 2K and can have HDR10/HLG/SDR fallback.
I am wondering if there'd be DV compatible players/displays that would be limited to 2K. Or maybe OP just wants to save harddrive space?
Boulder
2nd September 2023, 10:43
My idea also.
What's tickling me is why the downscale. I know DV can be 2K and can have HDR10/HLG/SDR fallback.
I am wondering if there'd be DV compatible players/displays that would be limited to 2K. Or maybe OP just wants to save harddrive space?
I think the idea is just to save space, I do the same all the time with both HD and UHD sources.
puremind
3rd September 2023, 03:43
Hello
In order to accelerate conversions from MKV to MP4 I customized your script so that you can pass a folder instead of a file path to allow for batch conversion of files.
18452
Changes include:
The script will now convert all files in the specified folder (C:\folder and C:\folder\ both work).
It will ask for the audio codec selection only for the first file and then apply those settings to all further files
It will summarize the output file name, FPS and audio codec while it is converting, not only the source characteristics
The converted files will go to the source folder instead of a custom folder for each conversion.
This allows the user to replace all of their MKV's with the MP4's without having to pull for multiple subfolders.
It will keep the MKV's until you have been able to check the files (user should delete the MKV's manually)
it will check if there is already an MP4 file with the output file name and skip the mkv conversion if there is
it will also convert any subfolder files, so be careful if you convert at root level, you may convert your entire mkv library at once :D
NOTE:
Only convert files that have the same characteristics using this script.
If you want to convert heterogeneous files, the loop would need to be tweaked so that each source file is analyzed (:CHECK is always performed) and only skipping the audio codec selection part.
I created this because I often have multiple files in one folder all waiting to be converted and it can be very tedious to do it one by one.
You should feel free to add this script to your rar release, either as a replacement of the DDVT_MKVTOMP4 script or as a separate command.
One thing that I wanted to ask you about. As you know, right now conversion fails if there is an image based subtitle track in the MKV. Should we just strip the subtitles when this is detected? It seems to me we could use something like this in the script so that no conversion would fail?
# remove all subtitles (copy none)
mkvmerge -o output.mkv --no-subtitles input.mkv
If you think it makes sense, I would appreciate if you could include in future versions of your scripts. :)
@-QfG-
I found we can use mkvextract:
mkvextract file.mkv tracks [tracknumber] file.srt
I think your script already saves key information using media info, so all you would have to do is store information about on which track each language is found, then ask the user which subtitles they want to extract and do the extraction command on the tracks that the user selected and put them in the same folder as the source folder.
This would allow srt subtitles to be preserved on all episodes of a same video within MP4all.cmd.
Is there a way to extrac them in a different format and then add them to an MP4 container?
benwaggoner
6th September 2023, 20:15
Since it's all just metadata, wouldn't it be okay to just crop the borders and downscale and then inject the RPU which is also marked as cropped? Of course, the metadata is not 100% correct due to the changes the downscales causes in the video, but the same applies to regular HDR10 as well.
Yeah, that should work in general. All HDR metadata explicitly ignores the letterboxing, so cropping it out shouldn't change anything.
Downscaling doesn't have a huge impact, but the low-pass filter nature of downscaling can reduce a frame's peak brightness quite a bit if it is coming from single points, like stars.
Worst case would be white single pixels on a black background. If they were 1000 nits at 4K, they'd only be 250 nits at 2K, as each white pixel would be averaged out with three black pixels.
Atlantis
8th September 2023, 11:32
Is there an up-to-date step by step guide on how to re-encode a Dolby Vision file?
Update: well that was easier than I thought. Didn't even need to learn anything! All I did was extract RPU, encode normally like an HDR file and inject RPU and it worked! Maybe it helped that the original was a hybrid!
Question, I tried both cropped RPU and no crop RPU and made 2 files, both look the same to my eyes. Is cropping RPU really make a huge difference?
GodzilaAvenger
9th September 2023, 07:52
This may help. (https://forum.doom9.org/showthread.php?p=1979732#post1979732)
Boulder
9th September 2023, 08:05
Couldn't get the files to switch on the DV mode, so I have to ask Sony if they can tell me which profiles are supported. I'm not keeping my hopes up too high because the support people may see the same information I see on their pages :D
Well, they never got back to me which does not surprise me, but I got a Homatics R box and the RPU injected encodes at least trigger Dolby Vision on the old Sony :D I have to try and see if the picture itself looks okay, I just tested on Death Wish which is probably not the best sample itself.
NeverExists
11th September 2023, 05:58
does this tool allow hdr extraction? cause I have an SDR video stream from one file that I'm using, and HDR and Dolby Vision metadata from a web release.
GodzilaAvenger
11th September 2023, 07:52
If I'm not mistaken you can't just turn an SDR video into HDR by adding metadata. SDR uses 8-bit colors and HDR uses 10-bit ones, so the base video streams are completely different. That HDR/DV metadata just tells the display how to adjust its brightness.
Yosho
12th September 2023, 17:34
How could we go about fixing:
Format : Timed Text
Muxing mode : sbtl
Codec ID : tx3g
Duration : 1 h 53 min
Bit rate mode : Variable
Bit rate : 69 b/s
Frame rate : 0.409 FPS
Stream size : 57.3 KiB (0%)
Title : Traditional
Language : English
Service kind : Dubbed
Default : No
Forced : No
If original was:
Format : UTF-8
Codec ID : S_TEXT/UTF8
Codec ID/Info : UTF-8 Plain Text
Duration : 1 h 52 min
Bit rate : 63 b/s
Frame rate : 0.287 FPS
Count of elements : 1945
Stream size : 52.7 KiB (0%)
Title : Traditional
Language : Cantonese (Hant)
Default : No
Forced : No
Before conversion?
Is this an mp4box issue perhaps?
GodzilaAvenger
12th September 2023, 19:34
I'm not sure if this thread is the right place to ask this question, as it doesn't deal with either subtitles or mp4box. You'd probably have better luck searching the forum or creating a new post.
Yosho
13th September 2023, 02:49
I'm not sure if this thread is the right place to ask this question, as it doesn't deal with either subtitles or mp4box. You'd probably have better luck searching the forum or creating a new post.
Oh, I see. I had thought this section was for the tool discussion, and help.
Arkana
13th September 2023, 05:43
How do I add borders?
Atlantis
13th September 2023, 17:27
When injecting what is "Match L6 Metadata Change L6 Metadata to match Video"? Should it be yes or no?
GodzilaAvenger
13th September 2023, 19:07
It matches the RPU's L6 values to those of the video, which you can find using MediaInfo. I remember quietvoid saying L6 values don't really matter and I've also seen a lot of files just have it be set to 0 (the MaxCLL and MaxFALL values), so do with it as you please.
Atlantis
13th September 2023, 19:16
I really like Dolby Vision, it seems like nothing matters in the settings, nothing you do can make it go wrong! :)
GodzilaAvenger
13th September 2023, 22:19
:)
Most of the time only L1 & L2 matter. L5 also matters if your playback device looks for it.
dkangel
20th September 2023, 17:06
hello everybody
sorry for my bad english but it's not my native langage.
i have 2 files. one is DV 23.76fps and one is hdr 24fps with exactly the same frames.
the 24 fps have french langage so i would like to import DV into this file.
i read the previous thread and some guys says that the DV is not FPS dependent so i can just use it with dvtools hybrid.
but why is there an option to convert fps in hybrid script ?
thank you
von Suppé
21st September 2023, 05:22
It is true that RPU works with framenumbers and framerate does not matter.
The option to change framerate may come in handy for e.g. cases where you want to be able to sync video with a certain audiotrack that comes from another source with a different framerate. Especially where you can't stretch/shrink the audio, such as Atmos (at least, not with freeware). I've done it several times to sync 24 fps (DoVi or not) video to 23.976 audio or vice versa.
I've never used this option in QfG's script as I always rewrite timestamps for HEVC streams manually with a ffmpeg.exe commandline. I'm educationally guessing QfG would make use of this too in his script. Maybe he cares to confirm.
dkangel
21st September 2023, 15:54
oh thank you for your answer, it's more clear for me. :)
but if i understand you correctly, it's possible to change fps of a video without recoding ?
Atlantis
21st September 2023, 19:01
Of course, but the audio goes out of sync. You have to re-encode the audio.
dkangel
21st September 2023, 19:56
ok i understand.
thank you very much
von Suppé
22nd September 2023, 08:30
...I always rewrite timestamps for HEVC streams manually with a ffmpeg.exe commandline. I'm educationally guessing QfG would make use of this too in his script. Maybe he cares to confirm.
I think my guess is right. Not having parsed the whole script, I did find the "-bsf:v hevc_metadata=tick_rate=" argument in the DDVT_HYBRID.cmd script.
Should you want to manually change framerate of a hevc stream, here's two examples. Create a .cmd file with Notepad and type following string for rewriting timestamps for "23.976" fps:
ffmpeg -i input.hevc -c copy -bsf:v hevc_metadata=tick_rate=(24000/1001):num_ticks_poc_diff_one=1 output.hevc
For 24 fps type:
ffmpeg -i input.hevc -c copy -bsf:v hevc_metadata=tick_rate=24:num_ticks_poc_diff_one=1 output.hevc
Where obviously "input.hevc" is the source-stream and "output.hevc" will be the result. Put the cmd file with a copy of ffmpeg.exe in same folder where input-stream is and run.
-QfG-
24th September 2023, 20:57
but why is there an option to convert fps in hybrid script ?
Simply for dubbing. I'm from Germany and i must dub sometimes US movies. If i have a German BD with 24 FPS, but the Hybrid stream is 23,976 fps, i change the fps of the stream.
This function is not needed to adjust DV timestamps.
Atlantis
25th September 2023, 01:08
Is it possible to convert those strange purple looking Dolby Vision files to DV that is compatible with HDR?
Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU
GodzilaAvenger
25th September 2023, 07:42
They use different color spaces, so the practical answer is no. Look at earlier posts for more info.
Atlantis
25th September 2023, 14:00
I can't read 720 posts! But it was so easy. You don't need to know anything to do Dolby Vision! Extracted the RPU and added it to an HDR version. Nothing goes wrong with DV!
von Suppé
25th September 2023, 17:15
I'd say much can go wrong with Dolby Vision. I made quite a bunch of mistakes in the beginning. Goes with learning.
Atlantis
25th September 2023, 17:33
I mean for us the simple users using the Dolby_Vision_Tool. It's so well written. It proposes all the correct settings by default.
GodzilaAvenger
25th September 2023, 19:26
I tend to agree with von Suppè, you can easily screw up DV if your RPU isn't synced with your file, e.g. when RPU is from a WEB-DL source and you add it to a Blu-ray, which causes weird flashes; or you can set the L5 wrong which (if your playback device cares for it) crops in too much.
Atlantis
25th September 2023, 19:26
I didn't use the DDVT_HYBRID.
Extracted the RPU from DV and added it to an HDR version.
Does DDVT_HYBRID do something more, or using DDVT_DEMUXER and DDVT_INJECTOR is enough?
(I obviously frame check to see that the versions match frame by frame)
GodzilaAvenger
25th September 2023, 21:06
As far as I know hybrid is just demuxer and injector rolled into one, for convenience. Demuxes RPU from one file and injects into another.
Fuso
27th September 2023, 09:02
Is there a way to implement also DoVi baker, for combining the FEL from P7 with the base HDR?
von Suppé
27th September 2023, 15:27
Is there a way to implement also DoVi baker, for combining the FEL from P7 with the base HDR?
Would you care to explain what "DoVi baker" is? Never heard of the term.
dkangel
27th September 2023, 16:30
Simply for dubbing. I'm from Germany and i must dub sometimes US movies. If i have a German BD with 24 FPS, but the Hybrid stream is 23,976 fps, i change the fps of the stream.
This function is not needed to adjust DV timestamps.
Thank you for your explanation. I understand it's better to change fps of the video without recoding than recoding audio.
GodzilaAvenger
28th September 2023, 00:01
Would you care to explain what "DoVi baker" is? Never heard of the term.
DoViBaker adds the EL information into the BL, essentially turning P7 into P8 without fully discarding the EL. At least that's what I think it does based on its GitHub repo.
-QfG-
5th October 2023, 22:04
v0.61 Online!
-v0.61
*Minor Bugfixes
*Some changes in scripts layout
*RENAMED Script Frameinfo.cmd to Fileinfo.cmd
Support for plotting DV / HDR10+ metadata graphs to png picture file.
If u use shell extensions start Options.cmd and reset Shell Extensions!
*Updated mkvtoolnix to v 79.0.0.0.
https://i.imgur.com/7IEDyAgh.png
EDIT v0.61a Online, some bugfixes.
von Suppé
6th October 2023, 11:16
Support for plotting DV / HDR10+ metadata graphs to png picture file.
Excellent addition, QfG.
A DoVi power user @ the MakeMKV forums has provided significant information on cases under what conditions certain RPU can or should not not be injected into BD video because of brightness expansion through FEL. Surely there are DoVi (Gung Ho) adventurers here that may appreciate it.
Hopefully you don't mind me putting up the link:
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit#gid=0
dkangel
6th October 2023, 21:17
Thanks for the update but i don't see the hybrid shorcut anymore...
-QfG-
6th October 2023, 21:55
Hybrid Shortcut works only on background. Don't target a file an click the right button.
dkangel
6th October 2023, 22:04
Hybrid Shortcut works only on background. Don't target a file an click the right button.
ok thank you :)
dkangel
6th October 2023, 22:29
i have one more question
what would be the easy way to convert a profile 7 to profile 8 ?
-QfG-
6th October 2023, 23:06
V0.61.1 Online!
-v0.61.1
*Minor Bugfixes
*ADDED Video Bitrate Plotter in FILEINFO Script.
*ADDED MediaInfo File Writer in FILEINFO Script.
https://i.imgur.com/pnmaCwOh.png
what would be the easy way to convert a profile 7 to profile 8 ?
Use <DDVT_DEMUXER> Script if u will demux only the RPU in Profile 8 from Profile 7 Single Layer File
Use <DDVT_HYBRID> Script if you have a target movie. First place your target movie in the first HDR section and the DV P7 Movie in the secondary DV section.
dkangel
6th October 2023, 23:17
in fact i would like to convert a profile 7 file to profile 8 to gain space, i don't need the FEL
i will try your solution
thank you
-QfG-
7th October 2023, 08:58
P8 is always a DV profile without EL (FEL/MEL) and have only the RPU (Dynamic Metadata).
dkangel
8th October 2023, 12:41
yes i understand that.
it seems that a lot of player can't read FEL so profile 8 is enough for me
i have a shield
GodzilaAvenger
9th October 2023, 05:49
V0.61.1 Online!
-v0.61.1
*Minor Bugfixes
*ADDED Video Bitrate Plotter in FILEINFO Script.
*ADDED MediaInfo File Writer in FILEINFO Script.
Use <DDVT_DEMUXER> Script if u will demux only the RPU in Profile 8 from Profile 7 Single Layer File
Use <DDVT_HYBRID> Script if you have a target movie. First place your target movie in the first HDR section and the DV P7 Movie in the secondary DV section.
When I tried using the FILEINFO script it errored out, saying "RPU_[All Frames Info].json Error". I noticed that the .json files where generated, but at the DDVT root folder instead of the RPU folder. A new folder named "SAME AS SOURCE" also popped up in the DDVT root folder.
-QfG-
9th October 2023, 06:06
-v0.61.2
*Minor Bugfixes
*FIXED FFPROBE Bug with UAC On.
When I tried using the FILEINFO script it errored out, saying "RPU_[All Frames Info].json Error". I noticed that the .json files where generated, but at the DDVT root folder instead of the RPU folder. A new folder named "SAME AS SOURCE" also popped up in the DDVT root folder.
Fixed with v. 0.61.2
GodzilaAvenger
9th October 2023, 07:56
It doesn't seem to work with v0.61.2 either. I got it working by adding "!INPUTFILEPATH!" in front of !INPUTFILENAME! on lines 558, 567, 580, and 581.
-QfG-
9th October 2023, 08:53
Hmmmm it looks so if the script ignore the "pushd %~dp1" function. Will fix this ;).
EDIT:
--v0.61.3
*Updated dovi_tool to v2.1.0.
*Minor Bugfixes
*REMOVED Crop Check function in DEMUXER script.
*ADDED Crop Check function in FILEINFO script.
*ADDED SCENECUTS option in FILEINFO script without extracting ALL frames.
Try v0.61.3 :D
NeverExists
17th October 2023, 02:01
Hi, What is this FILEINFO script and how do we access it?
von Suppé
17th October 2023, 09:18
It's for retrieving certain informations of a video- and/or RPU file. You can also use it for getting FRAMEINFO, which script was in earlier packages.
Just drag & drop a file on DDVT_FILEINFO.cmd and it'll opt for several actions which are pretty self-explanatory.
von Suppé
18th October 2023, 10:25
Hi -QfG-
I noticed the demuxer script doesn't support DoVi P7 dual-track mp4 files. Is there a particular reason to this?
Atlantis
18th October 2023, 11:34
How do you work with HDR10+? Is it like Dolby Vision, demuxing and injecting a file?
I did a test, the RPU.bin file is 39 MB and the HDR10Plus.json is 224 MB! Is this normal? The HDR10+ metadata is so much larger than Dolby Vision?
von Suppé
18th October 2023, 12:02
Yes, similar to RPU, HDR10+ metadata can be extracted and injected.
I imagine HDR10+ binaries being of comparable size to RPU. Keeping the data in .json would require more space.
Atlantis
18th October 2023, 14:53
You mean when you inject the HDR10+ data, it will become smaller and not occupy the json file size?
-QfG-
18th October 2023, 20:38
Hi -QfG-
I noticed the demuxer script doesn't support DoVi P7 dual-track mp4 files. Is there a particular reason to this?
Will check if i can support this feature in next update.
You mean when you inject the HDR10+ data, it will become smaller and not occupy the json file size?
https://forum.doom9.org/showthread.php?p=1992626#post1992626
quietvoid
19th October 2023, 00:09
No, HDR10+ Metadata is a RAW JSON file included in the stream
What? No.
The JSON is always reencoded into a binary representation which is a lot smaller, then added into the bitstream as SEI.
It's smaller than Dolby Vision in the actual video stream.
von Suppé
19th October 2023, 10:42
I imagine HDR10+ binaries being of comparable size to RPU. Keeping the data in .json would require more space.
Just for getting the idea of difference in sizes of HDR10+ binaries in hevc stream and written as json format:
I did a testvideo which is a 5 min hevc stream including HDR10+ metadata. Which size is 2,580,627 KB. When HDR10+ is removed, the size is 2,580,114 KB. So the HDR10+ in-stream binaries would take up approx 513 KB, if my guess would be valid.
Whereas extracting and saving HDR10+, the json file comes out 7,095 KB.
Atlantis
19th October 2023, 13:54
I did a test and indeed when you inject the HDR10+ Metadata into the video, it goes back to smaller size.
After injection it is actually smaller than the Dolby Vision RPU. Extracted, the .json is 5 times bigger than RPU!
-QfG-
19th October 2023, 19:50
What? No.
The JSON is always reencoded into a binary representation which is a lot smaller, then added into the bitstream as SEI.
It's smaller than Dolby Vision in the actual video stream.
Thanks mate, ok here the correct answer. :thanks:
olinko
21st October 2023, 17:37
Sorry if this has been answered already but I'm really having a tough time with this.
the goal: make an MP4 Dolby Vision profile 8 file out of a MKV DV Profile 7 file (=because I have an LG OLED which doesn't accept MKV Dolby Vision, only MP4 profile 5 & 8 Dolby Vision).
1) I demuxed the MKV, didn't save the HDR BL or the DoVi EL, saved and converted the RPU to Profile 8.1 HDR, didn't do any cropping
2) I injected the .bin file and muxed it in MKV with the injector (0 delay, no change in FPS, no change in L6 metadata)
(2.1) I used fastflix to remove any VOB subtitles from the original MKV file (while leaving the video untouched) so I can use the MKVTOMP4 script)
3) I used to MKVTOMP4 to output an MP4 file and also changed the audio codec to AC-3 @640k (because LG OLEDs don't support lossless audio formats)
in the end, the video part was fine, the Dolby Vision was working but there was significant audio delay (or is it video delay, the audio is early for a second or two).
the question: Which part am I doing wrong? Is it because I used fastflix to remove the VOB and in the process screwed something up or do I really always need to account for a video delay in the resulting MP4?
If so, I'm assuming I need to fix that at step 2) above and set the delay for X amount of frames. How can I know how many frames I need to delay it by?
EDIT: reading back, I see that I need to use the file info script and get the json file of all the scene cuts... but how does that help me if I can only compare it to the finished MP4 after I've already injected it. What do I do with the JSON file? (I've also installed the DJV software you recommended, but also not sure what I'm supposed to do with it)
GodzilaAvenger
21st October 2023, 19:50
From my experience with Fastflix (and FFmpeg in general) the video and audio timestamps can get screwed, so maybe try removing those subtitles with mkvtoolnix and see if you get a better result. You can also use FFmpeg to rewrite the timestamps (with genpts I think).
The scene cut .json file is to check if the Dolby Vision RPU is in sync with the base HDR stream, which I don't think is relevant here. You can use DJV to check if at the frame numbers the .json file says there is a scene cut, there actually is a scene cut. Just note that DJV starts from frame 1, while RPUs start from 0.
olinko
21st October 2023, 22:55
From my experience with Fastflix (and FFmpeg in general) the video and audio timestamps can get screwed, so maybe try removing those subtitles with mkvtoolnix and see if you get a better result. You can also use FFmpeg to rewrite the timestamps (with genpts I think).
The scene cut .json file is to check if the Dolby Vision RPU is in sync with the base HDR stream, which I don't think is relevant here. You can use DJV to check if at the frame numbers the .json file says there is a scene cut, there actually is a scene cut. Just note that DJV starts from frame 1, while RPUs start from 0.
Thanks!
von Suppé
22nd October 2023, 13:42
@olinko
Your source is P7 mkv. That means BL and EL+RPU are interleaved into one videotrack. You want to create P8 DoVi, which would be BL+RPU. There is no EL with P8.
1) I demuxed the MKV, didn't save the HDR BL or the DoVi EL...
The step I'm missing in your workflow is de-interleaving the mkv videotrack to retreive separate BL and EL+RPU streams. Note that only demuxing a P7 DV mkv leaves you with a videotrack that still holds interleaved BL and EL+RPU. So you do have to save BL (and indeed convert RPU into P8). I think this could be reason your file doesn't play right. Please correct me if I'm missing something.
It's only the BL you need to inject the P8-converted RPU into.
von Suppé
23rd October 2023, 12:05
Not only for @olinko's post, I'm currently more getting into Dolby Vision in mp4. If I'm not mistaken gpac mp4box.exe is the cli-tool used for creating them. First off, can somebody tell me if there'd be an up-to-date (DoVi ready) GUI for it?
I want to learn how to create a P7 dualtrack mp4.
For arguments sake, suppose I have "BL.hevc", "EL.hevc" and "AUDIO.ac3". Can somebody tell me how the basic mp4box cli string would look like for muxing these into a P7-dualtrack mp4?
Another thing. I understand chapters are now possible in mp4. Hope somebody can explain how to add these.
As for -QfG-'s script, when dropping a P7 mkv on the DDVT_MKVTOMP4.cmd, the output remains singletrack duallayer.
For P7 in this script, I'd appreciate the option to be able to choose between singletrack-duallayer and dualtrack-duallayer mp4 output.
Cr4z33
24th October 2023, 09:32
OK I wanted to convert a profile 5 DV MKV to profile 8, but DDVT_DEMUXER.cmd says
Video Info = [Resolution = 3840x2020] [Codec = HEVC-10Bit-YUV-4:2:0] [Frames = 193212] [FPS = 23.976]
HDR Info = [n.a.]
No Dolby Vision Profile found.
Abort Operation now.
However if I check the file with MediaInfo it reports it's a Profile 5 Dolby Vision MKV.
General
Unique ID : 327762964378660514121416967602856727062 (0xF694D9CC7158980A84655DE51AA31216)
Complete name : L:\2160p\Gran.mkv
Format : Matroska
Format version : Version 4
File size : 23.6 GiB
Duration : 2 h 14 min
Overall bit rate : 25.1 Mb/s
Frame rate : 23.976 FPS
Encoded date : 2023-10-22 13:49:22 UTC
Writing application : mkvmerge v79.0 ('Funeral Pyres') 64-bit
Writing library : libebml v1.4.4 + libmatroska v1.7.1
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@High
Codec ID : V_MPEGH/ISO/HEVC
Duration : 2 h 14 min
Bit rate : 24.8 Mb/s
Width : 3 840 pixels
Height : 2 020 pixels
Display aspect ratio : 1.901
Frame rate mode : Constant
Frame rate : 23.976 (23976/1000) FPS
Original frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.133
Stream size : 23.2 GiB (98%)
Language : Italian
Default : Yes
Forced : No
Audio
ID : 2
Format : E-AC-3
Format/Info : Enhanced AC-3
Commercial name : Dolby Digital Plus
Codec ID : A_EAC3
Duration : 2 h 14 min
Bit rate mode : Constant
Bit rate : 384 kb/s
Channel(s) : 6 channels
Channel layout : L R C LFE Ls Rs
Sampling rate : 48.0 kHz
Frame rate : 31.250 FPS (1536 SPF)
Compression mode : Lossy
Stream size : 369 MiB (2%)
Title : E-AC3 iTA
Language : Italian
Service kind : Complete Main
Default : Yes
Forced : No
Text
ID : 3
Format : UTF-8
Codec ID : S_TEXT/UTF8
Codec ID/Info : UTF-8 Plain Text
Duration : 2 h 4 min
Bit rate : 2 b/s
Frame rate : 0.013 FPS
Count of elements : 97
Stream size : 2.64 KiB (0%)
Title : FORCED
Language : Italian
Default : No
Forced : No
What can I do now? :confused:
von Suppé
24th October 2023, 11:26
I don't see anything referring to Dolby Vision.
If you'd mean the "Main 10@L5@High", this says something about certain parameters with which HEVC coding took place.
FYI this is a MediaInfo example outtake of a P5 DoVi file
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@Main
HDR format : Dolby Vision, Version 1.0, dvhe.05.09, BL+RPU
Codec ID : dvhe
Codec ID/Info : High Efficiency Video Coding with Dolby Vision
Duration : 1 min 18 s
Bit rate : 27.0 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio: 16:9
etc...
-QfG-
24th October 2023, 17:41
v0.61.4 Online!
-v0.61.4
*FIXED wrong error message during RPU.bin creating in DEMUXER Script.
*FIXED Sourcecode REMOVER Script.
Cr4z33
25th October 2023, 09:16
I don't see anything referring to Dolby Vision.
If you'd mean the "Main 10@L5@High", this says something about certain parameters with which HEVC coding took place.
FYI this is a MediaInfo example outtake of a P5 DoVi file
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5.1@Main
HDR format : Dolby Vision, Version 1.0, dvhe.05.09, BL+RPU
Codec ID : dvhe
Codec ID/Info : High Efficiency Video Coding with Dolby Vision
Duration : 1 min 18 s
Bit rate : 27.0 Mb/s
Width : 3 840 pixels
Height : 2 160 pixels
Display aspect ratio: 16:9
etc...
Yes correct, but then why do I see the movie correctly in a Amazon Fire TV Stick 4K Max with Dolby Vision enabled and purple on any other not Dolby Vision compatible device? :D
I mean isn't this already a sign the movie IS in Dolby Vision? :confused:
Atlantis
25th October 2023, 10:40
It obviously was not tagged correctly. If it is Dolby Vision tagged, Media Info says Dolby Vision.
von Suppé
25th October 2023, 12:44
On a non-DoVi device the colors being purple/green would indeed suggest the file being DoVi P5. I think @Atlantis has a point. To which I notice both 23.976 framerates where one stating 23976/1000. Which suspects me ffmpeg being involved in flawed container muxing.
Try importing and remuxing the file with MKVToolNix. When muxing Dolby Vision mkv, always force-set "Default duration/FPS" to the proper value; in your case being 24000/1001p. See if the file turns out allright in MediaInfo.
Note that even when tagged properly, a P5 DoVi file always turns up purple/green on a non-DoVi device. P5 offers no fallback video like other profiles because of Dolby's proprietary colorspace being used.
Atlantis
25th October 2023, 14:14
Can you convert RPU to HDR10+ metadata and if yes what command to use?
-QfG-
25th October 2023, 16:16
Can you convert RPU to HDR10+ metadata and if yes what command to use?
Nope. Only HDR10+ Json to DV RPU.
Atlantis
25th October 2023, 17:58
Wow, ok. I thought it should be the other way around! Since HDR10+ is an open standard I thought it should be possible to convert to something open!
mikraphne
26th October 2023, 14:34
So, basically, all I am trying to do is pull the DV data from a REMUX, then inject it into an encode. Is this possible? I tried to use DDVT Demuxer to extract the RPU, which was successful. I then tried running the DDVT Injector to inject it into the encode of that same REMUX, but it creates a raw BL+RPU.hevc. I tried bringing that hevc file into MKVToolnix to convert it over to a .mkv and re-add all the audio tracks and subs, but the file looks to still be missing DV info. When I check the Medianfo, it is just the HDR10 data.
Are you able to push the DV RPU into another .mkv and just mux in the DV data, or am I looking at this all wrong?
SeeMoreDigital
26th October 2023, 14:46
Are you able to push the DV RPU into another .mkv and just mux in the DV data, or am I looking at this all wrong?Out of interest... What make/model of playback device and display do you have?
von Suppé
26th October 2023, 15:10
REMUX is a common phrase and it's possible the file contains Profile 7 DoVi.
I tried to use DDVT Demuxer to extract the RPU, which was successful.
The demuxer script tells you what profile is found after having analyzed the input. If P7 is found, you must set CONVERT RPU to PROFILE 8.1 HDR. Such is used to inject into a single HDR HEVC video. Note that if your recode has no black bars, you also have to set CROP RPU to YES.
I am assuming here the recode has the same frames & framecount as the source.
mikraphne
26th October 2023, 15:27
REMUX is a common phrase and it's possible the file contains Profile 7 DoVi.
The demuxer script tells you what profile is found after having analyzed the input. If P7 is found, you must set CONVERT RPU to PROFILE 8.1 HDR. Such is used to inject into a single HDR HEVC video. Note that if your recode has no black bars, you also have to set CROP RPU to YES.
I am assuming here the recode has the same frames & framecount as the source.
Yeah, that part seems to work, and it does export a .RPU to a temp folder. I guess I am confused on how to mix this .RPU into another file. I basically encoded the REMUX down to a smaller size and I am looking to mix the DV data into it.
Atlantis
26th October 2023, 16:06
When you watch the file in MediaInfo in basic mode, it does NOT show Dolby Vision. It only shows Dolby Vision if you go into detail in MediaInfo.
Also in Injector you can choose output to MKV.
mikraphne
26th October 2023, 20:25
When you watch the file in MediaInfo in basic mode, it does NOT show Dolby Vision. It only shows Dolby Vision if you go into detail in MediaInfo.
Also in Injector you can choose output to MKV.
Yeah, I am looking at Medianfo's Text view. I have one video track with just HDR10, and this was the .hevc that was output from DDTV Injector.
So, I think I am missing something..
rco133
26th October 2023, 20:53
Yeah, I am looking at Medianfo's Text view. I have one video track with just HDR10, and this was the .hevc that was output from DDTV Injector.
So, I think I am missing something..
Are you using an old version of mkvtoolnix?
I mux the BL+RPU file with mkvtoolnix frequently, and the resulting mkv file always shows DV and HDR10 info.
Also mediainfo must be recent version.
-QfG-
26th October 2023, 20:54
So, basically, all I am trying to do is pull the DV data from a REMUX, then inject it into an encode. Is this possible? I tried to use DDVT Demuxer to extract the RPU, which was successful. I then tried running the DDVT Injector to inject it into the encode of that same REMUX, but it creates a raw BL+RPU.hevc. I tried bringing that hevc file into MKVToolnix to convert it over to a .mkv and re-add all the audio tracks and subs, but the file looks to still be missing DV info. When I check the Medianfo, it is just the HDR10 data.
Are you able to push the DV RPU into another .mkv and just mux in the DV data, or am I looking at this all wrong?
Simply use the DDVT_Hybrid script for this. Open the script and paste the ENCODE in the First HDR Input Video. Second Step: Paste the REMUX now in the second DV Input Video. Check the Menu if all settings are correct. Now mux the DV RPU into the ENCODE. Done.
Atlantis
26th October 2023, 21:39
Output as MKV as I always do.
-QfG-
27th October 2023, 22:38
Yes. You can always use mkv output.
von Suppé
28th October 2023, 11:14
I'm getting confused about MediaInfo here.
Would someone please confirm me either right or wrong in thinking MediaInfo only shows Dolby Vision when in-container, and not in elementary stream? For DoVi, I've always presumed it relied on metadata written on container-level.
rco133
28th October 2023, 16:58
I'm getting confused about MediaInfo here.
Would someone please confirm me either right or wrong in thinking MediaInfo only shows Dolby Vision when in-container, and not in elementary stream? For DoVi, I've always presumed it relied on metadata written on container-level.
Mediainfo will not show any DV info until you have muxed the BL+RPU file into a mkv file.
At least that is what it does here.
von Suppé
28th October 2023, 18:55
My presumption was correct then. Thanks for confirming, rco133.
SquallMX
30th October 2023, 00:04
Is there a way to convert DV level 8.1 to level 7 for Blu-ray?
DDVT Tool can convert DV 8 to 7, but after that what should I do to create a compliant UHD Blu-ray disc with a MEL DV?
Atlantis
30th October 2023, 17:19
Is it possible to set the default output to mkv in Injector? I want to avoid to change it every time.
dkangel
31st October 2023, 10:44
Is it possible to set the default output to mkv in Injector? I want to avoid to change it every time.
You can change paths with DDVT_OPTIONS.cmd
Atlantis
31st October 2023, 16:45
What about output?
dkangel
1st November 2023, 11:16
it's the TARGET path
von Suppé
1st November 2023, 11:55
DoViBaker adds the EL information into the BL, essentially turning P7 into P8 without fully discarding the EL. At least that's what I think it does based on its GitHub repo.
Hope you don't mind putting this up here, -QfG-
I'm now doing a short test video with dovibaker. Where I understand the avisynth script takes not only video from BL and FEL, but also processes RPU and merge all in one videostream. Do some of you guys already have experience with recoding this? I'm using StaxRip. The avs script seems to play correct but video encoding errors out. I already asked at the StaxRip thread, but up to now haven't received answer so I'll put the screenshots here too. If somebody can see what I'm doing wrong, please tell me.
avs script:
LoadPlugin("F:\dovibaker\DoViBaker_x64.dll")
LoadPlugin("F:\dovibaker\DGDecodeNV.dll")
bl = DGSource("F:\dovibaker\BL.dgi")
el = DGSource("F:\dovibaker\EL.dgi")
SetFilterMTMode("DoViBaker",2)
DoViBaker(bl, el, rpu= "F:\dovibaker\RPU.bin")
ConvertToYUV420(matrix="2020")
ConvertBits(10)
Prefetch(8)
StaxRip error:
https://i.postimg.cc/nLbJdKdB/Stax-Rip-video-encoding-error.png
Emulgator
1st November 2023, 19:06
Just guessing... CPU cap/build mismatch ?
I would try a different x265 build.
von Suppé
2nd November 2023, 06:31
Just guessing... CPU cap/build mismatch ?
I would try a different x265 build.
Took the one from MeGUI. Encoding as I speak. Have to wait for outrcome, but so far so good.
:thanks: Emulgator
DiscoD
5th November 2023, 18:04
Is there an extra process to convert hdr10+ to DV?
Never seems to work for me using the demuxer.
https://i.ibb.co/gzdLS1q/hdrtodverror.png (https://ibb.co/gzdLS1q)
Mark_Venture
6th November 2023, 03:28
Sorry, I'm a little late here, so I have a question I'm hoping someone would be kind enough to help with.
I have some videos that show:
ID/String : 1
Format/String : HEVC
Format/Info : High Efficiency Video Coding
Format_Profile : Main 10@L5.1@Main
HDR_Format/String : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible
CodecID : hvc1
CodecID/Info : High Efficiency Video CodingMy understanding is that this file should fall back to HDR10 IF the player or TV doesn't support DV. Is that correct?
When playing on my Roku R4670 or my FireTV 4K Max or Roku R4800 on a Sony Non-DV TV using Plex or Kodi (kodi on the firetv only of course), it seems the "fallback" isn't working as I get a greenish tint.
Files like this play fine:
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : SMPTE ST 2086, HDR10 compatible
Codec ID : hvc1
Codec ID/Info : High Efficiency Video CodingMy understanding (from elsewhere) is that this file is HDR10. Someone also suggested this file might also fall back to SDR if the player doesn't support HDR, but I don't know if that is true.
Am I reading this thread correctly that all I should need to do with the files in the first format, is drop the MP4 files onto the DDVT_REMOVER.cmd set Remove Dolby Vision Meta = Yes, and start. Then the output will be like the second file and should look right?
Is that correct?
GodzilaAvenger
6th November 2023, 08:25
DDVT_REMOVER removes the DV metadata, so yes, you should end up with an HDR10 file.
DiscoD
7th November 2023, 05:38
Sorry, I'm a little late here, so I have a question I'm hoping someone would be kind enough to help with.
I have some videos that show:
ID/String : 1
Format/String : HEVC
Format/Info : High Efficiency Video Coding
Format_Profile : Main 10@L5.1@Main
HDR_Format/String : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible
CodecID : hvc1
CodecID/Info : High Efficiency Video CodingMy understanding is that this file should fall back to HDR10 IF the player or TV doesn't support DV. Is that correct?
When playing on my Roku R4670 or my FireTV 4K Max or Roku R4800 on a Sony Non-DV TV using Plex or Kodi (kodi on the firetv only of course), it seems the "fallback" isn't working as I get a greenish tint.
Files like this play fine:
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@Main
HDR format : SMPTE ST 2086, HDR10 compatible
Codec ID : hvc1
Codec ID/Info : High Efficiency Video CodingMy understanding (from elsewhere) is that this file is HDR10. Someone also suggested this file might also fall back to SDR if the player doesn't support HDR, but I don't know if that is true.
Am I reading this thread correctly that all I should need to do with the files in the first format, is drop the MP4 files onto the DDVT_REMOVER.cmd set Remove Dolby Vision Meta = Yes, and start. Then the output will be like the second file and should look right?
Is that correct?
Make sure the devices are set to HDR only and not to any type of Dolby Vision Playback(LLDV,Automatic,etc) , I have those Roku's and my Files fallback to HDR fine with them. My files are MKV running through plex direct play but they always fallback to HDR.
ivanb
7th November 2023, 10:38
Hey guys, just wanted to drop a quick note that the new VTCLab Media Analyzer (https://media-analyzer.pro) can now show RPU headers in HEVC streams. Could be handy in some cases.
https://i.ibb.co/zVpfxZG/Screenshot-2023-11-07-at-16-23-06.png (https://ibb.co/zVpfxZG)
Grimm
12th November 2023, 21:08
Hello, I would like to ask you to add the option to set automatic start in the DDVT_OPTIONS file. Because when using demuxer and mkttomp4 I never change anything there anyway and pressing "S" becomes unnecessary
and I would like to ask you to add the option to set the default value for the mux stream in mkv yes/no item in the DDVT_OPTIONS file
Finally, I would like to ask you to add the option to create a file in the same directory as the source file without creating a separate folder. Because then you have to cut the rpu file and paste it into the source file for the injector to work, then when you convert it from mkv to mp4 it creates another folder again and that's how we get 2-3 additional folders....
In my opinion, the rpu file should be created right next to the source file so that you can immediately use the injector without having to deal with copying.
techdiver
23rd November 2023, 14:53
Hi Guys,
I recently stumbled across this tool and started using it to great success. For the most part I just run DDVT_DEMUXER.cmd on my source file with DV Profile 7 and it extract it as Profile 8 and then I use DDVT_INJECTOR.cmd to combine the base and DV layer back in. Then I use MKVToolNix to combine back into mkv which works great.
I came across an issue I hadn't seen before last night whereby after the initial scan step of DDVT_INJECTOR.cmd I saw the following:
== VIDEO INPUT =========================================================================================================
Filename = [2001.A.Space.Odyssey.1968.2160p.BluRay.REMUX.HEVC.DV.HDR10.DTS-HD.MA.5.1.mkv]
Video Info = [Resolution = 3840x2160] [Codec = HEVC-10Bit-YUV-4:2:0] [Frames = 214088] [FPS = 23.976]
HDR Info = [HDR, Dolby Vision Profile 7 Single Layer]
Borders = [LEFT=0 px], [TOP=208 px], [RIGHT=0 px], [BOTTOM=208 px] [NOT MATCH WITH RPU]
== RPU INPUT ===========================================================================================================
Filename = [RPU.bin]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 214088]
Borders = [LEFT=0 px], [TOP=207 px], [RIGHT=0 px], [BOTTOM=207 px] [NOT MATCH WITH VIDEO]
Now I just let the process Start and everything worked fine, but I'm wondering whether I've produced a "bad" file at the end?
GodzilaAvenger
24th November 2023, 07:13
It depends on the playback device, since some just discard the border values (L5 metadata, there is considerable conversation about it earlier in this thread which you can use the search tool to find). Also, the values are only off by 1 pixel so it won't be noticeable. It is also sometimes the case that ffmpeg outputs the wrong border values (the upper value).
techdiver
24th November 2023, 10:27
It depends on the playback device, since some just discard the border values (L5 metadata, there is considerable conversation about it earlier in this thread which you can use the search tool to find). Also, the values are only off by 1 pixel so it won't be noticeable. It is also sometimes the case that ffmpeg outputs the wrong border values (the upper value).
Thanks very much for the reply. I'm playing them on android tv devices (nvidia shield, Sony OLED, etc).
I'll have a search back through the thread.
Thanks.
von Suppé
25th November 2023, 09:11
As @GodzilaAvenger said, there's not to much worry about 1 pixel difference. If the values shown at the videosection were to be correct, that is.
On the other hand, why not just change RPU's L5 values to the exact amount of pixels of video's black borders? This can be done with "EDIT ACTIVE AREA" in the INJECTOR script.
The black borders detection tool can drop a stitch. I always get video's exact border sizes by manually determining them from a (cherry-picked) screenshot in an image editor.
techdiver
28th November 2023, 16:05
Cheers for the replies guys.
Another one that I have thought about is adding DV metadata from one release to say a ripped bluray remux. In some cases the duration of each mkv is different as as such I assume that a straight run of the hybrid script would not work correctly. I tested this and saw that for HDR10+ is was saying that since the timestamps are off it will ignore the metadata at the end of the file. But in the case where the difference is at the start of the file is there anything that can be done? I'm assuming no?
girod2033
28th November 2023, 18:29
Hello.
When using "DDVT_MKVTOMP4.cmd" in version v0.61.4, information about HDR was lost; in version v0.60 there is no such problem.
https://i.ibb.co/LQnRnj4/Dolby-Vision-Tool-v0-60.png (https://ibb.co/vsZqZy2)
https://i.ibb.co/Z2gh7pr/Dolby-Vision-Tool-v0-61-4.png (https://ibb.co/CP9nD3y)
dbgt7
28th November 2023, 22:15
About cropping:
1. There are any Retail Untouched RPUs without cropping informations. The tool says in this case :NO CROPPING INFORMATIONS FOUND. You can leave this RPUs untouched, but it is recommended to set the valid Borders.
I think, that no cropping informations in the RPU is the same how 0 entries. But i have no proof for this statement.
2. IMAX Format: You can do 3 Things:
Set all borders to 0 (this is the way that i use)
Set all borders to the lowest entry (Example: IMAX Scenes Borders 42/42, Normal Scenes Borders 272,272 -> set Borders to 42/42
For Freaks xd - Create a custom.json file and set all borders manually for IMAX / Normal frames. Good Luck :) In this case, don't forget to turn off border manipulation via the tool himself.
3. BORDERLESS VIDEO: If the video is cropped or full 16:9 without Black Bars, set all boreder entries to 0!
In my Tests i have no problems with RPUs with borders entries of 0 with cropped content. BUT ! I have trouble with RPUs with Border entries other than 0 by cropped (borderless) content!
In all cases it is recommended to set the correct borders in the RPU for maximal compatibility with the hardware players.
Does this still applies? So if i have a movie with mixed IMAX and normal widescreen content, do i set borders to 0? DDVT says top and bottom video border are 208 px and rpu top and bottom borders are 207 px.
Do i need to crop video borders to 0? or crop rpu? or both??
GodzilaAvenger
29th November 2023, 03:36
Cheers for the replies guys.
Another one that I have thought about is adding DV metadata from one release to say a ripped bluray remux. In some cases the duration of each mkv is different as as such I assume that a straight run of the hybrid script would not work correctly. I tested this and saw that for HDR10+ is was saying that since the timestamps are off it will ignore the metadata at the end of the file. But in the case where the difference is at the start of the file is there anything that can be done? I'm assuming no?
When adding DV or HDR10+ metadata you have to make sure that it's synced with the video stream, otherwise there'll be annoying artifacts (jumps in brightness). This is especially true when using sources from different medium, like digital vs. Blu-ray, as those are usually not synced because of some initial logo or something.
To check if the metadata is synced with the file you can use the FILEINFO script to get the scene cuts (frame numbers where scenes change, frame numbers starting from 0), and match that with the frame number in the actual video (I like using djv, though be careful since in it frame numbers start from 1, not 0). You can then apply the positive or negative delay in the INJECTOR script (I haven't used the HYBRID script but if it has a delay option you can use that too).
GodzilaAvenger
29th November 2023, 03:42
Does this still applies? So if i have a movie with mixed IMAX and normal widescreen content, do i set borders to 0? DDVT says top and bottom video border are 208 px and rpu top and bottom borders are 207 px.
Do i need to crop video borders to 0? or crop rpu? or both??
For mixed aspect ratio content I recommend leaving the RPU borders as they are, i.e. the border part should display something like "[LEAVE UNTOUCHED]". Another option would be to set the borders to the height of the smallest black bar (corresponding to the tallest scene(s)).
techdiver
29th November 2023, 12:24
When adding DV or HDR10+ metadata you have to make sure that it's synced with the video stream, otherwise there'll be annoying artifacts (jumps in brightness). This is especially true when using sources from different medium, like digital vs. Blu-ray, as those are usually not synced because of some initial logo or something.
To check if the metadata is synced with the file you can use the FILEINFO script to get the scene cuts (frame numbers where scenes change, frame numbers starting from 0), and match that with the frame number in the actual video (I like using djv, though be careful since in it frame numbers start from 1, not 0). You can then apply the positive or negative delay in the INJECTOR script (I haven't used the HYBRID script but if it has a delay option you can use that too).
Excellent. Thanks for the reply! :thanks:
-QfG-
5th December 2023, 05:12
-v0.61.5 Online.
*FIXED missing HDR Info String in mkvtomp4 script with DV P5 files.
*Updated mkvtoolnix to v 81.0.0.0.
EDIT: Little error in the DEMUXER script, it's fixed now, no version update, simply download again. (12/08/2023)
NeverExists
16th December 2023, 07:22
Hi, with Wandavision Web Version, when I try to extract the RPU It recognizes Dolby Vision Profile 5, but then gives an error saying 0 frames parsed.
Edit: NVM It's cause it was an mp4. using MKVToolnix to convert it to mkv, then running through the demuxer worked.
cool advertise
19th December 2023, 13:16
-v0.61.5 Online.
I think I found a bug in your tool, in the demuxer, when you have an .mkv with only hdr10+, without dolby vision, and you want to extract or demux the hdr10+ in a HDR10Plus.json file, the tool does not extract it. :(
EDIT: I had the first version of the tool v0.61.5, now I have downloaded the latest one and everything works, sorry...
-QfG-
21st December 2023, 22:11
No problem. :)
NVM It's cause it was an mp4. using MKVToolnix to convert it to mkv, then running through the demuxer worked.
Will check and fix mp4 demuxing in the next version.
GodzilaAvenger
24th December 2023, 04:19
I recently got the new Avatar (2009) Blu-ray which comes with Dolby Vision FEL, but when I looked at the RPU the brightness data seems to be static, like HDR10 (the L1 plot is just a straight line). I found a web source with HDR10+ metadata that seems to be far more dynamic when it comes to scene-by-scene (or even frame-by-frame) L1 data. So my question is, should I stick to the original RPU or should I convert the HDR10+ one to DV RPU and inject it into the file?
-QfG-
28th December 2023, 02:47
You must check the frames by the Seamless Branching CAN UHD. The Extended Cut from the CAN UHD has 396 Frames more as the BD and WEB versions. Theatrical Cut from the US UHD has better quality, but no DV. You can add the DV EL Layer from the CAN Theatrical Cut into the US UHD.
GodzilaAvenger
28th December 2023, 21:16
I have the US UHD Steelbook Theatrical Cut which does come with P7 DV FEL. The problem is that like every other 4K release of Avatar the brightness data in the RPU is just the same value for all scenes (essentially HDR10). But, I've found a web source (of the Theatrical Cut) with HDR10+ metadata where the brightness is dynamic. So my question is, do I stick to the original RPU, or should I turn the HDR10+ metadata into a new RPU and inject it instead?
von Suppé
3rd January 2024, 10:10
GA, why don't you just give HDR10+ a try and see if the result looks better than with native FEL/RPU.
Chances are that the HDR10+ video be of other grading, but in the end your eyes are the final judge.
GodzilaAvenger
6th January 2024, 23:31
So, to my eyes they pretty much look the same, but then again I'm not that good at judging picture quality in general, so I was wondering if there's a best practice in this situation since I don't know much about mastering or color grading or metadata generation.
sofakng
7th January 2024, 02:03
Can somebody explain the RPU and its relationship to profile 5 and profile 8?
If I understand correctly, the RPU is the dynamic metadata packets describing the change in brightness per frame/scene, etc.
Does profile 5 contain RPU data or is it 'already applied' (encoded) into the video stream?
I know profile 5 doesn't contain a base layer (and has a different colorspace) from profile 8 but I'm still trying to understand the basics...
GodzilaAvenger
7th January 2024, 09:34
Your understanding of RPU is generally correct (it also has dynamic tone-mapping data). P5 and P8 both have a base layer and an RPU, P5 base layer uses a different color space from the one that P8 uses to be backwards compatible with HDR10. You can use dovi_tool (which is baked into DDVT) to convert P5 RPU to P8.
-QfG-
21st January 2024, 20:55
-v0.62 Online
*UPDATED Complete overhaul of the Injector script.
*ADDED Feature for settings custom mkvtoolnix path in Options.
*Updated mkvtoolnix to v 82.0.0.0.
*FIXED minor bugfixes
Axeldook
21st January 2024, 22:08
Thank you
great tool for DV'ing my mkv's that wont play DV on my LG c1's.
Quick question, any way to add chapters ?
thank you
-QfG-
22nd January 2024, 20:30
You can simply add chapters with mkvtoolnix.
SeeMoreDigital
22nd January 2024, 21:23
...great tool for DV'ing my mkv's that wont play DV on my LG c1's.
What device are you going to play them with?
Axeldook
23rd January 2024, 21:13
Hi,
LG C1 with Plex app
Axeldook
23rd January 2024, 21:15
Hi,
MKV tool nix doesnt do mp4
Nico8583
23rd January 2024, 23:35
Hi,
mkvtoolnix now supports Dolby Vision but can't directly convert Profile 7 to Profile 8.1. Is there a way to convert MKV Profile 7 from mkvtoolnix to MKV Profile 8.1 directly ? So just convert video track and keep other elements untouched.
Thank you.
von Suppé
24th January 2024, 08:39
MKV tool nix doesnt do mp4
Doesn't the DDVT_MKVTOMP4 script work for you?
[EDIT] My bad, apologies. The script doesn't convert 7 to 8.1.
I take it your tv doesn't support P7?
Axeldook
24th January 2024, 11:19
Hi,
thank you for all the responses.
LG oled wont play DV MKV, only DV mp4.
hence the ask, is there a way to add chapters to the mp4 files once ive used this tool to convert from mkv to mp4
von Suppé
24th January 2024, 12:37
Cli-tool mp4box.exe has the capability to write chapters in mp4 container. Eventhough QfG-dovitools has this onboard, I think adding chapters has not been implemented in the DDVT_MKVTOMP4 script. Hopefully @-QfG- has it on the to-do list.
If you don't mind a workaround with 3rd party tools, you can use CleverFFMpegGUI (frontend to cli-tool ffmpeg.exe) to add chapters to mp4 files. AFAIK it would only accept timecodes.txt files, so you'd first have to extract the chapters from your mkv into that format. Which chapterEditor is capable of.
https://www.videohelp.com/software/clever-FFmpeg-GUI
https://www.videohelp.com/software/ffmpeg
https://www.videohelp.com/software/chapterEditor
Axeldook
24th January 2024, 12:39
great stuff. will give it a try and report back
thank you
von Suppé
24th January 2024, 12:59
will give it a try...
FYI when in chapterEditor, in the upper-left corner choose "Chapter editors" in which window you click on "Converter".
Select your mkv with "File" and at "Output format" choose "Timecodes (txt)". Beware to set proper and same Source- and Target FPS.
At last "Save as" and Bob's your uncle.
[EDIT]
To all, my apologies. I was mistaken in thinking ffmpeg accepting a chapter-timestamps textfile. I've asked hubblec4 (chapterEditor) for help.
-QfG-
26th January 2024, 20:27
-v0.63 Online!
*UPDATED Complete overhaul of the DEMUXER script.
*UPDATED Complete overhaul of the REMOVER script.
*UPDATED No more Target subfolders.
*FIXED minor bugfixes
I think adding chapters has not been implemented in the DDVT_MKVTOMP4 script. Hopefully @-QfG- has it on the to-do list.
DDVT_MKVTOMP4.cmd - Line 287:
Erase the switch "-map_chapters -1". I hope this works.
Or:
https://ikyle.me/blog/2020/add-mp4-chapters-ffmpeg
Is there a way to convert MKV Profile 7 from mkvtoolnix to MKV Profile 8.1 directly ?
Yes. Open the DDVT_HYBRID.cmd script. Now add in the HDR section your P7 File. Now add the same P7 file in the DV section. Press start and you have a P8 Hybrid.
Axeldook
27th January 2024, 09:45
great work !
AgentXXL
27th January 2024, 21:10
Just wondering if I missed something in the conversation... I was using 61.5 with no problems but I saw that 62 had been released so I updated to it. I noticed that there is no longer an option to mux the DV injected stream into a mkv with the audio and subtitles. I came back to check today and saw that v63 was released so I installed it, thinking it might fix the missing option (used to be option 5 for the injector script). I know I can manually remux using MKVToolnix, but is there a reason why that is no longer an option in v62/63?
Regardless, thanks again for these amazing scripts!
Nico8583
28th January 2024, 02:14
Yes. Open the DDVT_HYBRID.cmd script. Now add in the HDR section your P7 File. Now add the same P7 file in the DV section. Press start and you have a P8 Hybrid.
Thank you, just tried it and it works.
-QfG-
28th January 2024, 16:01
Just wondering if I missed something in the conversation... I was using 61.5 with no problems but I saw that 62 had been released so I updated to it. I noticed that there is no longer an option to mux the DV injected stream into a mkv with the audio and subtitles. I came back to check today and saw that v63 was released so I installed it, thinking it might fix the missing option (used to be option 5 for the injector script). I know I can manually remux using MKVToolnix, but is there a reason why that is no longer an option in v62/63?
Regardless, thanks again for these amazing scripts!
The muxing Option is only available, if your Input File is a *.mkv or *.mp4. The setting is in the Injector Script default = Disabled and in the Hybrid Script default = enabled. Otherwise send me a screenshot from the Menu and i will check for errors.
EDIT: There is a fixed version 0.63 Online, a little mistake in INJECTOR script with the logfile. But the mux function still works:
https://i.imgur.com/85JuuYNl.png
AgentXXL
31st January 2024, 20:34
The muxing Option is only available, if your Input File is a *.mkv or *.mp4. The setting is in the Injector Script default = Disabled and in the Hybrid Script default = enabled. Otherwise send me a screenshot from the Menu and i will check for errors.
EDIT: There is a fixed version 0.63 Online, a little mistake in INJECTOR script with the logfile. But the mux function still works:
I always use .mkv source files. I downloaded 0.63-Fixed and I'm still seeing no mux option. Here's screenshots from both Injector and Hybrid scripts.
Note that when I use DDVT_Options.cmd, it doesn't add a menu item for Hybrid. I also preferred the old method where it looked for a RPU.bin instead of needing to drag and drop.
I suspect it may be the menu entries in the registry are corrupted somehow - if I choose Remove from DDVT_Options.cmd, the menu items are still there, even after a reboot. I'll try manually removing them from the registry.
Sorry for the large pictures... forgot to resize before posting.
AgentXXL
31st January 2024, 20:48
I suspect it may be the menu entries in the registry are corrupted somehow - if I choose Remove from DDVT_Options.cmd, the menu items are still there, even after a reboot. I'll try manually removing them from the registry.
OK, after removing the entries from the registry manually I re-ran DDVT_Options.cmd after deleting the existing .ini file. Now I don't get context menus at all. Running Win11 Pro 23H2 fully updated.
Thoughts?
bobowb
1st February 2024, 11:11
Hello guys i am new here so please be good help me !
my TV is LG OLED C8 and i use the internal TV player to play movies As i know the TV supports DV Profile 8 too . I have problem with most of these "hybrid" DV-HDR .mkv files like the one below . The TV can play such files but the problem is that they always play in HDR mode and cant trigger the TV DolbyVision mode .
I have been tried these:
ffmpeg -i inputfile.mkv -c:v copy -c:a copy -strict unofficial outputfile.mp4
and to mux the .mkv file to .m2ts with tsMuxeR
but unfortunately the TV plays the .mp4 and .m2ts files again just in HDR mode but not in DolbyVision! I have been tried and all DDVT Tools scripts but no luck ... :(
So my question is there any more simple way to make the internal LG TV player to play such "Hybrid" files in DolbyVision mode ? Thank you in advance !
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L5@High
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 1 h 2 min
Bit rate : 23.2 Mb/s
Width : 3 840 pixels
Height : 1 606 pixels
Display aspect ratio : 2.40:1
Frame rate mode : Constant
Frame rate : 23.976 (24000/1001) FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.157
Stream size : 10.1 GiB (97%)
Language : English
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0050 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 765 cd/m2
Maximum Frame-Average Light Level : 293 cd/m2
Axeldook
1st February 2024, 20:49
Hi MAte
i have some C2's and they will only play DV if you remove subs and chapters (mkvtoolnix) then with the new mkv file with just audio and video, drag and drop into the 'DDVT_MKVTOMP4' bat file and run it.
the Mp4 file it outputs will run in DV.
bobowb
2nd February 2024, 14:47
Hi MAte
i have some C2's and they will only play DV if you remove subs and chapters (mkvtoolnix) then with the new mkv file with just audio and video, drag and drop into the 'DDVT_MKVTOMP4' bat file and run it.
the Mp4 file it outputs will run in DV.
Thank you very much for the tip my friend ! Will test it later and report the result here :thanks:
P.S Well i did all like you said but the TV doesnt trigger the DV mode again and unfortunately plays the .MP4 file just in HDR mode ... :(
guest
3rd February 2024, 02:15
Thank you very much for the tip my friend ! Will test it later and report the result here :thanks:
P.S Well i did all like you said but the TV doesnt trigger the DV mode again and unfortunately plays the .MP4 file just in HDR mode ... :(
Hi "bob",
I haven't done this for a little while, but when I was doing DV stuff to play on my LG with the "built in player", I found that you needed to remove this part :- HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU,HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible, using these tools, and I also found that it would only display DV when it was either a .ts or .m2ts file !!!!
So referencing AgentXXL's screenshot, I'd used item #4 in the "MENU" to "remove HDR10+"
EDIT:- I have been "playing around" with the latest build on a Hybrid video, and there appears to be no where you can remove any HDR10 info (as shown in the above screenshot), Menu item #4 isn't available :(
bobowb
3rd February 2024, 08:44
Hi "bob",
I haven't done this for a little while, but when I was doing DV stuff to play on my LG with the "built in player", I found that you needed to remove this part :- HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU,HDR10 compatible / SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible, using these tools, and I also found that it would only display DV when it was either a .ts or .m2ts file !!!!
So referencing AgentXXL's screenshot, I'd used item #4 in the "MENU" to "remove HDR10+"
EDIT:- I have been "playing around" with the latest build on a Hybrid video, and there appears to be no where you can remove any HDR10 info (as shown in the above screenshot), Menu item #4 isn't available :(
Thank you TDS but i already tried to remove the HDR+ metadata with DDVT_REMOVER.cmd (actually it removes just HDR+ but the HDR cant be removed)and to demux file to .m2ts but this doesnt make the TV to trigger the DV mode again ... :(
guest
3rd February 2024, 10:07
Thank you TDS but i already tried to remove the HDR+ metadata with DDVT_REMOVER.cmd (actually it removes just HDR+ but the HDR can't be removed)and to demux file to .m2ts but this doesn't make the TV to trigger the DV mode again ... :(
Yeah, well like I said, I haven't done any of this stuff for quite a while, and a LOT of things have changed, and I have forgotten probably just as much :(
Hopefully the "higher ups" will chime in with some advice.
There has to be a simple way of removing both types of HDR....
I know I was successfully modding some hybrid videos that would play on my LG.
I just need to get into it again !!!
There might be (probably is) a way to get x265 to remove the HDR & inject a DV rpu (I know it can inject an rpu.bin)
bobowb
3rd February 2024, 10:53
Ok if someone knows let share his experience please !
quietvoid
3rd February 2024, 16:49
The LG C8 doesn't work with current MP4 muxing tools. It should still work with tsMuxer if your file shows Dolby Vision in MediaInfo.
For MP4 you need to use Dolby's muxer from 2018: https://github.com/DolbyLaboratories/dlb_mp4base/tree/ad46704703d2f558a61c2dba444ae43a8e3effff/bin
Either way it's best to stick to .TS with tsMuxer, it should be working fine.
guest
4th February 2024, 02:26
The LG C8 doesn't work with current MP4 muxing tools. It should still work with tsMuxer if your file shows Dolby Vision in MediaInfo.
For MP4 you need to use Dolby's muxer from 2018: https://github.com/DolbyLaboratories/dlb_mp4base/tree/ad46704703d2f558a61c2dba444ae43a8e3effff/bin
Either way it's best to stick to .TS with tsMuxer, it should be working fine.
Yep, can confirm, simply run the "hybrid" mkv thru tsmuxer, and create a .ts or .m2ts file, and the LG will display Dolby Vision.
Only problem I have is if you "jump" (forward or back) the playback from the remote, the playback will take a second or 2 to start to play, but HDR hasn't got that issue.
guest
5th February 2024, 04:35
Attn -QfG-,
I have started using this tool again, after a long break, and the last build I used is #53
So I grabbed the latest build (#63.fixed) the other day, and when just simply wanting to extract the rpu.bin, it fails :(, however, #53 does the job, no issue :)
So I just got #60 & #62 (also noticed that there is a significant increase in the file size between #60 & #61.1, and then again between # 61.5 & #62.
#60 worked, #62 failed.
Am I missing something, or do I just need to keep using the older builds ??
Just fyi, that's all.
https://i.imgur.com/CpV5yY0.jpg
ripburnlearn
5th February 2024, 07:29
I need some guidance here. I have an Amazon firestick 4K max. I have an MKV file in 4K that's about 40GB in size. The playback is extremely choppy. I read that the Amazon firestick 4K max has trouble with files with both HDR10+ and Dolby vision. So I figured that was the issue (the other issue could also be streaming that 40GB is too much for the device to handle).
So I figured I'd use handbrake to shrink the size down. In the process of doing that I used this tool to backup the original (40GB) HDR10+ stream and remove the Dolby Vision.
I then used handbrake, only to find out it doesn't keep HDR10+, it reverts it down to HDR10. So I had this idea of injecting this newly compressed MKV with the original HDR10+ stream (using DDVT_INJECTOR) which was backed up by this program.
I tried doing that and it outputted a hevc file, rather than an MKV file. I guess I'm wondering if what I'm attempting is even possible (when I re-encode with handbrake, does that make it incompatible with the HDR10+ backup?)
Also, how do I get an MKV file? I figured the injector would inject the HDR10+.json file into the MKV and give me a new MKV file. Kinda lost as what I'm supposed to do with this hevc output.
Thanks!
GodzilaAvenger
5th February 2024, 08:42
AFAIK there are no issues with injecting DV/HDR10+ metadata into a re-encoded stream. You can use MKVToolNix to add the audio tracks/subtitles/chapters from the original .mkv along with the .hevc file and create a new .mkv.
ripburnlearn
5th February 2024, 11:56
AFAIK there are no issues with injecting DV/HDR10+ metadata into a re-encoded stream. You can use MKVToolNix to add the audio tracks/subtitles/chapters from the original .mkv along with the .hevc file and create a new .mkv.Ahhhh, good call! Completely forgot about that program being able to do that. So I was able to do it and MediaInfo says "SMPTE ST 2094 App 4, Version 1" under "HDR Format". Does that look right? In the original file where I striped out the Dolby Vision it says: "SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible". What's the significance if it missing that "HDR10+ Profile B compatible" line?
EDIT: The original file also has these included entries while the newly created file doesn't:
Mastering display color primaries : BT.2020
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 411 cd/m2
Maximum Frame-Average Light Level : 322 cd/m2
Fuso
5th February 2024, 13:15
Hello guys i am new here so please be good help me !
my TV is LG OLED C8 and i use the internal TV player to play movies As i know the TV supports DV Profile 8 too . I have problem with most of these "hybrid" DV-HDR .mkv files like the one below . The TV can play such files but the problem is that they always play in HDR mode and cant trigger the TV DolbyVision mode .
I have both B8 and C2, and also Samsung models, and so far the only universal solution is to mux them into TS/M2TS.
Profile 8 mp4 will work on both new and old type of internal LG players, but the Codec ID must be dvhe. This tool will convert to mp4 with Codec ID hev1 which plays as HDR on the B8/C8. But dvhe is not compatible with non-DoVi devices such as Samsung AU9072.
Still, it will be a great addition to add the option to chose the Codec ID when converting to mp4.
GodzilaAvenger
5th February 2024, 20:30
Ahhhh, good call! Completely forgot about that program being able to do that. So I was able to do it and MediaInfo says "SMPTE ST 2094 App 4, Version 1" under "HDR Format". Does that look right? In the original file where I striped out the Dolby Vision it says: "SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible". What's the significance if it missing that "HDR10+ Profile B compatible" line?
EDIT: The original file also has these included entries while the newly created file doesn't:
Mastering display color primaries : BT.2020
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 411 cd/m2
Maximum Frame-Average Light Level : 322 cd/m2
I'm not really sure how to interpret this. Does it play as you expect it? One possibility may be that what MediaInfo shows (info about the .mkv container) does not match the underlying .hevc stream. Another possibility, since display mastering and MaxFALL and MaxCLL are all HDR10 info, is that Handbrake stripped out the HDR10 metadata and left you with a PQ10 .hevc stream.
giyo279
6th February 2024, 07:26
I want to make an HDR10+ hybrid -- HDR10+ from the web, injected in the bluray. The HDR10+ from the web is 40 frames behind the bluray. I know there are ways to edit/sync DV RPUs to the base layer, but are there similar tools/methods for HDR10+?
GodzilaAvenger
6th February 2024, 08:06
I think you can enter the frame delay (positive or negative) in the DDVT_INJECTOR script.
Ritsuka
6th February 2024, 08:29
Ahhhh, good call! Completely forgot about that program being able to do that. So I was able to do it and MediaInfo says "SMPTE ST 2094 App 4, Version 1" under "HDR Format". Does that look right? In the original file where I striped out the Dolby Vision it says: "SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible". What's the significance if it missing that "HDR10+ Profile B compatible" line?
EDIT: The original file also has these included entries while the newly created file doesn't:
Mastering display color primaries : BT.2020
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 411 cd/m2
Maximum Frame-Average Light Level : 322 cd/m2
The latest HandBrake version will preserve HDR10+ and Dolby Vision when using the x265 10-bit encoder. So either something went wrong or who knows, it's hard to say without additional info.
bobowb
6th February 2024, 10:09
I have both B8 and C2, and also Samsung models, and so far the only universal solution is to mux them into TS/M2TS.
Profile 8 mp4 will work on both new and old type of internal LG players, but the Codec ID must be dvhe. This tool will convert to mp4 with Codec ID hev1 which plays as HDR on the B8/C8. But dvhe is not compatible with non-DoVi devices such as Samsung AU9072.
Still, it will be a great addition to add the option to chose the Codec ID when converting to mp4.
Thank you very much for the info ! Please can you share which tool (source) and command do you use to demux such hybrid .mkv files into .mp4 (.m2ts) dvhe Codec ID ?
bobowb
6th February 2024, 10:26
The LG C8 doesn't work with current MP4 muxing tools. It should still work with tsMuxer if your file shows Dolby Vision in MediaInfo.
For MP4 you need to use Dolby's muxer from 2018: https://github.com/DolbyLaboratories/dlb_mp4base/tree/ad46704703d2f558a61c2dba444ae43a8e3effff/bin
Either way it's best to stick to .TS with tsMuxer, it should be working fine.
Thank you for the support but can you share the command after mp4muxer_64bits.exe please ? And i originally have just hybrid .mkv but not .mp4 . Should i first convert it in .mp4 ?
cool advertise
6th February 2024, 10:42
to -QfG-
I would like to point out, that the DDVT_MKVTOMP4.cmd script of your tool, when converting an mkv file that has chapters, to mp4, loses the chapters in the conversion...
bobowb
6th February 2024, 10:44
Yep, can confirm, simply run the "hybrid" mkv thru tsmuxer, and create a .ts or .m2ts file, and the LG will display Dolby Vision.
The problem is that when i try to add the such hybrid .mkv files into TSMuxer i always get this error:
https://i.ibb.co/nr3FQ3t/error.png (https://ibb.co/XXyqFyM)
with other kind of .mkv files i dont get such error...
von Suppé
6th February 2024, 12:45
I doubt if tsMuxer 2.6.12 accepts Dolby Vision video. Try latest nightly builds.
https://github.com/justdan96/tsMuxer/releases
bobowb
6th February 2024, 13:15
I doubt if tsMuxer 2.6.12 accepts Dolby Vision video. Try latest nightly builds.
https://github.com/justdan96/tsMuxer/releases
Thank you - i got it ! The .ts file is ready and waiting for me to back home and try to play it on the C8 TV ! I hope it will works this time !:helpful:
ripburnlearn
7th February 2024, 10:17
The latest HandBrake version will preserve HDR10+ and Dolby Vision when using the x265 10-bit encoder. So either something went wrong or who knows, it's hard to say without additional info.Very very interesting. Looks like you pointed me in the right direction. I used H.265 10-Bit (NVEnc) instead of H.265 10-Bit (x265). My GPU compresses in 30-50 minutes rather than a bunch of hours via x265. That's why I used NVEnc.
But testing out both of them using the preview encoding option on Handbrake (encoding a 5 second clip) and dragging that output into MediaInfo, the NVEnc is stripping out the HDR10+ (SMPTE ST 2094 App 4, Version 1, HDR10+ Profile B compatible) and reverting it down to HDR10 (SMPTE ST 2086, HDR10 compatible)
I even tried fooling around with the "Filters tab" and turned on Colourspace to "BT.2020". That definitely was no good. All the HDR10 data gets removed in the section in MediaInfo.
For future time travelers.
Set Video Encoder to H.265 10-bit (x265)
Set Encoder Profile to Main 10, Encoder level to 5.1
In the "Summary" tab make sure "Passthru Common Metadata" is checked.
That worked.
bobowb
7th February 2024, 10:39
So i tried to remux the hybrid .mkv file with newer version of tsMuxer into .ts file and finally my LG C8 plays the file into DV mode ! Now the only problem is that for some reason the .ts file rewind forward and backwards dont work and the movie has wrong duration time . Can this be fixed somehow ?
GodzilaAvenger
7th February 2024, 11:10
One thing that may help is checking the timestamps of the .hevc stream with ffprobe. If there's something weird going on you can rewrite it with ffmpeg genpts.
rwill
7th February 2024, 11:38
So i tried to remux the hybrid .mkv file with newer version of tsMuxer into .ts file and finally my LG C8 plays the file into DV mode ! Now the only problem is that for some reason the .ts file rewind forward and backwards dont work and the movie has wrong duration time . Can this be fixed somehow ?
Transport Streams do not have an Index so they are not seek-able and their total duration is unknown unless parsed completely.
guest
7th February 2024, 11:52
So i tried to remux the hybrid .mkv file with newer version of tsMuxer into .ts file and finally my LG C8 plays the file into DV mode ! Now the only problem is that for some reason the .ts file rewind forward and backwards dont work and the movie has wrong duration time . Can this be fixed somehow ?
Hi "bob",
I have been playing around with all this stuff, the last couple of days, too.
So, try an .m2ts, mine play OK, but the seeking back or fwd, works, but there is a very slight but noticeable delay before things move again.
I read somewhere, that it was suggested to encode the .mkv with x265 with --uhd-bd in the encoding instructions / profile.
It overwrite's some setting's that might already exist in the command line, but it's to a "standard" !!!
So I tried that, and converting that -uhd-bd "fixed" .mkv to .m2ts, the seeking was so much better, but there is still a very, very slight delay, but SO much better.
I will trying a few different settings in the few days, so we'll see how that works out.
bobowb
7th February 2024, 13:17
Hi "bob",
...
Thanks for the help TDS . I still wonder is there any tool like tsMuxer - mp4muxer i guess that can convert the hybrid .mkv into .mp4 and set that dvhe Codec ID so the LG TV triggers the DV mode ? I have been watched a lot of .mp4 DV movies on this TV without any issues . Guess there wont be any problem with timestamp and rewind if the files is with .mp4 instead .ts ...
guest
7th February 2024, 13:35
Thanks for the help TDS . I still wonder is there any tool like tsMuxer - mp4muxer i guess that can convert the hybrid .mkv into .mp4 and set that dvhe Codec ID so the LG TV triggers the DV mode ? I have been watched a lot of .mp4 DV movies on this TV without any issues . Guess there wont be any problem with timestamp and rewind if the files is with .mp4 instead .ts ...
So where are you getting these DV mp4's ???
I cannot get any DV's to work, unless it's .ts or .m2ts !!!
Nico8583
7th February 2024, 20:01
Hi, what is the best way to demux elementaries HDR10+ / DoVi streams in order to use it with this script ? TsMuxer ? Thank you
von Suppé
8th February 2024, 10:29
I still wonder is there any tool like tsMuxer - mp4muxer i guess that can convert the hybrid .mkv into .mp4 and set that dvhe Codec ID so the LG TV triggers the DV mode ?
So where are you getting these DV mp4's ?
I cannot get any DV's to work, unless it's .ts or .m2ts
First off, I don't have a LG tv so can't try. I am however more into mp4 lately.
I don't know how far mp4 implementation has reached in -QfG- tools, but you may wanna try dovi scripts from RESET_9999. They make use of mp4muxer and mp4box (cli tools). Resulting mp4 files do carry Codec ID dvhe.
For LG C8, MakeMKV forums show info about DoVi mp4 support and under what conditions several DoVi profiles must be muxed. Where first audiotrack being lossy is of importance, it says.
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit#gid=427220017 Row 14
https://github.com/R3S3t9999/DoVi_Scripts/releases
As for these scripts, they do rely on a bunch of tools, which you have to get and put in a tools folder
Fuso
8th February 2024, 11:36
Thank you very much for the info ! Please can you share which tool (source) and command do you use to demux such hybrid .mkv files into .mp4 (.m2ts) dvhe Codec ID ?
The other not-so-official way to change the Codec ID is to use HxD to edit the converted mp4.
Open the mp4 in HxD, use the Find (Ctrl+F) function and search for hev1 as a Text-string, then simply write dvhe over hev1 and Save the file.
guest
8th February 2024, 12:24
https://github.com/R3S3t9999/DoVi_Scripts/releases
As for these scripts, they do rely on a bunch of tools, which you have to get and put in a tools folder
I did all this, earlier this week, and there IS quite a lot to get & install, (probably close to 3Gb) and put in the correct place, edit a few things so your hard work goes to the correct place, so you don't have to go looking for it.
Only today I had some success :)
guest
8th February 2024, 12:26
The other not-so-official way to change the Codec ID is to use HxD to edit the converted mp4.
Open the mp4 in HxD, use the Find (Ctrl+F) function and search for hev1 as a Text-string, then simply write dvhe over hev1 and Save the file.
Will definitely try that :)
von Suppé
8th February 2024, 12:40
The other not-so-official way to change the Codec ID is to use HxD to edit the converted mp4.
Open the mp4 in HxD, use the Find (Ctrl+F) function and search for hev1 as a Text-string, then simply write dvhe over hev1 and Save the file.
Nice! Didn't know. Thanks for this :)
cool advertise
8th February 2024, 13:09
The other not-so-official way to change the Codec ID is to use HxD to edit the converted mp4.
Open the mp4 in HxD, use the Find (Ctrl+F) function and search for hev1 as a Text-string, then simply write dvhe over hev1 and Save the file.
So from an mp4 file with dolby vision, it is sufficient to edit the 4 letters of the Codec ID with a hexadecimal editor, to change e.g. the compatibility between the LG TV or the Samsung TV or for any other device I suppose... And it seems to me the easiest method at the moment... Thank you also from me for this information.
von Suppé
8th February 2024, 13:45
A quick test indeed results in MediaInfo showing Codec ID: dvhe and Codec ID/Info: High Efficiency Video Coding with Dolby Vision. Looks good.
I did use "Replace all" btw. Nice to see that HxD backs-up the source mp4 as ***.bak
guest
8th February 2024, 13:58
A quick test indeed results in MediaInfo showing Codec ID: dvhe and Codec ID/Info: High Efficiency Video Coding with Dolby Vision. Looks good.
I did use "Replace all" btw. Nice to see that HxD backs-up the source mp4 as ***.bak
For what it's worth, would this work, and/or make a DV mkv play ??
I will try this myself, but I thought I'd ask, anyway.
UPDATE:- Well, as expected, I can't get this work, I even tried the "Replace All", it found 3 instances, but nothing got changed in Mediainfo.
Might the .mp4 I'm working with :(
von Suppé
8th February 2024, 18:23
As said, I don't have a LG tv so can't tell. For my standalone players it makes no difference.
The outcome looks good on MediaInfo and me learning more about mp4, it's nice to know about this hex-editing way.
von Suppé
9th February 2024, 08:26
I can't get this work, I even tried the "Replace All", it found 3 instances, but nothing got changed in Mediainfo.
Might the .mp4 I'm working with :(
Can you provide a link to the mp4 - or a small part?
AgentXXL
11th February 2024, 22:53
Attn -QfG-,
I have started using this tool again, after a long break, and the last build I used is #53
So I grabbed the latest build (#63.fixed) the other day, and when just simply wanting to extract the rpu.bin, it fails :(, however, #53 does the job, no issue :)
So I just got #60 & #62 (also noticed that there is a significant increase in the file size between #60 & #61.1, and then again between # 61.5 & #62.
#60 worked, #62 failed.
Am I missing something, or do I just need to keep using the older builds ??
Just fyi, that's all.
The failures you're seeing indicate path problems - I've found that these tools often fail when there are spaces in the path and/or filename.
I'm still fighting with the newer releases as well. The context menu options aren't working for me anymore. I even tried a fresh Win11 VM and running the DDVT_Options.cmd file no longer adds the context menu entries. I've rolled back to version 61.5 and it seems to be working for me. I was able to manually add the registry keys to re-add the context menu items.
I'm suspecting it's something to do with Win11 and some security patch that now prevents adding context menu items. Anyone else experiencing this? If the 63-FIXED version is working for anyone via the context menus, would it be possible for you to export the registry keys that it has added?
Thanks!
zomorf
14th February 2024, 19:17
Trying with the lastest FIXED 63 scripts. Loading a HDR file into the HYBRID script it doesn't recognise that it is HDR where I know it is...
this being the last portion of the filename... below...
1080p.NF.WEB-DL.DDP5.1.HDR.HEVC-NTb
it says "NO HDR File Chosen, HDR File must be set."
I had it working before in I think v0.61.5...
I'm a novice of this tool but I enjoyed the Hybrid script when it appeared...
Thanks...
sirbod
16th February 2024, 12:20
Attn -QfG-,
I have started using this tool again, after a long break, and the last build I used is #53
So I grabbed the latest build (#63.fixed) the other day, and when just simply wanting to extract the rpu.bin, it fails :(, however, #53 does the job, no issue :)
So I just got #60 & #62 (also noticed that there is a significant increase in the file size between #60 & #61.1, and then again between # 61.5 & #62.
#60 worked, #62 failed.
Am I missing something, or do I just need to keep using the older builds ??
The scripts will fail if there's a space in the generated temp path.
For example this line in the INJECTOR script:
FOR /F "tokens=2-5 delims=(,-)" %%A IN (!TMP_FOLDER!\Crop.txt) DO (
Will fail as it will split the path into tokens, not the contents. I switched it to:
FOR /F "tokens=2-5 delims=(,-)" %%A IN ('TYPE "!TMP_FOLDER!\Crop.txt"') DO (
Essentially, any FOR /F that uses a path to read the contents of a file is going to fail unless modified.
-QfG-
17th February 2024, 09:13
-v0.63.1 ONLINE
*FIXED Border check fails if temp folder includes spaces (THX @ sirbod).
*FIXED Better HDR detection.
AgentXXL
17th February 2024, 20:09
-v0.63.1 ONLINE
*FIXED Border check fails if temp folder includes spaces (THX @ sirbod).
*FIXED Better HDR detection.
Thanks again for these scripts! And FYI - I'm a dumbass sometimes. I figured out why the context menu was not appearing and it was as simple as forgetting to 'Run as Administrator' for DDVT_Options. All is good now.
Update: I still don't get any MUX into MKV option when using the Injector script. The Hybrid script does mux into a mkv, but I'm really not a fan of the drag and drop method. I'm sure I'll get used to it over time. And yes, when I ran DDVT_Options as administrator, I did set the MKVToolNix path. Was muxing removed from the Injector script since you added the Hybrid one?
-QfG-
18th February 2024, 02:54
The Muxing Option in the Injector script is Standard=Off. You can turn on with the switch. Also you can edit the script, in the header are the pre defined options.
Second you can only Mux into container, if the source file is containered (MP4/MKV).
set MUXINMKV=NO
:: YES / NO - Muxing video stream into MKV container if source was MKV container.
set MUXINMP4=NO
:: YES / NO - Muxing video stream into MP4 container if source was MP4 container.
set MUXP7SETTING=STANDARD
:: STANDARD / makeMKV - Method for muxing EL into BL.
AgentXXL
18th February 2024, 20:44
Ahh, perfect. Thank you! I'm already getting used to the Hybrid script with drag-n-drop, but it will be nice to have muxing available should I need to do any manually. And as mentioned before, I do only use .mp4 and .mkv source files.
zomorf
22nd February 2024, 05:52
Trying with the lastest FIXED 63 scripts. Loading a HDR file into the HYBRID script it doesn't recognise that it is HDR where I know it is...
this being the last portion of the filename... below...
1080p.NF.WEB-DL.DDP5.1.HDR.HEVC-NTb
it says "NO HDR File Chosen, HDR File must be set."
I had it working before in I think v0.61.5...
I'm a novice of this tool but I enjoyed the Hybrid script when it appeared...
Thanks...
Tried with latest still doesn't detect... I had it working in 0.58 so unsure what I have done or something has changed... I'm a novice to most of this... But I found it worked nice this HYBRID script compared to extracting manually like before...
I seen thread has been tidied up as pages #'s have reduced...
Nico8583
26th February 2024, 16:17
Does anyone have a document to describe HEVC structure ? Or a tool to analyze it ?
I would like to understand why a combined file created by dovi_tool, remuxed to MKV and extracted is different than a combined file created by mkvtoolnix and extracted. Only the last bytes are different.
Thank you.
ivanb
27th February 2024, 03:20
Doc: https://www.itu.int/rec/T-REC-H.265
Tool (high-level analysis): https://media-analyzer.pro
Nico8583
27th February 2024, 07:33
Thank you I'll look at it
Grimm
1st March 2024, 12:02
I wanted to convert dovi from 7.06 to 8.06 and I get this error
https://i.imgur.com/EdFWb7B.png
Problem solved. All you had to do was rename the file The.Hunger.Games.The.Ballad.of.Songbirds.and.Snakes.2023.MULTi.2160p.UHD.BluRay.REMUX.DoVi.HDR.HEVC.TrueHD7.1.Atmos-inTGrity
this name causes the above error
Fuso
11th March 2024, 19:42
The other not-so-official way to change the Codec ID is to use HxD to edit the converted mp4.
Open the mp4 in HxD, use the Find (Ctrl+F) function and search for hev1 as a Text-string, then simply write dvhe over hev1 and Save the file.
I've decided to test this method but it didn't work on my LG B8. Mediainfo shows dhve but the file still plays in HDR.
But I think I've found a universal format for playing on a non-DV TVs, older LGs, newer LGs - the so called fake Profile 5
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU / SMPTE ST 2086, HDR10 compatible
Codec ID : hev1
Container is mp4.
This file plays in HDR on a Samsung JS8000 (2015), AU9072 (2021), in Dolby Vision on LG B8 and C2.
zomorf
13th March 2024, 17:01
Can someone please point me in a direction. I'm trying a file that is HDR tv show with drag and drop to HYBRID script but pressing enter it reports no HDR HDR10+ detected... I had this working and now no files HDR is being detected... All I have done is extracted the new versions and all of a sudden it stopped... I had the Hybrid script working and found it a nice setup compared to the old extract and inject method...
I'm a novice to say the least...
benwaggoner
13th March 2024, 22:28
Can someone please point me in a direction. I'm trying a file that is HDR tv show with drag and drop to HYBRID script but pressing enter it reports no HDR HDR10+ detected... I had this working and now no files HDR is being detected... All I have done is extracted the new versions and all of a sudden it stopped... I had the Hybrid script working and found it a nice setup compared to the old extract and inject method...
Have you confirmed there is HDR-10 metadata through another means?
zomorf
14th March 2024, 13:06
Have you confirmed there is HDR-10 metadata through another means?
Yes mediainfo details. Also no file at present is detecting HDR data. I did have it running ok in 0.58. So unsure what happened. Currently using 0.63.1
Going back to 0.58 doesn't help either.
Boulder
14th March 2024, 14:41
Have you tried remuxing with mkvmerge/MKVToolnix GUI to see what happens?
AgentXXL
15th March 2024, 19:48
Ahh, perfect. Thank you! I'm already getting used to the Hybrid script with drag-n-drop, but it will be nice to have muxing available should I need to do any manually. And as mentioned before, I do only use .mp4 and .mkv source files.
@-QfG- Again, THANK YOU!! I now use the Hybrid script for the majority of my injecting attempts. And it's been flawless for the content I've done.
Should you and @quietvoid ever accept donations for your efforts, I'd be happy to send one.
zomorf
16th March 2024, 05:28
Have you tried remuxing with mkvmerge/MKVToolnix GUI to see what happens?
I'll give that a try... Just that NO FILE is working... I had it running and preferred the new HYBRID script... I'm trying it now...
Just loaded and saved new HDR file using mkvtoolnix no help... :(
Video Information from mediainfo...
Video
ID : 1
Format : HEVC
Format/Info : High Efficiency Video Coding
Format profile : Main 10@L4@Main
HDR format : SMPTE ST 2086, HDR10 compatible
Codec ID : V_MPEGH/ISO/HEVC
Duration : 1 h 0 min
Bit rate : 4 752 kb/s
Width : 1 920 pixels
Height : 1 080 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 24.000 FPS
Color space : YUV
Chroma subsampling : 4:2:0 (Type 2)
Bit depth : 10 bits
Bits/(Pixel*Frame) : 0.095
Stream size : 2.01 GiB (86%)
Default : Yes
Forced : No
Color range : Limited
Color primaries : BT.2020
Transfer characteristics : PQ
Matrix coefficients : BT.2020 non-constant
Mastering display color primaries : Display P3
Mastering display luminance : min: 0.0001 cd/m2, max: 1000 cd/m2
Maximum Content Light Level : 1053 cd/m2
Maximum Frame-Average Light Level : 358 cd/m2
-QfG-
16th March 2024, 12:32
@*zomorf What is the directory and filename? Use directory/filename without special letters and test again. Also check the 255 letters cap from windows. Mediainfo looks good, the HDR Detection is this String:
Transfer characteristics : PQ
If this string is existing in the file, HDR will be detected.
zomorf
16th March 2024, 21:07
@*zomorf What is the directory and filename? Use directory/filename without special letters and test again. Also check the 255 letters cap from windows. Mediainfo looks good, the HDR Detection is this String:
If this string is existing in the file, HDR will be detected.
Filename length isn't a problem... as I have tried from within the script directory even different paths drives etc have been tried... I'm at a loss... Below is the filename xxxx renamed...
xxx.xxxxxxx.S03E01.xxxxxxxxxx.1080p.NF.WEB-DL.DDP5.1.HDR.HEVC-NTb
https://www.dropbox.com/scl/fi/uffzpfs9h1v8f3pva8faz/ddvtools-image.png?rlkey=7g9cmz1meetws8u8curot9q1o&dl=0
At present NO FILE is detecting... That's what's strange... I was using this tool when you had to extract and then inject before the Hybrid script came through and from 0.58 I updated from 0.53 and found the HYBRID script which worked well... I updated to 0.63.1 and all of a sudden nothing detects...
I'm not sure what happened or why as I just extract the new versions of the releases...
I know my files have HDR and DV etc but I can't get past the HDR step :(
Strange indeed.... At a loss to explain or how to get around it...I even deleted the whole package and back to 0.58 still not working anymore... I'm stumped...
Titounet1965
17th March 2024, 13:15
Hello , can you add an option ( maybe in your option file ) to avoid the scripts exit from the CMD windows when job is finished ?
Thank you .
NeverExists
18th March 2024, 03:53
It always says no hdr10+ present no matter what...... just let it load past that part. it has always said that for me right when I first load the preset, then after it loads the main menu... you said your file was HDR10 hence why it says no HDR10+ PRESENT.
NeverExists
18th March 2024, 03:57
Can someone please point me in a direction. I'm trying a file that is HDR tv show with drag and drop to HYBRID script but pressing enter it reports no HDR HDR10+ detected... I had this working and now no files HDR is being detected... All I have done is extracted the new versions and all of a sudden it stopped... I had the Hybrid script working and found it a nice setup compared to the old extract and inject method...
I'm a novice to say the least...
IT is supposed to say that everytime you first load it. it will say that everytime there is no HDR10+ Present. You said you file was HDR10 Not HDR10+ so its working fine. let it load past that to the main screen.
zomorf
18th March 2024, 21:20
IT is supposed to say that everytime you first load it. it will say that everytime there is no HDR10+ Present. You said you file was HDR10 Not HDR10+ so its working fine. let it load past that to the main screen.
Nope juts keeps prompting... So it just doesn't detect it for some unknown reason... I'm working again tonight so limited time.. I'll revisit it Wednesday...
Thanks to all with info suggestions...
NeverExists
19th March 2024, 07:22
Nope juts keeps prompting... So it just doesn't detect it for some unknown reason... I'm working again tonight so limited time.. I'll revisit it Wednesday...
Thanks to all with info suggestions...
Also make sure you select the video file first when you're loading it in the program cause if you click on the rpu file first, it won't recognize it.
zomorf
20th March 2024, 02:49
Also make sure you select the video file first when you're loading it in the program cause if you click on the rpu file first, it won't recognize it.
I'm dragging an mkv file with HDR onto the Hybrid script. So I dont have the RPU file of the old extract and inject method.
I'll try a few more things later today when I get to the PC.
Once again thanks.
zomorf
20th March 2024, 11:40
OK solved... I'm sure before you could drag a file onto the SCRIPT name before and it would load... I was doing this... in versions 0.53 ???
NOW loading/running the HYBRID script and then dragging the file into the window solved the problem...
Sorry for the frustration but finally got it sorted... just when I was dragging the file onto the HYBRID script in file explorer etc it loaded the filename and I pressed enter presuming it knew the filename...
Dumb questions over and out :) Happily making Hybrids again...
cool advertise
24th March 2024, 17:25
to -QfG-
I would like to point out, that the DDVT_MKVTOMP4.cmd script of your tool, when converting an mkv file that has chapters, to mp4, loses the chapters (discard chapters) in the conversion...
I had reported it on 6th February 2024, but received no reply.
Can you fix it?
AgentXXL
31st March 2024, 20:23
Version 2.1.1 of dovi_tool was released last week and it looks like it supports the AV1 codec. I personally don't use AV1 widely yet, but would be nice to do some comparisons with DV/HDR10+ injected HEVC. I might just try dropping the new version into the DDVT tools folder but not sure if it needs further refinement of the DDVT scripts.
guest
2nd April 2024, 05:05
Version 2.1.1 of dovi_tool was released last week and it looks like it supports the AV1 codec. I personally don't use AV1 widely yet, but would be nice to do some comparisons with DV/HDR10+ injected HEVC. I might just try dropping the new version into the DDVT tools folder but not sure if it needs further refinement of the DDVT scripts.
Maybe not...
https://forum.doom9.org/showthread.php?p=1999834#post1999834
anta777
27th April 2024, 09:32
It is possible to find out, having a release in the 8th profile, whether the rpu in it is real or obtained by converting these utilities from the 5th profile
Atlantis
30th April 2024, 17:49
I just used version 0.63.1. You have removed the ability to output mkv in the Injector?
AgentXXL
1st May 2024, 17:31
I just used version 0.63.1. You have removed the ability to output mkv in the Injector?
You have to edit the script and set the options as per this post:
https://forum.doom9.org/showthread.php?p=1997844#post1997844
I was still doing it manually as well, but the new Hybrid script with drag and drop is working extremely well so I never use the manual method anymore.
frandan
13th May 2024, 09:51
Good morning,
i began to use DDVT Tool for dovi rip a few months ago, but for the first time i saw in mediainfo report the voice "no metadata compression" as you can see in the following text
"HDR format : Dolby Vision, Version 1.0, Profile 8.1, dvhe.08.06, BL+RPU, no metadata compression, HDR10 compatible / SMPTE ST 2086, Version HDR10, HDR10 compatible"
What does it mean? Did i make some mistake?
Thanks in advance for your answer
von Suppé
13th May 2024, 18:05
No, I don't think you made a mistake. This seems a default note stating that the RPU binaries in the SEI messaging aren't further compressed.
I don't think I've ever seen otherwise. Just ignore it, things are OK.
matey
21st May 2024, 22:44
The other not-so-official way to change the Codec ID is to use HxD to edit the converted mp4.
Open the mp4 in HxD, use the Find (Ctrl+F) function and search for hev1 as a Text-string, then simply write dvhe over hev1 and Save the file.
hi @Fuso
have you figured out a way to convert mkv DV files so they work on older & newer LG tv's? I have a C8 & a A2. currently I am converting to m2ts using tsmuxer but that only works for the C8. I am not able to use dovi tools as my pc is a linux ubuntu arm64 so I haven't found a way to convert to a format compatible with both tvs.
guest
22nd May 2024, 06:18
hi @Fuso
have you figured out a way to convert mkv DV files so they work on older & newer LG tv's? I have a C8 & a A2. currently I am converting to m2ts using tsmuxer but that only works for the C8. I am not able to use dovi tools as my pc is a linux ubuntu arm64 so I haven't found a way to convert to a format compatible with both tvs.
I have an older LG TV, and the only way I could play a DV was to convert with tsmuxer, but the "seeking" during playback was horrible.
But then I found an app that was my "Saviour", and it's not DDVT.
The DV's also have to .mp4 to play on an LG TV, or some other device would be needed.
But most of these apps are Windows based, so I think you might have maybe dual boot your PC, so you can keep your Linux, and have Windows to do this stuff.
Or get a 2nd PC.
matey
22nd May 2024, 11:25
I have an older LG TV, and the only way I could play a DV was to convert with tsmuxer, but the "seeking" during playback was horrible.
But then I found an app that was my "Saviour", and it's not DDVT.
The DV's also have to .mp4 to play on an LG TV, or some other device would be needed.
But most of these apps are Windows based, so I think you might have maybe dual boot your PC, so you can keep your Linux, and have Windows to do this stuff.
Or get a 2nd PC.
hi @TDS
I have a windows pc too. can you please let me know which app you are referring to? is this for converting or playback? does it work for old & new LG tv's?
guest
22nd May 2024, 11:29
hi @TDS
I have a windows pc too. can you please let me know which app you are referring to? is this for converting or playback? does it work for old & new LG tv's?
Happy to help...
I will send you a PM shortly.
hi @Fuso
have you figured out a way to convert mkv DV files so they work on older & newer LG tv's? I have a C8 & a A2. currently I am converting to m2ts using tsmuxer but that only works for the C8. I am not able to use dovi tools as my pc is a linux ubuntu arm64 so I haven't found a way to convert to a format compatible with both tvs.
I'm currently mux them to Profile 5 with Base HDR/HDR10+, with Codec ID hev1. For many people is not "the way", but for me it does the job for my tv sets.
But I think I've found a universal format for playing on a non-DV TVs, older LGs, newer LGs - the so called fake Profile 5
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU / SMPTE ST 2086, HDR10 compatible
Codec ID : hev1
Container is mp4.
This file plays in HDR on a Samsung JS8000 (2015), AU9072 (2021), in Dolby Vision on LG B8 and C2.
vitaloque
14th June 2024, 07:30
Hi,
Small feature request. Add an option 'Use DV border' option to Hybrid script. It is often detetmined small border difference HDR vs DV RPU, and I have to manullay correct active area to match RPU. And for TV series it surely takes too much time.
So I'd like to press some number and output borders are automatically set to the one from RPU.
Thanks in advance.
Titounet1965
18th June 2024, 18:31
Hi there
little bug repport
the scrpits fails if the filename contains the letter &
NeverExists
22nd June 2024, 06:24
Hi, has this been abandoned? no new release for 5 months. seems like it is..
-QfG-
25th June 2024, 16:22
Nothing to change (no bugs kwown).
the scrpits fails if the filename contains the letter &
the letter "&" is a command in batch. you must rename this file.
NeverExists
30th June 2024, 05:33
Nothing to change (no bugs kwown).
the letter "&" is a command in batch. you must rename this file.
How exactly can I set it to mux into an mkv stream? I usually take the Dolby Vision rpu from the web release and combine it with the video from the 4k Blu-ray, but now everything has changed. do I still use demuxer to get the rpu? do I still use the injector to make my mkv? or do I use hybrid? and where the hell is the mux into mkv option?
wow! Nobody can answer this??
AgentXXL
10th July 2024, 19:00
How exactly can I set it to mux into an mkv stream? I usually take the Dolby Vision rpu from the web release and combine it with the video from the 4k Blu-ray, but now everything has changed. do I still use demuxer to get the rpu? do I still use the injector to make my mkv? or do I use hybrid? and where the hell is the mux into mkv option?
wow! Nobody can answer this??
Most of us now use the hybrid script with its drag'n'drop method. You can still do it manually via the demuxer. For the mux into mkv option, you need to edit the injector script and set the variable MUXINMKV to YES.
Explained here: https://forum.doom9.org/showthread.php?p=1997844#post1997844
NeverExists
11th July 2024, 00:26
Most of us now use the hybrid script with its drag'n'drop method. You can still do it manually via the demuxer. For the mux into mkv option, you need to edit the injector script and set the variable MUXINMKV to YES.
Explained here: https://forum.doom9.org/showthread.php?p=1997844#post1997844
I still don't know where or how to edit the injector script. What is the script file called exactly? I looked and I don't see anything named injector.
AgentXXL
12th July 2024, 18:40
I still don't know where or how to edit the injector script. What is the script file called exactly? I looked and I don't see anything named injector.
The file you need to edit is called DDVT_INJECTOR.cmd which will reside wherever you extracted the DDVT rar file to. You can edit it in Notepad on Windows.
thegrunge
15th July 2024, 20:19
Hello I'm not sure I understand how it works, when I run the cmd it doesn't find any files.
https://ibb.co/M6zWGY7
thegrunge
15th July 2024, 21:34
Hello I'm not sure I understand how it works, when I run the cmd it doesn't find any files.
https://ibb.co/M6zWGY7
Ok I understood that you have to drag the file onto the cmd. but how to remove the hdr10 now? It's juste remove DV.
It's not that I don't like HDR10, but even with compatible devices the image remains darker than without HDR10 for tha same movie
Atlantis
17th July 2024, 01:53
Sorry, I can't read every page. What is the situation with AV1? I just tried to inject RPU into an AV1 file and it didn't work. Gives a 0 size file.
Boulder
17th July 2024, 10:37
Sorry, I can't read every page. What is the situation with AV1? I just tried to inject RPU into an AV1 file and it didn't work. Gives a 0 size file.
Dovi_tool cannot be used with AV1, so you can inject the RPU only during the encoding phase (with svt-av1-psy).
Atlantis
17th July 2024, 10:49
Thank you.
AgentXXL
18th July 2024, 16:56
Ok I understood that you have to drag the file onto the cmd. but how to remove the hdr10 now? It's juste remove DV.
It's not that I don't like HDR10, but even with compatible devices the image remains darker than without HDR10 for tha same movie
You can't remove HDR if you want to keep DV - DV is additional metadata that is applied to the base HDR10 layer. If you're seeing image issues, it's likely your display is not calibrated for DV content.
Wolfy59
11th August 2024, 11:30
Hi, first of all I'd like to thank you for all the work you've done here, which makes our day-to-day work so much easier. I'd like to know if there's a reason why the P5 profile is no longer supported?
Thank you
ReciprocalUniverse
12th August 2024, 19:48
OUTSTANDING! Just Bravo!!! Thank you so much for these great tools!!
Tom Roper
AngelGraves13
18th August 2024, 08:19
If I'm injecting a DV layer from a web-dl into a remux and the lengths don't match, do I apply a negative offset if the RPU is shorter by 22 frames? I also don't really have a way to verify the DV stream after as I can't actually play the DV layer, so how would I know if something is out of sync?
GodzilaAvenger
18th August 2024, 21:58
You have to compare the web-dl source video with the remux to figure out the frame sync. If the web-dl is e.g. 10 frames ahead then set the delay in DDVT to -10, if it's 10 frames behind set it to 10.
Arkana
20th August 2024, 15:38
https://i.postimg.cc/Wqj5B881/screenshot-780.png (https://postimg.cc/Wqj5B881)
why it happening? How to fix it?
AngelGraves13
20th August 2024, 22:10
You have to compare the web-dl source video with the remux to figure out the frame sync. If the web-dl is e.g. 10 frames ahead then set the delay in DDVT to -10, if it's 10 frames behind set it to 10.
Is there anyway to know if the hybrid remux I made is incorrect? Like would the colors be off or something if I did it wrong?
Ok, so my UHD Remux of The Nun (2018) is 138932 frames and the Web-DL DV is 138910 so I would delay "+22" frames by my understanding and everything will line up correctly? Is that all there is to it? I wish the frame mismatch would be automatically adjusted if that's the case.
What about "matchL6 metadata"?? What's that for exactly and when would one need enable it?
AngelGraves13
20th August 2024, 22:12
https://i.postimg.cc/Wqj5B881/screenshot-780.png (https://postimg.cc/Wqj5B881)
why it happening? How to fix it?
Looks like two different masterings if I'm not mistaken so you can't make a hybrid of the two.
Hellboy.
21st August 2024, 18:21
Is there anyway to know if the hybrid remux I made is incorrect? Like would the colors be off or something if I did it wrong?
Ok, so my UHD Remux of The Nun (2018) is 138932 frames and the Web-DL DV is 138910 so I would delay "+22" frames by my understanding and everything will line up correctly? Is that all there is to it? I wish the frame mismatch would be automatically adjusted if that's the case.
What about "matchL6 metadata"?? What's that for exactly and when would one need enable it?
There could be different frames at the end of the video.
GodzilaAvenger
21st August 2024, 22:19
Is there anyway to know if the hybrid remux I made is incorrect? Like would the colors be off or something if I did it wrong?
Ok, so my UHD Remux of The Nun (2018) is 138932 frames and the Web-DL DV is 138910 so I would delay "+22" frames by my understanding and everything will line up correctly? Is that all there is to it? I wish the frame mismatch would be automatically adjusted if that's the case.
What about "matchL6 metadata"?? What's that for exactly and when would one need enable it?
Looking at the number of frames is not enough to figure out the sync, the web-dl may have a few additional frames of a logo or something at the beginning, while also having cut out a few seconds at the end. In your case the remux may only have extra frames at the end which means you should leave the delay at 0. This is very often the case which is why the mismatch is not automatically adjusted
The main thing DV does is dynamically adjust scene brightness, so if your RPU is out of sync with the base video layer you may see weird brightness changes slightly before or after scene cuts, depending on the scene of course.
One way to check your remux is to extract the RPU from it using the Demuxer script, and then using the Fileinfo script on it. This gives you all the scene cut frames in the RPU, which you can then use to check if they match the actual video.
I don't think the L6 data matters, if I remember correcrly that's what quietvoid said a while back in this thread.
AngelGraves13
31st August 2024, 08:21
Well that's confusing.
Ok...let's say I downloaded a DV Hybrid of a x265 rip and want to only save the DV layer that's already synced to a 4K UHD rip and inject it into a 4K UHD Remux. If the video is cropped but mine is standard 2160p, do I have to enable anything when saving the DV layer? It seems no matter what I select for Convert, or crop rpu it always says the RPU and Video don't match because of the video borders, but the file output says "match with video"
Filename = [Red Sparrow 4K (2018).mkv]
Video Info = [Resolution = 3840x2160] [Codec = HEVC-10Bit-YUV-4:2:0] [Frames = 201740] [FPS = 23.976]
HDR Info = [HDR]
Borders = [LEFT=0 px], [TOP=280 px], [RIGHT=0 px], [BOTTOM=280 px] [NOT MATCH WITH RPU]
== RPU INPUT ===========================================================================================================
Filename = [RPU.bin]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 201740]
Borders = [LEFT=0 px], [TOP=0 px], [RIGHT=0 px], [BOTTOM=0 px] [NOT MATCH WITH VIDEO]
== FILE OUTPUT =========================================================================================================
Filename = [Red Sparrow 4K (2018)_[BL+RPU].hevc]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 201740]
Borders = [LEFT=0 px], [TOP=280 px], [RIGHT=0 px], [BOTTOM=280 px] [MATCH WITH VIDEO]
Delay = [0 FRAMES]
So for the demuxer...just leaving everything untouched is fine?
1. SAVE HDR BL : [NO]
2. SAVE RPU : [YES]
3. CONVERT RPU : [LEAVE UNTOUCHED]
4. CROP RPU* : [NO] *Whenever the final result doesn't have letterboxed bars set to [YES].
GodzilaAvenger
31st August 2024, 09:29
The RPU contains border information for each frame, what's called L5 data. It doesn't matter if you change it when you are saving it using the demuxer or when injecting it using the injector. At the end of the day the L5 data of the injected RPU should match the borders of the video it's injected into.
In your example above, DDVT is telling you that the borders on the RPU (0) don't match the borders on the video (280), so it will rewrite the L5 data before injecting the RPU so that it matches the video. I generally save the RPU as is and apply necessary changes when injecting it.
I suggest looking at dovi_tool's documentation, which is what DDVT uses. Hopefully that can clear things up.
AngelGraves13
1st September 2024, 04:23
Thanks!
Keemy
3rd September 2024, 10:10
Is there a version of this script for Macos or any equivalents?
-QfG-
9th September 2024, 21:32
Filename = [Red Sparrow 4K (2018).mkv]
Video Info = [Resolution = 3840x2160] [Codec = HEVC-10Bit-YUV-4:2:0] [Frames = 201740] [FPS = 23.976]
HDR Info = [HDR]
Borders = [LEFT=0 px], [TOP=280 px], [RIGHT=0 px], [NOT MATCH WITH RPU]
[B]NOT MATCH WITH RPU tells you, that the border entries in the RPU are incorrect.
== RPU INPUT ===========================================================================================================
Filename = [RPU.bin]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 201740]
Borders = [LEFT=0 px], [TOP=0 px], [RIGHT=0 px], [NOT MATCH WITH VIDEO]
[B]NOT MATCH WITH VIDEO tells you, that the border entries in the RPU are incorrect.
== FILE OUTPUT =========================================================================================================
Filename = [Red Sparrow 4K (2018)_[BL+RPU].hevc]
RPU Info = [DV Profile = 8] [CM Version = 2.9] [Frames = 201740]
Borders = [LEFT=0 px], [TOP=280 px], [RIGHT=0 px], [BOTTOM=280 px] [MATCH WITH VIDEO]
Delay = [0 FRAMES]
Blue: This is your BL Layer (HDR Stream) and the discovered borders.
Red: This is the section from your RPU with the discovered borders.
Green: Your final settings for injecting with corrected borders in the RPU to match the HDR Stream
lemaireus
21st September 2024, 11:53
I cannot work with a command prompt interface, but wish to use DDVT tools to extract and later inject the Dolby Vision metadata in my x265 encodes of 4k blu-rays. However, each time I start DDVT_DEMUXER.cmd, the cmd window flashes "waiting for 30 seconds, press a key to continue . . .". Thereafter, when I drag and drop the MKV file onto the DDVT_DEMUXER.cmd window, the cmd window instantly disappears. In fact, all the DDVT_XXX.cmd files, with the exception of DDVT_HYBRID.cmd and DDVT_OPTIONS.cmd, perform the same disappearing act after 30 seconds, or the moment when I drag and drop an MKV file onto the cmd window. Here's how the cmd window looks before disappearing:
https://i.postimg.cc/3wSVzGBD/DDVT-Tool-Error.jpg
I am unable to figure out exactly what it is that I might be doing wrong. Any help would be much appreciated. Thank you.
lemaireus
21st September 2024, 13:58
Elementary, dear Watson, elementary. Some wonderful, generous, and precisely articulated help in PMs provided the correct diagnosis. I should have dragged the mkv file over the DDVT_DEMUXER.cmd script. Instead, I was double clicking DDVT_DEMUXER.cmd and dragging the file on the cmd window that opened thereafter. That is the first step out of the way; now to the next. Many thanks for helping out.
lemaireus
22nd September 2024, 08:21
I succeeded in getting my first Ripbot encode with Dolby Vision metadata, all thanks to the wonderfully generous forum members walking me through in PMs and, in the Ripbot forum, thanks to Ryushin. Once my elementary but fundamental mistake became clear, the rest was a cakewalk.
Ryushin and my PM-ing friends, much, much gratitude.
sk2316
27th September 2024, 05:20
i'm newbie for ddvt tool
i would like to try this tool
1.sdr file with sharp picture
2.hdr10 file with worse picture
can i extract hdr10 meta and inject to sdr file?
GodzilaAvenger
27th September 2024, 09:08
DDVT is for working with Dolby Vision metadata and adding it to HDR10 or extracting it. It can't do what you want. I'm not sure if anything can. HDR10 uses the 10-bit BT.2020 colorspace whereas SDR uses the BT.709 colorspace.
lemaireus
28th September 2024, 06:47
Now that I have had the time to work with DDVT tools, I cannot be thankful enough: these scripts are exactly what so many of us had been missing since the introduction of Dolby Vision. Thank you so very much -QfG- and quietvoid (and that is a lovely nick!). You guys have done such awesome work that even an old dog like me, who has the will but no longer the energy to learn new tricks, can work effortlessly in extracting and injecting Dolby Vision into my encodes. Much, much gratitude for these incredibly useful and awesomely user-friendly batch scripts.
sk2316
28th September 2024, 10:57
DDVT is for working with Dolby Vision metadata and adding it to HDR10 or extracting it. It can't do what you want. I'm not sure if anything can. HDR10 uses the 10-bit BT.2020 colorspace whereas SDR uses the BT.709 colorspace.
thank for quick reply
hdr10(not hdr10+) is not metadata? it's just have 10-bit BT.2020 colorspace
GodzilaAvenger
28th September 2024, 20:16
Technically speaking, it has some overall brightness metadata, but it is part of the whole HDR10 package, it's not something you can take out and put on an SDR video and call it a day. You can Google "how HDR works".
sk2316
29th September 2024, 01:19
Technically speaking, it has some overall brightness metadata, but it is part of the whole HDR10 package, it's not something you can take out and put on an SDR video and call it a day. You can Google "how HDR works".
ok i got it
if i encode hdr10 file (SMPTE ST 2084) to h265 10 bits file
why output file information is not show "SMPTE ST 2084"
it's not hdr10? but color is like original file!
GodzilaAvenger
29th September 2024, 03:16
Bit depth isn't the defining factor, both HDR and SDR can be 10-bit. You are encoding to BT.709 colorspace, which is still SDR.
sk2316
29th September 2024, 03:42
Bit depth isn't the defining factor, both HDR and SDR can be 10-bit. You are encoding to BT.709 colorspace, which is still SDR.
i forgot to tell you ,output file is BT2020
i don't understand why output file color is like original file
it should be waste out color?
Z2697
29th September 2024, 04:07
The HDR part of HDR10 is PQ (ST2084). BT.2020 is WCG part.
sk2316
29th September 2024, 07:41
The HDR part of HDR10 is PQ (ST2084). BT.2020 is WCG part.
ok i got it
if i encode hdr10 file (SMPTE ST 2084) to h265 10 bits file
why output file information is not show "SMPTE ST 2084"
it's not hdr10? but color is like original file!
puremind
7th October 2024, 12:15
DDVT Tool Download Folder on MEGA.
(The tool based on quietvoids tools)
-Demuxing DV Metadata from MKVs/MP4s.
-Convert HDR10+ Metadata to DoVi Metadata (Experimental).
-Convert Profile 7/5 Metadata to Profile 8.1.
-Inject DoVi Metadata in Streams.
-Easy Delay Adjustment in Injector.
-Complete Open Source Batch Scripts!
Credits to quietvoid for his awesome tools.
Credits to Atak_Snajpera for the BorderDetect tool.
>> DOWNLOAD via MEGA Folder (https://mega.nz/folder/E5MjzAYD#xz9bKC8fnuQmOMo_ncjniQ) <<[/CENTER]
A while ago, I had shared a mass convert script adapted from yours so that it would do all files in a given folder sequentially. I had commented that it would be nice to also extract and convert subtitle tracks to MP4.
In case anyone is interested, I am sharing the updated script.
https://i.imgur.com/Vn40OUV.png
The use is very simple just type MP4all C:\YourFolder\ from where the file is script and it will translate all of your files. You can specify preferred audio and subtitle track you want and it will mux it all together for each file in the folder.
18727
Be careful that sometimes there are up to 3 subtitle tracks with the same language (e.g, forced, SDH and standard) and you want to extract the standard one, so if you don't see subtitles you probably extracted the wrong one. If I have time later, I will append the title information to help with the choice but those loops inside command files are killing me.
Edit: Fixed an issue whereby it would not detect subtitle tracks if there is only 1 subtitle track or the file name contained spaces.
asarian
10th October 2024, 03:34
I have a HDR video (Push), with a Dolby Vision layer (see below). Muxing the 2 into a single MKV doesn't trigger DV, though (on my new LG G4).
Can I use these tools to make that work? Or do I have to somehow re-encode the main stream with DV data? As the confusing part is, that I have a Star Trek blu-ray which also appears DV-enabled, but apparently there it's all in 1 single stream.
Thanks.
M2TS, 2 video tracks, 3 audio tracks, 2 subtitle tracks, 1:51:27, 11.988p
1: h265/HEVC, 2160p24 /1.001 (16:9), 10 bits
2: h265/HEVC, 1080p24 /1.001 (16:9), 10 bits - Dolby Vision Enhancement Layer
3: TrueHD/AC3 (Atmos), 7.1 channels, 48kHz
(embedded: AC3 EX, 5.1 channels, 448kbps, 48kHz)
puremind
10th October 2024, 15:14
I have a HDR video (Push), with a Dolby Vision layer (see below). Muxing the 2 into a single MKV doesn't trigger DV, though (on my new LG G4).
Can I use these tools to make that work? Or do I have to somehow re-encode the main stream with DV data? As the confusing part is, that I have a Star Trek blu-ray which also appears DV-enabled, but apparently there it's all in 1 single stream.
Thanks.
M2TS, 2 video tracks, 3 audio tracks, 2 subtitle tracks, 1:51:27, 11.988p
1: h265/HEVC, 2160p24 /1.001 (16:9), 10 bits
2: h265/HEVC, 1080p24 /1.001 (16:9), 10 bits - Dolby Vision Enhancement Layer
3: TrueHD/AC3 (Atmos), 7.1 channels, 48kHz
(embedded: AC3 EX, 5.1 channels, 448kbps, 48kHz)
You can use the tool in posted above, very simple instructions. You don't need to do much for the file you have. It is more complicated to transform HDR layer into DV readable, but here you already have the DV layer baked into.
guest
10th October 2024, 18:34
I have a HDR video (Push), with a Dolby Vision layer (see below). Muxing the 2 into a single MKV doesn't trigger DV, though (on my new LG G4).
Can I use these tools to make that work? Or do I have to somehow re-encode the main stream with DV data? As the confusing part is, that I have a Star Trek blu-ray which also appears DV-enabled, but apparently there it's all in 1 single stream.
Thanks.
M2TS, 2 video tracks, 3 audio tracks, 2 subtitle tracks, 1:51:27, 11.988p
1: h265/HEVC, 2160p24 /1.001 (16:9), 10 bits
2: h265/HEVC, 1080p24 /1.001 (16:9), 10 bits - Dolby Vision Enhancement Layer
3: TrueHD/AC3 (Atmos), 7.1 channels, 48kHz
(embedded: AC3 EX, 5.1 channels, 448kbps, 48kHz)
LG's require the video to be an .mp4 for DV to be displayed !!!
I have an LG C4, but I don't use DDVT.
asarian
10th October 2024, 18:41
You can use the tool in posted above, very simple instructions. You don't need to do much for the file you have. It is more complicated to transform HDR layer into DV readable, but here you already have the DV layer baked into.
Awesome! Thx. Yes, I rather not re-encode, if possible.
asarian
10th October 2024, 18:52
LG's require the video to be an .mp4 for DV to be displayed !!!
You'd think so; but on my LG G4, my remuxed Strange New Worlds Blu-Rays trigger Dolby Vision, with just the single layer (via Kodi)
X:\Star Trek\Star Trek Strange New Worlds>eac3to "Star Trek Strange New Worlds - S01E01.mkv"
MKV, 1 video track, 1 audio track, 0:52:51, 24p /1.001
1: h265/HEVC, English, 2160p24 /1.001 (16:9), 10 bits
2: RAW/PCM, English, 5.1 channels, 24 bits, 48kHz
I took a look at the original again, to make sure I hadn't perhaps forgotten to mux the DV layer, but nope, it's just the 1 STREAM (And it looks absoutely spectacular with DV, btw! My old Q90 couldn't do DV).
puremind
10th October 2024, 19:01
Awesome! Thx. Yes, I rather not re-encode, if possible.
This one just let's you choose video quality and your preferred srt subtitle track, and it will transform it into MP4 DV that plays anywhere.
But with DDVT_Hybrid tool it is actually very easy to reencode, you just drag and drop the same HDR file twice and it will create the DV layer and final file. It just takes longer.
asarian
10th October 2024, 20:52
You can use the tool in posted above, very simple instructions. You don't need to do much for the file you have. It is more complicated to transform HDR layer into DV readable, but here you already have the DV layer baked into.
I tried the DDVT_DEMUXER.cm tool, but it keeps saying no Dolby Vision profile found on any of the files with the extra DV Layer in it.
asarian
10th October 2024, 20:53
This one just let's you choose video quality and your preferred srt subtitle track, and it will transform it into MP4 DV that plays anywhere.
But with DDVT_Hybrif tool it is actually very easy to reencode, you just drag and drop the same HDR file twice and it will create the DV layer and final file. It just takes longer.
Okay, will try this DDVT_Hybrid tool too.
LaFirma
13th October 2024, 03:33
LG's require the video to be an .mp4 for DV to be displayed !!!
I have an LG C4, but I don't use DDVT.
You'd think so; but on my LG G4, my remuxed Strange New Worlds Blu-Rays trigger Dolby Vision, with just the single layer (via Kodi)
X:\Star Trek\Star Trek Strange New Worlds>eac3to "Star Trek Strange New Worlds - S01E01.mkv"
MKV, 1 video track, 1 audio track, 0:52:51, 24p /1.001
1: h265/HEVC, English, 2160p24 /1.001 (16:9), 10 bits
2: RAW/PCM, English, 5.1 channels, 24 bits, 48kHz
I took a look at the original again, to make sure I hadn't perhaps forgotten to mux the DV layer, but nope, it's just the 1 STREAM (And it looks absoutely spectacular with DV, btw! My old Q90 couldn't do DV).
LG OLED cx/c1/c2/c3/c4 will only work on DV in PROFILE 5 or 8... in PLEX/KODI they will only work if they are MP4/M2TS.
On Jellifyn it plays MKV.
I use DDVT TOOL to convert PROFILE 7 to 8 and it works perfectly.
NOT WORK:
HDR format : Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible
WORK:
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
asarian
13th October 2024, 13:24
LG OLED cx/c1/c2/c3/c4 will only work on DV in PROFILE 5 or 8... in PLEX/KODI they will only work if they are MP4/M2TS.
On Jellifyn it plays MKV.
I use DDVT TOOL to convert PROFILE 7 to 8 and it works perfectly.
NOT WORK:
HDR format : Dolby Vision, Version 1.0, dvhe.07.06, BL+EL+RPU, Blu-ray compatible / SMPTE ST 2086, HDR10 compatible
WORK:
HDR format : Dolby Vision, Version 1.0, dvhe.08.06, BL+RPU, HDR10 compatible / SMPTE ST 2086, HDR10 compatible
Let's look at this MKV again:
X:\Star Trek\Star Trek Strange New Worlds>eac3to "Star Trek Strange New Worlds - S01E01.mkv"
MKV, 1 video track, 1 audio track, 0:52:51, 24p /1.001
1: h265/HEVC, English, 2160p24 /1.001 (16:9), 10 bits
2: RAW/PCM, English, 5.1 channels, 24 bits, 48kHz
MediaInfo says the following about the video:
Dolby Vision, Version 1.0, Profile 7.6, dvhe.07.06, BL+EL+RPU, no metadata compression, Blu-ray compatible / SMPTE ST 2086, Version HDR10, HDR10 compatible
This WORKS, and yields a playable MKV, with DV, on my LG G4. (Played with Kodi 21.0)
This, however, is what I'm struggling with:
M2TS, 2 video tracks, 3 audio tracks, 2 subtitle tracks, 1:51:27, 11.988p
1: h265/HEVC, 2160p24 /1.001 (16:9), 10 bits
2: h265/HEVC, 1080p24 /1.001 (16:9), 10 bits - Dolby Vision Enhancement Layer
3: TrueHD/AC3 (Atmos), 7.1 channels, 48kHz
(embedded: AC3 EX, 5.1 channels, 448kbps, 48kHz)
I can't, for the life of me, get any of the DDVT TOOLS to even find Dolby Vision data in the file, though. The DV layer is clearly there, but I get no tool to recognize it.
SeeMoreDigital
13th October 2024, 14:50
Let's look at this MKV again:
This, however, is what I'm struggling with:
M2TS, 2 video tracks, 3 audio tracks, 2 subtitle tracks, 1:51:27, 11.988p
1: h265/HEVC, 2160p24 /1.001 (16:9), 10 bits
2: h265/HEVC, 1080p24 /1.001 (16:9), 10 bits - Dolby Vision Enhancement Layer
3: TrueHD/AC3 (Atmos), 7.1 channels, 48kHz
(embedded: AC3 EX, 5.1 channels, 448kbps, 48kHz)
I can't, for the life of me, get any of the DDVT TOOLS to even find Dolby Vision data in the file, though. The DV layer is clearly there, but I get no tool to recognize it.
Out of interest... What happens if you try and play the .m2ts file using the LG G4's built-in 'video' player?
asarian
13th October 2024, 20:28
Out of interest... What happens if you try and play the .m2ts file using the LG G4's built-in 'video' player?
Not even sure I can attach an SMB to the LG G4. :) But I can try.
P.S. That Push DV blu-ray was remuxed at some point (I removed all stuff I didn't need). Could DV metadata have been removed in the process?
I also ripped the entire blu-ray folder structure to disk, but MediaInfo still does not acknowledge DV presence in the alleged DV stream; just sees it as a regular 1080p hevc stream.
SeeMoreDigital
13th October 2024, 20:52
Not even sure I can attach an SMB to the LG G4. :) But I can try.How about an NTFS formatted USB powered HDD or thumb drive?
Personally, I currently use an old SATA 120GB solid state drive (within a USB caddy) for such testing. Which works fine with my 2016 LG television...
GodzilaAvenger
13th October 2024, 22:14
Let's look at this MKV again:
X:\Star Trek\Star Trek Strange New Worlds>eac3to "Star Trek Strange New Worlds - S01E01.mkv"
MKV, 1 video track, 1 audio track, 0:52:51, 24p /1.001
1: h265/HEVC, English, 2160p24 /1.001 (16:9), 10 bits
2: RAW/PCM, English, 5.1 channels, 24 bits, 48kHz
MediaInfo says the following about the video:
Dolby Vision, Version 1.0, Profile 7.6, dvhe.07.06, BL+EL+RPU, no metadata compression, Blu-ray compatible / SMPTE ST 2086, Version HDR10, HDR10 compatible
This WORKS, and yields a playable MKV, with DV, on my LG G4. (Played with Kodi 21.0)
This, however, is what I'm struggling with:
M2TS, 2 video tracks, 3 audio tracks, 2 subtitle tracks, 1:51:27, 11.988p
1: h265/HEVC, 2160p24 /1.001 (16:9), 10 bits
2: h265/HEVC, 1080p24 /1.001 (16:9), 10 bits - Dolby Vision Enhancement Layer
3: TrueHD/AC3 (Atmos), 7.1 channels, 48kHz
(embedded: AC3 EX, 5.1 channels, 448kbps, 48kHz)
I can't, for the life of me, get any of the DDVT TOOLS to even find Dolby Vision data in the file, though. The DV layer is clearly there, but I get no tool to recognize it.
The first one is single-layer DV (i.e. DV data baked as an Enhancement Layer (EL) into the video stream), the second one is dual-layer DV (DV data a separate 1080p stream). DDVT only works with the first one, mediainfo will also show DV only for the first one, showing the second one as having a 4k stream and a 1080p stream. You can use MKVToolNix to remux the .m2ts file into .mkv and then use DDVT.
asarian
14th October 2024, 04:50
The first one is single-layer DV (i.e. DV data baked as an Enhancement Layer (EL) into the video stream),
If I understood things correctly, I should be able to extract the EL from the main stream, and reapply it later, right? (So I can denoise movies first).
the second one is dual-layer DV (DV data a separate 1080p stream). DDVT only works with the first one, mediainfo will also show DV only for the first one, showing the second one as having a 4k stream and a 1080p stream. You can use MKVToolNix to remux the .m2ts file into .mkv and then use DDVT.
Tried that already; but if I drop the dual layer mkv on DDVT, it still says it cannot find DV data. Ideally, by the looks of it, I am looking for a way, in case of dual layer, to re-encode the EL into the main stream somehow.
GodzilaAvenger
14th October 2024, 07:50
If I understood things correctly, I should be able to extract the EL from the main stream, and reapply it later, right? (So I can denoise movies first).
I believe so, yes. DDVT_DEMUXER should give you a base layer HDR.hevc file, an EL.hevc file, and a RPU.bin file.
I think denoising the base layer could get tricky. If the DV is MEL, it should be fine. If it's FEL though (see here (https://forum.doom9.org/showthread.php?p=1924655#post1924655) for the difference) denoising the base layer may screw things up when it's put together with the EL, as the EL's purpose in FEL is to add up to the base layer to recreate the original 12-bit stream. Of course you can just add the RPU to the base layer and get a Profile 8 DV. Quite a while ago (documented in some of the conversation early in this thread) I tried adding EL to an encoded BL but the result wouldn't even trigger DV on any display (I think because encoding messed up frame orders as well).
Tried that already; but if I drop the dual layer mkv on DDVT, it still says it cannot find DV data. Ideally, by the looks of it, I am looking for a way, in case of dual layer, to re-encode the EL into the main stream somehow.
MKVToolNix (at least some of the later versions that I've tried) should give you a single-layer .mkv from a dual-layer .m2ts file (or playlist if the Blu-ray does branching). DDVT can't work with your .mkv if it is dual-layer.
asarian
14th October 2024, 11:48
I believe so, yes. DDVT_DEMUXER should give you a base layer HDR.hevc file, an EL.hevc file, and a RPU.bin file.
I think denoising the base layer could get tricky. If the DV is MEL, it should be fine. If it's FEL though (see here (https://forum.doom9.org/showthread.php?p=1924655#post1924655) for the difference) denoising the base layer may screw things up when it's put together with the EL, as the EL's purpose in FEL is to add up to the base layer to recreate the original 12-bit stream. Of course you can just add the RPU to the base layer and get a Profile 8 DV. Quite a while ago (documented in some of the conversation early in this thread) I tried adding EL to an encoded BL but the result wouldn't even trigger DV on any display (I think because encoding messed up frame orders as well).
Yeah, you cannot change framerate, of course, or resize the base layer; it's kind of a 1:1 deal. But I really hope denoising will work. :) Way I understood it (and my understanding is clearly minimal), the EL consists essentiallly of location-based nits information, per frame. Hoping no precise 1:1 pixel overlap is required, or denoising will indeed be a bust.
MKVToolNix (at least some of the later versions that I've tried) should give you a single-layer .mkv from a dual-layer .m2ts file (or playlist if the Blu-ray does branching). DDVT can't work with your .mkv if it is dual-layer.
Holy crap! I had no idea MKVtoolnix could do this! I thought it was just ignoring the DV layer, but, indeed, it mixes the two somehow, and MediaInfo suddenly reports DV data on the now single stream!
Thank you kindly! This will help me tremendously.
EDIT: The MKVToolNix route was a great success! :) Reason I never saw it mix the DV main with EL before, is that MKVToolNix only does this on pure m2ts files (whereas I generally mux everything to mkv, as that plays so much nicer with Kodi and such). So, I first used tsMuxer to convert my denoised Push UHD mkv to m2ts again. Then used MKVToolNix to use the main (denoised) stream of the new m2ts, and added the original m2ts from disc (sans the main stream, of course, but with the EL), and muxed them together with MKVToolNix.The result is a totally wonderfully playing, single-layer, DV edition, in MKV, of my denoised Push UHD disc. :) Worked flawlessly. (I guess my 'gut' was right about the EL only containing positional nits info, and not requiring a bit-for-bit matching main stream). And it didn't even require re-encoding (at least not the x265 kind, that takes 12 hours).
GodzilaAvenger
14th October 2024, 22:03
You are very welcome!
You can tell by looking at the DV layer's bitrate if it is MEL (Minimum Enhancement Layer), faux FEL (Full Enhancement Layer), or actual FEL (here (https://avdisco.com/t/demystifying-dolby-vision-profile-levels-dolby-vision-levels-mel-fel/95)'s a good explainer on DV).
(My information is from this (https://forum.blu-ray.com/showpost.php?p=12116287&postcount=1) post in particular, click on the three Show Spoilers to read the full post) If the DV layer bitrate is on the order of ~100 kbps, then it is MEL, i.e. it only contains the RPU, i.e. the scene-by-scene brightness and tonemapping metadata.
If the DV layer bitrate is a little over 2 Mbps, it is faux FEL. The EL contains the RPU along with a uniform 1080p stream. If the bitrate is more than that (generally anything above 2.2 Mbps), it is actual FEL, and the EL contains both the RPU and the stream data that, when added to the base 10-bit HDR layer, recreates the film's original 12-bit stream.
I looked at Push's disk info and it looks like this:
Disc Title : PUSH
Disc Size : 61,837,342,720 bytes
Protection : AACS2
BD-Java : Yes
Playlist : 00802.MPLS
Size : 56,903,645,184 bytes
Length : 15127.180
Total Bitrate : 68.07 Mbps
Video : MPEG-H HEVC Video / 49719 kbps / 2160p / 23.976 fps / 169 / Main 10 Profile 5.1 High / 420 / 10 bits / HDR / BT.2020 /
Video : * MPEG-H HEVC Video / 7836 kbps / 1080p / 23.976 fps / 169 / Main 10 Profile 5.1 High / 420 / 10 bits / Dolby Vision / BT.2020 /
Audio : English / Dolby Atmos/TrueHD Audio / 7.1-Atmos / 48 kHz / 5847 kbps / 24-bit (AC3 Core5.1-EX / 48 kHz / 448 kbps)
Audio : English / Dolby Digital Audio / 2.0 / 48 kHz / 192 kbps / Dolby Surround
Audio : Spanish / Dolby Digital Audio / 5.1 / 48 kHz / 448 kbps
Subtitle : English / 27.089 kbps
Subtitle : Spanish / 22.159 kbps
Based on the discussion above, this is actual FEL. So why didn't you encounter any issues when denoising the base layer? I think the most likely reason is that your player, like almost all players out there, discards the video stream on the EL and only uses the RPU, so what you see is the base 10-bit HDR stream. It is also true that most TVs (even the likes of G4) don't get bright enough for you to notice the difference FEL makes, as it seems to be geared toward movie theatre projectors.
asarian
15th October 2024, 03:28
You are very welcome!
...
Based on the discussion above, this is actual FEL. So why didn't you encounter any issues when denoising the base layer? I think the most likely reason is that your player, like almost all players out there, discards the video stream on the EL and only uses the RPU, so what you see is the base 10-bit HDR stream. It is also true that most TVs (even the likes of G4) don't get bright enough for you to notice the difference FEL makes, as it seems to be geared toward movie theatre projectors.
That would be disappointing. :) I do notice a huge difference between regular HDR and DV, though. The latter is far more vibrant, more accentuated, as it were.
If the player is ignoring FEL, at least the TV detects the 'Dolby Vision' signal.
As to why I didn't encounter any issues when denoising the base layer? I dunno. Why would I? (no sarcasm). I mean, I denoised the movie years ago (before I had a DV capable TV), and only used the main stream for the process. Is there something wrong with my assumption that the EL just adds locational info to the screen? All denoising does, is re-arrange the pixels a bit, in essence.
GodzilaAvenger
15th October 2024, 08:50
FEL is made up of two elements: a 1080p video stream that is essentially "(movie studio 12-bit stream - 10-bit base layer stream)", and metadata that gives your TV information about how to adjust the brightness and colors for each scene, i.e. the RPU.
Your player isn't completely discarding the FEL, it is keeping the RPU from the FEL that lets your TV detect the DV signal and leads to those vibrant colors you mentioned.
asarian
15th October 2024, 18:07
FEL is made up of two elements: a 1080p video stream that is essentially "(movie studio 12-bit stream - 10-bit base layer stream)", and metadata that gives your TV information about how to adjust the brightness and colors for each scene, i.e. the RPU.
Your player isn't completely discarding the FEL, it is keeping the RPU from the FEL that lets your TV detect the DV signal and leads to those vibrant colors you mentioned.
Again, that's disappointing to hear. How can you tell, though? I mean, MKVToolNix turned it all into a single layer now. Is there a way to tell what the TV is using? (or disgarding).
GodzilaAvenger
16th October 2024, 02:20
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit
Since the last time I checked this a few years ago more players have become capable of playing full fat DV, so perhaps I'm wrong and your player does play the FEL along the RPU, check the list to see if it does. I think it would be hard to say visaully if the FEL is being used, it is supposed to help remove banding introduced by x265 and to retain film grain, but personally I can't tell the difference.
Also, I misspoke earlier. Your original Push file is dual-track dual-layer Profile 7 DV, when you use MKVToolNix it becomes single-track dual-layer Profile 7 DV. I confused tracks and layers
AgentXXL
16th October 2024, 15:04
Holy crap! I had no idea MKVtoolnix could do this! I thought it was just ignoring the DV layer, but, indeed, it mixes the two somehow, and MediaInfo suddenly reports DV data on the now single stream!
Thank you kindly! This will help me tremendously.
EDIT: The MKVToolNix route was a great success! :) Reason I never saw it mix the DV main with EL before, is that MKVToolNix only does this on pure m2ts files (whereas I generally mux everything to mkv, as that plays so much nicer with Kodi and such). So, I first used tsMuxer to convert my denoised Push UHD mkv to m2ts again. Then used MKVToolNix to use the main (denoised) stream of the new m2ts, and added the original m2ts from disc (sans the main stream, of course, but with the EL), and muxed them together with MKVToolNix.The result is a totally wonderfully playing, single-layer, DV edition, in MKV, of my denoised Push UHD disc. :) Worked flawlessly. (I guess my 'gut' was right about the EL only containing positional nits info, and not requiring a bit-for-bit matching main stream). And it didn't even require re-encoding (at least not the x265 kind, that takes 12 hours).
You can also use MakeMKV to convert the dual layer files to single layer. Just open the dual layer file, choose a destination folder and click the Make MKV button.
asarian
18th October 2024, 04:59
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit
Since the last time I checked this a few years ago more players have become capable of playing full fat DV, so perhaps I'm wrong and your player does play the FEL along the RPU, check the list to see if it does. I think it would be hard to say visaully if the FEL is being used, it is supposed to help remove banding introduced by x265 and to retain film grain, but personally I can't tell the difference.
Your knowledge of players is impressive. I have a Dune Solo 8K, and, indeed, this is what your sheet says:
M2TS & TS & MP4 & MKV
*EL is ignored and only the dynamic
metadata in the RPU is processed
*colors are accurate
Also, I misspoke earlier. Your original Push file is dual-track dual-layer Profile 7 DV, when you use MKVToolNix it becomes single-track dual-layer Profile 7 DV. I confused tracks and layers
Also, if indeed grain is retained in the EL, then clearly FEL gets ignored, as the denoised movie didn't re-introduce new noise.
Z2697
18th October 2024, 05:31
https://docs.google.com/spreadsheets/d/1jBIGF8XTVi9VmDBZ8a5hEyongYMCDlUiLHU9n1f_S74/edit
Since the last time I checked this a few years ago more players have become capable of playing full fat DV, so perhaps I'm wrong and your player does play the FEL along the RPU, check the list to see if it does. I think it would be hard to say visaully if the FEL is being used, it is supposed to help remove banding introduced by x265 and to retain film grain, but personally I can't tell the difference.
Also, I misspoke earlier. Your original Push file is dual-track dual-layer Profile 7 DV, when you use MKVToolNix it becomes single-track dual-layer Profile 7 DV. I confused tracks and layers
It actually meant to brought the 10-bits BL into 12-bits but...
FEL is usually a complete mess (a lot of noise-like pixels) in 1/4 resolution and less than 1/5 bitrate of the BL, I highly doubt the benefit if not harm it has.
Just see how many blocking and other compression artifacts they ususlly has. I'm not sure if I really feel comfortable to put that back into the main video.
With that being said, 10-bits surely isn't super enough for HDR and applying FEL surely does *something* (whether it's good or not).
P.S. "Difference of bit depths" often looks like noise/grain especially when there's actual noise/grain present in the original image.
lemaireus
12th November 2024, 15:45
I seem to have run into a bug in DDVT tools. Each time I try to extract a Dolby Vision Profile 8 RPU, the option to enter a '4. Crop RPU' goes blank. Instead, the 'Crop RPU' option moves to '3. Convert *':
https://i.postimg.cc/K8NrmNq9/DDVT-Bug-DV-Profile-8-1.jpg
When I enter '4' to set the 'Crop RPU' option to 'Yes', it is the 'Convert' option that changes to 'Yes' but the 'Crop RPU' option remains unavailable:
https://i.postimg.cc/Sxq3ZgYV/DDVT-Bug-DV-Profile-8-2.jpg
Thereafter, DDVT duly extracts the RPU, but when it's time to inject that RPU back, it gives a 'RPU does not match video' and 'video does not match RPU' message.
This problem occurs every time when the RPU is of Dolby Vision Profile 8. I've never run into this error in DDVT when the RPU is of Dolby Vision Profile 7.
Any ideas whether this is a bug in DDVT tool or might it be an issue with Dolby Vision profile 8?
DarkRepaer
18th November 2024, 12:32
You are very welcome! I have not tried this personally yet, but based on what @quietvoid and @-QfG have said and dovi_tool's documentation, I think this is how things work:
Let's say you have a file where most scenes have a standard AR (3840x1608), two have IMAX AR (3840x2076), and one is something in between (3840x1960). Then your "custom.json" file which is located next to your "RPU.bin" would look something like this:
{
"mode": 0,
"active_area": {
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 276,
"bottom": 276
}
{
"id": 1,
"left": 0,
"right": 0,
"top": 42,
"bottom": 42
}
{
"id": 2,
"left": 0,
"right": 0,
"top": 100,
"bottom": 100
}
],
"edits": {
"all": 0,
"1000-1234": 1,
"2400-2468": 2,
"4800-4848": 1
}
}
}
You can then use the following command to edit your RPU:
dovi_tool editor -i RPU.bin -j custom.json -o Edited_RPU.bin
What this essentially does is to first assign the default AR L5 borders to all frames, then overwrite it for the frames specified. From what @-QfG- has said, I think if you have a "custom.json" file directly next to the "RPU.bin" file, when using DDVT_INJECTOR the tool first edits the RPU (using the dovi_tool command above) and then injects it into the mkv.
Hi GodzilaAvenger, thanks for the explanation on how to set the DV Aspect Ratio change.
I have two questions for you.
How can I find the crop values to set for the various AR changes?
And after injecting the RPU, how do I check if everything is correct?
GodzilaAvenger
18th November 2024, 23:17
Hi,
For the first question, I do it by hand. I have a 4K display and I use Microsoft PowerToys' Screen Ruler to measure the borders. It's pretty tedious. Hopefully someone else knows of a more automated way of doing it (I think you can detect borders with FFmpeg but I've never tried it).
As for the second one, I think you just have to watch it and see if there are any weird brightness issues or frame cropping. Again, I'd welcome those with more experience to share their method if they have a better one.
DarkRepaer
22nd November 2024, 20:11
Hi,
For the first question, I do it by hand. I have a 4K display and I use Microsoft PowerToys' Screen Ruler to measure the borders. It's pretty tedious. Hopefully someone else knows of a more automated way of doing it (I think you can detect borders with FFmpeg but I've never tried it).
As for the second one, I think you just have to watch it and see if there are any weird brightness issues or frame cropping. Again, I'd welcome those with more experience to share their method if they have a better one.
For the first question ok, but for the second question, is it possible to see perhaps from the info tool, such as the "all" scenecut file, the various crop values applied to individual frames or in some other technical way?
GodzilaAvenger
22nd November 2024, 23:17
Yes, if you use the FILEINFO tool with the default settings it'll give you a massive .json file that has the frame-by-frame info, you can look at the L5 data for each frame to verify your work.
DarkRepaer
23rd November 2024, 17:34
Yes, if you use the FILEINFO tool with the default settings it'll give you a massive .json file that has the frame-by-frame info, you can look at the L5 data for each frame to verify your work.
So to know the exact AR and therefore the top and bottom values I use the crop function of StaxRip (the software I use for the encodes), obviously in manual. Bringing a concrete example of a film, one of the most difficult complicated examples (25 different ARs), can you tell me if the custom json prepared can be corrected? :helpful:
Just for confirmation before proceeding with the injection. :thanks:
Aspect Ratio Film
0-3259 - 0,0,0,0 |id0
3260-16248 - 0,0,204,204 |id1
16249-17426 - 0,0,0,0 |id0
17427-35823 - 0,0,204,204 |id1
35824-38205 - 0,0,0,0 |id0
38206-39001 - 0,0,204,204 |id1
39002 - 0,0,138,138 |id2
39003 - 0,0,70,70 |id3
39004 - 0,0,4,4 |id4
39005-40639 - 0,0,0,0 |id0
40640-60260 - 0,0,204,204 |id1
60261-61591 - 0,0,0,0 |id0
61592-95714 - 0,0,204,204 |id1
95715-96263 - 0,0,0,0 |id0
96264-112299 - 0,0,204,204 |id1
112300 - 0,0,194,194 |id5
112301 - 0,0,184,184 |id6
112302 - 0,0,176,176 |id7
112303 - 0,0,168,168 |id8
112304 - 0,0,158,158 |id9
112305 - 0,0,150,150 |id10
112306 - 0,0,140,140 |id11
112307 - 0,0,130,130 |id12
112308 - 0,0,122,122 |id13
112309 - 0,0,114,114 |id14
112310 - 0,0,104,104 |id15
112311 - 0,0,94,94 |id16
112312 - 0,0,86,86 |id17
112313 - 0,0,76,76 |id18
112314 - 0,0,68,68 |id19
112315 - 0,0,58,58 |id20
112316 - 0,0,50,50 |id21
112317 - 0,0,40,40 |id22
112318 - 0,0,30,30 |id23
112319 - 0,0,22,22 |id24
112320 - 0,0,14,14 |id25
112321 - 0,0,4,4 |id4
112322-141753 - 0,0,0,0 |id0
141754-158601 - 0,0,204,204 |id1
158602-159671 - 0,0,0,0 |id0
159672-169886 - 0,0,204,204 |id1
Custom.json
{
"mode": 0,
"active_area": {
"crop": false,
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 0,
"bottom": 0
},
{
"id": 1,
"left": 0,
"right": 0,
"top": 204,
"bottom": 204
},
{
"id": 2,
"left": 0,
"right": 0,
"top": 138,
"bottom": 138
},
{
"id": 3,
"left": 0,
"right": 0,
"top": 70,
"bottom": 70
},
{
"id": 4,
"left": 0,
"right": 0,
"top": 4,
"bottom": 4
},
{
"id": 5,
"left": 0,
"right": 0,
"top": 194,
"bottom": 194
},
{
"id": 6,
"left": 0,
"right": 0,
"top": 184,
"bottom": 184
},
{
"id": 7,
"left": 0,
"right": 0,
"top": 176,
"bottom": 176
},
{
"id": 8,
"left": 0,
"right": 0,
"top": 168,
"bottom": 168
},
{
"id": 9,
"left": 0,
"right": 0,
"top": 158,
"bottom": 158
},
{
"id": 10,
"left": 0,
"right": 0,
"top": 150,
"bottom": 150
},
{
"id": 11,
"left": 0,
"right": 0,
"top": 140,
"bottom": 140
},
{
"id": 12,
"left": 0,
"right": 0,
"top": 130,
"bottom": 130
},
{
"id": 13,
"left": 0,
"right": 0,
"top": 122,
"bottom": 122
},
{
"id": 14,
"left": 0,
"right": 0,
"top": 114,
"bottom": 114
},
{
"id": 15,
"left": 0,
"right": 0,
"top": 104,
"bottom": 104
},
{
"id": 16,
"left": 0,
"right": 0,
"top": 94,
"bottom": 94
},
{
"id": 17,
"left": 0,
"right": 0,
"top": 86,
"bottom": 86
},
{
"id": 18,
"left": 0,
"right": 0,
"top": 76,
"bottom": 76
},
{
"id": 19,
"left": 0,
"right": 0,
"top": 68,
"bottom": 68
},
{
"id": 20,
"left": 0,
"right": 0,
"top": 58,
"bottom": 58
},
{
"id": 21,
"left": 0,
"right": 0,
"top": 50,
"bottom": 50
},
{
"id": 22,
"left": 0,
"right": 0,
"top": 40,
"bottom": 40
},
{
"id": 23,
"left": 0,
"right": 0,
"top": 30,
"bottom": 30
},
{
"id": 24,
"left": 0,
"right": 0,
"top": 22,
"bottom": 22
},
{
"id": 25,
"left": 0,
"right": 0,
"top": 14,
"bottom": 14
}
],
"edits": {
"all": 0,
"3260-16248": 1,
"17427-35823": 1,
"38206-39001": 1,
"39002-39002": 2,
"39003-39003": 3,
"39004-39004": 4,
"40640-60260": 1,
"61592-95714": 1,
"96264-112299": 1,
"112300-112300": 5,
"112301-112301": 6,
"112302-112302": 7,
"112303-112303": 8,
"112304-112304": 9,
"112305-112305": 10,
"112306-112306": 11,
"112307-112307": 12,
"112308-112308": 13,
"112309-112309": 14,
"112310-112310": 15,
"112311-112311": 16,
"112312-112312": 17,
"112313-112313": 18,
"112314-112314": 19,
"112315-112315": 20,
"112316-112316": 21,
"112317-112317": 22,
"112318-112318": 23,
"112319-112319": 24,
"112320-112320": 25,
"112321-112321": 4,
"141754-158601": 1,
"159672-169839": 1
}
}
}
GodzilaAvenger
24th November 2024, 00:53
I didn't check every value but overall looks good to me, you can try it out and then verify with the FILEINFO tool, then adjust values if needed.
DarkRepaer
24th November 2024, 22:09
I didn't check every value but overall looks good to me, you can try it out and then verify with the FILEINFO tool, then adjust values if needed.
Everything went as expected! The injection was successful (I'll post the log file). Now all that's missing is playback verification.
Thanks for the help! :thanks:
powered by quietvoids tools Copyright (c) 2021-2024 QfG
====================================
Dolby Vision Tool INJECTOR
====================================
== LOGFILE START =======================================================================================================
23/11/2024 21:41:20,72
== CUSTOM JSON =========================================================================================================
EditConfig {
"mode": 0,
"remove_cmv4": false,
"remove_mapping": false,
"active_area": {
"crop": false,
"presets": [
{
"id": 0,
"left": 0,
"right": 0,
"top": 0,
"bottom": 0
},
{
"id": 1,
"left": 0,
"right": 0,
"top": 204,
"bottom": 204
},
{
"id": 2,
"left": 0,
"right": 0,
"top": 138,
"bottom": 138
},
{
"id": 3,
"left": 0,
"right": 0,
"top": 70,
"bottom": 70
},
{
"id": 4,
"left": 0,
"right": 0,
"top": 4,
"bottom": 4
},
{
"id": 5,
"left": 0,
"right": 0,
"top": 194,
"bottom": 194
},
{
"id": 6,
"left": 0,
"right": 0,
"top": 184,
"bottom": 184
},
{
"id": 7,
"left": 0,
"right": 0,
"top": 176,
"bottom": 176
},
{
"id": 8,
"left": 0,
"right": 0,
"top": 168,
"bottom": 168
},
{
"id": 9,
"left": 0,
"right": 0,
"top": 158,
"bottom": 158
},
{
"id": 10,
"left": 0,
"right": 0,
"top": 150,
"bottom": 150
},
{
"id": 11,
"left": 0,
"right": 0,
"top": 140,
"bottom": 140
},
{
"id": 12,
"left": 0,
"right": 0,
"top": 130,
"bottom": 130
},
{
"id": 13,
"left": 0,
"right": 0,
"top": 122,
"bottom": 122
},
{
"id": 14,
"left": 0,
"right": 0,
"top": 114,
"bottom": 114
},
{
"id": 15,
"left": 0,
"right": 0,
"top": 104,
"bottom": 104
},
{
"id": 16,
"left": 0,
"right": 0,
"top": 94,
"bottom": 94
},
{
"id": 17,
"left": 0,
"right": 0,
"top": 86,
"bottom": 86
},
{
"id": 18,
"left": 0,
"right": 0,
"top": 76,
"bottom": 76
},
{
"id": 19,
"left": 0,
"right": 0,
"top": 68,
"bottom": 68
},
{
"id": 20,
"left": 0,
"right": 0,
"top": 58,
"bottom": 58
},
{
"id": 21,
"left": 0,
"right": 0,
"top": 50,
"bottom": 50
},
{
"id": 22,
"left": 0,
"right": 0,
"top": 40,
"bottom": 40
},
{
"id": 23,
"left": 0,
"right": 0,
"top": 30,
"bottom": 30
},
{
"id": 24,
"left": 0,
"right": 0,
"top": 22,
"bottom": 22
},
{
"id": 25,
"left": 0,
"right": 0,
"top": 14,
"bottom": 14
}
],
"edits": {
"112309-112309": 14,
"112321-112321": 4,
"112310-112310": 15,
"112314-112314": 19,
"39004-39004": 4,
"112301-112301": 6,
"17427-35823": 1,
"39002-39002": 2,
"112305-112305": 10,
"112306-112306": 11,
"112313-112313": 18,
"40640-60260": 1,
"112312-112312": 17,
"38206-39001": 1,
"112308-112308": 13,
"112315-112315": 20,
"112320-112320": 25,
"96264-112299": 1,
"3260-16248": 1,
"112303-112303": 8,
"112311-112311": 16,
"112317-112317": 22,
"112319-112319": 24,
"112304-112304": 9,
"112316-112316": 21,
"39003-39003": 3,
"112300-112300": 5,
"112302-112302": 7,
"159672-169839": 1,
"112307-112307": 12,
"61592-95714": 1,
"112318-112318": 23,
"all": 0,
"141754-158601": 1
}
}
}
Parsing RPU file...
Editing active area offsets...
Final metadata length: 169886
Writing RPU file...
== LOGFILE END =========================================================================================================
GodzilaAvenger
24th November 2024, 22:56
You're welcome :)
hidef_rec
12th December 2024, 22:23
Possible to use HDR info from a 1080p video into making a hybrid 2160p output also using a 2160p DV P5 only video? When I use DDVT_HYBRID, I get a 1080p output, not 2160p. Thanks.
matey
27th December 2024, 00:44
I'm currently mux them to Profile 5 with Base HDR/HDR10+, with Codec ID hev1. For many people is not "the way", but for me it does the job for my tv sets.
hi fuso
can you please give me step by step instructions to do this to convert mkv to mp4 to play it on lg c8, i tried but it doesn't work. also please let me know which version of the software you use?
thanks
-QfG-
27th December 2024, 02:19
-v0.64
*Minor Bugfixes.
*ADDED MEDIAINFO script (also quick video check for DV levels, included MEL/FEL analyse).
*ADDED SYNCCHECK (check frames and cropping borders between video and rpu).
*UPDATED dovi_tool to v2.1.3.
*UPDATED hdr10plus_tool to v1.6.1.
*UPDATED mkvtoolnix to v 88.0.0.0.
*UPDATED FFMPEG to 7.1
https://i.ibb.co/0c6fFf7/DDVT-Media-Info.png
https://i.ibb.co/z6X0CGM/DDVT-Quick-Info.png
https://i.ibb.co/H2VcgHT/DDVT-SYNCCHECK.png
-QfG-
27th December 2024, 23:13
-v0.64.1
*Minor Bugfixes.
*ADDED Custom JSON file directly Support (Injector) (also bin files).
*ADDED RPU Extracting via Demuxer Script. (bin files)
*FIXED Wrong L9 detection with MediaInfo.
Fuso
28th December 2024, 14:18
hi fuso
can you please give me step by step instructions to do this to convert mkv to mp4 to play it on lg c8, i tried but it doesn't work. also please let me know which version of the software you use?
thanks
Sure...
1. I use the latest tsmuxer (Nightly build from 2024-06-06-02-00-53) to extract the video and audio from MKV source.
2. Mux the .hevc and .ec3/.ac3 to profile 5 mp4
this is the script that I use
mp4muxer --dv-profile 5 --input-file 1.hevc --input-video-frame-rate 24000/1001 --input-file 1.ec3 --media-lang eng --output-file MOVIE.mp4
pause
you can change the framerate depending on the source, also the audio file extension to ac3.
I can't remember which version of the mp4muxer I use.
3. Then I rename the output file from .mp4 to .mkv. The output file is profile 5 with codec ID dvhe which will not play on non-DoVi TV like Samsung.
4. I use the DDVT_MKVTOMP4 script to convert the renamed file again to mp4, but this time it will have codec ID hev1.
I'm sure this not the perfect or correct way to do this, but for my needs it's enough.
Maybe someone can tell me a way of directly muxing the video and audio to Profile 5 mp4 with codec ID hev1.
Grimm
28th December 2024, 17:01
Please add an option to skip unsupported subtitles when converting mkv to mp4 and convert the video instead
matey
30th December 2024, 11:32
Sure...
1. I use the latest tsmuxer (Nightly build from 2024-06-06-02-00-53) to extract the video and audio from MKV source.
2. Mux the .hevc and .ec3/.ac3 to profile 5 mp4
this is the script that I use
mp4muxer --dv-profile 5 --input-file 1.hevc --input-video-frame-rate 24000/1001 --input-file 1.ec3 --media-lang eng --output-file MOVIE.mp4
pause
you can change the framerate depending on the source, also the audio file extension to ac3.
I can't remember which version of the mp4muxer I use.
3. Then I rename the output file from .mp4 to .mkv. The output file is profile 5 with codec ID dvhe which will not play on non-DoVi TV like Samsung.
4. I use the DDVT_MKVTOMP4 script to convert the renamed file again to mp4, but this time it will have codec ID hev1.
I'm sure this not the perfect or correct way to do this, but for my needs it's enough.
Maybe someone can tell me a way of directly muxing the video and audio to Profile 5 mp4 with codec ID hev1.
thanks very much for that.
when you get the chance if you could please let me know which version of mp4muxer you use so i can be sure and use that version.
appreciate it, cheers.
-QfG-
30th December 2024, 15:58
The output file is profile 5 with codec ID dvhe which will not play on non-DoVi TV like Samsung.
Profile 5 files will never played correctly on non-dv TVs like samsung. The base layer from L5 profiles uses not the HDR10 colorrrange BT.2020. L5 uses the DoVi specific colorrange ICtCp.
Please add an option to skip unsupported subtitles when converting mkv to mp4 and convert the video instead
I don't know the switches for FFMPEG to skip all non text subtitles, sorry :(
Also new release with many bugfixes:
-v0.64.2
*Major Bugfixes.
*FIXED MediaInfo bugs with AV1/VP1
Fuso
31st December 2024, 01:17
thanks very much for that.
when you get the chance if you could please let me know which version of mp4muxer you use so i can be sure and use that version.
appreciate it, cheers.
Here, I will upload it.
Profile 5 files will never played correctly on non-dv TVs like samsung. The base layer from L5 profiles uses not the HDR10 colorrrange BT.2020. L5 uses the DoVi specific colorrange ICtCp.
I know that. But my output has HDR10 as a base layer.
HDR format : Dolby Vision, Version 1.0, dvhe.05.06, BL+RPU / SMPTE ST 2086, HDR10 compatible
Codec ID : hev1
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.