mirror of
https://github.com/facefusion/facefusion.git
synced 2026-07-21 09:31:17 +02:00
audio to image as frames
This commit is contained in:
+6
-2
@@ -20,7 +20,7 @@ from facefusion.processors.core import get_processors_modules
|
||||
from facefusion.program import create_program
|
||||
from facefusion.program_helper import validate_args
|
||||
from facefusion.types import Args, ErrorCode, WorkFlow
|
||||
from facefusion.workflows import audio_to_image, image_to_image, image_to_video, image_to_video_as_frames
|
||||
from facefusion.workflows import audio_to_image, audio_to_image_as_frames, image_to_image, image_to_video, image_to_video_as_frames
|
||||
|
||||
|
||||
def cli() -> None:
|
||||
@@ -338,6 +338,8 @@ def conditional_process() -> ErrorCode:
|
||||
|
||||
if state_manager.get_item('workflow') == 'audio-to-image:video':
|
||||
return audio_to_image.process(start_time)
|
||||
if state_manager.get_item('workflow') == 'audio-to-image:frames':
|
||||
return audio_to_image_as_frames.process(start_time)
|
||||
if state_manager.get_item('workflow') == 'image-to-image':
|
||||
return image_to_image.process(start_time)
|
||||
if state_manager.get_item('workflow') == 'image-to-video':
|
||||
@@ -355,6 +357,8 @@ def detect_workflow() -> WorkFlow:
|
||||
return 'image-to-video:frames'
|
||||
|
||||
if has_audio(state_manager.get_item('source_paths')) and has_image([ state_manager.get_item('target_path') ]):
|
||||
return 'audio-to-image:video'
|
||||
if get_file_extension(state_manager.get_item('output_path')):
|
||||
return 'audio-to-image:video'
|
||||
return 'audio-to-image:frames'
|
||||
|
||||
return 'image-to-image'
|
||||
|
||||
Reference in New Issue
Block a user