WebUI Bridge Inpaint Conditioning
Everything VAE Encode For Inpaint does, in one node
- positive
- negative
- vae
- pixels
- mask
- positive
- negative
- latent
- denoise
- status
Mask-based inpainting in ComfyUI is one of those things that's genuinely simple in concept and annoyingly many nodes in practice. Load the image, load the mask, encode pixels to latent, encode the masked pixels again for the conditioning, set the noise mask, pick a denoise... WebUI Bridge Inpaint Conditioning collapses all of that into one node and hands you the latent, the conditioning and the denoise together.
It's the pack's replacement for the manual VAE Encode For Inpaint dance, and it's the node you'll reach for when a mask needs to actually change a region of an image. It sits comfortably in the "masked inpainting still owns this" camp that the KB defends: bit-identical unmasked pixels and a denoise dial are things instruction-edit models can't offer.
How it works
You feed it pixels (the image), mask, vae, and your existing positive/negative conditioning. It does the standard inpaint setup:
- Resizes the mask to match the image, snapping to 8-pixel alignment.
- Blanks out everything outside the mask in pixel space before encoding - that's the "masked pixels" latent that inpaint models condition on.
- Encodes the full image as the base latent and attaches the resized mask as
noise_mask(whennoise_maskis on), so the sampler only regenerates the masked area. - Tags both conditionings with
concat_latent_imageandconcat_mask- the exact metadata ComfyUI's native inpaint conditioning carries.
The denoise output is chosen from whichever module is driving the inpaint: the SAM/Inpaint config's inpaint_denoise (0.45 default), the ADetailer config's denoise, or the mask module's strength. That's a nice touch - the node figures out what the settings intend and hands you the matching number instead of making you remember it.
If none of those modules are enabled, it still does a plain VAE encode and returns a 1.0 denoise, so the node degrades gracefully in a workflow that forgot to enable anything.
Inputs and outputs
positive,negative- your conditioning.vae- required; the same VAE your decode will use.pixels,mask- the image and its mask.module_config- the settings blob; it picks denoise source from the SAM/ADetailer/mask sections.noise_mask- true by default; turn off to regenerate the whole latent at a different denoise.- Outputs:
positive,negative,latent(feed the KSampler),denoise(feed the KSampler's denoise) andstatus.
How to install
Ships with the ComfyUI-WebUI-Prompt-Bridge pack: Manager → ComfyUI WebUI Prompt Bridge, or clone into custom_nodes and restart. No models of its own - it uses the VAE you already have.
Common issues
The mask-source confusion is the classic stumble. The pack's SAM/Inpaint config stores SAM model and prompt settings, but this node doesn't run SAM - it expects an actual MASK to arrive at its mask input, from a SAM/segmenter node or a mask editor. The feature reference is explicit that it won't guess or auto-create third-party SAM nodes. Second gotcha: don't forget the denoise output exists. If you hardcode your own denoise on the KSampler, the node's settings-driven value is silently ignored, which defeats half the point.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| positive | CONDITIONING | — | |
| negative | CONDITIONING | — | |
| vae | VAE | — | |
| pixels | IMAGE | — | |
| mask | MASK | — | |
| module_config | STRING | — | |
| noise_mask | BOOLEAN | true | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| positive | CONDITIONING | — |
| negative | CONDITIONING | — |
| latent | LATENT | — |
| denoise | FLOAT | — |
| status | STRING | — |