Skip to main content

vArrayPointAttractor

Pulls points toward, or pushes them away from, an attractor position within a radius.

IntermediateMograph / ArrayArrayScriptValJSON
vArrayPointAttractor node

vArrayPointAttractor takes an array of points and moves those inside Radius of the attractor toward it, or away from it with a negative Strength. The attractor is set by Attractor Position and Attractor Z.

Parameters​

ParameterTypeDefaultDescription
Strength (+attract/-repel)Float0.001Force at the attractor. Positive pulls, negative pushes. Slider -0.01 to 0.01, default 0.001.
RadiusFloat1.0Distance within which points are affected. Minimum 0.000001, slider 0.001 to 5, default 1.
Falloff PowerFloat1.0Exponent of the falloff. Minimum 0.01, slider 0.01 to 5, default 1.
Spring ReturnFloat0.1Hidden control. Spring Return. Has no effect, since points start at rest at their input position. Default 0.1.
Spring BounceFloat0.01Hidden control. Spring Bounce. Has no effect for the same reason. Default 0.01.
+11 more parameters
ParameterTypeDefaultDescription
DampingFloat0.98Multiplies the speed after the push. Slider 0 to 1, default 0.98.
Time StepFloat10.0Scales the push and the move. Slider 0.01 to 100, default 10.
CenterPoint—Hidden control. Not read by the code.
Z OffsetFloat0Hidden control. Not read by the code.
Attractor PositionPoint—Attractor position in X and Y, as a point in the viewer. Default 0.5, 0.5, which is 0, 0 in the node.
Attractor ZFloat0.5Attractor position on Z, used with Use 3D Points. Slider -1 to 1, default 0.5.
AxisPoint—Hidden control. Not read by the code.
Relative Flare OffsetFloat1.5Hidden control. Relative Flare Offset. Not read by the code. Default 1.5.
MultiplierFloat1Divides the attractor X and Y. Minimum 0.000001, slider 0 to 2, default 1.
Use 3D PointsFloat1Uses and outputs Z when on (default). Off gives 2 values per point.
InputDATATYPE—Points to move.
Read the full description

For each point closer to the attractor than Radius, the node adds a push of Strength * (1 - (distance / Radius) ^ Falloff Power) along the line to the attractor, scaled by Time Step, multiplies it by Damping, and moves the point by that times Time Step again. Points outside Radius do not move. The move does not depend on the frame.

The attractor X and Y come from Attractor Position, centered on 0 and divided by Multiplier. Attractor Z is used when Use 3D Points is on (default), which also keeps the Z of the output. Defaults are Strength 0.001, Radius 1, Falloff Power 1, Damping 0.98 and Time Step 10. Spring Return and Spring Bounce are hidden and have no effect.

Example Connections​

vArrayPointsOnGrid.Output -> vArrayPointAttractor.ArrayA
vArrayPointAttractor.Output -> vArrayCameraProjection.ArrayA
vArrayCameraProjection.Output -> vArrayShapeRender.ArrayPoint
Background.Output -> vArrayShapeRender.Input