ComfyUI Node
cv2.cornerSubPix
Raw wrapper of cv2.cornerSubPix(image, corners, winSize, zeroZone, criteria). Parameters marked '?' are optional; blank means OpenCV default. See the OpenCV documentation for details.
cv2.cornerSubPix
- image
- corners
- winSize
- zeroZone
- nparray
◄criteria_typemax count or epsilon (whichever first)►
◄criteria_max_count30►
◄criteria_epsilon0.00►
Categoryimage/CV/low-level/cv2 C
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| image | NPARRAY,IMAGE,MASK | Input single-channel, 8-bit or float image. 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. | |
| corners | NPARRAY | Initial coordinates of the input corners and refined coordinates provided for output. A data array (points / matrix), NOT an image - only an NPARRAY link is accepted here. | |
| winSize | CV_TUPLE | 0,0 | Half of the side length of the search window. For example, if winSize=Size(5,5) , then a $(5*2+1) \times (5*2+1) = 11 \times 11$ search window is used. One value with 2 components (w, h) - it travels as a whole, so it cannot arrive half-connected. Wire it from 'CV Tuple' or type the components in place. |
| zeroZone | CV_TUPLE | -1,-1 | Half of the size of the dead region in the middle of the search zone over which the summation in the formula below is not done. It is used sometimes to avoid possible singularities of the autocorrelation matrix. The value of (-1,-1) indicates that there is no such a size. One value with 2 components (w, h) - it travels as a whole, so it cannot arrive half-connected. Wire it from 'CV Tuple' or type the components in place. |
| criteria_type | COMBO | max count or epsilon (whichever first) | When to stop iterating: after max_count iterations, when the change drops below epsilon, or whichever comes first. |
| criteria_max_count | INT | 301–2147483647 | Maximum iterations (ignored when 'epsilon only'). |
| criteria_epsilon | FLOAT | 0.000–1e+38 | Target accuracy / smallest change worth continuing for (ignored when 'max count only'). |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| nparray | NPARRAY | — |