diff --git a/workflow/video.py b/workflow/video.py index e154602..410751d 100644 --- a/workflow/video.py +++ b/workflow/video.py @@ -53,6 +53,17 @@ def get_encode_process_use_nvenc(orig_filename: str, subtitles: list[str], new_f def get_encode_process_use_intel(orig_filename: str, subtitles: list[str], new_filename: str): print("[+]Use Intel QSV Acceleration") + if platform.system().lower() == "windows": + encode_process = subprocess.Popen([ + FFMPEG_EXEC, *_common_ffmpeg_setting(), + "-hwaccel", "qsv", "-i", orig_filename, "-vf", + ",".join("subtitles=%s" % i for i in subtitles), + "-c:v", "h264_qsv", "-rc:v", "vbr", + *_common_ffmpeg_params(), + # "-t", "10", + new_filename + ], stdout=subprocess.PIPE) + return encode_process encode_process = subprocess.Popen([ FFMPEG_EXEC, *_common_ffmpeg_setting(), "-init_hw_device", "qsv=hw", "-filter_hw_device", "hw",