π Video Concat
Stitch two video files with ffmpeg β vertical, horizontal, or back-to-back
- STRING
There are two kinds of "concat" in the video world: appending clip A then clip B into one longer video, and stacking them side-by-side or top-and-bottom into a comparison frame. ACE_VideoConcat does both, plus a horizontal stack, all by shelling out to ffmpeg. It's the "before/after reel" node - the thing you reach for when you want one side-by-side video of your source and your result.
It's part of π
Ace Nodes (hay86/ComfyUI_AceNodes), a one-author grab-bag. And it's one of the more opinionated nodes in the pack, because it's built around specific assumptions you should know about.
How it works
You hand it two video paths (strings - wire them from ACE_VideoLoad, which is why that node exists) and pick:
method-verticalstacks clip 2 below clip 1;horizontalputs them side by side;appendplays them back-to-back as one continuous video.audio- whose audio to keep:video1orvideo2. (Forappend, audio is always mixed from both.)seam_size- the width (vertical stack) or height (horizontal stack) that each clip is scaled to before stacking. Default 1024. Both clips get resized to match, which is also how mismatched resolutions get reconciled.
The node builds an ffmpeg filter_complex command, runs it with os.system, and outputs the path to the result in ComfyUI's temp folder. Encode is hardcoded: libx264 video, aac audio, 25 fps.
The sharp edges - read these before you run it
- It calls
/usr/bin/ffmpeg- hardcoded. If you're on Windows, or your ffmpeg lives elsewhere, this fails outright. The stack branches (vertical/horizontal) also shell out toffprobeandawkto cap the output at the shorter clip's duration. This is very much a "Linux box with standard installs" node. - You need ffmpeg installed. ComfyUI ships without it by default;
apt install ffmpeg(or your platform equivalent) is a prerequisite. - No error handling. It prints the command and runs it via
os.system; if ffmpeg fails, you get a temp path pointing at a file that was never created. Check the console log for the actual ffmpeg error. - The output is a
STRINGpath - feed it toACE_VideoPreviewto play it, or grab the file fromComfyUI/temp.
Installing
ComfyUI Manager β search ComfyUI_AceNodes, or:
cd ComfyUI/custom_nodes
git clone https://github.com/hay86/ComfyUI_AceNodes
Then restart. The pack's requirements.txt drags in the usual heavy list, but this node needs nothing beyond a working ffmpeg/ffprobe on PATH.
Should you use it?
For the exact job of "make a comparison video from two existing files," it's fine on Linux. But if you want to process video - frames in, frames out, encode options, GPU encoding - it's the wrong layer entirely, and VideoHelperSuite or a dedicated video-tools pack will serve you better. The hardcoded /usr/bin/ffmpeg is the tell: this is a convenience wrapper, not a general video tool. Keep expectations at that level and it'll do what it says.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| video1 | STRING | β | |
| video2 | STRING | β | |
| method | COMBO | vertical | 3 options: vertical, horizontal, append |
| audio | COMBO | video1 | 2 options: video1, video2 |
| seam_size | INT | 10241β2048 | β |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | β |