Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

where is mediapipe code? #2

Open
lucasjinreal opened this issue Feb 3, 2023 · 5 comments
Open

where is mediapipe code? #2

lucasjinreal opened this issue Feb 3, 2023 · 5 comments

Comments

@lucasjinreal
Copy link

No description provided.

@creativeIKEP
Copy link
Owner

@jinfagang
This app uses HolisticBarracuda which has a similar implementation to official MediaPipe.

@lucasjinreal
Copy link
Author

@creativeIKEP Hello, may I ask how did you get the rotations from mediapipe 3d pose landmark outpiut?

@creativeIKEP
Copy link
Owner

@jinfagang
Each landmarks of MediaPipe is associated with each joint of humanoid, and the rotation is calculated by using the direction vector from the parent landmark to the child landmark and Quaternion.LookRotation method.

Detail implementation > HolisticMotionCapture/Packages/HolisticMotionCapture/Scripts/HolisticMotionCapture_Pose.cs

@lucasjinreal
Copy link
Author

lucasjinreal commented Feb 16, 2023

@creativeIKEP thanks, is that possible to do it in pure c++ rather than in a game engine like unity?

the 3d world landmarks are coordinates, the distance between 2 joint might be not same as bone length, does it effect? Where to get such a Humanoid skeleton tough

@creativeIKEP
Copy link
Owner

@jinfagang
I think that pure C++ can also calculate quaternions from MediaPipe landmarks.
HolisticMotionCapture calculates the quaternion of each joint of the avatar based on FK.
In other words, HolisticMotionCapture only calculating which direction to rotate the joints, so I don't think the length of the avatar's bones matters unless you need to be able to reach certain places like IK.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants