Triangle.Points

Triangle.Points

説明

このトライアングルに対するTrianglePointオブジェクトを含むTrianglePointCollectionを戻します。

C#構文

// get accessor

TrianglePointCollection rtn = Triangle.Points;

VBScript の例

' This example illustrates how to enumerate the triangles

' of a polygon mesh an print out the position of each

' triangle vertex

set oRoot = Application.ActiveProject.ActiveScene.root

set oCube = oRoot.AddGeometry( "Cube", "MeshSurface" )

set oGeometry = oCube.ActivePrimitive.Geometry

set oTriangles = oGeometry.Triangles

Application.LogMessage "Object: " & oCube.Name

Application.LogMessage "Number of triangles: " & oTriangles.Count

for each oTriangle in oTriangles

	Application.LogMessage oTriangle.Name

	for each oVertex in oTriangle.Points

		set oPosition = oVertex.Position

		Application.LogMessage vbTab & oPosition.x & "," & _

			oPosition.y & "," & _

			oPosition.z

	next

next

関連項目

TriangleCollection TrianglePoint TrianglePointCollection Geometry