usdrt::PhysxSchemaPhysxParticleAPI

Defined in usdrt/scenegraph/usd/physxSchema/physxParticleAPI.h

Functions

Variables

class PhysxSchemaPhysxParticleAPI : public usdrt::UsdAPISchemaBase

WARNING: This is a draft API; the design is not fixed and may change in the future. Do not apply. Provides parameters shared among particle objects.

Public Functions

inline explicit PhysxSchemaPhysxParticleAPI(const UsdPrim &prim = UsdPrim())

Construct a PhysxSchemaPhysxParticleAPI on UsdPrim prim. Equivalent to PhysxSchemaPhysxParticleAPI::Get(prim.GetStage(), prim.GetPath()) for a valid prim , but will not immediately throw an error for an invalid prim.

inline explicit PhysxSchemaPhysxParticleAPI(const UsdSchemaBase &schemaObj)

Construct a PhysxSchemaPhysxParticleAPI on the prim held by schemaObj . Should be preferred over PhysxSchemaPhysxParticleAPI(schemaObj.GetPrim()), as it preserves SchemaBase state.

inline virtual ~PhysxSchemaPhysxParticleAPI()

Destructor.

inline operator bool() const

Boolean operator.

Returns

Return true if the contained prim is has this api schema applied using HasAPI, and false otherwise.

inline UsdAttribute GetParticleEnabledAttr() const

Enable or disable the particle object.

Declaration

bool physxParticle:particleEnabled = 1

C++ Type

bool

Usd Type

SdfValueTypeNames->Bool

inline UsdAttribute CreateParticleEnabledAttr() const

See GetParticleEnabledAttr(), and also Create vs Get Property Methods 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.

inline UsdAttribute GetSelfCollisionAttr() const

Enables self-collision of the particles or of the particle object.

Declaration

bool physxParticle:selfCollision = 1

C++ Type

bool

Usd Type

SdfValueTypeNames->Bool

inline UsdAttribute CreateSelfCollisionAttr() const

See GetSelfCollisionAttr(), and also Create vs Get Property Methods 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.

inline UsdAttribute GetParticleGroupAttr() const

Group Id of the particles. Particles / objects in different groups in the same system collide with each other. Within the same group in the same system, the collision behavior is controlled by the selfCollision parameter. Range: [0, 2^20)

Declaration

int physxParticle:particleGroup = 0

C++ Type

int

Usd Type

SdfValueTypeNames->Int

inline UsdAttribute CreateParticleGroupAttr() const

See GetParticleGroupAttr(), and also Create vs Get Property Methods 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.

inline UsdRelationship GetParticleSystemRel() const

Single particle system that the particle-based object belongs to.

inline UsdRelationship CreateParticleSystemRel() const

See GetParticleSystemRel(), and also Create vs Get Property Methods for when to use Get vs Create.

UsdPrim GetPrim() const

Return this schema object’s held prim.

SdfPath GetPath() const

Return the SdfPath to this schema object’s held prim.

Public Static Functions

static inline PhysxSchemaPhysxParticleAPI Apply(const UsdPrim &prim)

Applies this single-apply API schema to the given prim. This information is stored by adding “PhysxParticleAPI” to the token-valued, listOp metadata apiSchemas on the prim.

See also

UsdPrim::GetAppliedSchemas()

See also

UsdPrim::HasAPI()

See also

UsdPrim::ApplyAPI()

See also

UsdPrim::RemoveAPI()

Returns

A valid PhysxSchemaPhysxParticleAPI object is returned upon success. An invalid (or empty) PhysxSchemaPhysxParticleAPI object is returned upon failure. See UsdPrim::ApplyAPI() for conditions resulting in failure.

Public Static Attributes

static const UsdSchemaType schemaType = UsdSchemaType::SingleApplyAPI

Compile time constant representing what kind of schema this class is.

See also

UsdSchemaType

Protected Functions

inline const TfToken &_GetInstanceName() const

Returns the instance name of the API schema object belonging to a multiple-apply API schema.

The returned instance name will be empty for non-applied and single-apply API schemas.