| image | COMFY_MATCHTYPE_V3 | | The picture to bend and paste. The output comes back in 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. |
| points_from | NPARRAY | | Nx2 control points in 'image' PIXEL coordinates - where each point currently is. |
| points_to | NPARRAY | | Nx2 target positions in 'background' PIXEL coordinates, row-aligned with points_from - where the same-numbered point must land. 'CV Annotate Correspondences' with a background connected outputs exactly this pair. |
| model | COMBO | thin plate spline | Which map is fitted through the correspondences. 'thin plate spline' BENDS the image so every 'from' point lands exactly on its 'to' point (3+ pairs, non-rigid - faces, cloth, anything a matrix cannot express). 'homography' is the 8-dof planar perspective map (4+ pairs; straight lines stay straight - posters, screens, documents). 'affine' is 6-dof (3+ pairs: rotation, scale, shear, translation, parallel lines stay parallel), 'similarity' 4-dof (2+ pairs: rotation, uniform scale, translation, shape preserved), 'translation' a pure shift (1+ pair). Fewer pairs than the model needs is not an error - nothing is warped and 'found' comes out false. |
| regularization | FLOAT | 00–1000000 | Smoothing of the SPLINE (ignored by the other models). 0 interpolates the control points EXACTLY and follows noisy correspondences faithfully; raising it trades exactness for a gentler, more rigid warp - the knob to turn when the result folds or ripples. IMAGE-SCALE DEPENDENT: cv2 adds this to the diagonal of a kernel matrix whose other entries are d^2*log(d^2) in PIXELS SQUARED, so useful values are large - on a few-hundred-pixel image 100 buys 0.1 px of give and ~1e4 is the first setting you can see. Scale it with the SQUARE of the image size. |
| backgroundopt | NPARRAY,IMAGE | | The image pasted INTO: points_to lives in its coordinates and the output is its size. Left unconnected, the image is warped within its own canvas over black, which is the plain warp. 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. |
| content_maskopt | NPARRAY,MASK | | Which part of 'image' is real content: white is pasted, black is not, and the mask travels through the same warp so the edge stays exact. Unconnected means all of it. A mask of a different size is resized, never rejected. 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. |
| background_paintableopt | NPARRAY,MASK | | Where on 'background' the paste is allowed to land - white is paintable. This is how something in the background occludes the pasted image. Unconnected means everywhere. 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. |