From 4ed2ea5a00aa1293135923b513925c46b963be93 Mon Sep 17 00:00:00 2001 From: Radek Czajka Date: Fri, 22 May 2020 14:19:51 +0200 Subject: [PATCH] Faster video cutting. --- src/youtube/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/youtube/utils.py b/src/youtube/utils.py index 3dbab09..6c95c69 100644 --- a/src/youtube/utils.py +++ b/src/youtube/utils.py @@ -52,7 +52,7 @@ def video_from_image(img_path, duration, fps=25, cache=True): def cut_video(video_path, duration): return process_to_file( - ['ffmpeg', '-y', '-i', video_path, '-t', str(duration)], + ['ffmpeg', '-y', '-i', video_path, '-t', str(duration), '-c', 'copy'], 'cut-', '.mkv' ) -- 2.20.1