Class Mesh
メッシュ情報です。
Unity や Unreal Engine でメッシュを生成するために必要な情報が含まれるよう意図されています。
具体的には 頂点リスト、Indicesリスト、UV、サブメッシュ(含テクスチャ)があります。
詳しくは Model クラスのコメントをご覧ください。
Inheritance
System.Object
Mesh
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Assembly: cs.temp.dll.dll
Syntax
Properties
CityObjectList
Declaration
public CityObjectList CityObjectList { get; set; }
Property Value
Handle
Declaration
public IntPtr Handle { get; }
Property Value
IndicesCount
Declaration
public int IndicesCount { get; }
Property Value
Type |
Description |
System.Int32 |
|
SubMeshCount
Declaration
public int SubMeshCount { get; }
Property Value
Type |
Description |
System.Int32 |
|
VertexColorCount
Declaration
public int VertexColorCount { get; }
Property Value
Type |
Description |
System.Int32 |
|
VerticesCount
Declaration
public int VerticesCount { get; }
Property Value
Type |
Description |
System.Int32 |
|
Methods
AddSubMesh(String, Int32, Int32)
Declaration
public void AddSubMesh(string texturePath, int subMeshStartIndex, int subMeshEndIndex)
Parameters
Type |
Name |
Description |
System.String |
texturePath |
|
System.Int32 |
subMeshStartIndex |
|
System.Int32 |
subMeshEndIndex |
|
Create(PlateauVector3d[], UInt32[], PlateauVector2f[], PlateauVector2f[], SubMesh[])
Declaration
public static Mesh Create(PlateauVector3d[] vertices, uint[] indices, PlateauVector2f[] uv1, PlateauVector2f[] uv4, SubMesh[] subMeshes)
Parameters
Type |
Name |
Description |
PlateauVector3d[] |
vertices |
|
System.UInt32[] |
indices |
|
PlateauVector2f[] |
uv1 |
|
PlateauVector2f[] |
uv4 |
|
SubMesh[] |
subMeshes |
|
Returns
Create(String)
Declaration
public static Mesh Create(string meshID)
Parameters
Type |
Name |
Description |
System.String |
meshID |
|
Returns
DebugString(StringBuilderWithIndent)
Declaration
public void DebugString(StringBuilderWithIndent sb)
Parameters
Type |
Name |
Description |
StringBuilderWithIndent |
sb |
|
Dispose()
取扱注意:
通常は Node が廃棄されるときに C++側で Mesh も廃棄されるので、このメソッドを呼ぶ必要はありません。
Node に属さず、C#側で明示的に Create した Mesh のみ Dispose() してください。
それ以外のタイミングで呼ぶとメモリ違反でUnityが落ちます。
Declaration
GetIndiceAt(Int32)
Declaration
public int GetIndiceAt(int index)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
Returns
Type |
Description |
System.Int32 |
|
GetSubMeshAt(Int32)
Declaration
public SubMesh GetSubMeshAt(int index)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
Returns
GetUv1()
Declaration
public PlateauVector2f[] GetUv1()
Returns
Type |
Description |
PlateauVector2f[] |
|
GetUv4()
Declaration
public PlateauVector2f[] GetUv4()
Returns
Type |
Description |
PlateauVector2f[] |
|
GetVertexAt(Int32)
Declaration
public PlateauVector3d GetVertexAt(int index)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
Returns
Type |
Description |
PlateauVector3d |
|
GetVertexColorAt(Int32)
Declaration
public PlateauVector3d GetVertexColorAt(int index)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
Returns
Type |
Description |
PlateauVector3d |
|
MarkInvalid()
Declaration
public void MarkInvalid()
MergeMesh(Mesh, Boolean)
Declaration
public void MergeMesh(Mesh otherMesh, bool includeTexture)
Parameters
Type |
Name |
Description |
Mesh |
otherMesh |
|
System.Boolean |
includeTexture |
|
SetVertexColors(PlateauVector3d[])
Declaration
public void SetVertexColors(PlateauVector3d[] colorArray)
Parameters
Type |
Name |
Description |
PlateauVector3d[] |
colorArray |
|