Scale Modifier

Summary

This modifier increases or decreases the scale (or radius, or mass) of a particle.

Interface

This is the modifier's interface:

For the 'Groups Affected', 'Mapping', and 'Falloff' tabs, and for the buttons at the bottom of the interface, please see the 'Common interface elements' page.

Parameters

Enabled

Uncheck this switch to disable the modifier.

Mode

Independent [default setting]

In this mode, particles will be affected if they come into the field of effect of the modifier. X-Particle Actions have no effect on the modifier in this mode.

Action-Controlled

In this mode, the modifier will only act on a particle when told to do so by an Action. Until that point, the particle will not be affected, but once activated for a particular particle, the modifier will continue to influence it as long as it is in the field of effect of the modifier. The modifier's effect on a particle can be halted by means of another Action, if desired.

Parameter to Change

This drop-down menu has three settings.

Particle Radius

The modifier will affect the particle radius. It will not then affect the geometry scale (if there is any geometry associated with the particle). However, the Generator, Sprite, and Fragmenter objects all have options to set the geometry scale from the particle radius. If that option is turned on, the geometry scale will be affected in this mode.

Particle Scale

The modifier will affect the particle scale value. If there is any geometry associated with the particle and it is set to use the particle scale as the geometry scale, the geometry scale will be altered in this mode.

Changing to this mode will alter the interface slightly:

Particle Mass

The modifier will increase or decrease the particle mass. Again, changing to this parameter will alter the interface slightly:

Operation

This drop-down has several settings:

Change Value Over Time (Absolute)

With this option, the selected parameter changes each frame by a value given in the 'Scale Change' field (for particle scale), the 'Radius Change' field (for particle radius) or the 'Mass Change' field (for particle mass).

This is the same parameter as 'Change Value Over Time' found In earlier versions of X-Particles.

Change Value Over Time (Relative)

One problem with changing a value over time is that the value (radius, scale or mass) for each particle is altered by the same amount each frame. For example, if the 'Radius Change' value is 0.2 scene units, the radius of each particle will be increased by that amount each frame. This might not be desirable for particles with very different initial radii.

If you select this mode, the 'Radius Percentage' (or mass or scale percentage) parameter becomes available. This will change the value of the radius by a percentage of its value, so small particles will scale up less rapidly than large ones.

Set Value

If this option is selected, the modifier will simply set the scale (or radius, or mass) value but will not change it over time. In this case, the relevant 'change' field is removed and a 'value field appears instead. You can then control the value using data mapping.

Set by Falloff

In this mode, the particle's radius (or scale, or mass) will be scaled up or down by the modifier's falloff. For example, suppose the radius initially is 10 units. When the particle enters the field of effect, the radius will be change in inverse proportion to the falloff, so as the falloff strength increases, the radius will decrease. But as the particle moves through the field, the falloff value may decrease again, causing the radius to increase back to what it was originally.

This enables effects like this:

Jiggle

As for 'Change Value Per Frame' but with random variation added. The amount of variation is set in the 'Jiggle Variation' field. This results in a constantly changing scale each frame, giving a jiggle effect. It is only available for scale, not radius or mass.

Use Spline

This enables you to alter the object scale over the lifetime of the particle by using the spline interface in 'Scale Spline'. The 'Scale Change' value is ignored. You can use the spline to change the scale by a factor where a scale of +1 is no change in scale, +2 is twice the scale, and 0 is an object with zero scale - i.e. it will be invisible. The initial scale is set the by the Y value of the leftmost point on the spline. Also be aware that negative Y values will be clamped at zero.

If you select this option, the following interface appears:

(The interface is the same whether you are changing the scale, radius or mass.)

Scale by Speed

As for 'Change Value Per Frame' except that the particle speed is used as a multiplier of the scale change. Effectively, the faster the particle, the greater the change in scale, radius, or mass.

Scale by Acceleration

As for 'Scale by Speed' except that the particle acceleration (i.e. the change in speed over successive frames) is used as a multiplier of the scale change. Effectively, the more the particle speeds up or slows down, the greater the change in scale, radius, or mass.

Use Shader

This setting is deprecated in the latest version of X-Particles and data mapping should be used instead. It is retained in this version for reasons of compatibility with older scenes, but should not be used in new scenes as it may be removed in a future version. Use data mapping instead.

With this option, you can change the scale, radius or mass with a shader. This uses the following interface:

These are discussed below.

Scale Change

This parameter is not available if 'Operation' is set to 'Use Spline' or 'Set Value'.

This is the change to apply to the scale of the object whose associated particle passes into the modifier’s field of effect. Negative values will cause the scale to decrease, positive values will increase the scale. Note that it is possible to set different changes in scale on different axes of the particle, if desired.

The full increment is applied to particles passing through the modifier’s red zone; those in the yellow zone have their scale altered in a reduced amount, depending on the strength of the falloff.

Variation

A variation applied to the scale change. A 20% variation would mean that the actual scale change for any particle will be somewhere in the range given by 'Scale Change' value +/- 20% of that value. This will cause the change in particle scale to vary from one particle to another.

This setting is not available if 'Operation' is set to 'Use Spline' or 'Jiggle'.

Jiggle Variation

A random variation applied to the particle scale (not radius or mass) if 'Operation' is set to 'Jiggle'. This

Clamp to Scale Limit

