Save Image Advanced (AVIF)
AVIF with a speed dial, alpha support, and DPI — the codec's full toolset
- images
- masks
Save Image Advanced (AVIF) is the full version of the pack's modern-codec saver. The simple Save Image (AVIF) locks quality at 85 and speed at 6 with no alpha; this one hands you both dials, adds mask-based transparency, DPI, and a copy-to-input-folder option. It's the node to reach for when AVIF is your target format and you care about the file, not just the pixels.
Two dials define this node:
- Quality (0–100, default 80) - AVIF quality behaves like JPG's, but the codec is efficient enough that 80 already looks strong. Bumping to 90+ buys diminishing returns at real file-size cost.
- Speed (0–10, default 6) - the AVIF encoding speed slider, and the one people don't expect. 0 is slowest and best compression, 10 is fastest. This is the pragmatic knob: if your batch is taking forever, push speed toward 8–10 and eat a little file size; if size is the whole point and you can wait, drop it low. The default 6 is a sensible middle.
Join Alpha Channel + Masks is the feature that makes AVIF actually interesting versus JPG: AVIF carries transparency, so you can export a cut-out subject directly in the modern format. Invert Alpha flips the mask for inverse pipelines. DPI (1–600, default 300) gets written into the file, mostly relevant if the AVIFs are headed toward a print-adjacent workflow. Save to Input Folder mirrors the file for reuse.
Standard terminal-save shape beyond that: Images input, optional Masks, Filename Prefix with token support (%date:yyyy-MM-dd%, %hour%, %minute%, %width%, %height%). No outputs.
The honest cost-benefit
AVIF remains a pick-your-audience format. For web deliverables it's excellent - this is the node you'd use for a batch of optimized site images. For compatibility-sensitive output (print shops, clients, social sites, older tools) it's still a gamble, and JPG/PNG/TIFF from this same pack are the safe plays. And encoding is CPU-heavy at any speed setting: a large batch at speed 6 will make your fans work. If you're generating lots of frames, the speed dial is the difference between a graph that finishes and one you abandon for dinner.
Install
Part of ComfyUI-Image-Process:
cd ComfyUI/custom_nodes
git clone https://github.com/wakaura-asaho/comfyui-image-process
pip install -r comfyui-image-process/requirements.txt
then restart, or find the pack in ComfyUI Manager. Requires a Pillow build with libavif - the pack pins Pillow ≥ 12.1, which has it, and the README's --upgrade-strategy only-if-needed advice exists to stop pip from downgrading you into a version that can't write AVIF. Deps: numpy, scipy, opencv, scikit-image beyond that; no models. Modern ComfyUI (frontend ≥ 1.37, base ≥ 0.12) required, like every node here.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | The images to be saved. | |
| join_alpha | BOOLEAN | false | Clip the image with the provided mask. |
| invert_alpha | BOOLEAN | false | Whether to invert the alpha channel before saving. |
| filename_prefix | STRING | ComfyUI | The prefix for the file to save. This may include formatting information such as %date:yyyy-MM-dd% or %Empty Latent Image.width% to include values from nodes. |
| dpi | INT | 3001–600 | The DPI to use when saving images. |
| quality | INT | 800–100 | The quality of the saved images (0-100). |
| speed | INT | 60–10 | AVIF encoding speed (0-10). 0 is slowest/best, 10 is fastest. |
| save_to_input_folder | BOOLEAN | false | Whether to sync the image to the input folder. |
| masksopt | MASK | Optional alpha channel masks to clip the saved images. If provided, these masks will be applied to the corresponding images before saving. |
Outputs (0)
No outputs