Mesh
.Mesh
Manual
Reference
Scripting
Scripting
>
Runtime Classes
>
Mesh
Mesh
.Mesh
Menu
Overview
Runtime Classes
Attributes
Enumerations
Editor Classes
Enumerations
History
Index
Mesh
All Members
Variables
bindposes
boneWeights
bounds
colors
normals
subMeshCount
tangents
triangles
uv
uv2
vertexCount
vertices
Constructors
Mesh
Functions
Clear
CombineMeshes
GetTriangles
Optimize
RecalculateBounds
RecalculateNormals
SetTriangles
Inherited Variables
hideFlags
name
Inherited Functions
GetInstanceID
ToString
Inherited Class Functions
Destroy
DestroyImmediate
DontDestroyOnLoad
FindObjectOfType
FindObjectsOfType
Instantiate
Instantiate.<T>
operator !=
operator ==
operator bool
static
function
Mesh () : Mesh
Description
Creates an empty mesh
JavaScripts
JavaScript
C#
Boo
// Create a new mesh and assign it to the mesh filter
function
Start
() {
var
mesh : Mesh =
new
Mesh ();
GetComponent(
MeshFilter
).mesh = mesh;
}
using UnityEngine;
using System.Collections;
public
class
example :
MonoBehaviour
{
void
Start
() {
Mesh mesh =
new
Mesh();
GetComponent<
MeshFilter
>().mesh = mesh;
}
}
import
UnityEngine
import
System.Collections
class
example(
MonoBehaviour
):
def
Start
():
mesh as Mesh = Mesh()
GetComponent[of
MeshFilter
]().mesh = mesh