Update preview.py

This commit is contained in:
h0lyf0ck 2024-12-07 14:53:41 +01:00 committed by GitHub
parent ec12f679bf
commit 3d4c69f175
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -225,10 +225,10 @@ def update_preview_frame_slider() -> gradio.Slider:
def process_preview_frame(reference_faces : FaceSet, source_face : Face, source_audio_frame : AudioFrame, target_vision_frame : VisionFrame) -> VisionFrame:
target_vision_frame = resize_frame_resolution(target_vision_frame, (1024, 1024))
source_vision_frame = target_vision_frame.copy()
if analyse_frame(target_vision_frame):
return cv2.GaussianBlur(target_vision_frame, (99, 99), 0)
target_vision_frame = resize_frame_resolution(target_vision_frame, (1024, 1024))
source_vision_frame = target_vision_frame.copy()
if analyse_frame(target_vision_frame):
return False
for processor_module in get_processors_modules(state_manager.get_item('processors')):
logger.disable()