FluidLoader : GeometryClass {6dad24c7,885cba23}: This class exposes the functionality of the Fluid Loader geometry object. Available in 3ds Max 2019.2 Update and higher.
This class is exposed but not implemented in 3ds Max 2018.4 to 3ds Max 2019.1 Update.
Constructor
FluidLoader()
BifLoader()
Properties
This class has many properties. They are organized here according to their order of appearance on the Simulation View dialog.
<FluidLoader>.showIcon Integer default: 1 -- integerIndicates whether to show the Fluid Loader icon in the viewport, where 0 = false (don't show) and 1 = true (show).
<FluidLoader>.iconSize Float default: 10.0 -- worldUnitsThe size of the FluidLoader icon in the viewport, in world units.
<FluidLoader>.cacheFlagsTab ArrayParameter default: #() -- int array; SubAnimAn array of integers that specify how the corresponding cache file (by index) is used and displayed, where:
<FluidLoader>.cacheNameTab ArrayParameter default: #() -- string array; SubAnimAn array that contains the names of the caches loaded by the FluidLoader. These are the files that appear under the Cache Files list on the Loader Properties tab of the Simulation View dialog.
<FluidLoader>.cacheTab ArrayParameter default: #() -- string array; SubAnimAn array that contains the full paths, including the first cache file name, for the caches loaded by the Fluid Loader.
<FluidLoader>.materialID_Tab ArrayParameter default: #() -- int array; SubAnimAn array of material IDs associated with the loaded caches, where the index of the material ID corresponds with the index of the cache in cacheTab.
<FluidLoader>.materialIDIndirect Integer default: 0 -- integerContains the material ID for the cache currently selected in the UI.
<FluidLoader>.playbackMode_Tab ArrayParameter default: #() -- int array; SubAnimAn array that contains the Cache Playback setting for the loaded caches, where the index of the playback mode corresponds with the index of the cache in cacheTab.
Possible values are:
<FluidLoader>.playbackModeIndirect Integer default: 0 -- integerThe playback mode for the currently selected cache.
<FluidLoader>.useLoaderObjectTransform BooleanClass default: true -- booleanIndicates whether the loader object transform is used. When true, all the cache files are offset by the transform .
<FluidLoader>.startFrame_Tab ArrayParameter default: #() -- int array; SubAnim
<FluidLoader>.endFrame_Tab ArrayParameter default: #() -- int array; SubAnimArrays that contains the start frame number and end fram number, for caches that have the Cache Playback (playbackMode_Tab) set to Custom Range. The index of the frame setting corresponds to the cache index in cacheTab.
<FluidLoader>.startFrameIndirect Integer default: 0 -- integer
<FluidLoader>.endFrameIndirect Integer default: 0 -- integerThe Start Frame and End Frame setting for the currently selected cache. This property only applies when the Cache Playback mode is Custom Range.
<FluidLoader>.startOnly_Tab ArrayParameter default: #() -- int array; SubAnimAn array that contains the start frame number, for caches that have the Cache Playback (playbackMode_Tab) set to Custom Start. The index of the start frame setting corresponds to the cache index in cacheTab.
<FluidLoader>.startOnlyIndirect Integer default: 0 -- integerThe Start Frame setting for the currently selected cache. This property only applies when the Cache Playback mode is Custom Start.
<FluidLoader>.playbackFrame_Tab ArrayParameter default: #() -- int array; SubAnimAn array that contains the start frame number, for caches that have the Cache Playback (playbackMode_Tab) set to Playback Graph. The index of the start frame setting corresponds to the cache index in cacheTab.
<FluidLoader>.playbackFrameIndirect Integer default: 0 -- animatable; integer; PlaybackFrameThe Start Frame setting for the currently selected cache. This property only applies when the Cache Playback mode is Playback Graph.
<FluidLoader>.displayCacheLimitEnable BooleanClass default: true -- booleanIndicates whether the cache size limit is turned on or off.
<FluidLoader>.displayCacheLimit Float default: 8.0 -- floatThe maximum amount of memory the cache can use, in GB.
<FluidLoader>.displayTypeMode Integer default: 3 -- integerThe liquid display type, where:
Mesh Settings
These settings apply when the displayTypeMode is 0 (Bifrost Dynamic Mesh).
The *Accessor property gets or sets the value for the currently selected cache, while the *Tab property corresponds to the cache with the same index in the cacheTab.
<FluidLoader>.meshingDropletRevealFactorAccessor Float default: 0.0 -- float
<FluidLoader>.meshingDropletRevealFactorTab ArrayParameter default: #(3.0) -- float array; SubAnimCreates 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.
<FluidLoader>.meshingSurfaceRadiusAccessor Float default: 0.0 -- float
<FluidLoader>.meshingSurfaceRadiusTab ArrayParameter default: #(1.4) -- float array; SubAnimThe radius of each particle blob used to create the surface, in multiples of the Base Voxel size.
<FluidLoader>.meshingDropletRadiusAccessor Float default: 0.0 -- float
<FluidLoader>.meshingDropletRadiusTab ArrayParameter default: #(1.2) -- float array; SubAnimThe radius of each droplet, relative to the Base Voxel size.
<FluidLoader>.meshingKernelFactorAccessor Float default: 0.0 -- float
<FluidLoader>.meshingKernelFactorTab ArrayParameter default: #(2.0) -- float array; SubAnimControls 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.
<FluidLoader>.meshingSmoothingAccessor Integer default: 0 -- integer
<FluidLoader>.meshingSmoothingTab ArrayParameter default: #(3) -- int array; SubAnimThe number of smoothing steps performed on a mesh.
<FluidLoader>.meshingResolutionFactorAccessor Float default: 0.0 -- float
<FluidLoader>.meshingResolutionFactorTab ArrayParameter default: #(1.0) -- float array; SubAnimA 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.
<FluidLoader>.meshingHoleKillThresholdAccessor Float default: 0.0 -- float
<FluidLoader>.meshingHoleKillThresholdTab ArrayParameter default: #(0.0) -- float array; SubAnimIncrease 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.
<FluidLoader>.meshingFlipFaceNormalAccessor BooleanClass default: false -- boolean
<FluidLoader>.meshingFlipFaceNormalTab ArrayParameter default: #(false) -- boolean array; SubAnimWhen true, flips the face normals of the mesh.
Particle Settings
These settings apply with the displayType is any value other than 0 (Bifrost Dynamic Mesh) and 7 (None).
<FluidLoader>.customNode UndefinedClass default: undefined -- nodeThe custom node to use as particles for display when the displayTypeMode is 6 (Custom).
<FluidLoader>.colorChannelMode Integer default: 13 -- integerThe channel that drives the fluid color. This property can be:
<FluidLoader>.colorChannelMax Color default: (color 51.9945 223.992 255) -- RGB color
<FluidLoader>.colorChannelMin Color default: (color 0 27.999 255) -- RGB colorThe color used to indicate minimum and maximum values for the data in the displayed channel, when the colorChannelMode is not "static" (0).
<FluidLoader>.staticColor Color default: (color 0 27.999 255) -- RGB colorThe color used when the colorChannelMode is 0 (static).
<FluidLoader>.opacityChannelMode Float default: 0.0 -- floatThe channel that drives the fluid opacity. This property can be:
<FluidLoader>.opacityChannelMax Float default: 1.0 -- float
<FluidLoader>.opacityChannelMin Float default: 0.0 -- floatThe opacity used to indicate minimum and maximum values for the data in the displayed channel, when the opacityChannelMode is not "static" (0).
<FluidLoader>.staticOpacity Float default: 1.0 -- floatThe opacity to use when opacityChannelMode is 0 ("static").
<FluidLoader>.sizeChannelMode Float default: 0.0 -- floatThe channel that drives the fluid particle size. This property can be:
<FluidLoader>.sizeChannelMax Float default: 1.0 -- float
<FluidLoader>.sizeChannelMin Float default: 0.0 -- floatThe opacity used to indicate minimum and maximum values for the data in the displayed channel, when the sizeChannelMode is not 0 (Static).
<FluidLoader>.staticSize Float default: 1.0 -- floatThe liquid particle size used when the sizeChannelMode is 0 (Static).
Display
<FluidLoader>.viewportPercentAccessor Float default: 100.0 -- floatThe percent of total liquid particles to display in the viewport.
<FluidLoader>.foamDisplayTypeMode Integer default: 3 -- integerThe Foam Display Type, where:
<FluidLoader>.foamColorChannelMode Integer default: 0 -- integerIndicates the data channel to use to drive color, where:
<FluidLoader>.foamColorChannelMin Color default: (color 255 255 255) -- RGB color
<FluidLoader>.foamColorChannelMax Color default: (color 47.991 47.991 47.991) -- RGB colorThe minimum and maximum color values to use to drive the foam color, when the foamColorChannelMode is not 0 (static).
<FluidLoader>.foamStaticColor Color default: (color 255 255 255) -- RGB colorThe foam color to use when foamColorChannelMode is 0 (static).
<FluidLoader>.foamOpacityChannelMode Integer default: 0 -- integerThe data channel used to drive foam opacity in the viewport display, where:
<FluidLoader>.foamOpacityChannelMin Float default: 0.0 -- float
<FluidLoader>.foamOpacityChannelMax Float default: 1.0 -- floatThe minimum and maximum opacity to use, when the foamOpacityChannelMode is not 0 (static).
<FluidLoader>.foamStaticOpacity Float default: 1.0 -- floatThe foam opacity to use when foamOpacityChannelMode is 0 (static).
<FluidLoader>.foamSizeChannelMode Integer default: 5 -- integerIndicates the data channel to use to drive the foam particle size where:
<FluidLoader>.foamSizeChannelMax Float default: 1.0 -- float
<FluidLoader>.foamSizeChannelMin Float default: 0.0 -- floatThe minimum and maximum size range to use, when foamSizeChannelMode is not 0 (static).
<FluidLoader>.foamStaticSize Float default: 1.0 -- floatThe foam particle size to use, when foamSizeChannelMode is 0 (static).
Display
<FluidLoader>.foamViewportPercentAccessor Float default: 100.0 -- floatThe percent of total foam particles to display in the viewport.
<FluidLoader>.renderChannelMapIndex ArrayParameter default: #(2) -- int array; SubAnimAn array that contains the indices of render channels for the Fluid Loader. This corresponds to the channels listed under Add Channels on the Render Settings tab.
<FluidLoader>.renderChannelMapName ArrayParameter default: #("velocity") -- string array; SubAnimAn array that contains the names of render channels for the Fluid Loader. This corresponds to the channels listed under Add Channels on the Render Settings tab.
<FluidLoader>.liquidRenderType Integer default: 6 -- integerThe Render As setting, where:
<FluidLoader>.liquidRenderSizeChannel String default: "Static" -- string
<FluidLoader>.liquidSizeChannelType Integer default: 0 -- integerSpecifies the name and type of the size channel for rendering.
<FluidLoader>.liquidRenderStaticSize Float default: 1.0 -- floatSpecifies the liquid particle size when the liquidRenderSizeChannel is static.
<FluidLoader>.liquidRenderSizeMax Float default: 1.0 -- float
<FluidLoader>.liquidRenderSizeMin Float default: 0.0 -- float
<FluidLoader>.liquidRenderSizeMaxDomain Float default: 1.0 -- float
<FluidLoader>.liquidRenderSizeMinDomain Float default: 0.0 -- floatSpecifies the minimum and maximum size and size domain for rendered liquid particles.
<FluidLoader>.liquidCustomRenderNode UndefinedClass default: undefined -- node; LiquidRenderCustomNodeHolds the scene node used for rendering liquid particles when the liquidRenderType is custom.
<FluidLoader>.foamRenderType Integer default: 0 -- integer; LiquidRenderTypeThe foam Render As setting, where:
<FluidLoader>.foamRenderSizeChannel String default: "Static" -- string
<FluidLoader>.foamSizeChannelType Integer default: 0 -- integerThe channel to use for size data when the Render As setting is Plane, Cross, Box, Sphere, or Custom.
The foamSizeChannelType can be:
<FluidLoader>.foamRenderStaticSize Float default: 1.0 -- floatThe foam particle size to use when the foamSizeChannelType is 0 (Static).
<FluidLoader>.foamRenderSizeMax Float default: 1.0 -- float
<FluidLoader>.foamRenderSizeMin Float default: 0.0 -- floatThe range of foam particle sizes to use.
<FluidLoader>.foamRenderSizeMaxDomain Float default: 1.0 -- float
<FluidLoader>.foamRenderSizeMinDomain Float default: 0.0 -- floatThe range of foam domain sizes to use.
<FluidLoader>.foamCustomRenderNode UndefinedClass default: undefined -- nodeCustom node to use to redner the foam mesh when foamRenderType = 5 (Custom).
These parameters are available when the liquidRenderType is Arnold Surface:
<FluidLoader>.arnoldSurfaceType : integer
<FluidLoader>.arnoldRenderComponentType : integer
<FluidLoader>.arnoldDropletRevealFactor : float
<FluidLoader>.arnoldSurfaceRadius : float
<FluidLoader>.arnoldDropletRadius : float
<FluidLoader>.arnoldResolutionFactor : float
<FluidLoader>.arnoldHoleKillThreshold : float
<FluidLoader>.arnoldFilteringDilate : float
<FluidLoader>.arnoldFilteringSmooth : float
<FluidLoader>.arnoldFilteringSmoothMode : integer
<FluidLoader>.arnoldFilteringSmoothIterations : integer
<FluidLoader>.arnoldFilteringErode : float
<FluidLoader>.arnoldMeshSubdivisions : integer
<FluidLoader>.arnoldMeshSmoothing : boolean
<FluidLoader>.arnoldImplicitStepSize : float
<FluidLoader>.arnoldImplicitSamples : integerArnold Point Foam Settings
The following parameters are available when the foamRenderType is Arnold Point:
<FluidLoader>.arnoldPointRadiusChannel : integer
<FluidLoader>.arnoldPointRadius : float
<FluidLoader>.arnoldPointStepSize : float
<FluidLoader>.arnoldPointChunkSize : integerArnold Surface Foam Settings
The following parameters are available when the foamRenderType is Arnold Surface:
<FluidLoader>.arnoldFoamSurfaceType : integer
<FluidLoader>.arnoldFoamDropletRevealFactor : float
<FluidLoader>.arnoldFoamSurfaceRadius : float
<FluidLoader>.arnoldFoamDropletRadius : float
<FluidLoader>.arnoldFoamResolutionFactor : float
<FluidLoader>.arnoldFoamHoleKillThreshold : float
<FluidLoader>.arnoldFoamFilteringDilate : float
<FluidLoader>.arnoldFoamFilteringSmooth Float default: 1.0 -- float
<FluidLoader>.arnoldFoamFilteringSmoothMode : integer
<FluidLoader>.arnoldFoamFilteringSmoothIterations : integer
<FluidLoader>.arnoldFoamFilteringErode : float
<FluidLoader>.arnoldFoamMeshSubdivisions : integer
<FluidLoader>.arnoldFoamMeshSmoothing : boolean
<FluidLoader>.arnoldFoamImplicitStepSize : float
<FluidLoader>.arnoldFoamImplicitSamples : integer
Properties not exposed in the UI
<FluidLoader>.enableGPUPoints BooleanClass default: true -- booleanIndicates whether points are rendered in the GPU. Standard points only have eight sizes and render slower. This property is on by default.
Interfaces
Interface: FluidLoaderObject id:{0x036af2c15,0x01d077672}
Properties
None
Methods
<boolean>AddCache <string>path <&index>index
index is Out parameterAdds the cache specified by a full path to the FluidLoader. Note that the path can either be to a file in the cache, or the cache directory itself. The index of the cache in the array of caches (the .cacheTab property) is returned in the by reference parameter index.
<boolean>RemoveCache <index>indexRemoves the cache at the specified index from the list of caches (the .cacheTab property). Note that this list is 1-based. Returns true if successful, false if not (eg, the index does not exist).
<integer>NumberCaches()Returns the number of caches in the FluidLoader.
<boolean>GetCacheIndex <string>name <&index>index
index is Out parameterReturns the index of the cache specified by name in the by-reference index parameter. Returns true if the named cache exists, false if not.
<boolean>GetPathAndFile <index>index <&string>path
path is Out parameterReturns the full path to the cache in the by-reference parameter path, at the specified by index. Note that this only returns the path, not the file name. Returns true if the index exists, false if not.
<boolean>GetCacheName <index>index <&string>name
name is Out parameterReturns the cache name in the by-reference parameter name, at the specified by index. Note that this is the name displayed in the Simulation View UI, not the cache file name or path. Returns true if the index exists, false if not.
<boolean>SetCacheName <index>index <string>nameSets the cache name at the specified by index to the specified name. Note that this is the name displayed in the Simulation View UI, not the cache file name or path. Returns true if the index exists, false if not.
<boolean>GetCachePath <index>index <&string>path
path is Out parameterReturns the full path and file name in the by-reference parameter path for the specified cache index. Returns true if the index exists, false if not.
<boolean>GetCacheType <index>index <&enum>type
type enums: {#unknown|#liquid|#smoke|#foam|#mesh}
type is Out parameterReturns the cache type in the by-reference parameter type for the specified cache index. Returns true if the index exists, false if not.
<boolean>GetCacheRange <index>index <&integer>start <&integer>end
start is Out parameter
end is Out parameterReturns the frame range for the cache at the specified index in the by-reference start and end parameters. Returns true if the index exists, false if not.
<boolean>GetCacheEnable <index>index <&boolean>enable
enable is Out parameter
<boolean>SetCacheEnable <index>index <boolean>enableGets or sets the enabled property for the cache at the specified index. This property is displayed in the Simulation View UI as the Use checkbox. Returns true if the index exists, false if not.
<boolean>GetCacheDisplay <index>index <&boolean>display
display is Out parameter
<boolean>SetCacheDisplay <index>index <boolean>displayGets or sets the display property for the cache at the specified index. This property determines whether the cache is displayed in the viewport. Returns true if the index exists, false if not.
<boolean>GetCacheMatID <index>index <&index>matID
matID is Out parameter
<boolean>SetCacheMatID <index>index <index>matIDGets or sets the material ID for the cache at the specified index. Returns true if the index exists, false if not.
<boolean>GetCachePlaybackMode <index>index <&enum>mode
mode enums: {#originalRange|#customStart|#customRange|#playbackGraph}
mode is Out parameter
<boolean>SetCachePlaybackMode <index>index <enum>mode
mode enums: {#originalRange|#customStart|#customRange|#playbackGraph}Gets or sets the playback mode for the cache at the specified index. Returns true if the index exists, false if not.
Actions
None