ComfyUI Node
CV Flow To Color
Debug helper: renders a per-pixel ANGLE field as the standard color wheel (angle = hue, magnitude = brightness) - the proper way to look at gradient directions, optical flow or any other vector field; a plain grayscale render of angles lies at the 0/360 wrap-around. Feed it cv2_cartToPolar's two outputs. Without a magnitude, every pixel renders at full brightness.
CV Flow To Color
- angle
- magnitude
- nparray
◄angle_unitradians (0-2*pi, cartToPolar default)►
◄max_magnitude0.00►
Categoryimage/CV/features
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| angle | NPARRAY | HxW per-pixel angles (cv2_cartToPolar output). | |
| angle_unit | COMBO | radians (0-2*pi, cartToPolar default) | Set to degrees when cartToPolar ran with angleInDegrees=true. |
| max_magnitude | FLOAT | 0.000–1000000000 | Magnitude mapped to full brightness; larger values clip. 0 = auto (the field's own maximum) - set it explicitly to compare renders across images on the same scale. |
| magnitudeopt | NPARRAY | HxW per-pixel magnitudes; scales brightness so weak vectors fade out. Must match the angle shape. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| nparray | NPARRAY | BGR uint8 rendering: HUE is the angle (0 deg / east at hue 0, then round the wheel) and BRIGHTNESS is the magnitude. Direction is carried by hue alone, which is the axis a colour-blind reader loses - read this as a picture of where the motion changes, and take the angle itself off the numbers ('Inspect CV Data') rather than off the colour. |