
Returns normals as a 2-dimensional Array. The x,y,z values are in the first dimension.
set oRoot = Application.ActiveProject.ActiveScene.Root
set oObj = oRoot.AddGeometry( "Cube", "MeshSurface" )
set oGeometry = oObj.ActivePrimitive.Geometry
' Offset all x positions
aNormals = oGeometry.Segments.NormalArray
for i = LBound(aNormals, 2) to UBound(aNormals, 2)
LogMessage "normal[" & i & "] =" & aNormals(0,i) & "," & aNormals(1,i) & "," & aNormals(2,i)
next
|