From 045d6b87588a2316b8e2025849d0bd2a4afe78ad Mon Sep 17 00:00:00 2001 From: j Date: Mon, 2 Oct 2017 13:41:24 +0200 Subject: [PATCH] duration --- render_mlt.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/render_mlt.py b/render_mlt.py index d182675..ee05b39 100755 --- a/render_mlt.py +++ b/render_mlt.py @@ -185,6 +185,8 @@ for name, plist in ( else: add_audio_clip(plist, clip['path'], frames) +duration = sum(clip['duration'] for clip in data['clips']) + save_xml(vocals, target_vocals) video.set("hide", 1) save_xml(video, target_source) @@ -234,7 +236,6 @@ subprocess.call([ 'qmelt', target_audio, '-consumer', 'avformat:' + target_audio_wav, ]) audiomix = mlt.Playlist() -duration = sum(clip['duration'] for clip in data['clips']) add_audio_clip(audiomix, target_audio_wav, int(duration * fps)) # mix video + audio