Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > New and alternative a/v containers

Reply
 
Thread Tools Search this Thread Display Modes
Old 4th December 2023, 15:17   #1941  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Oh? It shouldn't have, and none of my test cases have failed. That being said, the changes for Dolby Vision did modify the transport stream code quite a bit. It's quite possible something broke that shouldn't have.

Can you provide some more information? I just gave it a try; remuxing the "Solo — A Star Wars Story" Blu-ray via the GUI worked just fine (playlist 00800.mpls).
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 4th December 2023, 15:48   #1942  |  Link
Snowknight26
Registered User
 
Join Date: Aug 2007
Posts: 1,429
Ah ok, now I'm getting somewhere. It looks like v81 fails to write anything to the output file if the input is either a Blu-ray playlist or m2ts (and possibly others, but haven't tested) that contains a PCM track and you specifically don't include the PCM track in the output.

v81, M2TS with 2 streams, H.264 and PCM, with PCM unchecked:
Code:
C:\Users\Admin>"C:\Program Files\MKVToolNix\mkvmerge.exe" --ui-language en --priority lower --output ^"Z:\temp\temp.mkv^" --no-audio --language 0:und ^"^(^" ^"Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts^" ^"^)^"
mkvmerge v81.0 ('Milliontown') 64-bit
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
The file 'Z:\temp\temp.mkv' has been opened for writing.
v81, M2TS with 2 streams, H.264 and PCM, with PCM checked:
Code:
C:\Users\Admin>"C:\Program Files\MKVToolNix\mkvmerge.exe" --ui-language en --priority lower --output ^"Z:\temp\temp.mkv^" --language 0:und --language 1:ja ^"^(^" ^"Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts^" ^"^)^" --track-order 0:0,0:1
mkvmerge v81.0 ('Milliontown') 64-bit
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts' track 1: Using the output module for the format 'PCM'.
The file 'Z:\temp\temp.mkv' has been opened for writing.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00012.m2ts' track 0: Extracted the aspect ratio information from the video bitstream and set the display dimensions to 1920/1080.
^Cogress: 4%
v81, different M2TS with 2 streams, H.264 and PCM, with PCM unchecked:
Code:
C:\Users\Admin>"C:\Program Files\MKVToolNix\mkvmerge.exe" --ui-language en --priority lower --output ^"Z:\temp\temp.mkv^" --no-audio --language 0:und ^"^(^" ^"Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts^" ^"^)^"
mkvmerge v81.0 ('Milliontown') 64-bit
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
The file 'Z:\temp\temp.mkv' has been opened for writing.
v81, different M2TS with 2 streams, H.264 and PCM, with PCM checked:
Code:
C:\Users\Admin>"C:\Program Files\MKVToolNix\mkvmerge.exe" --ui-language en --priority lower --output ^"Z:\temp\temp.mkv^" --language 0:und --language 1:ja ^"^(^" ^"Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts^" ^"^)^" --track-order 0:0,0:1
mkvmerge v81.0 ('Milliontown') 64-bit
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts' track 1: Using the output module for the format 'PCM'.
The file 'Z:\temp\temp.mkv' has been opened for writing.
'Z:\temp\ES_FF_XIV_ORCHESTRAL_ALBUM_3\BDMV\STREAM\00010.m2ts' track 0: Extracted the aspect ratio information from the video bitstream and set the display dimensions to 1920/1080.
^Cogress: 4%
v81, playlist with multiple streams (H.264, PCM, DTS-HD MA, chapters), with PCM unchecked:
Code:
C:\Users\Admin>"C:\Program Files\MKVToolNix\mkvmerge.exe" --ui-language en --priority lower --output ^"Z:\temp\temp.mkv^" --audio-tracks 2,3,4 --language 0:und --language 2:ja --language 3:ja --language 4:ja ^"^(^" ^"Z:\temp\FFXIV_FATU\BDMV\PLAYLIST\00003.mpls^" ^"^)^" --chapter-language und --generate-chapters-name-template ^"Chapter ^<NUM:2^>^" --track-order 0:0,0:2,0:3,0:4
mkvmerge v81.0 ('Milliontown') 64-bit
Scanning 8 files in 1 playlist.
Done scanning playlists.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 4: Using the output module for the format 'DTS'.
The file 'Z:\temp\temp.mkv' has been opened for writing.
v81, playlist with multiple streams (H.264, PCM, DTS-HD MA, chapters), with PCM checked:
Code:
C:\Users\Admin>"C:\Program Files\MKVToolNix\mkvmerge.exe" --ui-language en --priority lower --output ^"Z:\temp\temp.mkv^" --language 0:und --language 1:ja --language 2:ja --language 3:ja --language 4:ja ^"^(^" ^"Z:\temp\FFXIV_FATU\BDMV\PLAYLIST\00003.mpls^" ^"^)^" --chapter-language und --generate-chapters-name-template ^"Chapter ^<NUM:2^>^" --track-order 0:0,0:1,0:2,0:3,0:4
mkvmerge v81.0 ('Milliontown') 64-bit
Scanning 8 files in 1 playlist.
Done scanning playlists.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts': Using the demultiplexer for the format 'MPEG transport stream'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00016.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00018.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00020.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00022.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00024.m2ts' track 4: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 0: Using the output module for the format 'AVC/H.264 (unframed)'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 1: Using the output module for the format 'PCM'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 2: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 3: Using the output module for the format 'DTS'.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00027.m2ts' track 4: Using the output module for the format 'DTS'.
The file 'Z:\temp\temp.mkv' has been opened for writing.
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts' track 0: Extracted the aspect ratio information from the video bitstream and set the display dimensions to 1920/1080.
Appending track 0 from file no. 1 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts') to track 0 from file no. 0 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts').
'Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts' track 0: Extracted the aspect ratio information from the video bitstream and set the display dimensions to 1920/1080.
Appending track 2 from file no. 1 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts') to track 2 from file no. 0 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts').
Appending track 3 from file no. 1 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts') to track 3 from file no. 0 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts').
Appending track 4 from file no. 1 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts') to track 4 from file no. 0 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts').
Appending track 1 from file no. 1 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00014.m2ts') to track 1 from file no. 0 ('Z:\temp\FFXIV_FATU\BDMV\STREAM\00039.m2ts').
^Cogress: 7%
Snowknight26 is offline   Reply With Quote
Old 4th December 2023, 16:06   #1943  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,812
Quote:
Originally Posted by Perenista View Post
I stopped splitting any file with MKVToolnix a long time ago, because that always broke the resulting MKV. It had A/V sync issues, and I was unable to revert the damage. Only a few were not affected, it was totally random. I used to do this because I had more than 1 Google Drive acc, with 15 GB each, and some MKVs were big.
Well I can't say I've ever had problems splitting files, and I've done it hundreds of times over the years. The only "issue" has been MKVToolNix applying a video delay to a split section. The delay can be removed by applying an appropriate negative delay to each stream, making the video delay zero. I've never experienced A/V sync problems as a result, but I was curious as to why there's a video delay in the first place, especially in the case of the samples I uploaded, where the video is the only stream....
hello_hello is offline   Reply With Quote
Old 4th December 2023, 18:35   #1944  |  Link
markfilipak
Registered User
 
