Hey folks -
I'm trying to export a skeletal mesh from Unreal, bring it into Houdini, modify the mesh, export an FBX, and read it back into Unreal.
Not having much luck. Even importing a skeletal mesh and immediately exporting it again doesn't work. Why? Because -- among other things -- Houdini effectively changes the skeleton structure and pathnames.
Seems like a real basic functional test should be confirming an unmodified round-trip between platforms. No such luck.
Is there an established workflow for this? I've seen some videos, but they're not using real rigs -- just the UE mannequin.
Alternatively, is there a way to control FBX pathname generation? It includes the entire Houdini object hierarchy. So, if I have a skeleton called, "Foo", I get "Foo/root/..." That's incorrect -- the Foo shouldn't be on there. The root of the path should be original root bone name you imported. I understand where it's coming from in Houdini; but it's not workable. I'd need an object with no name for this to work.
Anyone done this successfully?
Thanks!
-anna
Unreal skeletal mesh export/import/export
9067 10 3- annabd
- Member
- 14 posts
- Joined: April 2012
- Offline
- gguillermix
- Member
- 3 posts
- Joined: Nov. 2018
- Offline
- SalvatoSC
- Member
- 2 posts
- Joined: Jan. 2019
- Offline
- willh
- Member
- 134 posts
- Joined: Dec. 2006
- Offline
- gguillermix
- Member
- 3 posts
- Joined: Nov. 2018
- Offline
Yes, this is how you export and import characters, but that's not the issue.
Not having much luck. Even importing a skeletal mesh and immediately exporting it again doesn't work. Why? Because -- among other things -- Houdini effectively changes the skeleton structure and pathnames.
Edited by gguillermix - Dec. 15, 2022 07:50:24
- mrpdean
- Member
- 69 posts
- Joined: April 2019
- Offline
- alanvip220v
- Member
- 2 posts
- Joined: Jan. 2021
- Offline
Works for me: In houdini
i`ve set Root name: to my hips (in my case it was mixamorig:hips) at FBX Animation import node,
then i exported it with fbx_characteroutput node ,
After importing it unreal engine he gave me a massage FAILED TO MERGE BONES , then pressed YES ALL
UE5 asking to merge all skeletal meshes - press No
i`ve set Root name: to my hips (in my case it was mixamorig:hips) at FBX Animation import node,
then i exported it with fbx_characteroutput node ,
After importing it unreal engine he gave me a massage FAILED TO MERGE BONES , then pressed YES ALL
UE5 asking to merge all skeletal meshes - press No
- quentinsking
- Member
- 4 posts
- Joined: April 2019
- Offline
Had to solve this problem recently, and while this is the first thing that comes up in Google I thought I would chime in on what got it working for me. Not sure if this is even the same issue everyone else is having but it might help someone.
Basically what I was trying to do was Export skeletal mesh from Unreal -> Import into Houdini to decimate -> Import back to unreal as a LOD for the original skeletal mesh. Except it wouldn't let me import into unreal as a LOD since the skeleton had changed.
What I found is that when using the Character FBX Import and Character FBX Export nodes, Houdini will strip out any and all bones where there are no vertices with a weight for bone. So if I have a root bone that doesn't have verts directly weighted to it, it'll get removed on export despite the fact that it's the parent for a lot of other valid bones lol. You can see what it's removing by looking at the Rig Tree inspector after importing your result back into Houdini.
Anyways... the hacky solution I found was just add a dummy weight to random vertices for every bone I know was going to be stripped out. Basically right before exporting the skeletal mesh from Houdini throw it through this network:
- Capture Attribute Unpack node on your mesh so you can edit the boneCapture attributes in vex
- Attribute Wrangle vex code where I look at the imported skeleton and find bones that have no weights in the mesh. Add a dummy weight for that bone to any random vertex with a weight of 0.0 so it doesn't actually influence it.
- Capture Attribute Pack the boneCapture stuff back into the right format
Then, when you export it through the FBX Character Output node it will hopefully maintain the skeleton. Another gotcha I found was that Houdini adds an extra root node in your animated pose which messes up the import back into Unreal because the root nodes won't match (and prevents you from importing it as a LOD). I wasn't dealing with animation so I just omitted the animation pose from my export but I think you might also have to manually fix all those paths right before exporting.
This was all in Houdini 18.5 not sure if any of this behavior has changed, at the very least I would like an option to not strip out "unused" bones in the FBX Character Output node lol.
Basically what I was trying to do was Export skeletal mesh from Unreal -> Import into Houdini to decimate -> Import back to unreal as a LOD for the original skeletal mesh. Except it wouldn't let me import into unreal as a LOD since the skeleton had changed.
What I found is that when using the Character FBX Import and Character FBX Export nodes, Houdini will strip out any and all bones where there are no vertices with a weight for bone. So if I have a root bone that doesn't have verts directly weighted to it, it'll get removed on export despite the fact that it's the parent for a lot of other valid bones lol. You can see what it's removing by looking at the Rig Tree inspector after importing your result back into Houdini.
Anyways... the hacky solution I found was just add a dummy weight to random vertices for every bone I know was going to be stripped out. Basically right before exporting the skeletal mesh from Houdini throw it through this network:
- Capture Attribute Unpack node on your mesh so you can edit the boneCapture attributes in vex
- Attribute Wrangle vex code where I look at the imported skeleton and find bones that have no weights in the mesh. Add a dummy weight for that bone to any random vertex with a weight of 0.0 so it doesn't actually influence it.
- Capture Attribute Pack the boneCapture stuff back into the right format
Then, when you export it through the FBX Character Output node it will hopefully maintain the skeleton. Another gotcha I found was that Houdini adds an extra root node in your animated pose which messes up the import back into Unreal because the root nodes won't match (and prevents you from importing it as a LOD). I wasn't dealing with animation so I just omitted the animation pose from my export but I think you might also have to manually fix all those paths right before exporting.
This was all in Houdini 18.5 not sure if any of this behavior has changed, at the very least I would like an option to not strip out "unused" bones in the FBX Character Output node lol.
- Rob Chapman
- Member
- 53 posts
- Joined: July 2013
- Offline
omg, trying to train unreal engine skeleton mesh with muscle and tissue sims made in houdini and the round trip FBX Unreal > FBX houdini > FBX Unreal - I get 2 extra vertices (points) added in unreal engine (5.4)
Whilst everything imports OK the ML deformer training data needs the vertices count to match up between the FBX and the ground truth alembic geoemtry cache of the muscle sim...
this is an impossible situation. changing some of the FBX import settings in unreal I get varying amounts of vertices each time (generate normals, compute normals, preserve smoothing groups etc), the only way it seems to work is re-export the FBX from unreal - use this for the pose deformed muscle sim, and DO NOT REIMPORT to use as training data otherwise I get 2 extra verts added. OUCH!
Whilst everything imports OK the ML deformer training data needs the vertices count to match up between the FBX and the ground truth alembic geoemtry cache of the muscle sim...
this is an impossible situation. changing some of the FBX import settings in unreal I get varying amounts of vertices each time (generate normals, compute normals, preserve smoothing groups etc), the only way it seems to work is re-export the FBX from unreal - use this for the pose deformed muscle sim, and DO NOT REIMPORT to use as training data otherwise I get 2 extra verts added. OUCH!
- edward
- Member
- 7899 posts
- Joined: July 2005
- Offline
- Rob Chapman
- Member
- 53 posts
- Joined: July 2013
- Offline
After much further digging its the UV's causing the problem, deleting all UV attributes then problem goes away. so definately its an issue with Unreal engine 5.4 inmport end of the equation. Its a funny old game to get increasing vertices (points) every iteration doing a round trip from houdini > unreal > Houdini > unreal again. different settings with smoothing groups and various import FBX options with creating or not normals and tangents gave varying vertex count results, but this is an Unreal problem. normally(ha get it?) its not an issue for just an exported skeleton mesh to work as is, but in this case I needed the skeleton mesh vertices count to match EXACTLY another exported alembic file from Houdini, to train the ML Deformer correctly
so the training worked in the end ONLY if I made the alembic file from a point deformed version of the skeleton mesh via Houdini > Unreal > Houdini. it doesnt work from the orig Houdini export as the vertices ID number is different also so the deltas were WAY out of whack.
Happy days
so the training worked in the end ONLY if I made the alembic file from a point deformed version of the skeleton mesh via Houdini > Unreal > Houdini. it doesnt work from the orig Houdini export as the vertices ID number is different also so the deltas were WAY out of whack.
Happy days
Edited by Rob Chapman - May 10, 2024 16:05:07
-
- Quick Links