If this switch is checked, the scale of the object will be clamped at the values given in the 'Lower Scale Limit' and 'Upper Scale Limit' fields. This option is not available if 'Operation' is set to 'Use Spline'. Regardless of this setting, the modifier will never set the particle scale to be less than zero.

Lower Scale Limit, Upper Scale Limit

The minimum and maximum possible scales of the object. Not used if 'Operation' is set to 'Use Spline'. 'Clamp to Scale Limit' must be checked to change these settings. The lower scale limit cannot be less than zero.

Scale Value

This is only available if 'Operation' is set to 'Set Value'. It is the scale value which will be set by the modifier.

Radius Change, Variation, Clamp to Radius Limit, Lower Radius Limit, Upper Radius Limit and Radius Value

These are the same as the scale parameters 'Scale Change' etc., and are only available if 'Parameter to Change' is set to 'Radius'.

Mass Change, Variation, Clamp to Mass Limit, Lower Mass Limit, Upper Mass Limit and Mass Value

These are the same as the scale parameters 'Scale Change' etc., and are only available if 'Parameter to Change' is set to 'Mass'.

Radius Percentage, Mass Percentage and Scale Percentage

These are the percentage values to change the radius, mass or scale if 'Operation' is set to 'Change Value Over Time (Relative)'.

Clamp Within Range

If this switch is checked, instead of a scale (or radius, or mass) value being clamped to the upper or lower limits given in the lower and upper limit parameters, it will be clamped to a randomly-selected value between those two settings. The effect of this is that the modifier will increase (or decrease) the scale until the scale reaches the random limit, thereby resulting in particles having different final scales, rather than them all having the same final scale.

Remap Falloff Value

The effect of the modifier is dependent on the falloff. If the falloff value is zero, it will have no effect; if the falloff value is 1, the effect is at its maximum. A modifier falloff normally returns a value ranging from 0 to 1 - i.e. the value is always positive and negative values are not possible. If this switch is checked, the falloff value is remapped to a range of -1 to 1. This enables interesting effects when the particle passes through a modifier's field. With low falloff values this switch will remap them to negative ones, causing the scale to decrease, then as the falloff strength increases, the value becomes positive, increasing the scale. Note that the switch will have no effect if the falloff type is set to 'Infinite' as the value returned then is always 1.

Note that this feature may cause a sudden jump in the particle size if the 'Clamp Within Range' switch is also checked. This is unavoidable and it is recommended that these features are not used together.

Shader

When 'Operation' is set to 'Use Shader' you have access to several additional parameters. You can add a shader to this link and the scale, radius or mass is derived from the value returned from the shader. Any channel shader can be used but Noise gives the best results. Here is an example using an animated Noise shader to change the radius of particles stuck to a sphere:

The way this works is that the value in 'Scale Value' (or 'Radius Value' or 'Mass Value') is multiplied by the brightness of the colour returned from the shader and this value is then stored in the particle. Individual red, green and blue values are not relevant, the important value is the overall brightness of the colour.

Scale U, Scale V, Scale W

These three parameters control the size of the shader across the sample space. To put it another way, if the 'Tile' parameter is checked a bitmap will be tiled across the sample space and the number of tiles is controlled by these parameters. If 'Tile' is unchecked the bitmap is simply scaled.

Procedural shaders are scaled using these parameters but the 'Tile' switch has no effect.

Offset U, Offset V, Offset W

The shader will be offset by these amounts in the respective direction.

Mirror U, Mirror V, Mirror W

Checking these switches will mirror the shader across the respective axis.

Tile

If a bitmap is used, checking this switch will cause it to be tiled across the sample space. The number of tiles is controlled by the 'Scale U' and 'Scale V' settings. The switch has no effect on procedural shaders.

Scale Spline

Use this spline interface to control the scale of the generated object over the particle's life. The scale of the object at particle birth is given by the Y value of the point at the left of the spline (whose X value is zero) and the scale at the end of the particle's life is given by the Y value of the rightmost point (where X = 1). The range of values is 0 to +5.

Although you cannot set a point on the spline to be less than zero, the spline shape may make some points along its length have negative Y-values. These will all be clamped at zero (i.e. the object will have zero scale).

When using this spline, you should be aware of one issue. Suppose the scale of the object is set to 1 in the generator (or sprite) object but the leftmost point on the spline has a Y value of 0.5. What you will see is that for the first frame the object has a scale of 1, then in the next frame the scale immediately drops to 0.5. This is inherent in the way modifiers work - they are called after the initial particle generation - and the way round this is simply to ensure that the object scale in the generator is set to the same value as in the Y-value of the leftmost point in the spline.

Also note that If 'Parameter to Change' is set to 'Particle Radius' the spline will then set the particle radius directly. That is, a value of '2' in the spline will result in a particle radius of 2 units. If you are using a Generator or Sprite object with 'Scale from Particle Radius' checked, this will cause the objects to be very small, because they now take their scale from the particle radius. To alter this, you will need to increase the spline's 'Maximum Scale' parameter and adjust the spline as required.

Note that the Change Scale Action does not control the spline, so if you set 'Operation' to 'Use Spline' the action will no longer be able to control the object scale. In action-controlled mode the spline will still control the scale, but the modifier will have no effect until an action sets the particle to be affected by the modifier.

Maximum Scale

By default the maximum Y value in the spline is 2. You may want to scale up the objects more than that. To do that, use the 'Maximum Scale' setting (you can reduce it as well, of course, for finer control over the value). This parameter is only available if 'Operation' is set to 'Use spline'.