PhysX material extended parameters. More...
Inherits UsdAPISchemaBase.
Public Member Functions | |
PhysxSchemaPhysxMaterialAPI (const UsdPrim &prim=UsdPrim()) | |
Construct a PhysxSchemaPhysxMaterialAPI on UsdPrim prim . More... | |
PhysxSchemaPhysxMaterialAPI (const UsdSchemaBase &schemaObj) | |
Construct a PhysxSchemaPhysxMaterialAPI on the prim held by schemaObj . More... | |
virtual PHYSXSCHEMA_API | ~PhysxSchemaPhysxMaterialAPI () |
Destructor. More... | |
PHYSXSCHEMA_API UsdAttribute | GetFrictionCombineModeAttr () const |
Determines the way in which two material properties will be combined to yield a friction coefficient for a collision. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateFrictionCombineModeAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetFrictionCombineModeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
PHYSXSCHEMA_API UsdAttribute | GetRestitutionCombineModeAttr () const |
Determines the way in which two material properties will be combined to yield a restitution coefficient for a collision. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateRestitutionCombineModeAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetRestitutionCombineModeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
PHYSXSCHEMA_API UsdAttribute | GetDampingCombineModeAttr () const |
Determines the way in which two material properties will be combined to yield a damping coefficient for a collision. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateDampingCombineModeAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetDampingCombineModeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
PHYSXSCHEMA_API UsdAttribute | GetImprovePatchFrictionAttr () const |
Deprecated. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateImprovePatchFrictionAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetImprovePatchFrictionAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
PHYSXSCHEMA_API UsdAttribute | GetCompliantContactAccelerationSpringAttr () const |
If enabled, switches from force-based to acceleration-based compliant spring-damper contact effects. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateCompliantContactAccelerationSpringAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetCompliantContactAccelerationSpringAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
PHYSXSCHEMA_API UsdAttribute | GetCompliantContactStiffnessAttr () const |
Spring stiffness for a compliant contact model using implicit springs. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateCompliantContactStiffnessAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetCompliantContactStiffnessAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
PHYSXSCHEMA_API UsdAttribute | GetCompliantContactDampingAttr () const |
Damping coefficient for a compliant contact model using implicit springs. More... | |
PHYSXSCHEMA_API UsdAttribute | CreateCompliantContactDampingAttr (VtValue const &defaultValue=VtValue(), bool writeSparsely=false) const |
See GetCompliantContactDampingAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create. More... | |
Static Public Member Functions | |
static PHYSXSCHEMA_API const TfTokenVector & | GetSchemaAttributeNames (bool includeInherited=true) |
Return a vector of names of all pre-declared attributes for this schema class and all its ancestor classes. More... | |
static PHYSXSCHEMA_API PhysxSchemaPhysxMaterialAPI | Get (const UsdStagePtr &stage, const SdfPath &path) |
Return a PhysxSchemaPhysxMaterialAPI holding the prim adhering to this schema at path on stage . More... | |
static PHYSXSCHEMA_API bool | CanApply (const UsdPrim &prim, std::string *whyNot=nullptr) |
Returns true if this single-apply API schema can be applied to the given prim . More... | |
static PHYSXSCHEMA_API PhysxSchemaPhysxMaterialAPI | Apply (const UsdPrim &prim) |
Applies this single-apply API schema to the given prim . More... | |
Static Public Attributes | |
static const UsdSchemaKind | schemaKind = UsdSchemaKind::SingleApplyAPI |
Compile time constant representing what kind of schema this class is. More... | |
Protected Member Functions | |
PHYSXSCHEMA_API UsdSchemaKind | _GetSchemaKind () const override |
Returns the kind of schema this class belongs to. More... | |
Friends | |
class | UsdSchemaRegistry |
PhysX material extended parameters.
For any described attribute Fallback Value or Allowed Values below that are text/tokens, the actual token is published and defined in PhysxSchemaTokens. So to set an attribute to the value "rightHanded", use PhysxSchemaTokens->rightHanded as the value.
Definition at line 62 of file physxMaterialAPI.h.
|
inlineexplicit |
Construct a PhysxSchemaPhysxMaterialAPI on UsdPrim prim
.
Equivalent to PhysxSchemaPhysxMaterialAPI::Get(prim.GetStage(), prim.GetPath()) for a valid prim
, but will not immediately throw an error for an invalid prim
Definition at line 74 of file physxMaterialAPI.h.
|
inlineexplicit |
Construct a PhysxSchemaPhysxMaterialAPI on the prim held by schemaObj
.
Should be preferred over PhysxSchemaPhysxMaterialAPI(schemaObj.GetPrim()), as it preserves SchemaBase state.
Definition at line 82 of file physxMaterialAPI.h.
|
virtual |
Destructor.
|
overrideprotected |
Returns the kind of schema this class belongs to.
|
static |
Applies this single-apply API schema to the given prim
.
This information is stored by adding "PhysxMaterialAPI" to the token-valued, listOp metadata apiSchemas on the prim.
|
static |
Returns true if this single-apply API schema can be applied to the given prim
.
If this schema can not be a applied to the prim, this returns false and, if provided, populates whyNot
with the reason it can not be applied.
Note that if CanApply returns false, that does not necessarily imply that calling Apply will fail. Callers are expected to call CanApply before calling Apply if they want to ensure that it is valid to apply a schema.
PHYSXSCHEMA_API UsdAttribute CreateCompliantContactAccelerationSpringAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetCompliantContactAccelerationSpringAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
PHYSXSCHEMA_API UsdAttribute CreateCompliantContactDampingAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetCompliantContactDampingAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
PHYSXSCHEMA_API UsdAttribute CreateCompliantContactStiffnessAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetCompliantContactStiffnessAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
PHYSXSCHEMA_API UsdAttribute CreateDampingCombineModeAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetDampingCombineModeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
PHYSXSCHEMA_API UsdAttribute CreateFrictionCombineModeAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetFrictionCombineModeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
PHYSXSCHEMA_API UsdAttribute CreateImprovePatchFrictionAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetImprovePatchFrictionAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
PHYSXSCHEMA_API UsdAttribute CreateRestitutionCombineModeAttr | ( | VtValue const & | defaultValue = VtValue() , |
bool | writeSparsely = false |
||
) | const |
See GetRestitutionCombineModeAttr(), and also Usd_Create_Or_Get_Property for when to use Get vs Create.
If specified, author defaultValue
as the attribute's default, sparsely (when it makes sense to do so) if writeSparsely
is true
- the default for writeSparsely
is false
.
|
static |
Return a PhysxSchemaPhysxMaterialAPI holding the prim adhering to this schema at path
on stage
.
If no prim exists at path
on stage
, or if the prim at that path does not adhere to this schema, return an invalid schema object. This is shorthand for the following:
PHYSXSCHEMA_API UsdAttribute GetCompliantContactAccelerationSpringAttr | ( | ) | const |
If enabled, switches from force-based to acceleration-based compliant spring-damper contact effects.
An acceleration-based spring-damper directly influences the acceleration of (rather than the force on) the contacting bodies, which makes the sink-in depth independent of the mass. The setting has no effect if compliant contacts are disabled, i.e., if the compliant contact stiffness is zero.
Declaration | bool physxMaterial:compliantContactAccelerationSpring = 0 |
C++ Type | bool |
Usd Type | SdfValueTypeNames->Bool |
PHYSXSCHEMA_API UsdAttribute GetCompliantContactDampingAttr | ( | ) | const |
Damping coefficient for a compliant contact model using implicit springs.
Ignored if compliant contacts are disabled (compliantContactStiffness is set to zero), in which case rigid contacts are active. Depending on the compliantContactAccelerationSpring setting, the damping is interpreted as a force or acceleration, respectively, per unit velocity. Range: [0, inf) Units (force spring): force / (distance / seconds) = mass / seconds Units (acceleration spring): acceleration / (distance / seconds) = 1 / seconds
Declaration | float physxMaterial:compliantContactDamping = 0 |
C++ Type | float |
Usd Type | SdfValueTypeNames->Float |
PHYSXSCHEMA_API UsdAttribute GetCompliantContactStiffnessAttr | ( | ) | const |
Spring stiffness for a compliant contact model using implicit springs.
A higher stiffness results in behavior closer to a rigid contact. The compliant contact model is only enabled if the stiffness is larger than 0. Depending on the compliantContactAccelerationSpring setting, the stiffness is interpreted as a force or acceleration, respectively, per unit distance. Range: [0, inf) Units (force spring): force/distance = mass / seconds / seconds Units (acceleration spring): acceleration/distance = 1 / seconds / seconds
Declaration | float physxMaterial:compliantContactStiffness = 0 |
C++ Type | float |
Usd Type | SdfValueTypeNames->Float |
PHYSXSCHEMA_API UsdAttribute GetDampingCombineModeAttr | ( | ) | const |
Determines the way in which two material properties will be combined to yield a damping coefficient for a collision.
This value is only relevant for compliant contact interactions.
Declaration | uniform token physxMaterial:dampingCombineMode = "average" |
C++ Type | TfToken |
Usd Type | SdfValueTypeNames->Token |
Variability | SdfVariabilityUniform |
Allowed Values | average, min, multiply, max |
PHYSXSCHEMA_API UsdAttribute GetFrictionCombineModeAttr | ( | ) | const |
Determines the way in which two material properties will be combined to yield a friction coefficient for a collision.
Declaration | uniform token physxMaterial:frictionCombineMode = "average" |
C++ Type | TfToken |
Usd Type | SdfValueTypeNames->Token |
Variability | SdfVariabilityUniform |
Allowed Values | average, min, multiply, max |
PHYSXSCHEMA_API UsdAttribute GetImprovePatchFrictionAttr | ( | ) | const |
Deprecated.
At a future point, the simulation will always behave as if this attribute was set to true and no longer support the legacy behavior (triggered by setting the attribute to false). At that point this attribute will be removed. Until then, everyone is highly encouraged to always set this attribute to true to adapt to the corresponding friction behavior (note that true is currently the default value).
Flag only has an effect if physxScene:frictionType "patch" friction model is used.
Declaration | bool physxMaterial:improvePatchFriction = 1 |
C++ Type | bool |
Usd Type | SdfValueTypeNames->Bool |
PHYSXSCHEMA_API UsdAttribute GetRestitutionCombineModeAttr | ( | ) | const |
Determines the way in which two material properties will be combined to yield a restitution coefficient for a collision.
Declaration | uniform token physxMaterial:restitutionCombineMode = "average" |
C++ Type | TfToken |
Usd Type | SdfValueTypeNames->Token |
Variability | SdfVariabilityUniform |
Allowed Values | average, min, multiply, max |
|
static |
Return a vector of names of all pre-declared attributes for this schema class and all its ancestor classes.
Does not include attributes that may be authored by custom/extended methods of the schemas involved.
|
static |
Compile time constant representing what kind of schema this class is.
Definition at line 68 of file physxMaterialAPI.h.