Returns the approximate volume of one or more closed mesh objects.
Rhino.MeshVolume (strObject)
Rhino.MeshVolume (arrObjects)
strObject |
Required. String. The object's identifier. |
arrObjects |
Required. Array. An array of object identifier. |
Array |
An array containing three numbers if successful. The three elements of the array are as follows:
|
||||||||||||
Null |
If not successful, or on error. |
Const rhObjectMesh = 32
Dim strObject, arrVolume
strObject = Rhino.GetObject("Select mesh", rhObjectMesh )
If Not IsNull(strObject) and Rhino.IsMeshClosed(strObject) Then
arrVolume = Rhino.MeshVolume(strObject)
If IsArray(arrVolume) Then
Rhino.Print "Mesh volume: " & CStr(arrVolume(1))
End If
End If