Using the Runtime Mesh Component plugin, creating a runtime mesh requires the set of vertex normals (among other things) to be passed in. I was intending to do this by getting all needed data from a static mesh already in the level.
With a static mesh, I am able to get:
vertex positions from mesh->RenderData->LODResources[0].VertexBuffers.PositionVertexBuffer;
vertex indexes from mesh->RenderData->LODResources[0].IndexBuffer.GetArrayView();
I am guessing I can also get UVs and tangents from:
VertexBuffers.StaticMeshVertexBuffer.GetVertexUV(), and
I’m not 100% sure that this is the right thing to do for getting a Static Mesh’s vertex normals & tangents. I really only stumbled upon the public variables and did a quick test with an 8-vertex cube.
Those look like the normals. What are they needed for? Isn’t there a view mode or something in the dropdowns of the engine UI to show vertex normals of meshes? is it possible to reference that in a get / call operation that’d work with the plugin?
They were indeed what I needed (to confirm for you and any future readers); I’ve been using it since.
Hooking into something available in the UI might be possible but wouldn’t be as direct as using VertexTangentZ().