Get Body/Object Rotation/Orientation

anybody can help how to get body or objection orientation, the docs only saying:

// collect local rotation for each keypoint
for (auto &kp : obj.local_orientation_per_joint)
{
   // kp is the local keypoint rotation represented by a quaternion         -> how to do this btw
   // user code
}

thanks in advance

Hi,

You can have access to the detection’s orientation with the global_root_orientation field (https://www.stereolabs.com/docs/api/classsl_1_1ObjectData.html#ac776ec7900f90e78a1febee88bb06ec7) and the position with
the position field (https://www.stereolabs.com/docs/api/classsl_1_1ObjectData.html#a73ad5e3f5c238f322437399b54d8ec5e) of the ObjectData data struct.

Best,
Benjamin Vallon

Stereolabs Support