Example Node: Smooth Points

Smooths data in a very simple way by averaging values with neighbors.

Installation

To use this Node, you must enable omni.graph.examples.cpp in the Extension Manager.

Inputs

Name

Type

Description

Default

mesh

bundle

Bundle containing data to be smoothed and neighbor arrays.

nameOfAttributeToSmooth

token

Name of the attribute in ‘mesh’ containing the data to be smoothed

points

nameOfNeighborsInputAttribute

token

Name of the ‘int[]’ attribute in ‘mesh’ containing the neighbors of all points. The beginnings of each point’s neighbors within this array are provided in the attribute specified by ‘nameOfNeighborStartsInputAttribute’.

neighbors

nameOfNeighborStartsInputAttribute

token

Name of the ‘int[]’ attribute in ‘mesh’ containing the beginning index of neighbors of each point in the array attribute specified by ‘nameOfNeighborsInputAttribute’

neighborStarts

iterations

int

Number of times to average neighboring values

5

useGPU

bool

When this option is on, the node will use the GPU to perform the smoothing computation.

True

Outputs

Name

Type

Description

Default

mesh

bundle

A copy of ‘mesh’ with the specified attribute smoothed.