alignPhysicsJoint#
Fully qualified name: usdex::core::alignPhysicsJoint
- void usdex::core::alignPhysicsJoint(
- pxr::UsdPhysicsJoint joint,
- const JointFrame &frame,
- const pxr::GfVec3f &axis = pxr::GfVec3f(1.0f, 0.0f, 0.0f),
Aligns an existing joint with the specified position, rotation, and axis.
The Joint’s local position & orientation relative to each Body will be authored to align to the specified position, orientation, and axis.
The
axisspecifies the primary axis for rotation or translation, based on the local joint orientation relative to each body.To rotate or translate about the X-axis, specify (1, 0, 0). To operate in the opposite direction, specify (-1, 0, 0).
To rotate or translate about about the Y-axis, specify (0, 1, 0). To operate in the opposite direction, specify (0, -1, 0).
To rotate or translate about about the Z-axis, specify (0, 0, 1). To operate in the opposite direction, specify (0, 0, -1).
Any other direction will be aligned to X-axis via a local rotation or translation for both bodies.
- Parameters:
joint – The joint to align
frame – The position and rotation of the joint in the specified coordinate system.
axis – The axis of the joint.
- Returns:
void