remove useless hwupload_cuda

This commit is contained in:
root 2022-04-22 07:11:25 +08:00
parent add2957cc2
commit d5bb50c583

View File

@ -18,7 +18,7 @@ def encode_video_with_subtitles(orig_filename: str, subtitles: list[str], new_fi
encode_process = subprocess.Popen([ encode_process = subprocess.Popen([
FFMPEG_EXEC, "-hide_banner", "-progress", "-", "-v", "0", "-y", FFMPEG_EXEC, "-hide_banner", "-progress", "-", "-v", "0", "-y",
"-i", orig_filename, "-vf", "-i", orig_filename, "-vf",
",".join("subtitles=%s" % i for i in subtitles) + (",hwupload_cuda" if FFMPEG_USE_GPU and not FFMPEG_USE_INTEL_GPU else ""), ",".join("subtitles=%s" % i for i in subtitles),
"-c:a", "copy", "-c:v", "h264" if not FFMPEG_USE_GPU else ("h264_qsv" if FFMPEG_USE_INTEL_GPU else "h264_nvenc"), "-c:a", "copy", "-c:v", "h264" if not FFMPEG_USE_GPU else ("h264_qsv" if FFMPEG_USE_INTEL_GPU else "h264_nvenc"),
"-f", "mp4", "-preset:v", "fast", "-profile:v", "high", "-level", "4.1", "-f", "mp4", "-preset:v", "fast", "-profile:v", "high", "-level", "4.1",
"-b:v", VIDEO_BITRATE, "-rc:v", "vbr", *(["-tune:v", "hq"] if FFMPEG_USE_GPU and not FFMPEG_USE_INTEL_GPU else []), "-b:v", VIDEO_BITRATE, "-rc:v", "vbr", *(["-tune:v", "hq"] if FFMPEG_USE_GPU and not FFMPEG_USE_INTEL_GPU else []),