global coordinates of a joint

That’s right–controlJoints are a little different than regular exposed joints, since they are given in local coordinates.

If you want, you can make the controlJoints get a proper global coordinate from render by parenting them to their parent joint. This means you need to expose the parent joint.

parent = actor.exposeJoint(None, "modelRoot", "joint_parent")
child = parent.attachNewNode("joint_child")
actor.controlJoint(child, "modelRoot", "joint_child")

In case you have a controlled joint parented to another controlled joint, you stack them all up, with the exposed joint at the top:

grandparent = actor.exposeJoint(None, "modelRoot", joint_grandparent")
parent = grandparent.attachNewNode("joint_parent")
actor.controlJoint(parent, "modelRoot", "joint_parent")
child = parent.attachNewNode("joint_child")
actor.controlJoint(child, "modelRoot", "joint_child")

This works because if the first parameter of controlJoint or exposeJoint is not None, then it indicates the NodePath that you have already created and attached to the right place to represent the node. (Normally, if the first parameter is None, it indicates that exposeJoint/controlJoint should create a new NodePath and return it.)

David