markfilipak's Avatar
 
Join Date: Jul 2016
Location: Mansfield, Ohio (formerly San Jose, California)
Posts: 277
mkvextract, dots-in-filename bug

Quote:
Originally Posted by manolito View Post
Win7 compatible builds are here:

https://forum.doom9.org/showthread.php?t=184092

At the very end of this thread you can find the current versions which are built to work under Win7.
Thank you, Manolito. I was able to upgrade to v.81. The mkvextract bug is still there.

Script:
set NAME=STAR TREK, TNG [1987..1994] 1- 23 We'll Always Have Paris
set M2TS=h:\BDMV\STREAM\00004.m2ts
set TARGETPATH=g:\Movies I'm working on\STAR TREK, TNG
ffmpeg -i "%M2TS%" -map 0:s:0 -s 1920x1080 -c:s dvdsub -f matroska "%TARGETPATH%\%NAME%.mkv"
"C:\Program Files\MKVToolNix\mkvextract" "%TARGETPATH%\%NAME%.mkv" tracks 0:"%TARGETPATH%\%NAME%"

Result:
g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..idx
Should be:
g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..1994] 1- 23 We'll Always Have Paris.idx

Result:
g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..sub
Should be:
g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..1994] 1- 23 We'll Always Have Paris.sub

--Mark.
markfilipak is offline   Reply With Quote
Old 4th December 2023, 20:02   #1945  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Quote:
Originally Posted by Snowknight26 View Post
Ah ok, now I'm getting somewhere. It looks like v81 fails to write anything to the output file if the input is either a Blu-ray playlist or m2ts (and possibly others, but haven't tested) that contains a PCM track and you specifically don't include the PCM track in the output.
Interesting. Please open an issue over on Gitlab for it. Thanks.
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 4th December 2023, 20:42   #1946  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Quote:
Originally Posted by markfilipak View Post
Thank you, Manolito. I was able to upgrade to v.81. The mkvextract bug is still there.
This is not a bug. You're effectively calling mkvextract with like this (replacing the variables with copy-pasted content):

