You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(the word damping really only makes sense for when target_angular_velocity=0 - some more clever nomenclature may be warranted).
In addition, it would be desireable to clamp this to a given maximum absolute torque.
For a revolve joint this would then be five parameters (target_angle, target_angular_velocity, stiffness, damping, max_torque). One could then use target_angle and stiffness to move the hands of a clock, and target_velocity + damping to turn the wheels of a car.
For ball joints we have three DOFs, so target_angle would need to be a quaternion and target_angular_velocity a vector. For the siffness, damping and max_torque I think one dimension is enough for most use cases (i.e. use the same strength for all three DOFs).
Related to this is a generalization of all joints as one 6DOF joint. If one can set a target angle and velocity as well as stiffness and damping for all the six degrees of freedom independently, then one actually has a general joint constraint. Basically one would lock a degree of freedom by setting a very high stiffness and damping to one dimension (and zero target velocity). This may simplify the inner workings of rapier in the long run, but probably be more work in the short run.
Of course, all this can be approximated using RigidBody::apply_torque and friends, but it really ought to be part of the constraint solver, as forces and torques tend to "lose" against real constraints (after all, one can approximate all the constraints using forces and torques).
The text was updated successfully, but these errors were encountered:
Joint motors/limits/pose-control is something that will be added within the next few months.
A generic 6-DOF joint could be added too, however it will probably not end up simplifying the inner workings of Rapier in the long run because each joint has its specific formulation in order to solve all its constraints (for all the DOFs it affects) at once in a linearly-implicit way. So a generic 6-DOF joint will probably end up being a different formulation (somewhat more generic), perhaps slightly less efficient and less stable than the existing specific joints. Though I may be wrong since I have not thought about this in details yet.
Joint drives (or joint motors) allows one to simulate e.g. a motor turning a wheel, a muscle bending an arm, or a pushing piston.
In particular, I'd like to be able to set up angular forces for ball joints and revolute joints in an "angular spring" fashion, i.e.:
(the word
damping
really only makes sense for whentarget_angular_velocity=0
- some more clever nomenclature may be warranted).In addition, it would be desireable to clamp this to a given maximum absolute torque.
For a revolve joint this would then be five parameters (
target_angle, target_angular_velocity, stiffness, damping, max_torque
). One could then usetarget_angle
andstiffness
to move the hands of a clock, andtarget_velocity
+damping
to turn the wheels of a car.For ball joints we have three DOFs, so
target_angle
would need to be a quaternion andtarget_angular_velocity
a vector. For thesiffness
,damping
andmax_torque
I think one dimension is enough for most use cases (i.e. use the same strength for all three DOFs).Related to this is a generalization of all joints as one 6DOF joint. If one can set a target angle and velocity as well as stiffness and damping for all the six degrees of freedom independently, then one actually has a general joint constraint. Basically one would lock a degree of freedom by setting a very high stiffness and damping to one dimension (and zero target velocity). This may simplify the inner workings of rapier in the long run, but probably be more work in the short run.
Of course, all this can be approximated using
RigidBody::apply_torque
and friends, but it really ought to be part of the constraint solver, as forces and torques tend to "lose" against real constraints (after all, one can approximate all the constraints using forces and torques).The text was updated successfully, but these errors were encountered: