Need to rotate child of a 3D mesh

I am creating a vision pro app with a 3D model, it has a mesh hierarchy of head, hands, feet etc. I want the character to look towards the camera, but am not able to access head of character through sceneKit nor reality kit. when I try to print names of the child meshes, it only prints till the character, it does iterate through all the body parts. Can anyone help?

Hello @himanshu_nag, thank you for your question!

When you create a joint heirarchy in a third party DCC like Blender or Maya, you can access those joints in RealityKit through the JointTransforms API. This is accessible from a ModelEntity or any Entity that implements the HasModel protocol. In your case, you should find the joint you want and apply the appropriate transform that rotates the head toward the camera. Keep in mind that other animations playing on the skeleton will override any adjustments you make to the joint transforms.

Please send us any feedback you have about RealityKit's animation API to us using Feedback Assistant.

Let me know if you have any more questions. Thank you!

Need to rotate child of a 3D mesh
 
 
Q