浏览代码

Change FFMPEG arguments order

Micrufun 2 年之前
父节点
当前提交
7394143de1
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 3 3
      files/tasks.py

+ 3 - 3
files/tasks.py

@@ -871,13 +871,13 @@ def video_with_voices(user_or_session, friendly_token=None, voicesUid=None):
         cmd.append("{0}:a".format(voiceCounter))
         voiceCounter += 1
 
+    # https://stackoverflow.com/a/14528482/3405291
+    cmd.append("-filter_complex")
+    cmd.append("amix=inputs={0}:duration=longest:dropout_transition=0".format(len(voices)))
     cmd.append("-c:v")
     cmd.append("copy")
     cmd.append("-c:a")
     cmd.append("aac")
-    # https://stackoverflow.com/a/14528482/3405291
-    cmd.append("-filter_complex")
-    cmd.append("amix=inputs={0}:duration=longest:dropout_transition=0".format(len(voices)))
     cmd.append(result_file_name)
 
     ret = run_command(cmd, cwd=cwd)