Reorders the faces grouping together all those that use the same attribute id.
This optimizes draw submission by minimizing state changes and maximizing draw batches.
_In_ size_t nFaces, _Inout_updates_all_(nFaces) uint32_t* attributes,
_Out_writes_(nFaces) uint32_t* faceRemap );
array is sorted by this function.
indicates the new face ordering. See
This function does not duplicate any vertices. The ideal attribute sort for vertex pre-transform cache optimization ensures that each vertex is only used once for a given attribute. This can be accomplished by calling
before doing this sort.