Description
Checks the convexity of the edge-use if manifold.
Syntax
Function RFEdgeUse.CalcConvexity(pResult As Long) As RFErrorCode
The CalcConvexity syntax has these parts:
| Part | Description |
|---|---|
| pResult | [OUT] Long Required. -1, 0 or 1 value indicating two faces sharing the edge-use are concave, planar or convex respectively. |
Remarks
Sample
Dim rfErr As RapidForm.RFErrorCode
Dim shObj As RapidForm.RFShell
Dim fcObj As RapidForm.RFFace
Dim edObj As RapidForm.RFEdgeUse
' Assign RFShell, RFFace and RFEdgeUse interface objects
Set shObj = RapidForm.Shell
Set fcObj = RapidForm.Face
Set edObj = RapidForm.EdgeUse
' Pick a face.
Dim pickedID As RFEntityID
rfErr = RapidForm.SelectTools.PickEntity(RF_PICK_FACE, 1, pickedID)
fcObj.SetID (pickedID)
Dim vtID(2) As RFEntityID
' Retrieves 3 vertices of the face.
rfErr = fcObj.GetVertices(vtID(0), vtID(1), vtID(2))
' Identify an edge use by using the first two vertices.
rfErr = edObj.SetID(vtID(0), vtID(1))
' Check if the edge use is a manifold edge.
Dim bManifold As Boolean
rfErr = edObj.IsManifold(bManifold)
If bManifold = True Then
' Calculate the convexity
Dim cvxEd As Long
rfErr = edObj.CalcConvexity(cvxEd)
End If