ComfyUI Node
Remove Background & Resize
A ComfyUI node in image/processing with 8 inputs and 2 outputs.
Remove Background & Resize
- image
- image
- mask
◄tolerance30►
◄foreground_bias0.70►
◄color_clusters8►
◄output_sizeORIGINAL►
◄scaling_methodLANCZOS►
◄dither_handlingtrue►
◄binary_threshold128►
Categoryimage/processing
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| image | IMAGE | Input image tensor from upstream node | |
| tolerance | INT | 300–255 | Colour distance threshold. Higher = more aggressive foreground extraction (0-255). |
| foreground_bias | FLOAT | 0.700–1 | Bias toward keeping pixels as foreground. Higher = more pixels preserved. |
| color_clusters | INT | 82–20 | Number of k-means centres for colour segmentation. |
| output_size | COMBO | ORIGINAL | Resize output to this size. ORIGINAL keeps source dimensions. |
| scaling_method | COMBO | LANCZOS | Interpolation method. LANCZOS = best quality; NEAREST = pixel-perfect for pixel art. |
| dither_handlingopt | BOOLEAN | true | Apply edge erosion to suppress dither artefacts. |
| binary_thresholdopt | INT | 1280–255 | Alpha mask binarisation cutoff (0-255). |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| mask | MASK | — |