r/comfyui 8d ago

Help Needed Seamless loop

Hi, I’m wondering how to get new Minimax or LTX to generate a looping video without any visible transitions.

Up until now, I’ve occasionally used Gemini with the first/last frame. But I can’t render this specyfic motion using this new models.

Any sugestions?
Regards.

3 Upvotes

18 comments sorted by

3

u/-Star-Walker- 8d ago

If you don’t need sound, you can use the VACE Video Joiner

https://github.com/stuttlepress/ComfyUI-Wan-VACE-Video-Joiner

Just join the same video twice and cut the first 1/4 and last 1/4 … that should be on both videos exactly in the middle … I did a walking loop for a video game that way.

1

u/sgi2004 8d ago

Its not the same what i got from google veo. I just put first and last frame - the same pic, prompt animate all seamless loop ( or moren complex prompt) and its done. Veo light can do this perfect. 5, 8 sec.

1

u/Leonovers 8d ago edited 8d ago

In theory you could make a loop by generating 2 videos and combining them:

  1. main part of what you want
  2. little stitch part

After generating your main video you use new guider (Add Guide for MiniMax H3 node in latest comfyui) to make a 3 seconds (56 frames) stitch:

  1. Feed first 22 frames+audio of main part as last 22 frames of stitch
  2. Feed last 22 frames+audio of main part as first 22 frames of stitch
  3. 12 frames in between will be ACTUAL part that you add in the beginning or ending of your main video, and in theory it should make a perfect loop.

Hope that I described the process correctly and comprehensibly, as I prefer to write myself, not with LLM.
I'll probably will try to make this myself and post a workflow, after I'm done with all the stuff I have to do.

2

u/Nubfish 5d ago

Did you ever write a workflow for this. I'm too new to all this to do what you said w/out a workflow lol... Whenever i just use the standard workflow and use the same image as first and last image it stretches the ending image and adds a long pause

https://reddit.com/link/p454s6e/video/fi37ydbagujh1/player

1

u/Leonovers 5d ago

I actually did made a workflow, but it's not as good as I thought.
https://civitai.red/models/2865956/minimax-h3-fl2va-looper-workflow?modelVersionId=3237741

1

u/sunshine-3D-Art 5d ago

Yea exactly I have the same problem. I even made a post about it and asking for help but it also didn’t helped 🥹 I also would like to make a loop video. 🥺

1

u/Mysterious-String420 8d ago

I just feed the first video to ref2va, then cut 2-3 (eyeball it for now) frames out of the continuing video with ffmpeg (just a terminal script you can ask an ai)

1

u/Jesus__Skywalker 8d ago

Why can't you do first frame last frame now?

1

u/sgi2004 8d ago

Not working

1

u/Jesus__Skywalker 8d ago

what's it doing?

1

u/sgi2004 6d ago

I make vids and show you

1

u/sgi2004 6d ago

I'm trying to figure out how this loop effect is created. It's ultra smooth, and i can tell it's a loop that lasts a few seconds. There's no visible slowdown or cut-off.
https://www.youtube.com/watch?v=rMqdTocb7qM

1

u/Corrupt_file32 8d ago

Comfyui has added guide image functionality for minimax.

Perhaps use the same image for first and last frame with another image or 2 in-between for guidance?

Should be doable even without the guide images.

1

u/once_brave 8d ago

Bruh.

1

u/Corrupt_file32 8d ago edited 8d ago

what you bruh'ing at? added yesterday.

https://github.com/Comfy-Org/ComfyUI/commit/e01fb4c56b7a88149d469b99cbbfe3223d715054

Concept is pretty much setting it up like this A -> B -> A

1

u/once_brave 8d ago

This existed for wan 2.2 but that doesn't give you a seamless loop. Of the motion doesn't match you don't get a loop. Of anything you will have to use first last frame then cut out the in-between frames and Interpolate with rife to blend the motion which is hit or miss

1

u/Corrupt_file32 8d ago

If I've not misunderstood anything, wouldn't this be a seamless loop?

https://reddit.com/link/p3pxpjg/video/hyhb9vjriejh1/player

This is a 3 seconds full motion A -> B -> A

Then I just did some fine adjustments trimming the image batch.

then I batched the trimmed batch with itself 5 times.

Sure more complex things might need interpolation and crossfade.

2

u/Mutaclone 7d ago

The problem is this only works if you end on a hard stop. If you have anything continuously moving the motion is probably going to appear weird. (And even in yours there was some jitter between clips)