From 6547271dfba0d47ff68eba7d9ab5d24f3c5bce3a Mon Sep 17 00:00:00 2001 From: Csaba Henk Date: Mon, 1 Jan 2018 19:20:42 +0100 Subject: [PATCH] enhance chunk naming Instead of chunk index (0 to n-1) we apply "chunk index (1 to n)-of-n". --- ffmpeg-split.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ffmpeg-split.py b/ffmpeg-split.py index 6b8ae9e..e4f8b76 100644 --- a/ffmpeg-split.py +++ b/ffmpeg-split.py @@ -106,7 +106,8 @@ def split_by_seconds(filename, split_length, vcodec="copy", acodec="copy", split_start = split_length * n split_args += ["-ss", str(split_start), "-t", str(split_length), - filebase + "-" + str(n) + "." + fileext] + filebase + "-" + str(n+1) + "-of-" + \ + str(split_count) + "." + fileext] print "About to run: "+" ".join(split_cmd+split_args) subprocess.check_output(split_cmd+split_args)