ComfyUI Node
cv2.inpaint
Raw wrapper of cv2.inpaint(src, inpaintMask, inpaintRadius, flags). Parameters marked '?' are optional; blank means OpenCV default. See the OpenCV documentation for details.
cv2.inpaint
- src
- inpaintMask
- result
◄inpaintRadius0.0000►
◄flagsINPAINT_TELEA►
Categoryimage/CV/low-level/cv2 I
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| src | COMFY_MATCHTYPE_V3 | Input 8-bit, 16-bit unsigned or 32-bit float 1-channel or 8-bit 3-channel image. The image output(s) echo this input's format. Accepts a ComfyUI IMAGE/MASK directly (frame 0 of a batch) or an NPARRAY. Arithmetic ops (add, multiply, etc.) process the full IMAGE batch when both inputs have the same batch size. | |
| inpaintMask | NPARRAY,IMAGE,MASK | Inpainting mask, 8-bit 1-channel image. Non-zero pixels indicate the area that needs to be inpainted. Accepts a ComfyUI IMAGE/MASK directly (frame 0 of a batch) or an NPARRAY. Arithmetic ops (add, multiply, etc.) process the full IMAGE batch when both inputs have the same batch size. | |
| inpaintRadius | FLOAT | 0.0000-1e+38–1e+38 | Radius of a circular neighborhood of each point inpainted that is considered by the algorithm. |
| flags | COMBO | INPAINT_TELEA | Inpainting method that could be cv::INPAINT_NS or cv::INPAINT_TELEA The function reconstructs the selected image area from the pixel near the area boundary. The function may be used to remove dust and scratches from a scanned photo, or to remove undesirable objects from still images or video. See for more details. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| result | COMFY_MATCHTYPE_V3 | Echoes the 'src' input's format: an IMAGE link comes back as IMAGE, MASK as MASK, NPARRAY stays NPARRAY. |