Nodes/ComfyUI_Eclipse/Preview Video
ComfyUI Node

Preview Video

The Loop-Safe Video Preview That Refreshes Every Iteration

By r-vage·Created 10 months ago·Updated a day ago· 31
Preview Video
  • images
  • audio
  • images
fps16

What it is

Video generation has a preview problem that still images don't. You want to see the clip while you're iterating, but ComfyUI's video preview nodes have a nasty habit of caching - the browser keeps showing you the previous clip while your GPU grinds out the next one, so you're judging stale results. Preview Video is built specifically to dodge that, and it's designed for use inside loops, which is where the caching bug bites hardest.

Feed it a batch of frames, it encodes a temporary mp4, plays it in the node, and passes your frames through the other side. Same deal as a Preview Image, but for video.

How it works

The backend encodes the image batch (with an optional audio track muxed in) to an mp4 in ComfyUI's temp folder using PyAV - the same encoder stack ComfyUI ships for its own video support. The important design choice is in the filename: it includes a per-execution timestamp, so the browser's <video> element always fetches a fresh URL. That's the fix for the cached-preview problem that plagues video combine nodes inside loops - no stale clip, every iteration shows what this iteration actually made.

The other deliberate choice is the pass-through. The node's images output returns the frames it was given, and the whole point is how you use it in a loop: wire that output into the loop's next-iteration carry (the docs' example is easy-forLoopEnd). That forces the node to execute on every iteration - it can't be skipped as "unchanged" - and gives you a refreshing preview each pass. This is the loop-aware video preview, and that framing is the reason to reach for it over a plain save.

The inputs that matter

  • images (required) - the batch of frames to preview as video.
  • fps (required) - playback rate of the preview, default 16, range 1–120. This is the preview's fps, not necessarily your final output fps.
  • audio (optional) - an audio track to mux into the preview, if your workflow has one.

Output:

  • images - the frames passed through as a list.

When you'd use it

Inside a video iteration loop, wired into the carry so the preview refreshes per pass. Also useful outside loops any time the standard video preview goes stale and you want a guaranteed-fresh look - which, if you've spent any time with video nodes in ComfyUI, you know happens more often than it should.

Installing it

It's part of ComfyUI_Eclipse:

cd ComfyUI/custom_nodes
git clone https://github.com/r-vage/ComfyUI_Eclipse
pip install -r ComfyUI_Eclipse/requirements.txt

then restart, or install through Manager (search "Eclipse"). Two install notes specific to this node: it needs PyAV (av) - ComfyUI ships it as part of its own video support, but if you run a stripped-down environment and see an ImportError: av, pip install av into the same Python that runs ComfyUI. And remember the pack's v4.0.0 history (formerly RvTools_v2) if old workflows won't load - use the bundled migration tool.

Common issues

If the preview looks juddery or the timing is off, check the fps widget against what your frames actually represent - a 16-fps preview of 24-fps source plays slow on purpose. If you don't see the refresh you expected in a loop, make sure you actually wired the images output into the loop carry; that's the wiring that forces per-iteration execution, and without it the node can be skipped as cached. And keep the temp-folder rule in mind: previews are scratch, so save the real file with Save Video when you've got a keeper.

Category🌒 Eclipse/ Video

Inputs (3)

NameTypeDefaultDescription
imagesIMAGEBatch of frames to preview as a video.
fpsFLOAT161–120Frames per second of the preview video.
audiooptAUDIOOptional audio track to mux into the preview.

Outputs (1)

NameTypeDescription
imagesIMAGE