This project has moved and is read-only. For the latest updates, please go here.
Finishes mesh optimization by reordering vertices and/or adding duplicated vertices for the vertex buffer, and the point representatives.

HRESULT FinalizeVBAndPointReps(
   _In_reads_bytes_(nVerts*stride) const void* vbin, _In_ size_t stride,
   _In_ size_t nVerts,
   _In_reads_(nVerts) const uint32_t* prin, 
   _In_reads_opt_(nDupVerts) const uint32_t* dupVerts, _In_ size_t nDupVerts,
   _In_reads_opt_(nVerts+nDupVerts) const uint32_t* vertexRemap, 
   _Out_writes_bytes_((nVerts+nDupVerts)*stride) void* vbout,
   _Out_writes_(nVerts+nDupVerts) uint32_t* prout );

HRESULT FinalizeVBAndPointReps(
   _Inout_updates_bytes_all_(nVerts*stride) void* vb, _In_ size_t stride,
   _In_ size_t nVerts,
   _Inout_updates_all_(nVerts) uint32_t* pointRep,
   _In_reads_(nVerts) const uint32_t* vertexRemap );

Parameters

A vertexRemap is an array with nVerts elements that describes how to reorder the vertices of the original mesh. This maps the original vertex location to the optimized location. See OptimizeVertices.

dupVerts contains nDupVerts elements indicating vertices that need duplicating. Each entry indicates the index of the original vbin vertex buffer to duplicate. The vertexRemap array also indicates reorder information for the duplicated vertices.

Last edited Jun 14, 2014 at 2:41 AM by walbourn, version 1