Nodes/zhangp365/ComfyUI-utils-nodes/Image Transition Right to Left
ComfyUI Node

Image Transition Right to Left

Image Transition Right to Left

By zhangp365·Created 2 years ago·Updated 5 months ago· 135
Image Transition Right to Left
  • before_image
  • after_image
  • images
  • duration
  • fps
duration5.0
fps24
bounce_backfalse
start_end_pause_percent0.09
middle_pause_percent0.15
start_end_position_percent0.06
transition_line_width8

This node turns two still images into a short video clip of a slide transition - the before image slides off to the left while the after image slides in from the right, the kind of wipe you've seen in every before/after comparison video ever made. It's one of five directional siblings in this pack (left-to-right, top-to-bottom, bottom-to-top, and a plain fade also exist per the README), and this is the one that moves right-to-left specifically.

The obvious use case is showing off an edit: run an image through something like this pack's own FalNanoBananaNode or any other image-editing step, then feed the original and the edited result into this node to generate a clean transition clip instead of a static side-by-side. It's also a reasonable way to stitch together a slideshow-style output from a batch of still generations without reaching for a full video-editing node graph.

The inputs that matter: before_image and after_image are the two stills, required. duration (seconds, default 5) and fps (default 24) set the length and frame rate of the output clip - these two together determine your total frame count, so a 5-second clip at 24fps is 120 frames of output. The rest are tuning knobs for how the transition itself feels: start_end_pause_percent (default 0.09) and middle_pause_percent (default 0.15) hold the image still at the beginning/end and at the midpoint of the transition rather than moving continuously the whole time - useful if you want a beat where the viewer can actually look at each image before the wipe starts. start_end_position_percent (default 0.06) controls how far off-frame the slide starts and ends. bounce_back (off by default) reverses the transition back to the start instead of ending on the after-image - handy for a looping comparison clip rather than a one-way reveal. transition_line_width (default 8) draws a visible dividing line at the wipe edge as it moves across the frame, a nice touch for making the transition point obvious rather than relying purely on motion to read as "before vs. after."

Outputs: images (the generated frame sequence), plus duration and fps passed through as outputs - convenient for wiring straight into a video-save node that needs those values without you having to retype them.

Install: search "ComfyUI-utils-nodes" in ComfyUI Manager, or:

cd ComfyUI/custom_nodes
git clone https://github.com/zhangp365/ComfyUI-utils-nodes

Restart afterward. This node is pure image/frame generation - no models, no API keys, nothing external to configure.

What to watch for:

  • before_image and after_image should be the same resolution going in. A mismatch will get resized or produce an odd-looking transition, since the slide effect assumes both frames occupy the same canvas.
  • Longer duration at higher fps means more output frames, which means more memory and a longer encode when you actually save the result as a video - if you're chaining this into a video-writing node downstream, keep an eye on total frame count rather than just the duration number in isolation.
  • The pause and position percentages all operate as fractions of the total transition, not fixed seconds - bump duration up and a start_end_pause_percent of 0.09 holds still for a proportionally longer real-world time. Tune duration first, then dial in the pause feel, not the other way around.
Categoryutils

Inputs (9)

NameTypeDefaultDescription
before_imageIMAGE
after_imageIMAGE
durationFLOAT5.00.1–60
fpsFLOAT241–120
bounce_backoptBOOLEANfalse
start_end_pause_percentoptFLOAT0.090–0.5
middle_pause_percentoptFLOAT0.150–0.5
start_end_position_percentoptFLOAT0.060–0.5
transition_line_widthoptINT81–20

Outputs (3)

NameTypeDescription
imagesIMAGE
durationFLOAT
fpsFLOAT