Go to: Synopsis. Return value. Keywords. Flags. Python examples.
fluidCacheInfo([attribute=string], [cacheTime=time], [endFrame=boolean], [hasCache=boolean], [hasData=boolean], [initialConditions=boolean], [playback=boolean], [resolution=boolean], [startFrame=boolean])
Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.
fluidCacheInfo is undoable, queryable, and editable.
A command to get information about the fluids cache.
Get the startFrame and resolution for InitialConditions.
Get the endFrame as well for a playback cache.
Note that for the playback cache, it will look at the current time
(or last frame if the current time is past end of cache)
None
In query mode, return type is based on queried flag.
fluid
attribute, cacheTime, endFrame, hasCache, hasData, initialConditions, playback, resolution, startFrame
Long name (short name) |
Argument types |
Properties |
attribute(at)
|
string
|
|
|
Modifier to the "hasData" flag, used to query whether a
cache has data (at the current time)
for a specific fluid attribute. Valid attribute
values are "density", "velocity", "temperature", "fuel", "color",
"coordinates" (for texture coordinates), "falloff".
|
|
cacheTime(t)
|
time
|
|
|
Only valid with the -hasData flag. The time the -hasData flag
uses when it queries the cache to see if there is data.
|
|
endFrame(ef)
|
boolean
|
|
|
Returns end time of cache as float.
|
|
hasCache(hc)
|
boolean
|
|
|
Returns true if fluid has specified cache, false if not.
|
|
hasData(hd)
|
boolean
|
|
|
Queries whether a given cache has data in it at the time specified
by the -time flag. (If not -time flag is present, -hasData assumes
the current time.)
When used with
the "attribute" flag, indicates if data for the specified attribute
exists in the cache. When used without the "attribute" flag, "hasData"
indicates whether there is data in the cache for any of the valid
fluid attributes.
|
|
initialConditions(ic)
|
boolean
|
|
|
Specifies the cache to be queried is the "Initial Conditions" cache.
|
|
playback(pb)
|
boolean
|
|
|
Specifies the cache to be queried is the "Playback" cache.
|
|
resolution(re)
|
boolean
|
|
|
Returns cache resolution as float[].
|
|
startFrame(sf)
|
boolean
|
|
|
Returns start time for cache as float.
|
|
Flag can appear in Create mode of command
|
Flag can appear in Edit mode of command
|
Flag can appear in Query mode of command
|
Flag can have multiple arguments, passed either as a tuple or a list.
|
import maya.cmds as cmds
# get start frame for Initial Conditions Cache
cmds.fluidCacheInfo( ic=True, sf=True )
# get resolution for Initial Conditions Cache
cmds.fluidCacheInfo( ic=True, re=True )
# get end frame for Playback Cache
cmds.fluidCacheInfo( pb=True, ef=True )
# get resolution for Playback Cache
cmds.fluidCacheInfo( pb=True, re=True )
# Is there data for any of the valid properties
# in the playback cache?
cmds.fluidCacheInfo( pb=True, hd=True )
# Is there density data in the playback cache?
cmds.fluidCacheInfo( at='density', pb=True, hd=True )