unreal.RigDynamicsConstraintComponent

class unreal.RigDynamicsConstraintComponent(parent_component_key: RigComponentKey = Ellipsis, child_component_key: RigComponentKey = Ellipsis, constraint_type: RigParticleSimulationConstraintType = Ellipsis, strength: float = 0.0, damping_ratio: float = 0.0, extra_damping: float = 0.0, acceleration_mode: bool = False, length_multiplier: float = 0.0, extra_length: float = 0.0)

Bases: RigBaseComponent

A component that can be added to a joint/element that defines a constraint between two particles.

C++ Source:

  • Plugin: ControlRigDynamics

  • Module: ControlRigDynamics

  • File: RigDynamicsConstraintComponent.h

Editor Properties: (see get_editor_property/set_editor_property)

  • acceleration_mode (bool): [Read-Write] For soft constraints: When true, Strength is a mass-independent natural frequency. When false, the spring/damper acts as a true force, so heavier particles oscillate more slowly. For hard constraints, this has no effect.

  • child_component_key (RigComponentKey): [Read-Write] The child particle for the constraint

  • constraint_type (RigParticleSimulationConstraintType): [Read-Write] If the constraint is marked as “hard”, then the system will try as hard as possible to enforce it. This will also be a little cheaper than making a soft constraint.

  • damping_ratio (float): [Read-Write] DampingRatio for the constraint

  • extra_damping (float): [Read-Write] Additional damping for the constraint

  • extra_length (float): [Read-Write] This will be added on to the target length after the automatic/multiplication

  • length_multiplier (float): [Read-Write] The target length will be calculated automatically, multiplied by this

  • parent_component_key (RigComponentKey): [Read-Write] The parent particle for the constraint

  • strength (float): [Read-Write] The strength which we drive towards the target length. This is the oscillation frequency, so low values will be soft and springy, but values significantly above 1/timestep will track the target very accurately.

property acceleration_mode: bool

When true, Strength is a mass-independent natural frequency. When false, the spring/damper acts as a true force, so heavier particles oscillate more slowly. For hard constraints, this has no effect.

Type:

(bool)

Type:

[Read-Only] For soft constraints

property child_component_key: RigComponentKey

[Read-Only] The child particle for the constraint

Type:

(RigComponentKey)

property constraint_type: RigParticleSimulationConstraintType

[Read-Only] If the constraint is marked as “hard”, then the system will try as hard as possible to enforce it. This will also be a little cheaper than making a soft constraint.

Type:

(RigParticleSimulationConstraintType)

property damping_ratio: float

[Read-Only] DampingRatio for the constraint

Type:

(float)

property extra_damping: float

[Read-Only] Additional damping for the constraint

Type:

(float)

property extra_length: float

[Read-Only] This will be added on to the target length after the automatic/multiplication

Type:

(float)

property length_multiplier: float

[Read-Only] The target length will be calculated automatically, multiplied by this

Type:

(float)

property parent_component_key: RigComponentKey

[Read-Only] The parent particle for the constraint

Type:

(RigComponentKey)

property strength: float

[Read-Only] The strength which we drive towards the target length. This is the oscillation frequency, so low values will be soft and springy, but values significantly above 1/timestep will track the target very accurately.

Type:

(float)