Comments (8)
Yes, I've done something similar.
Bone names just map, The orientation needs to be recalculated with matrix calculations.
The formula:
New animation = (New Animation Binding)^-1 * (New global parent)^-1 * (global Parent) * (Animation Binding) * (animation) * (global bind offset) * (new global bind offset)^-1
This seems to work well for models with different orientations among mixamo models.
from anim.
The new binding pose can be calculated as:
-
Get R, S of the binding pose of the target model
-
Take the coordinates relative to the parent bone as T in the existing global coordinates
-
new binding = TRS
from anim.
@Nor-s hi, thank u for the reply, do u have an example for this? How should I get the R and S from a SMPL model and a Mixamo model in FBX format?
from anim.
see src/utility.h DecomposeTransform
T, R, S = DecomposeTransform(local bindpose)
"local bindpose" is "assimp aiNode::mTransformation"
And I wrote sample code for my editor.
(same mixamo name, different bone orientation)
( Here, PoseComponent holds source animation information and target character information.)
Sorry for the dirty code.
from anim.
example
I haven't tested SMPL because I don't have an SMPL model,
but this is the result of retargeting different orientation Mixamo models.
(But for now, Mixamo has updated them, they all have the same bone orientation.)
before
after
from anim.
@Nor-s thank, does there a way make your code buildable on macOS? I wnanna have a try, this seems exactly what I need
from anim.
sorry. I'm currently only trying the silicon version (m1),
so I don't know if it will work correctly. Also the animations can be weird like you did before.
To build embedded Python, you need to configure your environment according to this document
Setting up the embedded Python environment seems too difficult.
I configured the environment with this command.
- Clang 13.0.0 arm64-apple-darwin21.2.0
- Python 3.10 and newer
- Homebrew 3.5.9
xcode-select --install
brew install pkg-config [email protected] xz gdbm tcl-tk
git clone --recursive https://github.com/Nor-s/Anim.git
cd Anim
mkdir build
cd build
cmake ..
make
if u intel version
You will need to modify the following:
scripts/build_python_osx.sh
./pip3 install mediapipe-silicon
=>
./pip3 install mediapipe
from anim.
@Nor-s hello, I am exactly Sillcon version M1 mac. But you needn't build arm python yourself. Using mini-forge can have a arm python in conda.
Have you tride that? this can be more universal since usally users have python in conda.
from anim.
Related Issues (9)
- I can't open the program HOT 26
- [BUG] When pressing the mediapipe button HOT 1
- [BUG] Can not find python properly HOT 1
- [BUG] When moving the scene window
- the animate is not work
- animation was not fully correct HOT 21
- Error: glfwPollevents win32 HOT 2
- [BUG] Mediapipe Pose HTTPError (model complexity = 0) HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from anim.