modifier_influence
The modifier influence can be used to replace, add, multiply or clamp the value of a simulation property like voxel_density
,point_velocity
, or point_size
.
To use this node, plug its output into the influences
input of a simulate node like simulate_aero
, simulate_particles
, or simulate_mpm
.
Inputs
influence
One may optionally connect an influence field's out_influence
into this port. For example a mask_influence
node could be connected to mask the effect of this influence. Any number of influence fields may be added to the daisy chain to build a complex field.
enable
Turn off to disable the effect. Disabling makes it a pass through node. Note that any other influence fields connected to the influence input port will still be active when this is disabled.
property
The name of the simulation property to modify.
operation
The math operation to apply to the specified simulation property, using the specified value:
Replace
: Substitute the current value with the specifiedvalue
Multiply
: Multiply the current value byvalue
Add
: Addvalue
into the current value.
value
This is the value to replace, multiply or add by. In general it should be the same type as the property, but one could multiply a float3 property like point_velocity by a simple float value, which would have the effect of scaling the speed.
rate
This is how quickly the operation is applied. For example replace will not immediately set the simulation to value
unless the rate is very high. You can connect a ScalarField
to vary the effect over space.
enable_clamp
If this is enabled then the values for the defined property are clamped to be within the specified min
and max
values. The clamp does not use the rate but immediately clamps the values, even with a rate of zero. To only do a clamp with no math operation one can make the rate zero.
Clamp currently only works for float and float3 properties. For float properties one can clamp with a float or scalarField type for both min and max. For float3 properties the min and max should be float3 or vectorField.
min
The minimum value to clamp to (only has an effect when enable_clamp is on). This may be float, float3, scalarField or vectorField.
max
The maximum value to clamp to (only has an effect when enable_clamp is on). This may be float, float3, scalarField or vectorField.
Outputs
out_influence
An output influence object that one can connect to simulation nodes or other influence nodes.