Code:
"C:\Program Files\MKVToolNix\mkvextract" "g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..1994] 1- 23 We'll Always Have Paris.mkv" tracks 0:"g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..1994] 1- 23 We'll Always Have Paris"
Note that there's neither ".idx" nor ".sub" at the end. However, mkvextract has to create those two files. It assumes that the user always specifies a file extension for the output file name. It then replaces the extension with .idx for the first file & with .sub for the second file.

The extension is simply the part starting with the last . in the name. Therefore the result is pretty self-explanatory.

If it didn't replace the extension but only appended .idx & .sub, most users would simply end up with "filename.idx.idx" and "filename.idx.sub", which would be assinine.

No, mkvextract cannot read your mind. Therefore it makes the sensible assumption that the user always specifies a file extension.

Just add ".idx" to the end; it should work fine, e.g.

Code:
"C:\Program Files\MKVToolNix\mkvextract" "%TARGETPATH%\%NAME%.mkv" tracks 0:"%TARGETPATH%\%NAME%.idx"
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 6th December 2023, 22:01   #1947  |  Link
j7n
Registered User
 
j7n's Avatar
 
Join Date: Apr 2006
Posts: 136
Can you say which input formats currently have automatic audio delay compensation implemented? I want to avoid compensating twice.
j7n is offline   Reply With Quote
Old 7th December 2023, 09:07   #1948  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
For each source file mkvmerge will normalize the timestamps so that the lowest timestamp of that file starts at 0. The relative timestamps will remain intact (e.g. if audio starts at 120ms, video starts at 40ms, then mkvmerge will subtract 40ms from all timestamps from that one file so that audio starts at 80ms, video at 0ms). Meaning that if you take a file containing more than one track & mux it the audio, video & subtitles from that one file should always stay in sync.

There's nothing in mkvmerge to synchronize audio & video from different files apart from the aforementioned normalization to starting at 0ms for each individual file.

On top of that mechanism the GUI can scan file names & recognize a delay mentioned in the file name & apply it via mkvmerge's "--sync" option. mkvmerge itself doesn't have something similar (for good reason).

In other words: manually specifying --sync… should ideally only be needed if you combine tracks from different source files as there's no way for mkvmerge to automagically sync them up.
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 7th December 2023, 09:29   #1949  |  Link
markfilipak
Registered User
 
markfilipak's Avatar
 
Join Date: Jul 2016
Location: Mansfield, Ohio (formerly San Jose, California)
Posts: 277
Quote:
Originally Posted by Mosu View Post
This is not a bug.
Yes, I see that now. But it is illogical.
Quote:
Note that there's neither ".idx" nor ".sub" at the end. However, mkvextract has to create those two files.
That's why it's illogical.

The template I used was from another site. It appeared from it that only the /path/name was supplied -- no extension (file type). That made sense because mkvextract makes 2 files: IDX & SUB, and calling it with only one extension is illogical.

Your explanation works, thank you, but it doesn't explain why
g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987..1994] 1- 23 We'll Always Have Paris
became
g:\Movies I'm working on\STAR TREK, TNG\STAR TREK, TNG [1987.
Quote:
The extension is simply the part starting with the last . in the name. Therefore the result is pretty self-explanatory.
But why would mkvextract remove the 'extension'. That's illogical. I have plenty of files with names like 'mkvextract.exe.txt'.
Quote:
If it didn't replace the extension but only appended .idx & .sub, most users would simply end up with "filename.idx.idx" and "filename.idx.sub", which would be assinine.
I disagree. It would be logical and it would be immediately apparent to everyone what happened, and they would supply just /path/name. In my case, I was running a script and when the 'extensions' were removed, there was a collision because the only parts that differed were the 'extensions'. What would be logical is to specify just /path/name like I did.

