NewtonMeshMaterialGetIndexStream

From Newton Wiki
Jump to: navigation, search

NewtonMeshMaterialGetIndexStream

void NewtonMeshMaterialGetIndexStream (const NewtonMesh* const mesh, void* const handle, int materialId, int* const index)

Usage

Returns the vertex indices of the faces of the mesh which share the given material.

Parameters

  • const NewtonMesh* mesh - pointer to the mesh primitive.
  • int materialHandle - the mesh material handle.
  • int* index - pointer to the storage in memory which will hold the indices.

Return

  • Nothing.

Description

Returns the vertex indices of the faces of the mesh which share the given material.

Remarks

  • Added in Newton 2.0
  • The memory are pointed by index shall have enough room for the index data
  • If the number of indices in the mesh is small enough it is more efficient to use NewtonMeshMaterialGetIndexStreamShort instead

See also

NewtonMeshMaterialGetIndexCount NewtonMeshMaterialGetIndexStreamShort