MCPcopy Create free account
hub / github.com/assimp/assimp / GetMeshVFormat

Function GetMeshVFormat

code/PostProcessing/PretransformVertices.cpp:60–73  ·  view source on GitHub ↗

Get a bitwise combination identifying the vertex format of a mesh

Source from the content-addressed store, hash-verified

58
59// Get a bitwise combination identifying the vertex format of a mesh
60static unsigned int GetMeshVFormat(aiMesh *pcMesh) {
61 // the vertex format is stored in aiMesh::mBones for later retrieval.
62 // there isn't a good reason to compute it a few hundred times
63 // from scratch. The pointer is unused as animations are lost
64 // during PretransformVertices.
65 if (pcMesh->mBones)
66 return (unsigned int)(uint64_t)pcMesh->mBones;
67
68 const unsigned int iRet = GetMeshVFormatUnique(pcMesh);
69
70 // store the value for later use
71 pcMesh->mBones = (aiBone **)(uint64_t)iRet;
72 return iRet;
73}
74
75// Get a list of all vertex formats that occur for a given material index
76// The output list contains duplicate elements

Callers 3

GetVFormatListFunction · 0.85
CountVerticesAndFacesMethod · 0.85
CollectDataMethod · 0.85

Calls 1

GetMeshVFormatUniqueFunction · 0.85

Tested by

no test coverage detected