From ecadd61ef86575ba5b4f042f34f6c8a0b48216dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kjist=C3=B3f?= Date: Sun, 15 Jan 2017 21:23:36 +0100 Subject: [PATCH] implemented looping of video stream & muxing to final output --- coub-dl.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/coub-dl.py b/coub-dl.py index 62e404b..e19fc17 100644 --- a/coub-dl.py +++ b/coub-dl.py @@ -62,3 +62,8 @@ with open('list.txt', 'w') as f: for i in range(timesLoop): print("file '{}'".format(shorterFile), file=f) +call(('/usr/bin/env', 'ffmpeg', '-f', 'concat', '-i', 'list.txt', '-c', 'copy', 'loopedvideo.mp4')) +call(('/usr/bin/env', 'ffmpeg', '-i', 'loopedvideo.mp4', + '-i', FILES[Stream.AUDIO], + '-map', '0', '-map', '1', + '-c', 'copy', 'output.mp4'))