Houdini 22.0 Nodes Copernicus nodes

Segment by Connectivity Copernicus node

Segment a layer into connected components.

On this page

This node breaks the incoming layer into connected components according to a rule, which you set with the Connectivity parameter.

Note

The id output will vary with resolution changes as the shape of the islands may change the order. Note that the Collapse IDs option will give you “more stable” results, but not completely consistent. Without this option enabled, the IDs will be completely random when you change the resolution.

Parameters

Signature

The layer type that the source accepts.

See Signatures for more information.

Connectivity

The rule that determines whether pixels are connected or unconnected.

Below Threshold

Connect all pixels below the threshold.

Above Threshold

Connect all pixels above the threshold.

At Threshold

Connect pixels to their neighbors if they're on the same side of the threshold.

At Levels

Connect pixels if they're in the same band of values. Each band is the Threshold size.

Threshold

The threshold for connectivity. When Connectivity is At Levels, this is the width of a band of connectivity.

Tip

Click and then click on the layer to set the Threshold.

Offset

When Connectivity is At Levels, this is the global offset to adjust where the bands split.

Collapse IDs

Collapse the generated ID values so they range from zero to the number of segments. While the order is deterministic, it will vary depending on where the first pixel of each region is located, so should not be relied upon for an animated source.

Inputs

source

The layer in which to detect connectivity.

Outputs

id

The ID layer with a unique integer that’s greater than or equal to 0 for each connected region. Regions that don’t match the connectivity region get an ID of -1.

alpha

The mono layer, which is 1 if the pixel met the connectivity rule and 0 if it didn’t.

See also

Copernicus nodes