It's a small deal and I've 'fixed' my code, so don't trouble yourself.
Quote:
Just add ".idx" to the end; it should work fine, e.g.
Thank you. I am doing that now. But it's still illogical. :-)
markfilipak is offline   Reply With Quote
Old 7th December 2023, 10:26   #1950  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Quote:
Originally Posted by markfilipak View Post
But why would mkvextract remove the 'extension'.
Because most people who use mkvextract do actually specify an extensions such as .idx or .sub when they try to extract VobSub subtitles — as they have to specify extensions for all other file types, too. Therefore mkvextract assumes that people do that and replaces the existing extension for each of the two files.

Don't make the mistake of assuming that what you find logical or illogical is universal. Most people work differently than you do (same goes for anyone, really; most people work differently than I do, for example). I had tried not to replace extensions in the past, which lead to a lot of confused users. The current way of replacing extensions only lead to one complaint (yours) over the last ten years or so. This is my experience, and that's why mkvextract behaves this way.
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 7th December 2023, 10:39   #1951  |  Link
j7n
Registered User
 
j7n's Avatar
 
Join Date: Apr 2006
Posts: 136
I read some time ago that in MP4 files the tag ITunSMPB was taken into account and converted into a delay in addition to one specified by --sync. What I want to know is which (if any) other elementary stream formats have received similar treatment since that issue was resolved. I'm not asking for any changes, just to clarify the current situation.
j7n is offline   Reply With Quote
Old 7th December 2023, 10:41   #1952  |  Link
-QfG-
QfG Group Germany
 
-QfG-'s Avatar
 
Join Date: Oct 2018
Location: Germany
Posts: 244
Quote:
Originally Posted by Perenista View Post
Is there a way to actually add a new subtitle to a MKV, but that new track have the "default" disabled by default?

If I am not mistaken, if we enable this option, it also disables the "default" for the others which are already DEFAULTED.


Simply set this switch. I hope in future of the same options for audio, too.
-QfG- is offline   Reply With Quote
Old 7th December 2023, 11:18   #1953  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Quote:
Originally Posted by j7n View Post
I read some time ago that in MP4 files the tag ITunSMPB was taken into account and converted into a delay in addition to one specified by --sync. What I want to know is which (if any) other elementary stream formats have received similar treatment since that issue was resolved. I'm not asking for any changes, just to clarify the current situation.
There are no other formats that I know of that have similar information on top of the already existing timestamps in the file format.
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 9th December 2023, 00:24   #1954  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,812
Quote:
Originally Posted by hello_hello View Post
There's a link to a 6kB zip file below containing two small sample MKVs. Neither MKV contains a stream other than (blank) video and neither has a video delay. The first MKV contains 140 frames of AVC video.
If I open "Test A.mkv" from the zip file and append "Test B.mkv", then remux while telling MKVToolnixGUI to split the output after frame 140, logically the output MKVs should be the same as the input MKVs, but in this case the second output MKV has a video delay of 600ms, and I'm just trying to understand why.

Test.zip

Cheers.
Mosu, any chance of an answer to this one? I'm curious....

Cheers.
hello_hello is offline   Reply With Quote
Old 9th December 2023, 12:08   #1955  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
I've written in depth about how mkvmerge's splitting & appending works and am not in the mood to write all that up once again. Sorry. Just be aware that splitting+appending is not a lossless process, for various reasons. You can play around with "--append-mode file" vs "--append-mode track", if you want.
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 9th December 2023, 14:23   #1956  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,812
I don't know if it's expected, but when I append Test B.mkv to Test A.mkv (from the zip file I linked to) using "add as additional parts", the output is only Test A.mkv and there's no error or warning message.

I played around with "--append-mode file" and "--append-mode track". Neither changes the result.
It doesn't matter which --append-mode I use, after appending, the video timecodes from the output files are the same. There's no "gap" in the timecodes where they were appended.
After appending Test B.mkv to Test A.mkv, regardless of the --append-mode specified, if I then split the output MKV after frame 140, the second part has no video delay.

If I append them while also splitting after frame 140 in a single operation though (as I often do to split the audio and subtitles to match), it doesn't matter which --append-mode I use, the second part has a video delay of 600ms.

So unfortunately playing around with --append-mode didn't explain why appending and splitting in a single operation sometimes creates a video delay for the second part (even when there's no other streams), whereas appending and splitting in two steps doesn't.

