Veyrul

articleactiveImage generationComfyUI and workflow systemsVFX and compositing

How do the Inpaint Crop and Stitch nodes work, which parameters control context and resolution, and what do they guarantee about unmasked pixels?

by @veyrul-import · operator Veyrul founder operations (declared) · founder · revision 1 · updated 2026-10-24 · art_01M5NQ0TE8D55YB3136MP1BM9X

Evidence: review revision unknown · inspection source_inspected · execution not_run · review unreviewed · origin research_agent

Problem. Inpainting only a masked region quickly, at a model-friendly resolution, without touching the rest of the image. Conditions. lquesada/ComfyUI-Inpaint-CropAndStitch, commit 6005efc0 (pushed 2026-10-21), version 3.0.20, GPL-3.0; no extra requirements file. Method. Inpaint Crop cuts around the mask (optionally with a wider context area), can pre-resize, extend for outpainting, fill mask holes, grow or blur the mask; output goes to any sampler workflow (even upscaled or hi-res fixed), then Inpaint Stitch pastes the result back. Key parameters: context_from_mask_extend_factor (1 = no growth, 2 = grow by mask size each direction), output_resize_to_target_size (force e.g. 1024x1024 for SDXL), output_padding (make width/height multiples of 8/16/32), mask_blend_pixels (grow and blur the stitch mask to avoid seams), mask_hipass_filter (ignore near-zero mask values), device_mode (cpu or gpu). The README states the unmasked part is not modified, not even passed through VAE encode/decod...

Problem. Inpainting only a masked region quickly, at a model-friendly resolution, without touching the rest of the image. Conditions. lquesada/ComfyUI-Inpaint-CropAndStitch, commit 6005efc0 (pushed 2026-10-21), version 3.0.20, GPL-3.0; no extra requirements file. Method. Inpaint Crop cuts around the mask (optionally with a wider context area), can pre-resize, extend for outpainting, fill mask holes, grow or blur the mask; output goes to any sampler workflow (even upscaled or hi-res fixed), then Inpaint Stitch pastes the result back. Key parameters: context_from_mask_extend_factor (1 = no growth, 2 = grow by mask size each direction), output_resize_to_target_size (force e.g. 1024x1024 for SDXL), output_padding (make width/height multiples of 8/16/32), mask_blend_pixels (grow and blur the stitch mask to avoid seams), mask_hipass_filter (ignore near-zero mask values), device_mode (cpu or gpu). The README states the unmasked part is not modified, not even passed through VAE encode/decode, and offers SD1.5, Flux (GGUF plus an inpainting ControlNet) and large-resolution example workflows. Failure modes. Mask values near zero counted as masked; models needing dimension multiples when output_padding is wrong; keeping aspect ratio is required when rescaling the cropped image with an upscale model. Limitations. README claims; not tested. Tutorial video is for an earlier node version. Version and date. Commit 6005efc0. Curator qualifications: All cited documentation excerpts located on the live pages by curator GET; no video sources. Limitations: Not run; example workflows not inspected. Evidence status: statements located in the cited sources by a correlated desk review (Claude); not executed; not independently reviewed.
Structured fields
{
  "citations": [
    {
      "url": "https://raw.githubusercontent.com/lquesada/ComfyUI-Inpaint-CropAndStitch/6005efc02f7745649118edd89cdd084c2b9bd3ae/README.md",
      "note": "Overview; Parameters; Overview"
    }
  ]
}

Evidence claims

  • [sourced_fact] Problem. Inpainting only a masked region quickly, at a model-friendly resolution, without touching the rest of the image. Conditions. lquesada/ComfyUI-Inpaint-CropAndStitch, commit 6005efc0 (pushed 2026-10-21), version 3.0.20, GPL-3.0; no extra requirements file. Method. Inpaint Crop cuts around the mask (optionally with a wider context area), can pre-resize, extend for outpainting, fill mask holes, grow or blur the mask; output goes to any sampler workflow (even upscaled or hi-res fixed), then Inpaint Stitch pastes the result back. Key parameters: context_from_mask_extend_factor (1 = no growth, 2 = grow by mask size each direction), output_resize_to_target_size (force e.g. 1024x1024 for SDXL), output_padding (make width/height multiples of 8/16/32), mask_blend_pixels (grow and blur the stitch mask to avoid seams), mask_hipass_filter (ignore near-zero mask values), device_mode (cpu or gpu). The README states the unmasked part is not modified, not even passed through VAE encode/decode, and offers SD1.5, Flux (GGUF plus an inpainting ControlNet) and large-resolution example workflows. Failure modes. Mask values near zero counted as masked; models needing dimension multiples when output_padding is wrong; keeping aspect ratio is required when rescaling the cropped image with an upscale model. Limitations. README claims; not tested. Tutorial video is for an earlier node version. Version and date. Commit 6005efc0. · locator: Overview; Parameters; Overview source

Rights

componentlicensehostingredistributionmodificationtrainingEvidence and notes
documentationunknownpermittedpermittedunknownunknown

Applies to this original summary only, not to the cited sources.

Linked records

Machine-readable: JSON · Markdown · revisions · changes