*ACTUAL* IK arm position is handled elsewhere as if it was regular unity Mechanim IK.įinger IK (in late update) then traverses each bone in the OVRSkeleton and positions the appropriately mapped HTFinger at the same position. You'll notice FingerIK in the editor takes a reference to the Oculus object for left and right hand as well as the HandTrackingFingerMap for the left and right hand of my custom model. THEN I put my FingerIK on my character model as a sibling of their Animator (strictly speaking they could be empty game objects outside of my model, which would probably be slightly better organization, but I digress.Įach BONE in the custom model, gets mapped within the hand tracking finger map. Within the editor, I add a HandTrackingFingerMap to each of my custom-model's HAND transforms. This is a hard-coded list of all of the fingers that you can find in an OVRSkeleton (the oculus finger bones object). Then I have an object called a HandTrackingFingerMap It's actually a bit of a bad name since I should probably call it a HandTrackingFingerBone but we'll live. By moving the custom model's finger transforms in LateUpdate, the changes you make don't get overwritten by your model's AnimationController.Ĭonceptually what I've done is I've hard-coded an object called an HTFinger (ht for hand-tracking) it has a transform and an offset. LateUpdate as you may or may not know happens within the Unity frame's lifecycle AFTER animation has happend but before the frame gets written to the screen. So the hand tracking you see in the video above with "no finger rigging" is the code basically as it comes out of the box from Oculus after you follow their docs.įor the NEXT part which is moving my custom-model's fingers in time with the OCULUS fingers, I had to put a function in LateUpdate. Let me know if you want any clarification after too.įirst of all, recall that this is working on the quest.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |