|
To me it looks like a issue of your application. Because ComputerVertexNormal will give you normals of 8 vertices and the cache file also reference 8 vertices, they are match.
So in your application it need to be able to map the 8 vertices to 24 polygon vertices. And I think FBX already keep this kind of informations as PolygonVertexIndex.
Also there are several other ways to deal this:
1. Split the mesh in Maya first, to make sure the generated cache are also by per polygon vertices, in this example, with 24 vertices. Then export FBX file with “split per-vertex normals” on.
2. In you application, you can set same normal for the vertices that are taken as one vertex in Maya/FBX. In the cube example, in your application there are 24 vertices, but in FBX files, there are only 8 normals, so actually there are 3 vertices in your application should have the same normal, just find them and map the same normal.
All in all, the purpose is to make the number of vertices, normals and cache points match.
Author: Jiayang Xu
|