Last edited by hello_hello; 9th December 2023 at 14:38.
hello_hello is offline   Reply With Quote
Old 9th December 2023, 15:15   #1957  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,812
Quote:
Originally Posted by Mosu View Post
There are no other formats that I know of that have similar information on top of the already existing timestamps in the file format.
MP3, Ogg and Opus (can) support gapless playback. Foobar2000 always knows the exact duration and number of samples compared to the original lossless file. Obviously it's not the case for AC3 though. Is gapless playback the same thing?

https://en.wikipedia.org/wiki/Gapless_playback

Opus doesn't support a 44.1k sample rate, hence the extra samples, but the duration is correct.


Last edited by hello_hello; 9th December 2023 at 15:20.
hello_hello is offline   Reply With Quote
Old 9th December 2023, 15:47   #1958  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Quote:
Originally Posted by hello_hello View Post
I don't know if it's expected, but when I append Test B.mkv to Test A.mkv (from the zip file I linked to) using "add as additional parts", the output is only Test A.mkv and there's no error or warning message.
Read this FAQ entry for understanding what "add as additional part" is for.
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.

Last edited by Mosu; 9th December 2023 at 16:00.
Mosu is offline   Reply With Quote
Old 9th December 2023, 15:59   #1959  |  Link
Mosu
MKVToolNix author
 
Mosu's Avatar
 
Join Date: Sep 2002
Location: Braunschweig, Germany
Posts: 4,273
Quote:
Originally Posted by hello_hello View Post
MP3, Ogg and Opus (can) support gapless playback.
Ogg is a container format, not a codec, unlike MP3 & Opus. Ogg doesn't really have any kind of controls for gaps or no gaps. All it has is a value called "granulepos" for each Ogg page whose interpretation depends on the codec used in the track you're looking at (it's generally described as "the absolute position of this packet in the original uncompressed data stream", but how that's calculated depends on the codec — for some it's simply multiplied by the sampling frequency, for others some bits are a number of frames since the last key frame, for others it's just a fraction of seconds, etc.). With this definition it is possible to precisely locate the end of a stream (and therefore ensure the next stream starts right afterwards). The drawback of only recording the end of the frame is that there's no way to properly encode gaps in such a stream, or offsets at the beginning, without deeply inspecting each frame and maybe eben enocding them. Additionally having different time bases is impossible for most codecs.

For Opus you're correct, in as that it has a pre-roll/pre-skip header fields for specifying the exact start & discard padding packet fields for specifying non-full last frames, thereby specifying the exact end. It's a very good format, not just for that but for its compression properties, too, of course. mkvmerge supports all of these fields for Opus.

All that being said, MP4 with iTunes tags is different insofar as there's the container format that already contains precise timestamps, then there's potential codec-inherent values and THEN there's the iTunes tags-based delay on top of those two. These are three layers of timestamp adjustments, and that's not how Ogg, Mp3 or Opus work. Ogg+Opus are two layers, MP3 in an elementary stream is just one level etc. That tags-based level is… interesting, and that's what I meant with "I don't know if there's any other similar mechanism".
__________________
Latest MKVToolNix is v81.0

If I ever ask you to upload something, please use my file server.
Mosu is offline   Reply With Quote
Old 12th December 2023, 05:07   #1960  |  Link
j7n
Registered User
 
j7n's Avatar
 
Join Date: Apr 2006
Posts: 136
Quote:
Originally Posted by hello_hello View Post
MP3 [..] (can) support gapless playback. Foobar2000 always knows the exact duration and number of samples compared to the original lossless file. Obviously it's not the case for AC3 though. Is gapless playback the same thing?
In MP3 the duration of delay and padding are saved in a silent frame, and cut off on playback. Compensating for the delay in a movie is easier than implementing gapless playback because films start and end with silence. Only the starting point needs be offset, and any extra silence at the end doesn't matter. All lossy codecs have a short fade-in, typically around 256 samples. I think Ogg codecs handle it internally.

Should latency compensation be added for other formats, may I suggest it is made opt-in, or an information about the correction is output to the muxing log. The audio stream might already be in perfect sync because X samples were deleted from the start, it was made using the --no-delay parameter in Qaac, or the audio was extracted from another container where sync was corrected using unknown means.
j7n is offline   Reply With Quote
Reply

Tags
matroska

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 23:19.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.