Click or drag to resize
Ab4d.SharpEngine logo

TriangleMeshTSetCustomIndexBuffer(Int32, GpuBuffer, Int32, Int32, IndexType) Method

Sets the TriangleIndices and a custom index buffer that is used to render the mesh.

Namespace: Ab4d.SharpEngine.Meshes
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 4.1.9680+a1b1e43de1ad9a7e35472c33948d688d7b40ef79
Syntax
C#
public void SetCustomIndexBuffer(
	int[]? newTriangleIndices,
	GpuBuffer customIndexBuffer,
	int indexOffset = 0,
	int customIndexCount = -1,
	IndexType indexBufferType = IndexType.Uint32
)

Parameters

newTriangleIndices  Int32
Array of integers that define the triangles
customIndexBuffer  GpuBuffer
new indexBuffer as GpuBuffer
indexOffset  Int32  (Optional)
custom index offset (0 by default) that specifies an offset in the index buffer where data for this mesh begins
customIndexCount  Int32  (Optional)
when positive number, then it specifies the custom number of used triangle indices; when negative, then number of items in the indexBuffer is used (-1 by default).
indexBufferType  IndexType  (Optional)
Type of index buffer (Uint32 by default)
See Also