Seb*_*bMa 47
您可以尝试FFmpeg(很棒的工具!):
$ ffmpeg -i file.srt file.vtt
Run Code Online (Sandbox Code Playgroud)
RAS*_*ASG 16
我用来转换字幕的非常简单有效的oneliner:
for i in *.ass ; do ffmpeg -i "$i" "$i.srt" ; done
Run Code Online (Sandbox Code Playgroud)
只需更改ass
并srt
根据您的需要。
字幕 perl 瑞士军刀(滚动到页面末尾)。
在这里您可以找到更多选项。
此外,mplayer/mencoder有一些 dumpXXXsub 选项,这可能会起作用。我从来没有试过这个,但是读那个人,它应该有效。例子:
-dumpmpsub (MPlayer only)
Convert the given subtitle (specified with the -sub option) to MPlayer's subtitle format, MPsub. Creates a dump.mpsub file in the current directory.
Run Code Online (Sandbox Code Playgroud)
小智 6
开源程序Subtitle Edit有一个命令行转换器,可用于 Windows 和 Linux。
语法:
SubtitleEdit /convert "pattern" "name-of-format-without-spaces"
示例 1:
SubtitleEdit /convert sub1.srt sami
结果:将 sub1.srt 转换为 sub1.sub 为 SAMI 格式示例 2:
SubtitleEdit /convert *.srt adobeencore
结果:将所有 .srt 文件转换为 Adobe Encore 格式
对于Linux,命令行需要稍长一些……
语法:
mono SubtitleEdit.exe /convert "pattern" "name-of-format-without-spaces"
...但可以很容易地包装在脚本中。