Convert frame animation to shape keys

   1962   11   1
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
Hello. I'm trying to convert frame animation and convert it to shape keys to export it to fbx. How can I achieve it?

I've tried to use the setup below (timeshift_fiteration has this expression for frame:
detail("../foreach_count1/", "iteration", 0)
. But it turn out that "Blend Shapes" overrides all previous blend shapes and resulting object after loop has just 1 last frame blend shape and not 52 (number of frames in animation) as I would expect.


What I've learned is that the only way to create multiple shape keys for export is to add them all at once (screenshot below). But how can I add them all at once if number of frame could be changed? How can I store all these timeshifts in some array to use them later as blend shapes?
Edited by Andrej730 - Aug. 22, 2022 18:04:46
User Avatar
Member
8525 posts
Joined: July 2007
Offline
you should be able to use Character Blendshapes Add SOP to add all your blendshapes in similar loop like you have above
and then probably FBX Character Output SOP to export your fbx
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
tamte
you should be able to use Character Blendshapes Add SOP to add all your blendshapes in similar loop like you have above
and then probably FBX Character Output SOP to export your fbx

Testing it without loop first. What should I provide to "Capture pose" input to make it work?

User Avatar
Member
8525 posts
Joined: July 2007
Offline
Try a null maybe?
Some nodes have min inputs requirement, but may not need any specific geo
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
tamte
Try a null maybe?
Some nodes have min inputs requirement, but may not need any specific geo

Adding null to pins results in error:
Error
Can't find 'name' nor 'path' point attribute
Error
Missing 'name' point attribute in animated pose

Tryed to add "name" attribute to animated pose to fit the requirement - no errors but exported fbx is empty.


I've also tried to use "Skeleton" to fill the input pins - no errors but exported fbx contains just 1 bone and no geometry.
User Avatar
Member
1 posts
Joined: Dec. 2019
Offline
Hi, did you manage to find the solution?
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
To put it out here too - the only solution I've found is the one I've described in the first post.
If anyone knows how to reproduce the same thing using loops, arrays or some other more clever method - please let me know.
User Avatar
Member
311 posts
Joined: Oct. 2016
Offline

Andrej730
Testing it without loop first. What should I provide to "Capture pose" input to make it work?


I’m not sure about that node but here are some suggestions.

With rig deforms the need can be:
1) the mesh (geo) with capture weights
2) the skeleton in bind pose
3) the skeleton with animated poses

Otherwise, if the second input is for a mesh in bind pose you can either find it or get this frame using a frozen timeshift.

Cheers!
Interested in character concepts, modeling, rigging, and animation. Related tool dev with Py and VEX.
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
@SWest What I'm looking for now actually is the way to simplify the setup below. Or an example how to create object with blend shapes and export given that I don't have any rest pose, it's just an geometry object and some morph targets (also geometry objects, frames of alembic).




I tried to merge pack it / merge it and unpack it but had no success:

Edited by Andrej730 - Sept. 6, 2023 09:14:26
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
Update! If someone is looking for a way to add blend shapes using character nodes (character blend shapes add), I've found a great tutorial.

Edited by Andrej730 - Sept. 19, 2023 01:10:16
User Avatar
Member
15 posts
Joined: Aug. 2022
Offline
> Okay, I’ve just a little time. If I understood the original case you try to export an automated sequence. However the output is overwritten?
The problem was that I needed to export it specifically as fbx with blend shapes.
I've solved it by creating python script that creates N timeshifts and connects thems all to blend shapes node.
The only question is left - is there some way to do it without using python, by just using nodes, perhaps loops.
Edited by Andrej730 - Sept. 19, 2023 05:05:54
User Avatar
Member
311 posts
Joined: Oct. 2016
Offline
Sorry I deleted my post because I feel that my understanding of the whole picture is too limited.

However, regarding ”one shot” cases I do not see a disadvantage to use Python in a custum snippet. All nodes are just packaged code anyway. Some times it is very beneficial to use some Python. Also, I find a lot of my own Python to mostly call methods already in the HOM.
Interested in character concepts, modeling, rigging, and animation. Related tool dev with Py and VEX.
  • Quick Links