google / filament

Filament is a real-time physically based rendering engine for Android, iOS, Windows, Linux, macOS, and WebGL2
https://google.github.io/filament/
Apache License 2.0
17.69k stars 1.87k forks source link

feat: updateBoneMatricesForInstance #7859

Open hannojg opened 4 months ago

hannojg commented 4 months ago

Added a method to control to which instance to apply the bone matrices updates of an animator.

This is particularly useful if you want to apply the animation from one master asset to other instances that are different assets (have different meshes) but share the same skeleton as the master asset. A common example for this is e.g. clothing.

In our use case we have one main character which contains all the animations. We then have clothings that are rigged to the same skeleton of the main character. We are then able to apply the transformations of the character to the clothing assets while playing an animation.

The initial discussion has been started here:

ninjz commented 4 months ago

Wasn't able to get this solution working on Android. Are there any additional instructions you can provide on how this should be used?

hannojg commented 4 months ago

Wasn't able to get this solution working on Android. Are there any additional instructions you can provide on how this should be used?

I provided instructions here: