Regional IPAdapter Encoded By Color Mask (Inspire)
Regional image prompting from a color map and pre-encoded embeds
- color_mask
- embeds
- neg_embeds
- REGIONAL_IPADAPTER
- MASK
This node combines two conveniences from the Inspire regional family. It's the "encoded" flavor (you feed it a pre-computed IP-Adapter embedding instead of a reference image) and the "color mask" flavor (you define the region by a color in a color map instead of drawing a MASK). If you've already encoded your reference and you're laying out regions with a painted color map, this is the one node that speaks both.
The point of regional IP-Adapter at all: IP-Adapter is image prompting - hand it a reference and it steers the image toward that reference's look via its own cross-attention path, leaving your text prompt intact. Doing that per region is how you say "this half of the image looks like reference A, that half looks like reference B." The color-mask input makes region layout painless: paint a color map where each region is a flat color, and pick the color that marks this region's area.
One era caveat the knowledge base is firm on: IP-Adapter is an SD1.5 / SDXL tool. There's no Flux-generation adapter in this form, so regional image prompting like this lives on those older architectures.
How it works
You supply a color map image and the specific color that marks the region, plus pre-encoded EMBEDS for the reference. The node turns that color region into a mask internally, binds the embeds as an IP-Adapter conditioning scoped to it, and emits a REGIONAL_IPADAPTER handle. Chain one per region, combine them, and apply the combined result to your model - that final apply is done by Apply Regional IPAdapters (Inspire).
Using pre-encoded embeds (rather than an image) buys you control: you can blend several reference images into one embed before applying it, reuse one expensive encode across regions, or feed embeds you've averaged or weighted that never existed as a single picture.
The inputs and outputs that matter
color_mask(IMAGE) - the color map that defines your regions.mask_color(STRING, default#FFFFFF) - the color marking this region. Hex like#FF0000or a decimal value.embeds(EMBEDS) - the pre-encoded reference. This is the whole reason to pick the "Encoded" node.weight(default 0.7) - reference strength in-region. KB guidance: ~0.6–0.8 for style; drop it if the prompt stops mattering.start_at/end_at(0–1) - the denoising window the adapter runs over. End early to preserve detail; running IP-Adapter across all steps softens output.neg_embeds(optional EMBEDS) - a negative reference embedding.
Outputs: REGIONAL_IPADAPTER (combine with other regions, then apply) and MASK (the mask derived from your color - handy for previewing that you selected the right region).
How to install it
ComfyUI Manager: search ComfyUI Inspire Pack, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/ltdrdata/ComfyUI-Inspire-Pack
then restart. It's a Dr.Lt.Data pack (ComfyUI-Manager, Impact Pack).
Common issues & troubleshooting
weight_type shows "IPAdapterPlus is not installed." That literal string in the dropdown is the tell: the dependency is missing. These nodes ride on cubiq's ComfyUI_IPAdapter_plus - install it via Manager and restart, and the real weight-type options appear. Without it the node is inert.
Nothing happens in the region / wrong area. The mask_color must exactly match a color present in your color_mask. Anti-aliased edges and JPEG artifacts create in-between colors that won't match - use flat, hard-edged colors and a lossless format (PNG). Check the MASK output to confirm you actually selected the region you meant.
Where do the embeds come from? An IP-Adapter encoder node (cubiq's pack has one). If you don't have an EMBEDS source and just want to point at an image, use Regional IPAdapter By Color Mask instead - it takes an image and encodes it for you.
Embed / model mismatch. Embeds are tied to a specific CLIP Vision encoder, which is tied to your base model. Embeds encoded for SD1.5 won't behave on SDXL. Keep encoder, adapter, and base on one architecture.
Regions bleed into each other. Standard regional behavior. Shorten the window with end_at so the hard region only fixes composition and the base blends the rest - the KB's consistent advice against the collaged, seamy look.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| color_mask | IMAGE | — | |
| mask_color | STRING | #FFFFFF | — |
| embeds | EMBEDS | — | |
| weight | FLOAT | 0.70-1–3 | — |
| weight_type | COMBO | 1 options: IPAdapterPlus is not installed | |
| start_at | FLOAT | 0.0000–1 | — |
| end_at | FLOAT | 1.0000–1 | — |
| unfold_batch | BOOLEAN | false | — |
| neg_embedsopt | EMBEDS | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| REGIONAL_IPADAPTER | REGIONAL_IPADAPTER | — |
| MASK | MASK | — |