MaxLiquidSolver
MaxLiquidSolver : MaxFluidSolverClass {49815c51,49491593}Available in 3ds Max 2018.3 and higher. The liquid class contains the set up parameters for a fluid simulation, including references to other objects, such as colliders and kill planes, that interact with the liquid in the simulation.
Constructor
Not directly creatable by MAXScript. Solvers are "owned" by MaxLiquid objects. You can create a solver using MaxFluidLiquidObject.createSolver().
For example:
liquid = maxLiquid pos:[0,0,50]
liquid.CreateSolver 1
solver = liquid.solvers[1]
solver.baseVoxelSize = 4.0
Properties
This class has many properties. They are organized here according to their order of appearance on the Simulation View dialog.
- General Parameters
- Liquid Attributes Tab
- Solver Parameters Tab
- Caching Tab
- Display Settings Tab
- Render Settings Tab
General Parameters
<MaxLiquidSolver>.solveName : stringThe solver name.
Liquid Attributes Tab
Properties in this area of the dialog are associated with the parent MaxLiquid object. See MaxLiquid.
Solver Parameters Tab
Simulation Parameters
General Parameters Rollup
<MaxLiquidSolver>.simUseTimeline : booleanIndicates whether to use the full scene timeline for the start and end of the simulation.
<MaxLiquidSolver>.simStartFrame : integerWhen simUseTimeline is false, sets the start frame of the simulation.
<MaxLiquidSolver>.simEndFrame : integerWhen simUseTimeline is false, sets the end frame of the simulation.
<MaxLiquidSolver>.useSystemScale : booleanIndicates whether to use the default system scale (where one unit = 1 inch).
<MaxLiquidSolver>.fluidScale : float
<MaxLiquidSolver>.fluidScaleList : integerWhen useSystemScale is false, these parameters set the scale of one fluid unit. The fluidScale parameter sets the value, and the fluidScaleList parameter sets the units, where:
- 0=inches
- 1=feet
- 2=miles
- 3 = millimeters
- 4 = centimeters
- 5 = meters
- 6 = kilometers
<MaxLiquidSolver>.reScaleParams : booleanGets or sets the Auto-rescale parameters setting.
<MaxLiquidSolver>.baseVoxelSize : floatGets or sets the Base Voxel size, which is the base resolution for the simulation.
Prior to 3ds Max 2022 this property was called masterVoxelSize.
<MaxLiquidSolver>.gravityMagnitude : floatThe base gravity magnitude, in meters per second squared. The default of 9.8 corresponds to the earth's gravity.
<MaxLiquidSolver>.gravityForceNode : nodeGets or sets the gravity force node (which is a Gravity : SpacewarpObject object) that affects the gravity direction for the simulation.
<MaxLiquidSolver>.useGravityNodeStrength : booleanIndicates whether to use the .strength parameter on the gravity force node instead of the .gravityMagnitude parameter to determine gravity strength.
<MaxLiquidSolver>.enableSpatialAdapt : booleanGets or sets whether the special adaptivity is turned on for the simulation. This feature is useful in deep water simulations, where detail is needed at the surface and edges, and lower resolution can be used everywhere else.
<MaxLiquidSolver>.deleteExceedingParticles : booleanIndicates whether exceeding particles are deleted. These are particles in low resolution areas. This further reduces the number of voxels simulated, which can improve simulation performance.
Simulation Parameters Rollup
<MaxLiquidSolver>.transportStepAdaptivity : floatGets or sets the transport adaptivity value, which determines the distance voxels can travel before additional transport phase substeps are calculated. This value can be in the range of 0.0 to 1.0, where:
- 0.0 - particles can move an unlimited distance without triggering further substeps.
- 0.32 (the default) - particles can move about 5 voxel lengths before triggering further substeps.
- 0.5 - particles can move up to 1 voxel length before triggering further substeps.
- 0.75 - particles can move about half a voxel length before triggering further substeps.
- 1.0 - particles can only move about 0.001 voxel lengths before triggering further substeps.
<MaxLiquidSolver>.minSteps : integerThe minimum number of substep calculations to perform per frame.
<MaxLiquidSolver>.maxSteps : integerThe maximum number of substep calculations to perform per frame.
<MaxLiquidSolver>.transportTimeScale : floatSets the speed of the particle flow, where values greater than 1.0 speed up the flow without introducing any new velocities or accelerations, and values between 0.0 and 1.0 slow it down.
<MaxLiquidSolver>.timeStepAdaptivity : floatGets or sets the time stepping adaptivity value. This determines the number of iterations of the whole simulation per frame, including voxelization, pressure, and transport phases.
<MaxLiquidSolver>.minTimeSteps : integerThe minimum number of time steps to perform per frame.
<MaxLiquidSolver>.maxTimeSteps : integerThe maximum number of time steps to perform per frame.
<MaxLiquidSolver>.solidVoxelScale : floatGets or sets the collision voxel scale, which is the multiplier applied to the Base Voxel size when voxelizing collider objects.
<MaxLiquidSolver>.forceVoxelScale : floatGets or sets the acceleration voxel scale, which is the multiplier applied to the Base Voxel size when voxelizing accelerator objects.
<MaxLiquidSolver>.foamMaskVoxelScale : floatGets or sets the foam mask voxel scale, which is the multiplier applied to the Base Voxel size when voxelizing foam mask objects.
Liquid Parameters
<MaxLiquidSolver>.dropletThreshold : float The threshold at which particles get converted to droplets. Values of 1.0 or above prevent droplet formation.
<MaxLiquidSolver>.dropletMergeBackDepth : float The depth (in voxel widths) within the liquid surface that a droplet must reach before it rejoins the liquid and is included in the fluid dynamic computations.
<MaxLiquidSolver>.surfaceBandWidth : float The width of the liquid's surface, in voxels.
<MaxLiquidSolver>.interiorParticleDensity : float The particle density of the inner volume of the liquid.
<MaxLiquidSolver>.surfaceParticleDensity : float The particle density at the surface of the liquid.
<MaxLiquidSolver>.vorticityEnable : boolean Enables the calculation of the vorticity channel.
<MaxLiquidSolver>.vorticityDecay : floatA value that is subtracted from the accumulated vorticity every frame.
<MaxLiquidSolver>.vorticityMult : float A multiplier for the magnitude of the curl of the current frame, before it is added to the accumulated vorticity.
<MaxLiquidSolver>.vorticityMax : float A clamp for the total allowed vorticity.
<MaxLiquidSolver>.surfaceTensionEnable : boolean Enables surface tension calculations.
<MaxLiquidSolver>.surfaceTension : float The surface tension value, which is an attractive force between particles on the surface. This causes a clumping effect.
<MaxLiquidSolver>.viscosity : float Controls the thickness of the liquid. Higher values are thicker.
<MaxLiquidSolver>.viscosityScale : float Smooths and dampens the liquid flow by blending the simulated velocities with the neighboring average. This is not physically correct, but can be used to mimic viscosity with very little computational cost. Values over 2.0 may produce unpredictable results over the duration of the simulation.
<MaxLiquidSolver>.erosionFactor : floatControls how closely the fluid boundary gets shrink wrapped back to the particle positions, as a percentage of the particle radius. A value of 0.0 results in no erosion, while 1.0 erodes by the full particle radius.
<MaxLiquidSolver>.erosionFactorNearSolids : float Determines whether the fluid surface is eroded in regions that are close to collider objects, based on the normal of the collider surface. Whenever the surface is eroded, it is always eroded by the full factor amount.
Emitter Objects
Emitter parameters have "global" and "override" versions for each setting. The global parameters are applied to all emitters, except for those with override enabled. The override versions of parameters are arrays of values, with the index of the value affecting the corresponding emitter in the owning MaxLiquid.emitter_Meshes array.
Emitter Parameters Rollup
<MaxLiquidSolver>.emitterOverrideTab : boolean arrayIndicates whether to override the global parameters for the corresponding emitter in the MaxLiquid.emitter_Meshes array.
<MaxLiquidSolver>.globalEmitterEmitType : int
<MaxLiquidSolver>.emitterOverrideEmitTypeTab : int arrayGets or sets the emitter type, where:
- 0 = Emitter
- 1 = Container
<MaxLiquidSolver>.enableEmission : boolean
<MaxLiquidSolver>.emitterOverrideEnableEmissionTab (OverrideEnableEmission) : boolean arrayIndicates whether liquid emission is enabled for the emitter.
<MaxLiquidSolver>.globalEmitterDensity : float
<MaxLiquidSolver>.emitterOverrideDensityTab (EmitterOverrideDensity) : float arrayThe physical density of the fluid. Water has a higher density than oil.
<MaxLiquidSolver>.densityMap : texturemap
<MaxLiquidSolver>.globalEmitterDensityTexmap : texturemap
<MaxLiquidSolver>.emitterOverrideDensityTexmapTab : texturemap arrayA texture map to use for density distribution.
<MaxLiquidSolver>.globalEmitterExpansionRate : float
<MaxLiquidSolver>.emitterOverrideExpansionRateTab (OverrideExpansionRate) : float arrayExpands or contracts the liquid within the emitter. Positive values push particles out of the emitter in all directions while negative values pull particles in. A value of 0.0 neither pushes nor pulls.
<MaxLiquidSolver>.expansionRateMap : texturemap
<MaxLiquidSolver>.globalEmitterExpansionRateTexmap : texturemap
<MaxLiquidSolver>.emitterOverrideExpansionRateTexmapTab : texturemap arrayA texture map to use for expansion distribution.
<MaxLiquidSolver>.globalEmitterStickinessStrength : float
<MaxLiquidSolver>.emitterOverrideStickinessStrengthTab (OverrideStickinessStrength) : float arrayThe amount that the fluid from this emitter adheres to nearby colliders.
<MaxLiquidSolver>.globalEmitterStickinessBandwidth : float
<MaxLiquidSolver>.emitterOverrideStickinessBandwidthTab (OverrideStickinessBandwidth) : float arraySets, in world-space units, how close the fluid from this emitter must be to a collider in order for the stickiness to affect it.
Emitter Conversion Parameters
<MaxLiquidSolver>.emitterConversionOverrideTab : boolean arrayIndicates whether to override the global parameters for the corresponding emitter in the MaxLiquid.emitter_Meshes array.
<MaxLiquidSolver>.globalEmitterMode : integer
<MaxLiquidSolver>.emitterConversionOverrideModeTab : int arrayThe emitter mode, where:
- 0 = Solid
- 1 = Shell
- 2 = Solid (Robust)
<MaxLiquidSolver>.globalEmitterCoarsenInterior : boolean
<MaxLiquidSolver>.emitterConversionOverrideCoarsenInteriorTab : boolean arraySets the distance in voxel widths used to close (dilate and then erode) the solid voxels when the conversion mode is Solid (Robust). The internal minimum is 1.0 so that only greater values have an effect. Note that high values can create artifacts.
<MaxLiquidSolver>.globalEmitterOffsetSurfaceDistance : float
<MaxLiquidSolver>.emitterConversionOverrideOffsetDistanceTab (OverrideOffsetSurfaceDistance) : float arrayThe distance in voxel widths used to close (dilate and then erode) the solid voxels when Mode is Solid (Robust). The internal minimum is 1.0 so only values greater than that have an effect. High values can create artifacts.
<MaxLiquidSolver>.globalEmitterThicknessUnits : integer
<MaxLiquidSolver>.emitterConversionOverrideThicknessUnitsTab : int arraySets whether thickness is in voxels or world-space units. When set to Voxels, the effective thickness depends on the Base Voxel Size of the simulation. Possible values are:
- 0 = Voxels
- 1 = World Units
<MaxLiquidSolver>.globalEmitterThickness : float
<MaxLiquidSolver>.emitterConversionOverrideThicknessTab : float arraySets the amount to thicken the mesh. For solid shapes that are already quite thick, you can use 0.0 for a precise boundary or even negative values to shrink along the surface normals. For thinner volumes and shells, you should use larger values to prevent holes.
<MaxLiquidSolver>.emitter_voxelScale : float
<MaxLiquidSolver>.emitterConversionOverrideVoxelScaleTab : floatSets a scaling factor for the Base Voxel Size used to initially voxelize meshes that share this property.
<MaxLiquidSolver>.globalEmitterVelocityScale : point3
<MaxLiquidSolver>.emitterConversionOverrideVelocityScaleTab (OverrideVelocityScale) : point3 arrayControls the proportion of velocity that is inherited from the emitters' animated transformation and deformation by the fluid at the time of emission in each of the world X, Y, and Z axes.
<MaxLiquidSolver>.globalEmitterEnableAdditionalVelocity : boolean
<MaxLiquidSolver>.emitterConversionOverrideEnableAdditionalVelocityTab (OverrideAddlVelocityMult) : float arrayAdds extra velocity to any existing velocity from other sources (such as velocity inherited from the emitter's animation).
<MaxLiquidSolver>.globalEmitterAdditionalVelocityMult : float
<MaxLiquidSolver>.emitterConversionOverrideAdditionalVelocityMultTab : floatSets a multiplier to scale additional velocity uniformly across all axes.
<MaxLiquidSolver>.globalEmitterAdditionalVelocity : point3
<MaxLiquidSolver>.emitterConversionOverrideAdditionalVelocityTab (OverrideAddlVelocity) : point3 arraySets the base velocity to add in world coordinates.
<MaxLiquidSolver>.globalEmitterArrowNode : node
<MaxLiquidSolver>.emitterConversionArrowNodeTab : node arrayHolds an arrow helper object in the scene. The orientation of the arrow will adjust the direction of additional velocity.
Collision Objects
Collider parameters have "global" and "override" versions for each setting. The global parameters are applied to all colliders, except for those with override enabled. The override versions of parameters are arrays of values, with the index of the value affecting the corresponding collider in the owning MaxLiquid.collider_Meshes array.
<MaxLiquidSolver>.colliderConversionOverrideTab : boolean arrayIndicates whether to override the global parameters for the corresponding collider in the MaxLiquid.collider_Meshes array.
<MaxLiquidSolver>.globalColliderMode : integer
<MaxLiquidSolver>.colliderConversionOverrideModeTab : int arrayThe collider mode, where:
- 0 = Solid
- 1 = Shell
- 2 = Solid (Robust)
<MaxLiquidSolver>.globalColliderCoarsenInterior : boolean
<MaxLiquidSolver>.colliderConversionOverrideCoarsenInteriorTab : boolean arraySets the distance in voxel widths used to close (dilate and then erode) the solid voxels when the conversion mode is Solid (Robust). The internal minimum is 1.0 so that only greater values have an effect. Note that high values can create artifacts.
<MaxLiquidSolver>.globalColliderOffsetSurfaceDistance : float
<MaxLiquidSolver>.colliderConversionOverrideOffsetDistanceTab : float arrayThe distance in voxel widths used to close (dilate and then erode) the solid voxels when Mode is Solid (Robust). The internal minimum is 1.0 so only values greater than that have an effect. High values can create artifacts.
<MaxLiquidSolver>.globalColliderThicknessUnits : integer
<MaxLiquidSolver>.colliderConversionOverrideThicknessUnitsTab : int arraySets whether thickness is in voxels or world-space units. When set to Voxels, the effective thickness depends on the Base Voxel Size of the simulation.
<MaxLiquidSolver>.globalColliderThickness : float
<MaxLiquidSolver>.colliderConversionOverrideThicknessTab : float arraySets the amount to thicken the mesh. For solid shapes that are already quite thick, you can use 0.0 for a precise boundary or even negative values to shrink along the surface normals. For thinner volumes and shells, you should use larger values to prevent holes.
<MaxLiquidSolver>.collider_voxelScale : float
<MaxLiquidSolver>.colliderConversionOverrideVoxelScaleTab : float arraySets a scaling factor for the Base Voxel Size used to initially voxelize meshes that share this property.
<MaxLiquidSolver>.globalColliderVelocityScale : point3
<MaxLiquidSolver>.colliderConversionOverrideVelocityScaleTab : point3 arrayControls the proportion of velocity that is inherited from the collider's animated transformation and deformation by the fluid at the time of collision in each of the world X, Y, and Z axes.
<MaxLiquidSolver>.globalColliderEnableAdditionalVelocity : boolean
<MaxLiquidSolver>.colliderConversionOverrideEnableAdditionalVelocityTab : boolean arrayAdds extra velocity to any existing velocity from other sources (such as velocity inherited from the collider's animation).
<MaxLiquidSolver>.globalColliderAdditionalVelocityMult : float
<MaxLiquidSolver>.colliderConversionOverrideAdditionalVelocityMultTab : float arraySets a multiplier to scale additional velocity uniformly across all axes.
<MaxLiquidSolver>.globalColliderAdditionalVelocity : point3
<MaxLiquidSolver>.colliderConversionOverrideAdditionalVelocityTab : point3 arraySets the base velocity to add in world coordinates.
<MaxLiquidSolver>.globalColliderArrowNode : node
<MaxLiquidSolver>.colliderConversionArrowNodeTab : node arrayHolds a reference to a helper object that determines the direction of additional velocity.
<MaxLiquidSolver>.globalColliderRefineNearbyFluids : boolean
<MaxLiquidSolver>.colliderConversionOverrideRefineNearbyTab : boolean arrayPrevents the fluid resolution from being coarsened in regions that are close to the collider when spatial adaptivity is enabled on the liquid.
Kill Plane Objects
There are no additional parameters for kill plane objects. This part of the UI is reserved for future use.
Guide System
<MaxLiquidSolver>.enableGuiding : boolean
<MaxLiquidSolver>.guideEnableTab : boolean arrayWhen true, self-collision and volume preservation calculations use foam particles in neighboring tiles. This increases simulation accuracy and eliminates visible boundary artifacts between tiles, especially in thick, static foam.
<MaxLiquidSolver>.computeGuideFromHighResLiquid: booleanComputes a final guiding shape that takes the high-resolution liquid into account.
<MaxLiquidSolver>.guideVoxelScale : float
<MaxLiquidSolver>.guideMeshVoxelScaleTab : float arrayA scaling factor for the Base Voxel Size that is used to voxelize the guide shapes.
<MaxLiquidSolver>.minSimulationDepth : floatSets the depth to simulate below the top liquid surface in scene units. You may need to change this depending on the scale of the modelled scene.
<MaxLiquidSolver>.surfaceLayer : floatSets the height of the simulated layer on top of the guide surface, in scene units. This can be useful for surface splashes.
<MaxLiquidSolver>.reseedParticleDensity : floatControls the number of particles to add per voxel in air pockets.
<MaxLiquidSolver>.reseedGuideOverlap : floatMultiplies the Base Voxel Size to determine how deeply into the guiding shape and liquid shape to reseed.
<MaxLiquidSolver>.reseedLiquidOverlap : floatMultiplies the Base Voxel Size to determine how deeply into the guiding shape and liquid shape to reseed.
<MaxLiquidSolver>.minReseedAirDistance : floatSets the minimum distance in scene units from the air-liquid boundary, below which particles are not reseeded. This prevents noise at the surface.
Foam Parameters
Foam Properties Rollup
<MaxLiquidSolver>.emissionRate : floatSets the number of emission points generated per voxel per second. Increasing this value generates more foam particles.
<MaxLiquidSolver>.minLiquidSpeed : floatSets the threshold to trigger foam emission, in meters per second, based on the velocity vectors of the liquid. Lower values generate more foam particles, while faster moving areas of the liquid emit more particles.
<MaxLiquidSolver>.minLiquidChurn : floatSets the threshold to trigger foam emission, in meters per second, based on the rotational and angular momentum in the liquid. Set Min Liquid Churn between 0 and 2, with lower values emitting more foam.
<MaxLiquidSolver>.minLiquidCurvature : floatSets the threshold to trigger foam emission based on curvature forming on the surface of the liquid. Lower values generate more foam particles. Liquid curvature refers to shapes on the liquid surface, such as those generated by rolling and cresting waves. Areas of the liquid with the steepest curves emit the largest number of particles. Liquid curvature refers to shapes on the liquid surface, such as those generated by rolling and cresting waves. Areas of the liquid with the steepest curves emit the largest number of particles.
Advanced:
<MaxLiquidSolver>.minLiquidDepth : floatSets the top of the voxel region in the liquid, in voxels, that emits foam particles. A value of 0 sets the liquid surface as the top of the emission region.
<MaxLiquidSolver>.maxLiquidDepth : floatSets the bottom of the voxel region in the liquid, in voxels, that emits foam particles. Positive non-zeros values set the bottom of the emission region below the surface of the liquid. Use a value of 3 for typical foam effects.
<MaxLiquidSolver>.maxSolidDepth : floatSets the distance, in voxels, between foam emission points and closed boundaries such as collision objects. Use values between 0 and 1 to maintain a boundary between voxel emission points and collision objects. To emit foam under the liquid surface (bubbles), set Max Solid Depth to a negative value and Max Liquid Depth to a high value such as 10 or greater.
<MaxLiquidSolver>.emitFlatnessToSurface : floatSnaps particles to the surface of the liquid at the time of emission. This prevents particles from being emitted under the surface of the liquid.
When set to 1.0, particles snap to the liquid surface. When set to 0 the particles are not affected, which allows buoyancy to direct the particles' upward motion.
<MaxLiquidSolver>.microVortices : floatCreates fine structure in the foam when it is emitted by pushing the particles using vortices that are a few voxels in size.
<MaxLiquidSolver>.emitMotionStreak : floatRandomizes the particle positions along the velocity vector when they are emitted. Higher values may help to reduce banding but also may result in a noisier appearance.
Behavior Parameters Rollout
<MaxLiquidSolver>.evaluateNeighborTile : booleanWhen enabled, self-collision and volume preservation calculations use foam particles in neighboring tiles. This increases simulation accuracy and eliminates visible boundary artifacts between tiles, especially with thick, static foam. You must set Preserve Volume to a non-zero value to compute this option. Enabling Evaluate Neighbor Tile increases simulation time.
<MaxLiquidSolver>.compressionModel : booleanEnables the Compression Model solver method. Similar to smoothed-particle hydrodynamics (SPH), Compression Model uses incompressibility calculations to resolve overlapping foam particles. This method increases accuracy and realism of foam simulations in small-scale liquids. When the combined particle overlap density is less than the set Target Density value, particles attract each other. When the particle overlap density is greater than the set Target Density however, foam particles repel each other.
<MaxLiquidSolver>.targetDensity : floatControls how the computations of the Compression Model method are applied to the foam simulation. Increasing this value allows more particles to overlap before they repel each other. For typical foam simulations, use values between 0 and 2. Values such as 10 can provide smoother distribution of particles. When using higher values, the Point Radius needs to be increased to compensate for the higher particle overlap density. This results in greater accuracy at the cost of longer computation.
<MaxLiquidSolver>.inheritLiquidVelocity : floatApplies acceleration to the emitted foam particles based on the liquid velocity. When set to 1, foam particles emit with a velocity equal to the liquid velocity vector. At values greater than 1, foam can shoot off the surface as spray; values of less than 1 will dampen the particle velocity.
<MaxLiquidSolver>.gravityMult : floatSets a value that scales the liquid container's Gravity Magnitude and applies it to the foam particles.
<MaxLiquidSolver>.maskFalloffDistance : floatSets a falloff region, in scene units, around the input mesh of a foam mask. Increase this value to soften the emission boundaries around mask.
<MaxLiquidSolver>.dissipationRate : floatSets the rate per-second that foam particles lose density. Foam particles at and above the liquid surface will dissipate. Particles under the liquid surface do not dissipate.
<MaxLiquidSolver>.killDensityThreshold : floatSets the Threshold Density value causing foam particles to be eliminated. Particles below the surface of the liquid have a density of 1 plus the Max Liquid Depth value. At the surface particles have a density of 1; above the surface they have a density of less than 1.
<MaxLiquidSolver>.buoyancy : floatSets the upward acceleration of foam particles in m/s2. With turbulent, fast moving liquids, increase Buoyancy to force particles to the surface. This stops the particles from remaining under the surface as bubbles, which do not dissipate.
<MaxLiquidSolver>.collideKillDepth : floatSets the distance from collision objects, in voxels, that triggers an additional dissipation effect on colliding particles. This is useful for eliminating particles that are trapped by collision objects and cannot rise to the liquid surface and dissipate. When set to 1, colliding particles dissipate at the set Dissipation Rate. When set to 0 or a negative value, particles dissipate at a rate greater than the Dissipation Rate. The relation between Collide Kill Depth and dissipation rate is non-linear. For example, when set to -0.5, dissipation increases by a factor of 10. Values greater than 1 do not noticeably affect dissipation as collisions stop particles from penetrating more that 1 voxel inside the collision object.
<MaxLiquidSolver>.foamSurfaceTension : floatSets the amount of surface tension to apply to the foam particles. The attractive force pulling particles together works within the region set by Tension Radius. Use values between 0 and 0.1, and more typically in the 0.01 to 0.02 range. Values higher than 0.1 can cause foam particles to ball together. The effect is most noticeable in small-scale non-turbulent liquids. Foam Surface Tension works best with Compression Model and Evaluate Neighbor Tile turned on. You must set Preserve Volume to a non-zero value to compute this option.
<MaxLiquidSolver>.tensionRadius : floatSets the active distance of Surface Tension in voxels. This distance is computed as a multiple of the Point Radius option, where a value of 2 corresponds to a distance that is two times the point radius.
Foam Volume Behavior Rollup
<MaxLiquidSolver>.snapToSurface : booleanWhen enabled, causes particles to snap back to the surface each frame. Use this setting to keep foam on the surface of the liquid.
<MaxLiquidSolver>.surfaceOffset : floatSets a distance, in voxels, between the liquid surface and the foam particles that are emitted at the liquid surface. When set to a non-zero value, the solver uses the Surface Offset option to determine whether foam particles are below or above the liquid surface.
<MaxLiquidSolver>.preserveVolume : floatApplies a repulsive force to particles when the distance between them is equal to the Point Radius option. Increase this value if you notice foam collapsing rather than dissipating as expected, or if particles are piling up and making the foam too thick.
<MaxLiquidSolver>.pointRadius : floatSets the radius, in voxels, used by the repulsive force applied by the Preserve Volume option. Point Radius does not determine the size of simulated or rendered foam particles.
<MaxLiquidSolver>.overlapPruning : floatDeletes overlapping particles without affecting the overall density of the foam simulation. Use Overlap Pruning to reduce excessive foam particle counts in highly turbid liquids, such as at the bottom of a waterfall, where bursts of foam emission can occur. When set to 0, no particles are deleted. Values closer to 0 allow more particles to overlap before they are deleted. At a value of 1, one out of every two overlapping particles is deleted. The effect of Overlap Pruning intensifies with increasing Point Radius values. The density of the deleted particles is transferred to the remaining foam particles. This means that the foam object's emission and dissipation rates do need to change to maintain overall density of the simulation. Overlap Pruning does not apply when the Compression Model is on.
Foam Wind/Air Parameters Rollup
<MaxLiquidSolver>.airDrag : floatApplies a drag force to foam particles above the liquid surface, which slows down falling particles at a rate relative to their density. Lower density particles are most affected by drag, which causes them to hang in the air longer and behave like mist. Higher density particles are still affected by drag, but tend to be more affected by gravity and behave like spray.
<MaxLiquidSolver>.boundaryDrag : floatApplies a drag force that is strongest where foam particles are not colliding with each other and weakest where they are. This can help to break up clumps of foam above the liquid surface because particles on the outside of the clump experience more drag than particles on the inside. For this attribute to be effective, set Preserve Volume to a non-zero value and make sure Point Radius is large enough for particles to collide.
<MaxLiquidSolver>.foamWindMagnitude : floatSets the amount of wind directed by the wind helper object.
<MaxLiquidSolver>.foamWindDirectionArrowNode : nodeHolds a reference to an arrow helper object in the scene. The orientation of the arrow adjusts the direction of additional velocity.
<MaxLiquidSolver>.airTurbulence: floatSets the magnitude of a turbulence field to be applied to the air velocity, affecting particles above the liquid surface. Note that this controls the speed of the air, while the Air Drag and Boundary Drag options control how strongly particles are affected by the air velocity based on their density.
<MaxLiquidSolver>.airTurbulenceFrequency: floatSets the granularity of the turbulence. Higher values produce smaller, denser vortices.
<MaxLiquidSolver>.airTurbulenceSpeed: floatSets the rate at which the turbulence pattern evolves over time.
Foam Mask Objects
<MaxLiquidSolver>.foamMaskConversionOverrideTab : boolean arrayIndicates whether to override the global parameters for the corresponding emitter in the MaxLiquid.emitter_Meshes array.
<MaxLiquidSolver>.globalFoamMaskMode : integer
<MaxLiquidSolver>.foamMaskConversionOverrideModeTab : int arraySets the foam mask mode, which determines how the foam mask is voxelized, where:
- 0 = Solid
- 1 = Shell
- 2 = Solid (Robust)
<MaxLiquidSolver>.globalFoamMaskEmitterCoarsenInterior : boolean
<MaxLiquidSolver>.foamMaskConversionOverrideCoarsenInteriorTab : boolean array Sets the distance in voxel widths used to close (dilate and then erode) the solid voxels when the conversion mode is Solid (Robust). The internal minimum is 1.0 so that only greater values have an effect. Note that high values can create artifacts.
<MaxLiquidSolver>.globalFoamMaskOffsetSurfaceDistance : float
<MaxLiquidSolver>.foamMaskConversionOverrideOffsetDistanceTab (OverrideOffsetSurfaceDistance) : float arrayThe distance in voxel widths used to close (dilate and then erode) the solid voxels when Mode is Solid (Robust). The internal minimum is 1.0 so only values greater than that have an effect. High values can create artifacts.
<MaxLiquidSolver>.globalFoamMaskThicknessUnits : integer
<MaxLiquidSolver>.foamMaskConversionOverrideThicknessUnitsTab : int arraySets whether thickness is in voxels or world-space units. When set to Voxels, the effective thickness depends on the Base Voxel Size of the simulation. Possible values are:
- 0 = Voxels
- 1 = World Units
<MaxLiquidSolver>.globalFoamMaskThickness : float
<MaxLiquidSolver>.foamMaskConversionOverrideThicknessTab : float arraySets the amount to thicken the mesh. For solid shapes that are already quite thick, you can use 0.0 for a precise boundary or even negative values to shrink along the surface normals. For thinner volumes and shells, you should use larger values to prevent holes.
<MaxLiquidSolver>.foammask_voxelScale : float
<MaxLiquidSolver>.foamMaskConversionOverrideVoxelScaleTab : float arraySets a scaling factor for the Base Voxel Size used to initially voxelize meshes that share this property.
Motion Field Objects
Not implemented.
Caching Tab
See the cache options for the MaxLiquid object.
Display Settings Tab
Liquid Settings Rollup
<MaxLiquidSolver>.displayTypeModeSets the way the liquid mesh is displayed in the viewport, where:
- 0 = Bifrost Dynamic Mesh
- 1 = Bifrost Cache Mesh
- 2 = Point
- 3 = Plane
- 4 = Sphere
- 5 = Custom
- 6 = None
Mesh Settings
<MaxLiquidSolver>.meshing_dropletRevealFactor : float
<MaxLiquidSolver>.meshingDropletRevealFactorTab : float arrayCreates and preserves detail around splashes when generating and smoothing the mesh. Lower values result in smoother meshes, while higher values give more small, higher frequency detail. The slots in the meshingDropletRevealFactorTab correspond to the setting for the index of the matching display type.
<MaxLiquidSolver>.meshing_surfaceRadius : float
<MaxLiquidSolver>.meshingSurfaceRadiusTab : float arrayThe radius of each particle blob used to create the surface, in multiples of the Base Voxel size.
<MaxLiquidSolver>.meshing_dropletRadius : float
<MaxLiquidSolver>.meshingDropletRadiusTab : float arrayThe radius of each droplet, relative to the Base Voxel size.
<MaxLiquidSolver>.meshing_kernelFactor : float
<MaxLiquidSolver>.meshingKernelFactorTab : float arrayControls the width of the surface smoothing kernel. Smaller values give sharper features and higher curvature in the resulting mesh. Larger values result in smoother features.
<MaxLiquidSolver>.meshing_smoothing : integer
<MaxLiquidSolver>.meshingSmoothingTab : int arrayThe number of smoothing steps performed on a mesh.
<MaxLiquidSolver>.meshing_resolutionFactor : float
<MaxLiquidSolver>.meshingResolutionFactorTab : float arrayA scaling factor for adjusting the particle resolution before the mesh is generated. Higher values create more high-frequency detail at a cost of longer calculation times.
<MaxLiquidSolver>.meshing_holeKillThreshold : float
<MaxLiquidSolver>.meshingHoleKillThresholdTab : float arrayIncrease this value to eliminate meshed holes in the interior of the fluid. Such holes can occur especially when using high Resolution Factor values with spacially adaptive simulations.
<MaxLiquidSolver>.meshing_flipFaceNormal : boolean
<MaxLiquidSolver>.meshingFlipFaceNormalTab : boolean arrayWhen true, flips the face normals of the mesh.
Particle Settings
<MaxLiquidSolver>.customNode : nodeHolds the geometry node used as a custom node when the display type is custom.
<MaxLiquidSolver>.colorChannelMode : integerDisplays the specified color channel as a color ramp. This can be useful for previewing or diagnosing your simulation. Possible values are:
- 0 = Static
- 1 = Age
- 2 = Air Distance
- 3 = Churn
- 4 = Curvature
- 5 = Density
- 6 = Droplet
- 7 = Expansion Rate
- 8 = Position
- 9 = Stiction Bandwidth
- 10 = Stiction Strength
- 11 = UV
- 12 = Velocity
- 13 = Vorticity
<MaxLiquidSolver>.staticColor : RGB colorSets the channel color when the colorChannelMode is static.
<MaxLiquidSolver>.colorChannelMin : RGB color
<MaxLiquidSolver>.colorChannelMax : RGB colorSet the minimum and maximum color values for the color ramp.
<MaxLiquidSolver>.opacityChannelMode : integerUses the selected channel to control the fluid opacity in the viewport. Possible values are:
- 0 = Static
- 1 = Age
- 2 = Air Distance
- 3 = Churn
- 4 = Curvature
- 5 = Density
- 6 = Droplet
- 7 = Expansion Rate
- 8 = Position
- 9 = Stiction Bandwidth
- 10 = Stiction Strength
- 11 = UV
- 12 = Velocity
- 13 = Vorticity
<MaxLiquidSolver>.staticOpacity : floatSets the channel color when the opacityChannelMode is static.
<MaxLiquidSolver>.opacityChannelMin : float
<MaxLiquidSolver>.opacityChannelMax : floatSets the minimum and maximum opacity values for the opacity ramp.
<MaxLiquidSolver>.sizeChannelMode : floatUses the specified channel to control the size of the particles in the viewport.
Possible values are:
- 0 = Static
- 1 = Age
- 2 = Air Distance
- 3 = Churn
- 4 = Curvature
- 5 = Density
- 6 = Droplet
- 7 = Expansion Rate
- 8 = Position
- 9 = Stiction Bandwidth
- 10 = Stiction Strength
- 11 = UV
- 12 = Velocity
- 13 = Vorticity
<MaxLiquidSolver>.staticSize : floatSets the particle size when the sizeChannelMode is static.
<MaxLiquidSolver>.sizeChannelMin : float
<MaxLiquidSolver>.sizeChannelMax : floatSets the minimum and maximum size values for the particle size ramp.
Foam Settings
<MaxLiquidSolver>.foamDisplayTypeMode : integerThe foam display type. Possible values are:
- 3 = Point
- 4 = Plane
- 7 = None
<MaxLiquidSolver>.foamColorChannelMode : integerSpecifies the data channel to use as the foam color channel. Possible values are:
- 0 = Static
- 1 = Age
- 2 = Air Distance
- 3 = Churn
- 4 = Curvature
- 5 = Density
- 6 = Droplet
- 7 = Expansion Rate
- 8 = Position
- 9 = Stiction Bandwidth
- 10 = Stiction Strength
- 11 = UV
- 12 = Velocity
- 13 = Vorticity
<MaxLiquidSolver>.foamStaticColor : RGB colorSpecifies the foam color when the foamColorChannelMode is static.
<MaxLiquidSolver>.foamColorChannelMin : RGB color
<MaxLiquidSolver>.foamColorChannelMax : RGB colorSpecifies the minimum and maximum colors to use for the foam color ramp.
<MaxLiquidSolver>.foamOpacityChannelMode : floatUses the specified channel to control the foam opacity in the viewport.
<MaxLiquidSolver>.foamStaticOpacity : floatSpecifies the foam opacity when the foamOpacityChannelMode is static.
<MaxLiquidSolver>.foamOpacityChannelMin : float
<MaxLiquidSolver>.foamOpacityChannelMax : floatSpecifies the minimum and maximum opacity values for the opacity ramp.
<MaxLiquidSolver>.foamSizeChannelMode : floatUses the specified channel to control the foam particle size in the viewport.
<MaxLiquidSolver>.foamStaticSize : floatSpecifies the foam particle size when the foamSizeChannelMode is static.
<MaxLiquidSolver>.foamSizeChannelMin : float
<MaxLiquidSolver>.foamSizeChannelMax : floatSpecifies the minimum and maximum foam particle sizes for the size ramp.
Display
<MaxLiquidSolver>.viewportPercentAccessor : float
<MaxLiquidSolver>.foamViewportPercentAccessor : floatGets or sets the percent of liquid and foam particles visible in the viewport.
Render Settings Tab
Channels Rollup
<MaxLiquidSolver>.renderChannelMapIndex : int array
<MaxLiquidSolver>.renderChannelMapName : string arrayThese arrays contain the channel names and corresponding map channels to be rendered.
Liquid Settings Rollup
<MaxLiquidSolver>.liquidRenderType : integerThe object type to render the liquid as. Possible values are:
- 0 = Cache Mesh
- 1 = Plane
- 2 = Cross
- 3 = Box
- 4 = Sphere
- 5 = Custom
- 6 = Arnold Surface
- 7 = None
<MaxLiquidSolver>.liquidRenderSizeChannel : string
<MaxLiquidSolver>.liquidSizeChannelType : integerSpecifies the name and type of the size channel for rendering.
<MaxLiquidSolver>.liquidRenderStaticSize : floatSpecifies the liquid particle size when the liquidRenderSizeChannel is static.
<MaxLiquidSolver>.liquidRenderSizeMin : float
<MaxLiquidSolver>.liquidRenderSizeMax : float
<MaxLiquidSolver>.liquidRenderSizeMinDomain : float
<MaxLiquidSolver>.liquidRenderSizeMaxDomain : floatSpecifies the minimum and maximum size and size domain for rendered liquid particles.
<MaxLiquidSolver>.liquidCustomRenderNode (LiquidRenderCustomNode) : nodeHolds the scene node used for rendering liquid particles when the liquidRenderType is custom.
Foam Settings Rollup
<MaxLiquidSolver>.foamRenderType : integerThe object type to render the foam as. Possible values are:
- 0 = Arnold Point
- 1 = Plane
- 2 = Cross
- 3 = Box
- 4 = Sphere
- 5 = Custom
- 6 = Arnold Surface
- 7 = None
<MaxLiquidSolver>.foamRenderSizeChannel : string
<MaxLiquidSolver>.foamSizeChannelType : integerThe name and index of the channel used to determine foam particle size in the renderer.
<MaxLiquidSolver>.foamRenderStaticSize : floatThe rendered foam particle size, when foamRenderSizeChannel is static.
<MaxLiquidSolver>.foamRenderSizeMin : float
<MaxLiquidSolver>.foamRenderSizeMax : float
<MaxLiquidSolver>.foamRenderSizeMinDomain : float
<MaxLiquidSolver>.foamRenderSizeMaxDomain : floatSets the minimum and maximum size and size domain for rendered foam particles.
<MaxLiquidSolver>.foamCustomRenderNode (FoamRenderCustomNode) : nodeHolds the custom scene node used as rendered foam particles when the foamRenderType is custom.
Arnold Surface Liquid Render Parameters
These parameters are available when the liquidRenderType is Arnold Surface:
<MaxLiquidSolver>.arnoldSurfaceType : integer
<MaxLiquidSolver>.arnoldRenderComponentType : integer
<MaxLiquidSolver>.arnoldDropletRevealFactor : float
<MaxLiquidSolver>.arnoldSurfaceRadius : float
<MaxLiquidSolver>.arnoldDropletRadius : float
<MaxLiquidSolver>.arnoldResolutionFactor : float
<MaxLiquidSolver>.arnoldHoleKillThreshold : float
<MaxLiquidSolver>.arnoldFilteringDilate : float
<MaxLiquidSolver>.arnoldFilteringSmooth : float
<MaxLiquidSolver>.arnoldFilteringSmoothMode : integer
<MaxLiquidSolver>.arnoldFilteringSmoothIterations : integer
<MaxLiquidSolver>.arnoldFilteringErode : float
<MaxLiquidSolver>.arnoldMeshSubdivisions : integer
<MaxLiquidSolver>.arnoldMeshSmoothing : boolean
<MaxLiquidSolver>.arnoldImplicitStepSize : float
<MaxLiquidSolver>.arnoldImplicitSamples : integer Arnold Point Foam Settings
The following parameters are available when the foamRenderType is Arnold Point:
<MaxLiquidSolver>.arnoldPointRadiusChannel : integer
<MaxLiquidSolver>.arnoldPointRadius : float
<MaxLiquidSolver>.arnoldPointStepSize : float
<MaxLiquidSolver>.arnoldPointChunkSize : integerArnold Surface Foam Settings
The following parameters are available when the foamRenderType is Arnold Surface:
<MaxLiquidSolver>.arnoldFoamSurfaceType : integer
<MaxLiquidSolver>.arnoldFoamDropletRevealFactor : float
<MaxLiquidSolver>.arnoldFoamSurfaceRadius : float
<MaxLiquidSolver>.arnoldFoamDropletRadius : float
<MaxLiquidSolver>.arnoldFoamResolutionFactor : float
<MaxLiquidSolver>.arnoldFoamHoleKillThreshold : float
<MaxLiquidSolver>.arnoldFoamFilteringDilate : float
<MaxLiquidSolver>.arnoldFoamFilteringSmoothMode : integer
<MaxLiquidSolver>.arnoldFoamFilteringSmoothIterations : integer
<MaxLiquidSolver>.arnoldFoamFilteringErode : float
<MaxLiquidSolver>.arnoldFoamMeshSubdivisions : integer
<MaxLiquidSolver>.arnoldFoamMeshSmoothing : boolean
<MaxLiquidSolver>.arnoldFoamImplicitStepSize : float
<MaxLiquidSolver>.arnoldFoamImplicitSamples : integer
MaxLiquidSolver interfaces
Interface: MaxFluidLiquidSolver
Properties:
Methods:
<boolean>RunSolve()Runs the current solve.
<boolean>PauseSolve <boolean>waitPauses the current solve, if it is running. If wait is true, the call waits to return until the solver has actually paused. This parameter should always be true.
<boolean>StopSolve <boolean>waitStops the current solve, if it is running. If wait is true, the call waits to return until the solver has actually stopped. This parameter should always be true.
<boolean>IsSolveRunning()Returns true if the solve is running.
<boolean>ExportSolve <integer>startFrame <integer>endFrame <string>filenameExports the current solve settings and sets the start and end frames to the specified file. The file is saved to the current path if an absolute path is not specified.
<boolean>ImportAndRunSolve <string>filenameImports and runs the solve settings from the specified file.
<boolean>RenameSolve <string>nameRenames the solve to the specified name.
<void>ClearCaches <boolean>liquid <boolean>foam <boolean>meshClears the caches for those caches specified as true.
<void>ClearStaleCaches()Clears any stale caches. Any cache with a timestamp older than the liquid cache is considered "stale", since all cache states depend on the liquid cache, and should be calculated after it has been created.
<boolean>GetCacheMesh <integer>frame <&mesh>meshOut
meshOut is In and Out parameterGets the cache mesh for the specified frame.
<boolean>GetDynamicMesh <integer>frame <enum>meshOrFoam <&mesh>meshOut
meshOrFoam enums: {#liquid|#foam}
meshOut is In and Out parameterGets the dynamic mesh for the specified frame for either liquid or foam, specified by the meshOrFoam parameter.
<boolean>ImportSolveTest <string>filenameImports a test file and runs the solve. This is for internal use only.
<Interface>GetParticleCache <enum>type
type enums: {#liquid|#foam}Gets the particle cache for the specified type, liquid or foam. See ParticleCache for the properties and methods implemented by this interface.
<void>AddMeshChannel <string>name <integer>mapChannelIndexAdds a channel to the simulation's render settings, using the given name and map index. Note: the name must match an existing channel type, which is one of:
- age
- airDistance
- churn
- curvature
- density
- droplet
- expansionRate
- position
- stictionBandwith
- stictionStrength
- uv
- velocity
- vorticity
<void>DeleteMeshChannel <string>nameDeletes the channel from the simulation's render settings with the matching name.
<boolean>FrameStatus <integer>frameReturns true if there is simulation data for the specified frame.
Actions:
