I’ve been trying to build a character creator with Mutable for a while (currently using UE 5.6.1). It is a really great plugin when it works as it should, but I’ve ran into a few problems:
The biggest issue I currently have is that I have found no way to force the generated mesh to recompute its tangents (except by using an ugly C++ hack, which causes its own issues), so the shading ends up being off when applying morph targets.
This was not an issue with UE 5.5, but I believe certain rendering functionality was changed for the skeletal meshes at this engine version, so maybe not directly the fault of the Mutable plugin.
Changing the morph values on one of the base skeletal meshes in the skeletal mesh editor (after enabling recompute tangents and setting a mask channel) works as expected (except that choosing “Enable with no mask” doesn’t do anything, but I suspect that is a base engine bug, would still be nice to see it fixed as soon as possible).
Another issue is the inability to set a custom mesh deformer on the generated asset. Any attempts at applying one through the skeletal mesh component causes the editor to crash. But the main reason I’ve been trying to apply a deformer is as a workaround for the tangent re-computation issue.
I’ve also had issues where changing a morph target value will fail to update the generated mesh geometry if the model has more than one UV-layer, but I saw a thread mentioning it would be fixed later (but not as of 5.7.3, from what I’ve seen in my tests).
But back to the tangent re-calculations: Perhaps I’m doing something wrong, maybe an option that I’ve missed in the customizable object or something like that? Anyone else using Mutable having the same issue?
Hi Eranon, I’m having the exact same issues here in Unreal 5.7.4!
I have been trying to apply a Deformer Graph to the Skeletal Mesh component that gets populated by the Customizable Skeletal Component, and just like you I get an editor crash instantly when trying to compile the actor.
I also have been trying to find a way to turn on Recompute Tangents on the base skeletal meshes, but those settings never make it through into the Mutable transient generated skeletal mesh.
Hi @Eranon Whats the CPP patch for this ? and what are the extra issues caused by your patch? im having this issue too. would like to try your fix. thanks.
Hi. Unfortunately I haven’t been able to get any closer to a workaround for this issue (except for the C++ solution I mentioned in my original post, which causes a nasty visual bug. I explain it more in my post below). I think we just have to wait for Epic to add a “recompute tangents” option to the mutable system.
Hi. The issue with the C++ “fix” that I tried to implement is that it creates a very visible shadowy seam along the UV-borders of the mesh. I haven’t been able to figure out why it does that.
But if you’d like to try it out here’s the code I wrote:
FSkeletalMeshLODRenderData* RenderData = &CustomizableObjectInstance->GetSkeletalMeshComponentSkeletalMesh(GeneratedMeshName)->GetResourceForRendering()->LODRenderData[0];
for (FSkelMeshRenderSection& Section : RenderData->RenderSections)
{
Section.bRecomputeTangent = true;
Section.RecomputeTangentsVertexMaskChannel = ESkinVertexColorChannel::Blue; // <-- Doesn't have to be the blue channel
}
I run this code in a function that is bound to the update callback when updating the look of the skeletal mesh. The “GeneratedMeshName” variable is just the name of the skeletal mesh component that is set inside of your customizable object.
You’ll also probably need to include this header to access the rendering resources: “Rendering/SkeletalMeshRenderData.h”
I haven’t really tried to do more with this approach since I’m guessing recomputing tangents will eventually get implemented into Mutable. But if anyone figures out a workaround that doesn’t have any notable visual issues, then I’d like to know.