ComfyUI Node
LC SDXL AnyPaint 🩹
Inpaint and outpaint for any SDXL checkpoint (SDXL, Pony, Illustrious, your finetunes), painted by xinsir's ControlNet Union ProMax in repaint mode, optionally with Fooocus's inpaint patch. The kept pixels are put back after every step and a border is blended. Your picture outside the mask comes back unchanged. No LoRA needed. Describe what goes in the mask in a short prompt. Outpaint: wire LC Outpaint's or Rotate + Pad's control_image and control_mask in.
LC SDXL AnyPaint 🩹
- model
- clip
- vae
- image
- mask
- image
- mask
◄prompt►
◄negative►
◄controloff►
◄control_strength1.00►
◄fooocus_inpaintoff►
◄seed0►
◄steps25►
◄cfg5.0►
◄sampler_namedpmpp_2m►
◄schedulerkarras►
◄crop_to_masktrue►
◄padding128►
◄inpaint_resolution1024►
◄boundary_px32►
◄compositekeep original►
CategoryLC MaskMaker/inpaint
Inputs (20)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | Any SDXL checkpoint. The inpaint patch is added for this node only. | |
| clip | CLIP | The checkpoint's CLIP. | |
| vae | VAE | — | |
| image | IMAGE | — | |
| mask | MASK | White = paint, black = keep. Optional: no mask with LC Outpaint's canvas uses its mask. Wire LC Outpaint's control_image as the image and control_mask as the mask to outpaint. | |
| prompt | STRING | Describe what goes in the mask, short: "a red bucket full of fish on the pier". To remove something, describe what should be there instead ("empty wooden planks"). Empty works too: it fills from the picture around the mask. | |
| negative | STRING | What you don't want. SDXL uses a real negative prompt. | |
| control | COMBO | off | xinsir's ControlNet Union SDXL ProMax (models/controlnet), used in repaint mode: it holds edges, light and perspective to your picture. off = Fooocus inpaint only. |
| control_strength | FLOAT | 1.000–2 | How strongly the ControlNet holds the painting to your picture. Lower = more freedom inside the mask. |
| fooocus_inpaint | COMBO | off | Optional. lllyasviel's Fooocus inpaint patch (models/inpaint, with fooocus_inpaint_head.pth next to it). Blends best and matches the colours around it, but rebuilds what was there more than it adds new things. Good for outpaint and fills. With the ControlNet on too, drop control_strength to about 0.5 (Pony / Illustrious turn to noise at 1). Needs Acly's comfyui-inpaint-nodes. |
| seed | INT | 00–18446744073709550000 | — |
| steps | INT | 251–100 | 25 - 30 for a normal SDXL checkpoint, fewer for Lightning / DMD ones (then cfg 1 - 2). |
| cfg | FLOAT | 5.00–30 | SDXL cfg. 4 - 6 for most checkpoints. |
| sampler_name | COMBO | dpmpp_2m | 44 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +38 |
| scheduler | COMBO | karras | 9 options: simple, sgm_uniform, karras, exponential, ddim_uniform, beta, +3 |
| crop_to_mask | BOOLEAN | true | On: a small mask is redrawn in its own crop, scaled up to inpaint_resolution (more detail). Off: the whole picture at inpaint_resolution. |
| padding | INT | 1280–2048 | Context around the mask when cropping (px). More = the model sees more of the scene. |
| inpaint_resolution | INT | 1024256–2048 | Size of the redraw (as an area: 1024 = about 1 MP). AusBoss found above about 1.6 MP Krea 2 starts to crease limbs and darken skies. |
| boundary_px | INT | 320–128 | Border around the mask the model redraws to blend the seam (in redraw pixels). 32 = the reference. |
| composite | COMBO | keep original | keep original = only the painted area (soft edge, colour fixed) is pasted back: everything else is exactly your picture. raw = the model's whole redraw of the crop. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | Your picture with the masked area painted. |
| mask | MASK | Where it was pasted back (soft edge). |