-
Notifications
You must be signed in to change notification settings - Fork 153
Open
Description
Thank you for the excellent work.
I have a question regarding the implementation of Forward Kinematics (FK), as shown in the code below.
Why is the local rotation of the child joint not used when calculating the global position of the bones, and instead, only the global rotation of the parent joint is applied? In my understanding, the bone from the parent joint to its own joint is also influenced by the local rotation of its own node. However, according to your code, it seems that the bone is manipulated based on the parent node's rotation.
def transform_mul(x, y):
# Combine two transformation together
# old version
z = transform_from_rotation_translation(
r=quat_mul_norm(transform_rotation(x), transform_rotation(y)),
t=quat_rotate(transform_rotation(x), transform_translation(y))
+ transform_translation(x),
)
# my version
joint_r = quat_mul_norm(transform_rotation(x), transform_rotation(y))
z = transform_from_rotation_translation(
r=joint_r,
t=quat_rotate(joint_r, transform_translation(y)) + transform_translation(x),
)
return z
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels