ComfyUI Node

UV Save Video

The export node that actually speaks ffmpeg for you

By GeekatplayStudio·Created 5 months ago·Updated 5 months ago· 0
UV Save Video
  • images
  • saved_path
output_pathoutput.mp4
profile
fps24.00
quality_mode
overwritetrue
audio_mode
pix_fmt
color_range
colorspace
audio_path
advanced_quality_args

UV_SaveVideo is the workhorse of this pack - the node that turns a batch of frames into a real, properly encoded video file through actual ffmpeg. Most ComfyUI video exports are either opaque (a "save video" node that hides everything) or deeply fiddly (hand-typed ffmpeg flags in a string input). This one sits in the middle: a dropdown of sane encoder profiles plus a few knobs you'll actually want, and no command line in sight unless you ask for one.

Mechanically it's straightforward and a little old-school: the node writes your frames out as a temporary PNG sequence, then runs ffmpeg to encode that sequence using the selected profile - container, video codec, pixel format, and quality args all come from a table per profile. That temp-sequence detour is why it's slower than it feels like it should be, but it's also why the codec support is what it is; this is ffmpeg doing the encoding, not some Python-only approximation.

The profile dropdown is the heart of it: youtube_h264, hevc_hq, av1_web, vp9_webm, prores_422hq_master, prores_4444_alpha, dnxhr_hq_master, dnxhr_hqx_master. These are the same keys UV_CodecPreset emits, and the profiles bake in sensible quality defaults - h264 at CRF 18, HEVC at 10-bit CRF 20, AV1 at CRF 28. For most people the answer is "youtube_h264" and it's a good answer.

The inputs beyond images, output_path (default output.mp4) and fps (default 24) are where it gets interesting:

  • quality_mode - preset or advanced. In advanced mode, advanced_quality_args replaces the profile's quality flags entirely (it's a space-separated string, so -crf 22 -preset fast becomes the flags). The codec and container stay profile-driven; only the quality args swap. That's the escape hatch when you know exactly what you want.
  • audio_mode - none or mux. mux requires an audio_path (wire UV_LoadVideo's audio_ref in) and attaches it during encode, trimming to the shorter of video and audio.
  • pix_fmt - auto uses the profile default (yuv420p for h264, 10-bit for HEVC/ProRes). yuva444p10le is the alpha option.
  • color_range (tv/pc) and colorspace (bt709/bt2020nc/smpte170m) - the color-science knobs. Set them when you know the delivery spec; leave auto otherwise, because wrong values produce colors that look fine in your player and wrong on everyone else's.

Where people get burned:

  • output.mp4 lands in ComfyUI's root, not output/. Relative paths resolve against wherever you launched ComfyUI. Default output.mp4 ends up in the ComfyUI install folder. Use output/clip.mp4 or an absolute path.
  • Codec availability. libsvtav1, libx265, prores_ks, dnxhd aren't in every ffmpeg build. The pack resolves ffmpeg from PATH first, then imageio-ffmpeg, and probes codecs at import - but the real test is the export. "FFmpeg export failed" with an encoder-not-found message means your binary needs upgrading.
  • Audio mux needs a real file. audio_mode: mux with an empty audio_path raises a clear error, which is by design.

Install

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

Restart ComfyUI. No models to download; imageio, imageio-ffmpeg, numpy, torch are the whole dependency list. The saved_path output returns the path you gave it, so you can log it or pass it on.

CategoryUniversalVideoIO

Inputs (12)

NameTypeDefaultDescription
imagesIMAGE
output_pathSTRINGoutput.mp4
profileCOMBO8 options: av1_web, dnxhr_hq_master, dnxhr_hqx_master, hevc_hq, prores_422hq_master, prores_4444_alpha, +2
fpsFLOAT24.001–240
quality_modeCOMBO2 options: preset, advanced
overwriteBOOLEANtrue
audio_modeCOMBO2 options: none, mux
pix_fmtCOMBO5 options: auto, yuv420p, yuv420p10le, yuv422p10le, yuva444p10le
color_rangeCOMBO3 options: auto, tv, pc
colorspaceCOMBO4 options: auto, bt709, bt2020nc, smpte170m
audio_pathoptSTRING
advanced_quality_argsoptSTRING

Outputs (1)

NameTypeDescription
saved_pathSTRING