Cylinder

class rhino3dm.Cylinder
Cylinder(baseCircle)

Constructs a new cylinder with infinite height.

Parameters:baseCircle (Circle) – Base circle for infinite cylinder.
Cylinder(baseCircle, height)

Constructs a new cylinder with a finite height.

Parameters:
  • baseCircle (Circle) – Base circle for cylinder.
  • height (float) – Height of cylinder (zero for infinite cylinder).
IsValid

bool: Gets a boolean value indicating whether this cylinder is valid. A valid cylinder is represented by a valid circle and two valid heights.

IsFinite

bool: True if the cylinder is finite (Height0 != Height1) False if the cylinder is infinite.

Center

rhino3dm.Point3d: Gets the center point of the defining circle.

Axis

rhino3dm.Vector3d: Gets the axis direction of the cylinder.

TotalHeight

float: Gets the height of the cylinder. Infinite cylinders have a height of zero, not Double.PositiveInfinity.

Height1

float: Gets or sets the start height of the cylinder. The center of bottom cap is: BasePlane.Origin + Height1 * BasePlane.ZAxis.

Height2

float: Gets or sets the end height of the cylinder. If the end height equals the start height, the cylinder is presumed to be infinite. The center of top cap is: BasePlane.Origin + Height2 * BasePlane.ZAxis.

Radius

float: Gets or sets the radius of the cylinder.

CircleAt(linearParameter)

Compute the circle at the given elevation parameter.

Parameters:linearParameter (float) – Height parameter for circle section.
Return type:Circle
ToBrep(capBottom, capTop)

Constructs a Brep representation of this Cylinder. This is synonymous with calling NurbsSurface.CreateFromCylinder().

Parameters:
  • capBottom (bool) – If true, the bottom of the cylinder will be capped.
  • capTop (bool) – If true, the top of the cylinder will be capped.
Returns:

A Brep representation of the cylinder or null.

Return type:

rhino3dm.Brep

ToNurbsSurface()

Constructs a Nurbs surface representation of this cylinder. This is synonymous with calling NurbsSurface.CreateFromCylinder().

Returns:A Nurbs surface representation of the cylinder or null.
Return type:NurbsSurface