Nodes/ComfyUI/Conditioning (Set Area)
ComfyUI Node Runs on cloud

Conditioning (Set Area)

Regional prompting for two characters that keep bleeding into each other

By Comfy-Org·Created 4 years ago·Updated about 12 hours ago· 130,493
Conditioning (Set Area)
  • conditioning
  • CONDITIONING
width64
height64
x0
y0
strength1.00

Prompt adherence is global. A single prompt describing two characters will smear their attributes together - the girl on the left ends up with a hint of the girl on the right's hair, and no amount of prompt engineering fixes it. Regional prompting is the standing answer, and ConditioningSetArea is the classic ComfyUI way to do it: you tell one prompt to apply only to a rectangle of the canvas, another prompt to apply to a different rectangle, then combine them and let the sampler keep the attributes where they belong.

How it works

The node takes a conditioning and attaches a target area to it: width, height, x, y define a rectangle (x, y is the top-left corner), and strength (default 1, up to 10) scales how much that prompt's influence is pushed inside the region versus bleeding out. Under the hood the node writes {"area": (h//8, w//8, y//8, x//8), "strength": strength} into the conditioning's metadata - the division by 8 is because the coordinates are in latent space, which is 8x smaller than pixels. The sampler then applies that prompt only within its region (with a soft falloff governed by strength).

The node itself doesn't combine anything - it annotates one conditioning. The regional workflow is: encode a prompt, run it through this node with its rectangle, do the same for the second prompt, then merge the two annotated conditionings with ConditioningCombine and feed the result to the sampler. One node per region, combine at the end.

The inputs that matter

  • width / height / x / y - the rectangle, in pixels, stepping in multiples of 8. You're really specifying latent coordinates, so the snapping is to keep the maths clean. Keep regions inside the canvas; overlapping regions get combined influence.
  • strength - the bleed control. Lower it and the region's prompt leaks outward; higher and it dominates inward. When two regions fight over a shared boundary, this is the dial that settles the war.

The output is the same CONDITIONING type, ready for Combine.

How you get it

Core node, no install - "Conditioning (Set Area)" in the default menu, right next to the Percentage variant. There's also a mask-based cousin (ConditioningSetMask) for irregular regions.

Where people get burned

Forgetting Combine. Each SetArea produces an annotated conditioning; wire them into the sampler directly and only the last one wins. They must be merged first. Seams and overlaps. Rectangles are rigid, and at the boundaries you'll sometimes see a visible transition - that's the strength dial's job to soften, and it's why the mask-based variant exists for organic regions. The modern asterisk. The 2026-generation models with LLM encoders are better at keeping subjects apart in the first place, so regional prompting is needed less often than it used to be - but when it's needed, it's still needed. The Percentage variant (ConditioningSetAreaPercentage) is worth knowing too: same idea, but the rectangle is specified as fractions of the canvas, which survives resolution changes better than hard pixel coordinates.

Categorymodel/conditioning/transform

Inputs (6)

NameTypeDefaultDescription
conditioningCONDITIONING
widthINT6464–16384
heightINT6464–16384
xINT00–16384
yINT00–16384
strengthFLOAT1.000–10

Outputs (1)

NameTypeDescription
CONDITIONINGCONDITIONING