Save Video (WepeNerd)
One file, sound inside, no FFmpeg scavenger hunt
- images
- audio
- mask
- filepath
Why you'd want a different video saver
The usual ComfyUI video combine node wants an FFmpeg executable on your PATH, drops a first-frame PNG beside every clip so the workflow has somewhere to live, and - with audio - writes two files, the video and a -audio remux. It works, and it's three artifacts per clip plus an install step that breaks differently on every machine.
This node does the same job in-process with PyAV, the library ComfyUI already uses for its video nodes. One IMAGE batch plus optional audio and mask in, one file out, workflow embedded inside it. Your output/ folder stops filling with companion PNGs.
What it actually writes
Eight formats, and the differences matter more than a dropdown implies:
- MP4 · H.264 is the default and the right answer for anything you'll post. 8-bit 4:2:0, AAC audio.
- MP4 · H.265 10-bit and MP4 · AV1 10-bit for smaller files. H.265 is tagged
hvc1so QuickTime and Safari play it. - WebM · VP9 is the practical transparency pick - alpha plays in Chrome and Firefox.
- MOV · ProRes is 422 HQ, or 4444 with transparency - for the editor, not for sharing.
- MKV · FFV1 16-bit lossless is the archive: 16-bit RGB from the float frames.
- GIF and WebP loop forever, no audio, for embeds.
The list is filtered at load time by what your PyAV build can encode, so an AV1 option that never appears means a missing encoder in your av install, not a broken node.
The inputs that matter
- images - the frames; a fourth channel is read as transparency.
- fps - 23.976, 29.97 and 59.94 are written as the exact NTSC rates (24000/1001 and friends) rather than rounded decimals, which decides whether a clip stays in sync with a soundtrack.
- filename_prefix - numbered
name_00001_.mp4like ComfyUI's savers; subfolders and%date:…%tokens work. - format and crf - lower crf is better and bigger, default 19. 0 is genuinely lossless for AV1, VP9 and WebP; H.264/H.265 clamp at 51; ProRes, FFV1 and GIF ignore it entirely.
Set once and forget: pingpong writes frames forwards then backwards without repeating either end frame, for a seamless loop. save_output off writes a temp preview instead of a file in output/. Optional audio is muxed into the same file and trimmed to the video's length. Optional mask is transparency where 1 means transparent, as Load Image and Load Video output it - one mask for the clip or one per frame, with Load Video's 64×64 placeholder for opaque sources correctly ignored.
The output is one thing: filepath, a plain STRING with the full path. Feed it into filename builders or ignore it - it runs regardless, since this is an output node.
Under the hood, briefly
Frames convert on the batch's own device in ~64 MB blocks, so only what's being written leaves the GPU, and 10/16-bit formats get 16-bit RGB so gradients don't band. YUV is tagged BT.709, so the file matches your preview instead of looking slightly pink. Odd sizes get an edge row or column repeated, with a warning. The prompt and workflow go into MP4/MOV/MKV/WebM tags and WebP EXIF, so dropping the finished video on the canvas reloads the graph - same caveat as a PNG: anyone who re-encodes your file strips it.
Installing it
ComfyUI Manager, search ComfyUI-WepeNerd, or:
cd ComfyUI/custom_nodes
git clone https://github.com/WepeNerd/ComfyUI-WepeNerd
python -m pip install -r ComfyUI-WepeNerd/requirements.txt
Restart after. requirements.txt is Pillow, numpy, SciPy and av>=17.0.0; PyAV wheels ship their own FFmpeg libraries, which is why there's no executable to install and no gifski. No models, no GPU wheels - and ComfyUI's own video nodes use PyAV too, so you probably have it.
Common issues
Nothing from the pack shows up. Every node module is imported from one __init__.py, so one missing dependency takes the whole pack down - you lose the resolution tools and Speedpaint along with this node. Read the startup traceback, then reinstall requirements with the Python that actually runs ComfyUI.
You wired a mask and got an opaque file. H.264 has no alpha; the node logs a warning and saves opaque rather than failing. Pick WebM, ProRes or FFV1.
The file won't preview. ProRes, FFV1 and 10-bit MP4 are fine on disk and useless in a browser player. Use your editor, or H.264.
Audio is early or late. Audio is muxed from the start of the clip and only trimmed to its length - never shifted. Trimmed the head with a slicer upstream? Then the sound won't line up; trim at load time instead, where the clip's audio is selected with its frames.
The clip ends weirdly. Upstream, not the saver. Models have frame-count grids - 4n+1 for Wan and Hunyuan, 8n+1 for LTX - and the Wan VAE's ~4x temporal compression means 111 frames in can decode as 109 out. Land on a legal count before saving, then let pingpong handle the loop seam.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | Frames to save. A fourth channel is used as transparency. | |
| fps | FLOAT | 24.000.01–240 | Frame rate. 23.976, 29.97 and 59.94 are saved as the exact NTSC rates (24000/1001...). |
| filename_prefix | STRING | video | Name prefix; may include subfolders and %date:...% tokens. |
| format | COMBO | MP4 · H.264 | MP4 plays everywhere. WebM, ProRes, FFV1, GIF and WebP keep transparency. FFV1 is a lossless 16-bit archive; ProRes is for editing software. |
| crf | INT | 190–63 | Quality: lower is better and larger. 0 is lossless for AV1, VP9 and WebP. H.264/H.265 stop at 51. Ignored by ProRes, FFV1 and GIF. |
| pingpong | BOOLEAN | false | Play forwards then backwards, for a seamless loop. |
| save_output | BOOLEAN | true | Save to the output folder. Off writes a temporary preview only. |
| audioopt | AUDIO | Muxed into the same file and trimmed to the video's length. Not supported by GIF and WebP. | |
| maskopt | MASK | Transparency, 1 = transparent (as output by Load Image and Load Video). One mask for all frames or one per frame. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| filepath | STRING | Full path of the saved file. |