MVEx Differential Diffusion (Soft)
Differential Diffusion for Video, Without the Razor-Sharp Mask Edges
- model
- MODEL
ComfyUI's stock Differential Diffusion node is great at one thing and quietly bad at another. It takes a grayscale denoise mask and schedules it so the mask grows as sampling proceeds - but every intermediate mask it produces is a hard binary threshold, razor-sharp at the edge no matter how feathered your input was. On stills that's usually fine. On video, hard mask edges that step between frames are a flicker and seam generator, and your beautifully feathered inpaint mask loses its softness at every single step.
MVEx Differential Diffusion (Soft) is a drop-in replacement that thresholds with a soft ramp instead, so each per-step mask keeps a soft edge whose width tracks the blur already present in your input mask. Heavily feathered masks stay feathered at every step; sharp masks stay sharp. It's purely per-pixel with no spatial blur, which is exactly what you want for temporal stability on video.
How it works
Mechanically it's the stock node with a different threshold function. The schedule is identical - a threshold that starts at 1 on the first step and falls to 0 on the last, so more of the mask denoises as sampling proceeds. The difference is what happens at the boundary: stock DD does mask >= threshold (hard binary), this node ramps through a band of width softness in mask-value space, clamped to 0–1.
That band width maps to a spatial soft edge whose width scales with the gradient of your mask - heavily feathered input has a shallow gradient, so the ramp spans more pixels, and the soft edge stays wide. Per-pixel and blur-free means no temporal smearing frame to frame. The endpoints are preserved to match the stock schedule: mask==1 pixels denoise fully from the first step, mask==0 pixels never do.
The inputs that matter
- model - the model to patch, wired into your sampler's model input.
- softness (default 0.2) - the width of the soft threshold band. 0 exactly reproduces the stock node's hard threshold, which is a nice escape hatch. 1 degenerates to plain static mask blending (no schedule at all). Default 0.2 is a gentle soft ramp; start there and raise it if seams still show.
- strength (default 1.0, optional) - blend between the thresholded per-step mask (1) and the raw input mask (0), same as the stock node's strength.
Output is a patched model - same as the stock node, so it drops into any existing Differential Diffusion wiring. If you have a graph already using the core node, swap it in and the schedule carries over.
Why you'd reach for it
The case is video inpainting with feathered masks - the README's framing is that this variant exists for exactly that. If your per-frame inpaint is showing seams at the mask boundary that a soft blur in the mask never fixed, this is likely the missing piece: the stock node was eating your feathering on every step and this one doesn't. It's also worth trying on any workflow where the stock node produces a visible banding or "stepped" edge. If you're on stills with sharp masks, honestly, the stock node is fine - but softness 0 makes this a zero-risk replacement anyway.
Install
Part of MaskVidExperiments, the pack from drozbay (RES4LYF maintainer, Wan VACE tooling). ComfyUI Manager, search "MaskVidExperiments", or:
cd ComfyUI/custom_nodes
git clone https://github.com/drozbay/MaskVidExperiments
restart. No model files, no extra dependencies - this one doesn't even need the video pipeline, it's a standalone model patch. Needs ComfyUI v0.15.0+.
One troubleshooting note: softness near 1 removes the schedule's time dependence, so if your result looks like the mask was applied statically rather than grown over sampling, your softness is too high. And like any Differential Diffusion variant, it only does something if a denoise mask is actually attached to the latent at sampling - wire it with Set Latent Noise Mask (or this pack's Mask To Latent Space feeding it) or it's just a model clone doing nothing.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| softness | FLOAT | 0.200–1 | Width of the soft threshold band in mask-value units. 0 is the stock hard threshold; larger values keep wider soft edges on each per-step mask (spatial width scales with the input mask's blur). 1 disables the schedule entirely and blends by the mask as-is. |
| strengthopt | FLOAT | 1.000–1 | Blend between the thresholded per-step mask (1) and the raw input mask (0), as in the stock node. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |