Create Method


Construct a cylindrical surface defined by a local coordinate system and a radius.

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 22.0.0.0 (22.1.0.0)
Since: 2017

Syntax

C#
public static CylindricalSurface Create(
	Frame frameOfReference,
	double radius
)
Visual Basic
Public Shared Function Create ( _
	frameOfReference As Frame, _
	radius As Double _
) As CylindricalSurface
Visual C++
public:
static CylindricalSurface^ Create(
	Frame^ frameOfReference, 
	double radius
)

Parameters

frameOfReference
Type: Autodesk.Revit.DB Frame
frameOfReference is an orthonormal frame that defines a local coordinate system for the cylinder.
  • Frame.Origin is a point on the cylinder's axis.
  • Frame.BasisZ points along the axis, while Frame.BasisX and Frame.BasisY are orthogonal to the axis.
  • The frame may be either left-handed or right-handed (see Frame.IsRightHanded). Note that the "handedness" of the frame does not, by itself, determine the surface's orientation.
radius
Type: System Double
Radius of the circle that defines the base of the cylindrical surface.

Return Value

The created CylindricalSurface.

Remarks

The parametric equation of the cylinder is S(u, v) = Frame.Origin + radius*cos(u)*Frame.BasisX + radius*sin(u)*Frame.BasisY + v*Frame.BasisZ. This implies the following facts:
  • Frame.BasisX points from the axis point to the point on the cylinder with coordinates (0, 0).
  • Frame.BasisY points in the direction of the partial derivative dS/du at (0, 0).
  • Frame.BasisZ points in the direction of the partial derivative dS/dv at (0, 0).

Exceptions

Exception Condition
Autodesk.Revit.Exceptions ArgumentException This Frame object may not be used as a local frame of reference.
Autodesk.Revit.Exceptions ArgumentNullException A non-optional argument was null
Autodesk.Revit.Exceptions ArgumentOutOfRangeException The given value for radius must be greater than 0 and no more than 30000 feet.

See Also