Builds a mesh by extruding curve loop(s) along extrusion distance.
Namespace: Autodesk.Revit.DBAssembly: RevitAPI (in RevitAPI.dll) Version: 21.0.0.0 (21.1.1.109)
Since: 2015
Syntax
C# |
---|
public static MeshFromGeometryOperationResult CreateMeshByExtrusion( IList<CurveLoop> profileLoops, XYZ extrusionDirection, double extrusionDistance, ElementId materialId ) |
Visual Basic |
---|
Public Shared Function CreateMeshByExtrusion ( _ profileLoops As IList(Of CurveLoop), _ extrusionDirection As XYZ, _ extrusionDistance As Double, _ materialId As ElementId _ ) As MeshFromGeometryOperationResult |
Visual C++ |
---|
public: static MeshFromGeometryOperationResult^ CreateMeshByExtrusion( IList<CurveLoop^>^ profileLoops, XYZ^ extrusionDirection, double extrusionDistance, ElementId^ materialId ) |
Parameters
- profileLoops
- Type: System.Collections.Generic..::..IList<(Of <(<'CurveLoop>)>)>
The profile loops to be extruded. The loops will not be modified.
- extrusionDirection
- Type: Autodesk.Revit.DB..::..XYZ
Direction of extrusion. The length of this vector is ignored.
- extrusionDistance
- Type: System..::..Double
The positive distance by which the loops are extruded in the direction of the input extrusionDir.
- materialId
- Type: Autodesk.Revit.DB..::..ElementId
Material which should be used by a constructed mesh.
Return Value
Returns a mesh, which was constructed, and some additional information.
Remarks
This function supports creation of a mesh given a collection
of continuous curve loops, which are processed independently
from each other. Loops with gaps or with curves with
wrong flips will be split before processing.
Exceptions
Exception | Condition |
---|---|
Autodesk.Revit.Exceptions..::..ArgumentException | The input value cannot be used as thickness for an extrusion, or blend, or wall layer, or similar geometric construct. |
Autodesk.Revit.Exceptions..::..ArgumentNullException | A non-optional argument was NULL |
Autodesk.Revit.Exceptions..::..ArgumentOutOfRangeException | extrusionDirection has zero length. |