Nodes/S42-CutFlow/🎭 S42 CutFlow Background Remover
ComfyUI Node

🎭 S42 CutFlow Background Remover

A ComfyUI node in S42 CutFlow/Expanded with 20 inputs and 4 outputs.

By GeekyGhost·Created 5 months ago·Updated 4 months ago· 3
🎭 S42 CutFlow Background Remover
  • images
  • guidance_mask
  • reference_bg
  • result_rgb
  • result_rgba
  • mask
  • info
methodbirefnet-general
use_gpuyes
processing_resolution1024
mask_blur0.8
mask_dilation1
mask_erosion1
remove_small_objects300
invert_maskno
chroma_threshold0.12
chroma_softness0.08
spill_suppress0.70
luma_modeshadows_highlights
shadow_threshold0.08
highlight_threshold0.92
luma_softness0.10
temporal_smooth0
guidance_strength1.00
CategoryS42 CutFlow/Expanded

Inputs (20)

NameTypeDefaultDescription
imagesIMAGEImage or video batch [B,H,W,C].
methodCOMBObirefnet-generalbirefnet-general = best all-around AI. birefnet-portrait = people. birefnet-massive = highest quality. birefnet-hr = high-res 2048px. birefnet-dynamic = robust across resolutions. birefnet-matting = soft edges (hair, fur). u2net/isnet/silueta = classic AI (rembg). chroma_green/blue/red = screen keying. luma_key = brightness-based.
use_gpuCOMBOyesGPU for AI inference.
processing_resolutionINT1024256–2048AI inference resolution. 1024=standard, 2048=BiRefNet_HR.
mask_blurFLOAT0.80–5Edge blur. 0=sharp, 0.8=smooth.
mask_dilationINT10–10Expand mask N px. Helps with hair.
mask_erosionINT10–10Shrink mask N px. Removes fringe.
remove_small_objectsINT3000–5000Remove noise < N px. Disabled for traditional methods.
invert_maskCOMBOnoSwap foreground/background.
chroma_thresholdFLOAT0.120.01–0.5Chroma key sensitivity (chroma_* only).
chroma_softnessFLOAT0.080.01–0.3Chroma edge softness.
spill_suppressFLOAT0.700–1Color spill suppression.
luma_modeCOMBOshadows_highlightsWhat to KEEP. shadows=keep dark. highlights=keep bright. both=keep midtones.
shadow_thresholdFLOAT0.080–0.5Below = removed. Luma key only.
highlight_thresholdFLOAT0.920.5–1Above = removed. Luma key only.
luma_softnessFLOAT0.100.02–0.3Luma edge softness. Min 0.02 prevents freezes.
temporal_smoothINT00–5Video mask smoothing window. 0=off, 1-5=flicker reduction.
guidance_strengthFLOAT1.000–1How hard the guidance mask gates the output. 0 = guidance ignored. 1.0 = strictly removes everything outside the white mask areas. Recommended: 1.0 for clean isolation.
guidance_maskoptMASKPaint white over the subject you want to KEEP. Leave everything else black. The BG remover will ONLY keep what's inside your white area. How it works: this mask GATES the AI output. White = AI mask passes through (subject kept). Black = forced to zero (guaranteed removed).
reference_bgoptIMAGEClean background plate. Enhances AI with difference info.

Outputs (4)

NameTypeDescription
result_rgbIMAGE
result_rgbaIMAGE
maskMASK
infoSTRING