|
MaxUSDAPI | MappedAttributeBuilder (MeshFacade &maxMesh, std::shared_ptr< MappedData > data) |
| Constructor. More...
|
|
MaxUSDAPI | MappedAttributeBuilder (MeshFacade &&maxMesh, std::shared_ptr< MappedData > data) |
| Constructor. This overload was added to allow passing a temporary MeshFacade as parameter.
|
|
MaxUSDAPI bool | BuildPrimvar (pxr::UsdGeomMesh &target, const Config &config, const pxr::UsdTimeCode &timeCode, bool animated) const |
| Creates a new primvar onto the target USD mesh and populate it with the the mapped data. More...
|
|
MaxUSDAPI bool | PopulateAttribute (pxr::UsdAttribute &attribute, const DataLayout &layout, pxr::UsdGeomPrimvar *primvar, const pxr::UsdTimeCode &timeCode) const |
| Populates a given attribute with the mapped data. More...
|
|
MaxUSDAPI DataLayout | InferAttributeDataLayout () const |
| Infers the data layout i.e. the interpolation scheme and whether it should be indexed or not. More...
|
|
|
static MaxUSDAPI pxr::SdfValueTypeName | GetValueTypeName (const Type &type) |
| Returns the SdfValueTypeName associated with this type. More...
|
|
static MaxUSDAPI size_t | GetTypeDimension (const Type &type) |
| Returns the dimension of the given type. More...
|
|
static MaxUSDAPI Type | GetEquivalentType (const Type &type, int dimension) |
| Returns a type equivalent to the given type for a given dimension. For example the equivalent to texcoord2farray for 3 dimensions would be texcoord3farray. When no direct equivalent exists, return a float array of the requested dimension. If an unkown type, fallback to float3Array. More...
|
|
◆ MappedAttributeBuilder()
MaxUSDAPI MAXUSD_NS_DEF::MappedAttributeBuilder::MappedAttributeBuilder |
( |
MeshFacade & |
maxMesh, |
|
|
std::shared_ptr< MappedData > |
data |
|
) |
| |
Constructor.
- Parameters
-
maxMesh | The max mesh on which the data is mapped. |
data | The mapped data. |
◆ BuildPrimvar()
MaxUSDAPI bool MAXUSD_NS_DEF::MappedAttributeBuilder::BuildPrimvar |
( |
pxr::UsdGeomMesh & |
target, |
|
|
const Config & |
config, |
|
|
const pxr::UsdTimeCode & |
timeCode, |
|
|
bool |
animated |
|
) |
| const |
Creates a new primvar onto the target USD mesh and populate it with the the mapped data.
- Parameters
-
target | The target USD mesh where to create the new primvar. |
config | The configuration for the new primvar. |
timeCode | The timecode at which to set the data. |
animated | Whether or not the primvar is intended to be animated. |
- Returns
- True on success, false otherwise.
◆ GetEquivalentType()
static MaxUSDAPI Type MAXUSD_NS_DEF::MappedAttributeBuilder::GetEquivalentType |
( |
const Type & |
type, |
|
|
int |
dimension |
|
) |
| |
|
static |
Returns a type equivalent to the given type for a given dimension. For example the equivalent to texcoord2farray for 3 dimensions would be texcoord3farray. When no direct equivalent exists, return a float array of the requested dimension. If an unkown type, fallback to float3Array.
- Parameters
-
type | The type for which to get an equivalent type. |
dimension | The required dimension of the equivalent type. Should be 1, 2, or 3, any other value will be clamped in that range. |
- Returns
- The equivalent type in the given dimension.
◆ GetTypeDimension()
static MaxUSDAPI size_t MAXUSD_NS_DEF::MappedAttributeBuilder::GetTypeDimension |
( |
const Type & |
type | ) |
|
|
static |
Returns the dimension of the given type.
- Parameters
-
type | The type for which to get the dimension. |
- Returns
- The dimension of the type.
◆ GetValueTypeName()
static MaxUSDAPI pxr::SdfValueTypeName MAXUSD_NS_DEF::MappedAttributeBuilder::GetValueTypeName |
( |
const Type & |
type | ) |
|
|
static |
Returns the SdfValueTypeName associated with this type.
- Parameters
-
type | The type for which to get the name. |
- Returns
- The value type name.
◆ InferAttributeDataLayout()
MaxUSDAPI DataLayout MAXUSD_NS_DEF::MappedAttributeBuilder::InferAttributeDataLayout |
( |
| ) |
const |
Infers the data layout i.e. the interpolation scheme and whether it should be indexed or not.
- Returns
- The inferred data layout.
◆ PopulateAttribute()
MaxUSDAPI bool MAXUSD_NS_DEF::MappedAttributeBuilder::PopulateAttribute |
( |
pxr::UsdAttribute & |
attribute, |
|
|
const DataLayout & |
layout, |
|
|
pxr::UsdGeomPrimvar * |
primvar, |
|
|
const pxr::UsdTimeCode & |
timeCode |
|
) |
| const |
Populates a given attribute with the mapped data.
- Parameters
-
attribute | The attribute to populate. |
primvar | The primvar associated with the attribute, null if the attribute is not owned by a primvar. |
layout | The data layout (interpolation scheme and whether indexing is used) |
timeCode | The timecode at which to populate the attribute. |
- Returns
- True on success, false otherwise.
The documentation for this class was generated from the following file: