Class XRHandSkeletonDriverUtility
Utility methods for XRHandSkeletonDriver.
Inherited Members
Namespace: UnityEngine.XR.Hands
Syntax
public static class XRHandSkeletonDriverUtility
Methods
FindJointsFromRoot(XRHandSkeletonDriver, List<String>)
Set up the joint references for an XRHandSkeletonDriver by checking the hierarchy and comparing the children GameObject's names with the names of the joints. The GameObjects names are expected to either start or end with the name of the joint.
Declaration
public static void FindJointsFromRoot(XRHandSkeletonDriver skeletonDriver, List<string> missingJointNames = null)
Parameters
Type | Name | Description |
---|---|---|
XRHandSkeletonDriver | skeletonDriver | The XRHandSkeletonDriver component to setup. |
List<String> | missingJointNames | A list of strings that will be cleared and populated with the joints that are missing. |
Remarks
This method is expensive because it searches the hierarchy by comparing the names of GameObjects so it should not be called frequently. Instead, the joint references can be set once and serialized in either the scene or a prefab.