mirror of
https://github.com/s0md3v/roop.git
synced 2025-12-06 18:08:29 +00:00
Update utils.py
Updated the frame extraction command, with all the colorspace information needed to keep the colors of the original mp4 without changing colorspaces and/or producing gamma shifts
This commit is contained in:
parent
70108223f9
commit
1f774cf917
@ -49,7 +49,7 @@ def create_video(video_name, fps, output_dir):
|
||||
def extract_frames(input_path, output_dir):
|
||||
hwaccel_option = '-hwaccel cuda' if roop.globals.gpu_vendor == 'nvidia' else ''
|
||||
input_path, output_dir = path(input_path), path(output_dir)
|
||||
run_ffmpeg(f' {hwaccel_option} -i "{input_path}" "{output_dir}{sep}%04d.png"')
|
||||
run_ffmpeg(f' {hwaccel_option} -i "{input_path}" pix_fmt rgb24 -sws_flags +accurate_rnd+full_chroma_int -colorspace 1 -color_primaries 1 -color_trc 1 "{output_dir}{sep}%04d.png"')
|
||||
|
||||
|
||||
def add_audio(output_dir, target_path, video, keep_frames, output_file):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user