【发布时间】:2017-09-26 05:14:49
【问题描述】:
我需要将 mp4 分割成指定的片段。它们都是不同的持续时间。细分示例:
1 - 0:00:00 to 0:01:11
segment 2 - 0:01:11 to 0:04:24
segment 3 - 0:05:51 to 0:06:30
...
我已经写了一个脚本来逐个提取它们,但是速度很慢。 我猜是因为它浪费了大量时间打开文件、解码和从头开始搜索。
【问题讨论】:
我需要将 mp4 分割成指定的片段。它们都是不同的持续时间。细分示例:
1 - 0:00:00 to 0:01:11
segment 2 - 0:01:11 to 0:04:24
segment 3 - 0:05:51 to 0:06:30
...
我已经写了一个脚本来逐个提取它们,但是速度很慢。 我猜是因为它浪费了大量时间打开文件、解码和从头开始搜索。
【问题讨论】:
ffmpeg 有这个选项
- segment_times times
Specify a list of split points. times contains
a list of comma separated duration specifications,
in increasing order. See also the segment_time option.
【讨论】: