Nodes/opencv-comfyui/OpenCV convertPointsToHomogeneous_1
ComfyUI Node

OpenCV convertPointsToHomogeneous_1

ConvertPointsToHomogeneous_1 — same node, one suffix over

By geroldmeisinger·Created about a year ago·Updated about a year ago· 35
OpenCV convertPointsToHomogeneous_1
  • src
  • dst
  • nparray

You found the _1 suffix and you're wondering what changed. Nothing. convertPointsToHomogeneous_1 is the second overload of cv2.convertPointsToHomogeneous from OpenCV's type definitions - the UMat-typed variant of a signature that also exists for MatLike - and this pack auto-generated both into identical nodes. The real content lives in convertPointsToHomogeneous_0; consider this the pointer page.

The whole behavior in one breath: src (NPARRAY) in, NPARRAY out, with a 1 appended as the last coordinate of every point - (x, y)(x, y, 1). Optional dst is an OpenCV out-parameter you should leave empty. It's the forward step that makes Euclidean points usable in homogeneous/projective math, and it pairs with convertPointsFromHomogeneous_0 to round-trip the other way.

Is it useful to you? Only if your workflow does homography/projection math, and even then it's a convenience wrapper around a slice operation. The pack author (who announced opencv-comfyui on r/comfyui with the honest tagline that these nodes are "auto-generated from their type definitions" and complex to use) recommends these wrappers for small, quick image operations - blur, edges, thresholds - not full geometry pipelines. This node is on the geometry side.

Install, standard for the pack

cd ComfyUI/custom_nodes
git clone https://github.com/geroldmeisinger/opencv-comfyui
pip install opencv-python-contrib

Or ComfyUI Manager → search opencv-comfyui → restart. No downloads beyond the OpenCV dependency.

One reminder that applies across all these nodes: they operate on numpy NPARRAYs, so Comfy images need Image2Nparray (batch size 1 only) to get in, and outputs that are point arrays aren't displayable - Nparrays2Image will throw the 'NoneType' object has no attribute 'shape' error from the README if you treat one as a picture.

_0 or _1? Genuinely your call - they're the same node. Grab whichever's already in the workflow you're reading and don't look back.

Categoryimage/OpenCV

Inputs (2)

NameTypeDefaultDescription
srcNPARRAY
dstoptNPARRAY

Outputs (1)

NameTypeDescription
nparrayNPARRAY