Nodes Browser

ComfyDeploy: How seamless-clone-comfyui works in ComfyUI?

What is seamless-clone-comfyui?

Seamless Clone for ComfyUI

How to install it in ComfyDeploy?

Head over to the machine page

  1. Click on the "Create a new machine" button
  2. Select the Edit build steps
  3. Add a new step -> Custom Node
  4. Search for seamless-clone-comfyui and select it
  5. Close the build step dialig and then click on the "Save" button to rebuild the machine

ComfyUI Seamless Clone Node

Publish to Comfy registry

Seamless Clone Example

A custom node for ComfyUI that implements OpenCV's seamless cloning functionality, allowing you to blend images naturally using Poisson blending techniques.

Features

  • Seamless image blending using OpenCV's

  • Three blending modes:

    • NORMAL_CLONE: Standard seamless

    • MIXED_CLONE: Mixed seamless cloning that preserves gradients

    • MONOCHROME_TRANSFER: Monochrome transfer mode

  • Automatic or manual center point selection

  • Compatible with ComfyUI's image processing pipeline

Installation

  1. Navigate to your ComfyUI custom nodes directory:
cd ComfyUI/custom_nodes/
  1. Clone this repository:
git clone https://github.com/Aksaz/comfyui-seamless-clone
  1. Install the required dependencies:
pip install -r requirements.txt

Usage

The node accepts the following inputs:

  • source_image: The image to be cloned (foreground)

  • destination_image: The target image (background)

  • mask_image: A binary mask defining the region to be cloned

  • blend_mode: Choose between NORMAL_CLONE, MIXED_CLONE, or MONOCHROME_TRANSFER

  • center_x: X-coordinate of the clone center (optional)

  • center_y: Y-coordinate of the clone center (optional)

Output:

  • cloned_image: The resulting seamlessly blended image

Requirements

  • numpy==2.2.0
  • opencv_python==4.10.0.84
  • torch==2.5.1

License

See the LICENSE file for details.

Credits

This node utilizes OpenCV's seamless cloning implementation based on the paper "Seamless Image Cloning and Editing" by Patrick Pérez, Michel Gangnet, and Andrew Blake.