Nodes/ComfyUI-Apt_Preset/View_video_compare
ComfyUI Node

View_video_compare

Frame-locked A/B wipe for videos, right in your workflow

By cardenluo·Created 2 years ago·Updated a day ago· 331
View_video_compare
  • video_a
  • video_b
    direction
    split_position50
    autoplayfalse
    looptrue

    Comparing two videos frame-by-frame is the hardest routine QC task in video generation, because temporal differences - a wobble, a flicker, a motion that drifts - are nearly invisible when you watch two clips one after another. Your brain smooths them over. View_video_compare solves it the way video editors have for decades: it plays both clips at the same time in the same viewer, locked to the same timeline, with a wipe divider you drag across to reveal which pixels differ. It's the video sibling of the pack's View_image_compare, and if you're iterating on motion quality it's the more useful half of the pair.

    What it compares

    Both inputs are native VIDEO objects - the decoded video type ComfyUI's video tooling produces, not a batch of image tensors. video_a and video_b. Anything that outputs VIDEO works: this pack's own samplers and merges, the graded output of AD_Video_color_grad, or any other pack's video results. The controls:

    • direction - 左右 / 上下 for the wipe.
    • split_position - where the divider sits (0–100), draggable in the widget and saved with the workflow.
    • autoplay - start both playing as soon as they load, instead of waiting for you to hit play.
    • loop - restart both on end. Defaults to on, which is right: you usually want to keep scrubbing the same short comparison instead of babysitting a play button.

    The widget is a small media player with opinions. One play button drives both streams, the scrubber seeks them together, and the divider drag works while playing - so you can watch a clip and sweep the wipe back and forth to catch exactly the frames where motion diverges. Timecode runs underneath so you can note "it breaks at 00:04" and go fix precisely that moment. There's a mute toggle and a fullscreen button for when you need to actually see detail.

    Three things to know

    Three practical details worth knowing before you wire it up:

    1. Audio is not symmetric. Video B is always muted; the A stream is the one with audible audio (muted by default until you unmute). So put the version whose soundtrack you want to judge - or the one whose audio is newer and untested - in video_a.
    2. The frames stay in sync, not the encodings. Both videos run under one timeline and seek together, but if the two clips have different frame counts or durations (a 5-second refine vs. a 6-second first pass), the shorter one simply runs out early. Comparing same-length generations is the intended use.
    3. It's a preview node - nothing passes through it. No outputs, OUTPUT_NODE only, so it belongs at the end of a branch you're actively judging, not in the middle of a data path.

    How it works

    How it works on the backend is worth a mention because it explains the occasional delay: each input video gets written to an MP4 (H.264) in ComfyUI's temp folder - unless it's already an on-disk .mp4/.webm sitting in your input/output/temp directories, in which case the node serves it directly without re-encoding. Either way the browser gets two file URLs and plays them stacked, B clipped with CSS to the wipe position. Total runtime cost is modest - it's encode-and-serve, not re-sampling.

    Installing it

    Install is the pack install:

    git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git
    

    into custom_nodes, run install.bat, restart. It's a clean dependency-free node beyond that, and its real prerequisite is just being inside an ecosystem where VIDEO objects flow around - the MiniMax H3 staged workflows this pack pushes are the natural home (compare your first pass against the refined merge to check the detail pass didn't wreck motion), but any VIDEO input works.

    If you've been doing video A/B by exporting two clips and tabbing between player windows, this will feel like a small revelation. The wipe is the entire product, and it's exactly what you needed.

    CategoryApt_Preset/PreView

    Inputs (6)

    NameTypeDefaultDescription
    video_aVIDEO
    video_bVIDEO
    directionCOMBO2 options: 左右, 上下
    split_positionFLOAT500–100
    autoplayBOOLEANfalse
    loopBOOLEANtrue

    Outputs (0)

    No outputs