Houdini 22.0 Nodes Geometry nodes

Neighbor Search CL geometry node

Finds neighboring points using OpenCL.

Since 22.0

The Neighbor Search CL SOP is a low-level SOP that finds neighboring points for the input points using OpenCL. It is usually much faster than the pcfind VEX function. An example of its use can be found in the OpenCL path of the Grain Source SOP.

Note

This SOP only supports uniform radius points, and requires several point attributes present to work correctly.

Type

Name

Description

float

pscale

The size of the points. This value must be the same for all input points.

integer

phase

Indicates whether a point should be included in the search, based on the Source Phase and Destination Phase parameters.

integer

isgrain

Used in place of the phase attribute if phase is not present.

integer array

neighbors

This SOP fills this array with the neighboring particles within the Radius Scale.

Additional per-particle point attributes can be used to control this node’s behavior:

Type

Name

Description

string

name

Used when Ignore Neighbors with Same Name or Piece is turned on. If present, this attribute is used before piece.

integer

piece

Used when Ignore Neighbors with Same Name or Piece is turned on.

Parameters

Radius Scale

The size of the neighborhood around each point to search for neighbors. This value scales the particles pscale attribute.

Source Phase

Only points with this phase attribute values will be considered neighbors. The default value of -1 will consider all points.

Destination Phase

Only fill in the neighbors array for points with this phase attribute value. The default value of -1 will find neighbors for all points.

Ignore Neighbors with Same Name or Piece

If turned on, neighbors with the same name or piece attribute value as the current point will be ignored. If both attributes exist, name is used.

Leave on GPU

If turned on, the neighbors array is filled but not transferred back to the CPU. This means CPU code (such as VEX) and the Geometry Spreadsheet cannot access the values, but OpenCL code can use the array without the cost of copying large neighbor arrays back to the CPU.

Note

In SOPs, GPU buffers are cleared outside compiled blocks. If Leave on GPU is turned on, any OpenCL SOP that uses the data must be in the same compiled SOP where the array was created.

See also

Geometry nodes