OpenVDBAsset
A Field representing an OpenVDB volume grid. See the OpenVDB website for more information on OpenVDB.
An example OpenVDBAsset referencing a single density field in a .vdb file:
def OpenVDBAsset "densityVDB"
{
token fieldDataType = "float"
int fieldIndex.timeSamples = {
10: 0,
}
token fieldName = "density"
asset filePath.timeSamples = {
10: @/vdb_test_data/grids.vdb@,
}
}
The FieldAsset filePath
attribute must specify a file in the OpenVDB (.vdb)
format on disk.
Properties
fieldClass
USD type: token
Represents the class of an indivdual grid. This attribute is optional.
This is a mapping to OpenVDB’s openvdb::GridClass where the values are
GRID_LEVEL_SET
, GRID_FOG_VOLUME
, GRID_STAGGERED
, and GRID_UNKNOWN
.
Inherited Properties (FieldAsset)
fieldDataType
USD type: token
The data type of a field, such as “float”.
Use this attribute to tell consumers more about the field without requiring the consumer access the asset file directly. The list of allowed tokens reflects the available choices for OpenVDB volumes.
fieldIndex
USD type: int
The index of a field within a FieldAsset asset file. This attribute is optional.
An asset file can contain multiple fields with the same name. This optional
attribute is an index used to disambiguate between multiple fields with the same
name. For example, in an OpenVDB file asset, there might be two Grids named
“density”. A fieldIndex
of 0 would specify that this Field refers to the first
“density” Grid.
fieldName
USD type: token
Represents the name of an individual field within a FieldAsset asset file.
A FieldAsset file asset may contain multiple fields in a single asset file. This
attribute specifies the name of field within the asset file. For example, an
OpenVDB file asset might have multiple named Grids, such as “density”,
“temperature”, etc. fieldName
would specify one of the named Grids in the
OpenVDB file asset.
Note that a Volume also provides a way to specify the “name” for a field, via
the field relationship. This name is not associated with asset data and is used
by the Volume for organizing fields for the rendering pipeline. See
Understanding fieldName and the Field’s Relationship Name for more details on how the field’s
relationship name differs from fieldName
.
filePath
USD type: asset
An asset path attribute that points to a file on disk.
The asset pointed to by filePath must be a file type that the FieldAsset-derived schema supports. For example, for OpenVDBAsset, the file type must be an OpenVDB (.vdb) file. For Field3DAsset, the file type must be a Field3D (.f3d) file.
This attribute’s value can be animated over time, as most volume asset formats represent just a single timeSample of a volume. However, it does not, at this time, support any pattern substitutions like “$F”.
See Using Animated Field Data for an example of using filePath
to refer to animated volumetric data.
vectorDataRoleHint
USD type: token
Fallback value: None
Specifies the role of a vector valued field, such as “Color”. This can drive the data type in which fields are made available in a renderer or whether the vector values are to be transformed. This attribute is optional.
This token can drive the data type in which fields are made available in a
renderer or whether the vector values are to be transformed. Allowed tokens
include None
, Point
, Normal
, Vector
, and Color
.
Inherited Properties (Xformable)
xformOpOrder
USD type: token[]
Inherited Properties (Imageable)
proxyPrim
USD type: rel
(relationship)
purpose
USD type: token
Fallback value: default
visibility
USD type: token
Fallback value: inherited