tuatec / TTToolbox

TTToolbox provides useful helper scripts to automate your character integration workflows in Unreal Engine
MIT License
108 stars 30 forks source link

Add Unweighted Bones directly in Unreal #2

Closed AchimTuran closed 2 years ago

AchimTuran commented 2 years ago

With the current state of Metahumans it is impossible to use them with ALS, as they don't provide any ik bones so far.

Sure you can add them via Blender or any other 3d software, but then you might have to deal with importing and exporting all meshes (LODs). Wouldn't it be no better to add them directly in Unreal❓

So far there seem to be only a few plugins that allows an Unreal user to introduce a root bone or unweighted bones. But these might be to expensive for you. 😄 https://www.unrealengine.com/marketplace/en-US/product/virtual-animation-tools https://www.unrealengine.com/marketplace/en-US/product/mixamo-animation-retargeting https://www.unrealengine.com/marketplace/en-US/product/mixamo-animation-retargeting-2

After this pull request is merged you can add those bones via a right click and a data table. Additionally, the data table was extended to get a Mixamo character working without renaming the bones. For details see https://youtube.com/playlist?list=PLslFX7TZAr8_rp0_Oj5v6-8HlEvKU_JKw. image image

First tests seem to be fine here. image image

Furthermore, it can happen that your virtual bones might get messed up during retargeting... to work around this issue we can trigger the recompression of animations when we restart the editor. Wouldn't be it more valuable if we as a user could decide when the recompression task should be trigger❓ To workaround this issue this node was implemented. It can trigger the process and your virtual bones will be automatically constraint to the target bones. 😉 image

AchimTuran commented 2 years ago

Feature is still in experimental state so please if you use it backup your project before trying to introcude the bones. It might break your existing animations, skleleton assets or meshes. 😉 TTToolbox_v0.4_UE5.0.1.zip

Special thanks to corinadow, Vlad the Iron Clad, Orphic and J0hnC0nn0r for testing and giving feedback.

AchimTuran commented 2 years ago

This version does not try to release the ressources on the render thread to avoid issues with shader struct parameter validation. Tested this version with opened preview mesh and skeleton. So far no issues here. Somehow the render thread does not like if we try to release ressources and initialize them again for the introduction of unweighted bones. Without touching this multithreading issue it seems to be fine here. 😉 TTToolbox_v0.4_UE5.0.0_win64_2.zip

Special thanks to corinadow, Vlad the Iron Clad, Orphic and J0hnC0nn0r for testing and giving feedback.

AchimTuran commented 2 years ago
AchimTuran commented 2 years ago
AchimTuran commented 2 years ago
AchimTuran commented 2 years ago

Thank you already for your contribution, we will try to get back to you asap when we find the time and of course give you feedback. Looking forward to a great review session with valuable discussions.

ill commented 2 years ago

Oooh nice, I was also looking for a way to delete bones. I ended up doing the whole painful export as fbx, import into engine, redo all settings as precisely as possible, process. I basically just wanted to take the UE5 mannequin and modify its IK bone setup to how my game needs.

AchimTuran commented 2 years ago

@ill Delete or add bones? Yeah it's a huge time saver. 😉

feature request is available here https://github.com/tuatec/TTToolbox/issues/6.

colorindarkness commented 2 years ago

This will really improve the workflow. Thank you.

AchimTuran commented 2 years ago
AchimTuran commented 2 years ago

Secured adding virtual bones through source and target bone name checks. Sadly the public UE API does not care about this use case. Furthermore, it seems to be that unparented virtual bones create issues while adding unweighted bones through the TTToolbox preview v0.4.

AchimTuran commented 2 years ago

TTToolbox_v0.4_UE5.0.0_win64_3.zip TTToolbox_v0.4_UE5.0.0_win64_4.zip

AchimTuran commented 2 years ago

@lakkyhb Please don't use my pull request for asking questions. For that I have the issue handling already setup within this GitHub project.

See https://github.com/tuatec/TTToolbox#how-to-contribute-to-tttoolbox.

Furthermore, I already created a issue for your problem here, https://github.com/tuatec/TTToolbox/issues/10.

AchimTuran commented 2 years ago

feature is now developed and will be merged to master, which enables me to create v0.4.