Post

MotorJoint

Overview

MotorJoint drives relative angular velocities between body1 and body2 within a common reference frame. Contains two RigidBody nodes (containerField values body1, body2).

The MotorJoint node belongs to the RigidBodyPhysics component and requires at least level 2, its default container field is joints. It is available from X3D version 3.2 or higher.

Hierarchy

1
2
3
+ X3DNode
  + X3DRigidJointNode
    + MotorJoint

Fields

SFNode [in, out] metadata NULL [X3DMetadataObject]

Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node.

Hint

SFBool [ ] autoCalc FALSE

autoCalc controls whether user manually provides individual angle rotations each frame (false) or if angle values are automatically calculated by motor implementations (true).

MFString [in, out] forceOutput “NONE” [“ALL”, “NONE”, …]

forceOutput controls which output fields are generated for the next frame. Values are ALL, NONE, or exact names of output fields updated at start of next frame.

SFFloat [in, out] axis1Angle 0 [-π,π]

axis1Angle (radians) is rotation angle for corresponding motor axis when in user-calculated mode.

Hint

SFFloat [in, out] axis2Angle 0 [-π,π]

axis2Angle (radians) is rotation angle for corresponding motor axis when in user-calculated mode.

Hint

SFFloat [in, out] axis3Angle 0 [-π,π]

axis3Angle (radians) is rotation angle for corresponding motor axis when in user-calculated mode.

Hint

SFFloat [in, out] axis1Torque 0 (-∞,∞)

axis1Torque is rotational torque applied by corresponding motor axis when in user-calculated mode.

SFFloat [in, out] axis2Torque 0 (-∞,∞)

axis2Torque is rotational torque applied by corresponding motor axis when in user-calculated mode.

SFFloat [in, out] axis3Torque 0 (-∞,∞)

axis3Torque is rotational torque applied by corresponding motor axis when in user-calculated mode.

SFInt32 [in, out] enabledAxes 1 [0,3]

enabledAxes indicates which motor axes are active. (0) none, (1) axis 1, (2) axes 1 and 2, (3) all three axes.

SFVec3f [in, out] motor1Axis 1 0 0 (-∞,∞)

motor1Axis defines axis vector of corresponding motor axis.

Hint

  • 0 0 0 means motor disabled about this axis.

SFVec3f [in, out] motor2Axis 0 1 0 (-∞,∞)

motor2Axis defines axis vector of corresponding motor axis.

Hint

  • 0 0 0 means motor disabled about this axis.

SFVec3f [in, out] motor3Axis 0 0 1 (-∞,∞)

motor3Axis defines axis vector of corresponding motor axis.

Hint

  • 0 0 0 means motor disabled about this axis.

SFFloat [in, out] stop1Bounce 0 [0,1]

stop1Bounce is velocity factor for bounce back once stop point is reached.

Hint

  • 0 means no bounce, 1 means return velocity matches.

SFFloat [in, out] stop2Bounce 0 [0,1]

stop2Bounce is velocity factor for bounce back once stop point is reached.

Hint

  • 0 means no bounce, 1 means return velocity matches.

SFFloat [in, out] stop3Bounce 0 [0,1]

stop3Bounce is velocity factor for bounce back once stop point is reached.

Hint

  • 0 means no bounce, 1 means return velocity matches.

SFFloat [in, out] stop1ErrorCorrection 0.8 [0,1]

stop1ErrorCorrection is fraction of error correction performed during time step once stop point is reached.

Hint

  • 0 means no error correction, 1 means all error corrected in single step.

SFFloat [in, out] stop2ErrorCorrection 0.8 [0,1]

stop2ErrorCorrection is fraction of error correction performed during time step once stop point is reached.

Hint

  • 0 means no error correction, 1 means all error corrected in single step.

SFFloat [in, out] stop3ErrorCorrection 0.8 [0,1]

stop3ErrorCorrection is fraction of error correction performed during time step once stop point is reached.

Hint

  • 0 means no error correction, 1 means all error corrected in single step.

SFFloat [out] motor1Angle

motor1Angle provides calculated angle of rotation (radians) for this motor joint from last frame.

Hint

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

SFFloat [out] motor2Angle

motor2Angle provides calculated angle of rotation (radians) for this motor joint from last frame.

Hint

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

SFFloat [out] motor3Angle

motor3Angle provides calculated angle of rotation (radians) for this motor joint from last frame.

Hint

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

SFFloat [out] motor1AngleRate

motor1AngleRate provides calculated anglular rotation rate (radians/second) for this motor joint from last frame.

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

SFFloat [out] motor2AngleRate

motor2AngleRate provides calculated anglular rotation rate (radians/second) for this motor joint from last frame.

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

SFFloat [out] motor3AngleRate

motor3AngleRate provides calculated anglular rotation rate (radians/second) for this motor joint from last frame.

Warning

  • It is an error to define this transient outputOnly field in an X3D file, instead only use it a source for ROUTE events.

SFNode [in, out] body1 NULL [RigidBody]

The body1 and body2 fields indicate the two RigidBody nodes connected by this joint.

SFNode [in, out] body2 NULL [RigidBody]

The body1 and body2 fields indicate the two RigidBody nodes connected by this joint.

Advice

Hints

  • Useful in combination with BallJoint.
  • RigidBodyPhysics component, level 2.

See Also

This post is licensed under CC BY 4.0 by the author.