[SOLVED] Is it possible to animate a morphInstance separately?

I know that right now there are no animation layer features in PlayCanvas.
But we have meshInstances and morphInstances. Is it possible to make two separate animation tracks:

  1. One to handle all bone transformations without any morph information.
  2. One with morph keyframes without anything else.
    I don’t think it is possible to play those two tracks simultaneously. But is it possible to play them separately without affecting each other?

What are you looking to do here? There may be some features in the beta Anim Component with State Graph that could help here.

I have a character with a bone structure, all meshes are skinned meshes, and one of them contains morph information. I want to:

  1. Play an ordinal animation to set the character to a pose.
  2. Play a special morph-only animation track to affect morphInstance only. I want the character to remain in his pose.
  3. Play the next ordinal animation track. All changes made by the morph-only track must be untouched by it.
1 Like

@Elliott One for you?

1 Like

You cold probably export bone animation separately, and morph animation separately, and import them. Then create two anim components (on two entities) … one would animate bones, one would animate morphs. Perhaps this would work for now?

1 Like

Sure, I could export files with only bones/morph keyframes.
But how does the engine would play those tracks? The engine has no keyframe information about bones, as an example. Is not it expected to reset all bones to “null” positions? Is not it expected to set all morphs to 0 if there are no morph keyframes?
But thank you for the advice. I’ll try to test it.

Engine looks at what tracks you have in the animation assets, and only plays there. Just because some track does not store bone animations would not cause engine to set bone animations to null or anything like this. What I suggested should work …

Actually, thinking about it … you should not even need two anim components. You can create a single anim component, have two layers on it … and use bone animations on one layer, and morph animations on the other layers.

I’ve performed the test. It is actually working without any layer/mask features, on the current version of PC.
But you need to export morph keys only. It is quite a tricky workflow. I followed this guide for exporting .glb files from 3Ds Max: https://forum.babylonjs.com/t/morph-animation/1172
I am not sure if it is possible to export this way from Blender or with a PC converter.

Feel free to mark this thread as Solved.

2 Likes