Skip to content

nxFoam

nxFoam analyzes fluid data and, from that data, generates bubbles, foam and spray particles.

nxFoam_Main_Image_01.jpg


nxFoam_Image_01.jpg

Adds a new diffuse particle layer to the modifier.

Each layer is independent and can be configured as one of three options: Surface Foam, Bubbles or Spray.

Multiple layers of the same type can be added to create separate populations with different settings, for example a fine surface foam layer alongside a coarser one.

Lists all active layers on this modifier.

Each layer can be individually enabled or disabled using the toggle on the right.

Selecting a layer in the list displays its settings below.

Layers are evaluated in order and all active layers run every simulation step.


nxFoam_Image_01_Alt.jpg

Surface Foam particles form at the fluid surface in areas of high kinetic energy and wave curvature.

They are generated by fluid particles whose velocity runs along the surface rather than through it, making them characteristic of breaking wave crests, turbulent chop, and fastmoving surface flows.

Once spawned they are advected by the local fluid velocity and gradually die off as the surface energy around them drops.

nxFoam_Surface_Foam_Spawn_SubTab_01.jpg

Links the foam layer to an emitter to create these foam particles.

With no emitter set, the foam particles are spawned from the emitter of the fluid particles that created the foam.

Click this button to create a new spawning xpEmitter and add it to the Emitter link field.

This emitter will then be used to create the foam particles.

Assigns spawned foam particles to a particle group.


Sets the initial color of spawned foam particles.


Controls how many foam particles are created per fluid particle per frame.

Higher values produce denser foam but increase particle counts.

Defines how far from the fluid particle newly spawned foam can appear.

A larger radius scatters foam more widely around the spawn point.

The simulation accumulates a potential on each fluid particle every frame, driven by its kinetic energy and surface curvature.

Foam only spawns once this accumulated value exceeds the threshold.

Higher values make foam harder to trigger, producing a more burst-like spawning pattern rather than a continuous trickle.

Limits foam spawning to fluid particles that are within this distance of the fluid surface.

Particles deeper than this value are excluded, reducing foam from appearing inside the bulk of the fluid.

Set to 0 (zero) to disable the depth check.


The minimum age a fluid particle must reach before it can spawn foam.

Newly emitted particles are excluded until they have been alive for this time.

Adds a random per-particle offset to the After Age threshold.

This breaks up the uniform onset of foam across the simulation, producing a more organic staggered appearance.

The base lifespan of a spawned foam particle.

The actual lifetime is scaled by the conditions at spawn.

Particles born during high-energy, high-curvature events live longer; those created under marginal conditions die sooner.

Randomly varies the lifespan of each foam particle around the computed Foam Life value.

Higher variation produces a broader spread of foam ages, avoiding the artificial look of all foam dying at the same time.

Scales the initial velocity transferred from the local fluid flow to the newly spawned foam particle.

At 100%, foam starts moving at the full local fluid speed; lower values produce slower, more sluggish foam that lags behind the fluid.

Adds per-particle randomness to the velocity at spawn.

This disperses foam over a range of initial speeds rather than all particles launching at exactly the same velocity, producing a more natural spread.

Sets the base size of spawned foam particles.

Randomly varies the size of each foam particle around the Foam Radius base value, adding natural size diversity and preventing the uniform look of identically sized particles.


Optional volume objects that restrict where foam can be spawned.

Only fluid particles inside the defined volumes will generate foam.

This is useful for limiting foam to specific regions of a scene without affecting the rest of the simulation.


nxFoam_Surface_Foam_Detection_SubTab_01_Alt.jpg

The minimum kinetic energy a fluid particle must have before it can contribute to foam generation.

Slow-moving particles are excluded, ensuring foam only appears in energetic regions such as wave crests, impacts, and fast-moving flows.

The upper bound of the kinetic energy ramp.

Above this speed the kinetic energy contribution to foam potential is clamped at its maximum.

Together with Kinetic Energy Min, this defines the transition region between no contribution and full contribution.

The minimum surface curvature a fluid particle must exhibit before it contributes to foam.

Curvature measures how much the local surface is bending; flat calm surfaces have low curvature, while breaking wave crests and collisions have high curvature.

This limits foam to areas of surface deformation.

The upper curvature value at which the crest contribution to foam potential is fully saturated.

Above this value, curvature no longer increases the foam potential.

Setting this close to the minimum produces a sharper, more abrupt foam onset at the crest.

The minimum turbulence level required before a fluid particle contributes to foam.

Turbulence measures how much neighboring particles are diverging in velocity, regions of high shear, swirling vortices, and colliding flows are high.

This threshold restricts foam to turbulent areas.

The upper turbulence value at which the turbulence contribution to foam potential reaches its maximum.

Above this level the contribution is clamped.

Together with Turbulence Min, this controls how quickly turbulence saturates the foam potential.

The minimum local fluid density a particle must have to spawn foam.

Very sparse regions, such as isolated droplets or the outermost edge of the simulation, fall below this threshold and are excluded, preventing foam from appearing in unrealistically thin parts of the fluid.

The maximum local fluid density beyond which foam spawning is suppressed.

Particles deep within the bulk of the fluid are surrounded by neighbors on all sides, giving them a high density, and are excluded from surface foam generation.

Only particles near the surface, where density naturally drops, are eligible.

This ensures foam is generated at the surface rather than in the interior.


Bubbles are diffuse particles that form inside the body of the fluid, in regions of high turbulence and kinetic energy.

Unlike Surface Foam, Bubbles are generated by interior fluid particles that have a weak or absent surface normal, meaning they are fully submerged.

Once created they rise through the fluid under buoyancy and are advected by the local flow.

nxFoam_Bubbles_Spawn_SubTab_01.jpg

Links the bubble layer to an emitter to create these bubble particles.

With no emitter set, the bubble particles are spawned from the emitter of the fluid particles that created them.

Assigns spawned bubble particles to a particle group.


Sets the initial color of spawned bubble particles.


Controls how many bubble particles are created per fluid particle per frame.

Higher values produce denser bubbles but increase particle counts.

Defines how far from the fluid particle newly spawned bubbles can appear.

A larger radius scatters bubbles more widely around the spawn point.

The simulation accumulates a potential on each fluid particle every frame, driven by its kinetic energy and turbulence.

Bubbles only spawn once this accumulated value exceeds the threshold.

Higher values make bubbles harder to trigger, producing a more burst-like spawning pattern rather than a continuous trickle.

Limits bubble spawning to fluid particles that are at least this distance below the fluid surface.

Particles too close to the surface are excluded, keeping bubbles in the interior of the fluid body.

Set to 0 (zero) to disable the depth check.


The minimum age a fluid particle must reach before it can spawn bubbles.

Newly emitted particles are excluded until they have been alive for this time.

Adds a random per-particle offset to the After Age threshold.

This breaks up the uniform onset of bubbles across the simulation, producing a more organic staggered appearance.

The base lifespan of a spawned bubble particle.

The actual lifetime is scaled by the conditions at spawn.

Particles born in highly turbulent, energetic regions live longer; those created under marginal conditions die sooner.

Randomly varies the lifespan of each bubble particle around the computed Bubble Life value.

Higher variation produces a broader spread of bubble ages, avoiding the artificial look of all bubbles dying at the same time.

Scales the initial velocity transferred from the local fluid flow to the newly spawned bubble particle.

At 100% bubbles start moving at the full local fluid speed; lower values produce slower bubbles.

Adds per-particle randomness to the velocity at spawn, dispersing bubbles over a range of initial speeds rather than all particles launching at exactly the same velocity.

Sets the base size of spawned bubble particles as a scale of the parent fluid particle’s radius.

The resulting size is proportional to the fluid particle that generated it.

Randomly varies the size of each bubble particle around the Bubble Radius base value, adding natural size diversity.


Optional volume objects that restrict where bubbles can be spawned.

Only fluid particles inside the defined volumes will generate bubbles.

Useful for limiting bubbles to specific regions of a scene without affecting the rest of the simulation.


nxFoam_Bubbles_Detection_SubTab_01_Alt.jpg

The minimum kinetic energy a fluid particle must have before it can contribute to bubble generation.

Slow-moving particles are excluded, ensuring bubbles only appear in energetic regions such as submerged impacts and fast-moving internal flows.

The upper bound of the kinetic energy ramp.

Above this speed the kinetic energy contribution to bubble potential is clamped at its maximum.

Together with Kinetic Energy Min, this defines the transition region between no contribution and full contribution.

The minimum curvature value used in the bubble life calculation.

Unlike surface foam where curvature is a primary driver, for bubbles it plays a secondary role.

It contributes to how long a bubble lives but is not a hard gate on whether spawning occurs.

The upper curvature value at which the curvature contribution to bubble lifetime is fully saturated.

Together with Wave Curvature Min, this controls the curvature component of the lifespan calculation.

The minimum turbulence level required before a fluid particle contributes to bubble generation.

Turbulence is the primary driver for bubbles.

Regions of high shear, swirling vortices, and colliding internal flows score high.

This threshold restricts bubbles to genuinely turbulent areas of the fluid interior.

The upper turbulence value at which the turbulence contribution to bubble potential reaches its maximum.

Above this level the contribution is clamped.

Together with Turbulence Min, this controls how quickly turbulence saturates the bubble potential.

The minimum local fluid density a particle must have to spawn bubbles.

Because bubbles form inside the fluid body, this is typically set higher than the equivalent surface foam value.

Only particles well embedded within the fluid, surrounded by enough neighbors, are eligible.

The maximum local fluid density beyond which bubble spawning is suppressed.

Setting this to 100% allows bubbles to form anywhere inside the fluid up to the densest packed regions.

Lowering it can restrict bubbles to less tightly packed interior areas.


nxFoam_Spray_01.jpg

Spray particles form at the fluid surface from fluid particles that are actively ejecting outward.

Their velocity must be directed through the surface normal rather than along it, which distinguishes spray from Surface Foam.

Surface Foam forms where fluid moves along the surface, while Spray forms where fluid is being thrown clear of it, such as at the tip of a breaking wave or the peak of an impact.

Once airborne, Spray particles are governed primarily by gravity and drag with minimal fluid coupling.

nxFoam_Spray_Spawn_SubTab_01.jpg

Links the spray layer to an emitter to create these spray particles.

With no emitter set, the spray particles are spawned from the emitter of the fluid particles that created them.

Assigns spawned spray particles to a particle group.


Sets the initial color of spawned spray particles.


Controls how many spray particles are created per fluid particle per frame.

Higher values produce denser spray but increase particle counts.

Defines how far from the fluid particle newly spawned spray can appear.

A larger radius scatters spray more widely around the spawn point.

The simulation accumulates a potential on each fluid particle every frame, driven by its kinetic energy and surface curvature.

Spray only spawns once this accumulated value exceeds the threshold.

Higher values make spray harder to trigger, producing a more burst-like spawning pattern rather than a continuous trickle.

Limits spray spawning to fluid particles that are within this distance of the fluid surface.

Particles deeper than this value are excluded.

Set to 0 (zero) to disable the depth check.


The minimum age a fluid particle must reach before it can spawn spray.

Newly emitted particles are excluded until they have been alive for this time.

Adds a random per-particle offset to the After Age threshold, producing a more organic staggered appearance across the simulation.

The base lifespan of a spawned spray particle.

The actual lifetime is scaled by the conditions at spawn, with turbulence and surface curvature contributing equally.

Particles born at high energy, highly curved surface breaks live longer; those created under marginal conditions die sooner.

Randomly varies the lifespan of each spray particle around the computed Spray Life value, avoiding the artificial look of all spray dying at the same time.

Scales the initial speed of spawned spray particles.

Unlike foam and bubbles, spray velocity fans out in a cone around the fluid flow direction.

This parameter controls the overall magnitude of that ejected velocity.

Adds per-particle randomness to the velocity magnitude at spawn, dispersing spray over a range of speeds for a more natural appearance.

Sets the base size of spawned spray particles as a scale of the parent fluid particle’s radius.

Randomly varies the size of each spray particle around the Spray Radius base value, adding natural size diversity.


Optional volume objects that restrict where spray can be spawned.

Only fluid particles inside the defined volumes will generate spray.


nxFoam_Spray_Detection_SubTab_01.jpg

The minimum kinetic energy a fluid particle must have before it can contribute to spray generation.

Spray typically requires higher kinetic energy than foam since it represents fluid being actively ejected from the surface.

The upper bound of the kinetic energy ramp.

Above this speed the kinetic energy contribution to spray potential is clamped at its maximum.

Together with Kinetic Energy Min, this defines the transition region between no contribution and full contribution.

The minimum surface curvature required before a fluid particle can generate spray.

Spray forms at sharply curved surface features.

Breaking crests and high-curvature impacts, so this threshold is typically set higher than for surface foam.

The upper curvature value at which the curvature contribution to spray potential is fully saturated.

Together with Wave Curvature Min, this controls how sharply the curvature drives spray generation.

The minimum turbulence level required before a fluid particle contributes to spray.

High turbulence combined with high curvature produces the most intense spray events.

The upper turbulence value at which the turbulence contribution to spray potential reaches its maximum.

Together with Turbulence Min, this controls how quickly turbulence saturates the spray potential.

The maximum local fluid density beyond which spray spawning is suppressed.

Spray is exclusively a low-density surface phenomenon.

Only particles at the outer edge of the fluid, where density is naturally low, are eligible.

There is no minimum density threshold for spray; any particle sparse enough is a candidate provided it meets the other detection criteria.


nxFoam_Advection_01.jpg

The Advection tab controls how existing diffuse particles move and behave once spawned.

While the Object tab determines whether and where particles are created, this tab governs their physics: how strongly they are dragged by the fluid, how they respond to buoyancy, whether they can change type during their lifetime, and how they interact with each other.

Parameters are split across four subtabs: Simulation, which covers shared settings and type transition behaviour, and one subtab each for Spray, Foam, and Bubbles.

nxFoam_Advection_Simulation_Transition_01.jpg

Set as Disabled, by default, the other options are: Convert or Kill.

Diffuse particles are continuously classified by the local fluid density around them.

A particle in low-density fluid is considered spray, one in moderate density is foam and one in high-density fluid is a bubble.

Type Transition controls what happens when that classification changes during a particle’s lifetime.

When set to Disabled, particles keep the type they were born as regardless of where they end up.

A particle that has been in conditions matching a different type for longer than the Transition Time setting will switch to that new type, optionally changing color and group.

When set to Kill, the particle is removed after spending Transition Time in conditions that no longer match its original type.

The amount of time a particle must spend in conditions matching a different type before the transition is committed.

This prevents rapid flickering when a particle sits near a density boundary.

Only active when Type Transition is set to Convert or Kill.

Sets the gravity vector applied to all diffuse particles.

This should normally match the gravity used by the fluid simulation.

Gravity is opposed by each particle type’s buoyancy setting, so the net vertical acceleration depends on both values together.


One or more volume objects that define the region within which diffuse particles are allowed to exist.

Any diffuse particle that moves outside these volumes is immediately killed.

This is typically set to the same bounds used by the fluid simulation, such as an nxFluids object for a FLIP or APIC simulation, ensuring diffuse particles do not survive beyond the edges of the simulated fluid domain.


nxFoam_Advection_Spray_01.jpg

These parameters govern the physics and appearance of particles currently classified as spray.

A particle is classified as spray when the local fluid density around it falls at or below the Spray Density threshold, meaning it is in very sparse fluid or fully airborne.

The fluid density threshold at or below which a diffuse particle is classified as spray.

Since spray particles are typically airborne and away from the bulk of the fluid, this is normally set low.

Raising it causes more particles to be treated as spray even when partially submerged.

Controls how strongly a spray particle’s velocity is pulled toward the local fluid velocity when submerged.

At 0 (zero) % there is no coupling and the particle moves freely.

Higher values cause the particle to follow the fluid more closely.

Drag is only applied in proportion to how deeply submerged the particle is, so fully airborne spray particles are unaffected.

Adds an upward force to spray particles when they are submerged.

At 0 (zero) % the upward force balances gravity, leaving submerged spray neutrally buoyant.

Higher values cause submerged spray to rise back toward the surface.

Like drag, this force scales with submersion depth and has no effect on fully airborne particles.

Controls how much a spray particle rotates to align with the local flow direction each frame.

At 0 (zero) % particles do not rotate.

Higher values cause the particle’s orientation to track the surrounding fluid flow, which is useful when spray particles are rendered as oriented sprites or instanced geometry.

When enabled, a particle that transitions into the spray type will have its color changed to the value set in Spray Color.

This only applies during a type transition, not at initial spawn.

The color applied to a diffuse particle when it transitions into the spray type.

Only active when Spray Set Color is enabled.

The particle group a diffuse particle is moved into when it transitions into the spray type.

Useful for applying spray-specific rendering or modifiers after a type change.

When enabled, spray particles will push each other apart when they come within proximity of each other.

This prevents spray from clustering into tight overlapping clumps and gives a more physically plausible distribution.

Controls how forcefully spray particles push each other apart when Spray Push is enabled.

Higher values produce stronger separation.

The push radius is derived automatically from the maximum particle radius in the simulation.


nxFoam_Advection_Foam_01.jpg

These parameters govern the physics and appearance of particles currently classified as foam.

A particle is foam when the local fluid density around it falls between the Spray Density and Foam Density thresholds, placing it at the fluid surface.

The fluid density threshold above which a diffuse particle is reclassified as a bubble.

Particles with local density between Spray Density and this value are treated as surface foam.

Raising this value widens the density band in which particles behave as foam before transitioning to bubbles.

Controls how strongly a foam particle’s velocity is pulled toward the local fluid velocity when submerged.

High drag values cause foam to move tightly with the fluid surface, which is typically desirable for realistic foam advection.

Drag scales with submersion depth.

Adds an upward force to foam particles when submerged.

At 0 (zero) % the upward force balances gravity, keeping foam neutrally buoyant.

Higher values cause foam to rise back toward the surface more actively.

The force scales with submersion depth, so foam sitting exactly at the surface receives less push than foam that has been momentarily pushed below it.

Controls how much foam particles rotate to align with the local flow direction each frame.

Useful when foam particles are rendered as oriented geometry such as flat card sprites that should visually track the surface flow.

When enabled, a particle that transitions into the foam type will have its color changed to the value set in Foam Color.

Only applies during a type transition.

The color applied to a diffuse particle when it transitions into the foam type.

Only active when Foam Set Color is enabled.

The particle group a diffuse particle is moved into when it transitions into the foam type.

When enabled, foam particles will push each other apart when they come within proximity of each other, preventing tight overlapping clusters.

Controls how forcefully foam particles push each other apart when Foam Push is enabled.

When enabled, isolated foam particles that have fewer neighboring foam particles than the Erosion Threshold have a chance to be removed each frame.

This gradually clears sparse, straggly foam from areas where the foam sheet is thinning out, leaving foam only where it is dense enough to be plausible.

Erosion only affects particles of the foam type.

The minimum number of neighboring foam particles a foam particle must have to be safe from erosion.

Particles with fewer neighbors than this value are candidates for removal each frame.

Raising this value makes erosion more aggressive, thinning the foam sheet more quickly.

The probability per frame that an isolated foam particle below the Erosion Threshold will be removed.

At 100% every isolated particle is removed immediately.

Lower values cause the foam sheet to erode gradually rather than all at once


nxFoam_Advection_Bubbles_01.jpg

These parameters govern the physics and appearance of particles currently classified as bubbles.

A particle is classified as a bubble when the local fluid density around it exceeds the Foam Density threshold, meaning it is fully submerged within the fluid body.

Controls how strongly a bubble particle’s velocity is pulled toward the local fluid velocity.

Bubbles are always submerged so drag is always active, unlike spray and foam where it scales with depth.

High drag causes bubbles to follow the fluid flow closely; lower values allow them to drift more independently.

Adds an upward force to bubble particles.

Since bubbles are submerged, this force is always active and drives them toward the surface.

Higher values cause bubbles to rise faster.

The net upward acceleration is gravity plus buoyancy, so a higher value here overcomes gravity more strongly.

Controls how much bubble particles rotate to align with the local flow direction each frame.

When enabled, the buoyancy force applied to bubbles is modulated by how deep below the surface they are.

Bubbles near the surface receive the full buoyancy force.

Bubbles deeper than Max Depth have their buoyancy scaled by the Strength value.

This simulates the increasing pressure at depth reducing the effective rise speed of deep bubbles.

The depth below the fluid surface at which the buoyancy modulation reaches its full effect.

Bubbles shallower than this receive a linearly interpolated buoyancy between full strength and the scaled Strength value.

Only active when Depth is enabled.

The buoyancy scale factor applied to bubbles at or beyond Max Depth.

A value of 100% means no reduction.

Lower values slow the rise of deep bubbles significantly.

Only active when Depth is enabled.

When enabled, a particle that transitions into the bubble type will have its color changed to the value set in Bubble Color.

Only applies during a type transition.

The color applied to a diffuse particle when it transitions into the bubble type.

Only active when Bubble Set Color is enabled.

The particle group a diffuse particle is moved into when it transitions into the bubble type.

When enabled, bubble particles will push each other apart when they come within proximity of each other.

Controls how forcefully bubble particles push each other apart when Bubble Push is enabled.


To specify the group, drag and drop the desired Group object into this field.

This setting is useful if you want to ensure that the spawned particles are, or are not, affected by nxFoam.


You can use the Fields options to control where nxFoam operates.


Copyright © 2026 INSYDIUM LTD. All Rights Reserved.