所以这就是交易......我正在尝试使用 mkvextract.exe 通过批处理脚本从 mkv 容器中提取特定轨道,我能想到的唯一方法是通过批处理提取部分轨道并手动提取其余轨道(这个成本我很多时间)。实际上是否有更好、更智能、更快的方法来实现这一目标?我需要提取的只是:
文件夹“subs”中具有原始名称的所有字幕轨道
“atchmnts”文件夹中具有原始名称的所有附件(更新:我管理了这个)
和文件夹“xml”中具有XML格式原始名称的章节轨道(更新:完成xDeathwing .tho,它不是原始请求的原始文件名,在这种情况下它可以,因为每个 mkv 总是有 1 个 xml 文件)
到目前为止,我对此表示赞同:
@echo off
mkvextract.exe attachments "video.mkv" 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
mkvextract.exe chapters "video.mkv" --redirect-output chapters.xml
mkvextract.exe --ui-language en tracks "video.mkv" 0:"%CD%\%~sub.ass" (Update: this one
actually working, but I can extract only one track instead of all of them and also its not
keeping original filename as given by mkvextract - "video_track4_eng.ass" - and also
I assume this will work only if track ID/language was defined during muxing process)
md "atchmnts"
md "subs"
md "xml"
move "*.ttf" "atchmnts\"
move "*.otf" "atchmnts\"
move "*.png" "atchmnts\"
move "*.srt" "subs\"
move "*.ass" "subs\"
move "*.sub" "subs\"
move "*.xml" "xml\"
pause
exit
我知道https://mkvtoolnix.download/doc/mkvextract.html,但无法真正找到我要查找的内容并修复我的脚本。