Skip to main content

Mesh

info
  • This class is only available on LocalAvatarScripts and LocalScripts

Allows developers to create or modify meshes.

Methods

Method NameReturn TypeParametersDescription
ClearvoidnoneClears all the vertex data and all triangle indices
GetVerticesfloat3[]noneGets the vertex positions of the Mesh
GetIndicesint[]noneFetches the index list for the specified sub-mesh
SetVerticesvoidfloat3[]Assigns a new vertex positions array
SetNormalsvoidfloat3[]Set the normals of the Mesh
SetTangentsvoidfloat4[]Set the tangents of the Mesh
SetUVsvoidfloat2[]Sets the texture coordinates (UVs) stored in a given channel
SetIndicesvoidint[], intSets the index buffer for the sub-mesh
SetSubMeshvoidint, int, intSets the information about a sub-mesh of the Mesh
RecalculateNormalsvoidnoneRecalculates the normals of the Mesh from the triangles and vertices

Properties

Property NameTypeDescription
IsReadableboolReturns if the mesh has read/write enabled
SubMeshCountintThe number of sub-meshes inside the Mesh object