UStaticMesh::BuildFromMeshDescription specify tangents?

Hi all,

I’m generating a custom mesh programmatically via the new BuildFromMeshDescription functionality.

I am able to successfully generate a mesh with desired vertex position, normal, colour + triangles.

However, things fall down when I try and apply a normal map (it doesn’t work) presumably because I haven’t specified tangents/binormals.

I’m struggling to figure out how to do so via the api…

Anyone overcome this issue before? Am I missing something simple?

Thanks

Disregard! Figured out you can get the VertexInstanceTangents from the Static mesh attributes and update from there -

TVertexInstanceAttributesRef VertexInstanceTangents = Attributes.GetVertexInstanceTangents();