From 0bebbdfb37d6b6abab0b8738532d704010bf191e Mon Sep 17 00:00:00 2001 From: yolain Date: Fri, 13 Feb 2026 21:49:19 +0800 Subject: [PATCH] Fix bug for new comfyui version --- SaveVideoRGBA.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/SaveVideoRGBA.py b/SaveVideoRGBA.py index 958adbd..b0b1513 100644 --- a/SaveVideoRGBA.py +++ b/SaveVideoRGBA.py @@ -60,14 +60,17 @@ class SaveVideoRGBA(io.ComfyNode): resized_images.append(resized_tensor.unsqueeze(0)) images = torch.cat(resized_images, dim=0) - - video = RGBAVideoFromComponents( - VideoComponents( - images=images, - audio=audio, - frame_rate=Fraction(fps), + try: + from comfy_api.latest import InputImpl, Types + video = InputImpl.VideoFromComponents(Types.VideoComponents(images=images, audio=audio, frame_rate=Fraction(fps))) + except Exception as e: + video = RGBAVideoFromComponents( + VideoComponents( + images=images, + audio=audio, + frame_rate=Fraction(fps), + ) ) - ) width, height = video.get_dimensions() results = list()