AddCylinder

Adds a cylinder to the document.

Syntax

Rhino.AddCylinder (arrBase, arrHeight, dblRadius [, blnCap [, blnExtrusion]])

Rhino.AddCylinder (arrPlane, dblHeight, dblRadius [, blnCap [, blnExtrusion]])

Parameters

arrBase

Required.  Array.  The 3-D base point of the cylinder.

arrPlane

Required.  Array.  The base plane of the cylinder.

arrHeight

Required.  Array.  The 3-D height point of the cylinder.  The height point defines the height and direction of the cylinder.

dblHeight

Required.  Number.  The height of the cylinder.

dblRadius

Required.  Number.  The radius of the cylinder.

blnCap

Optional.  Boolean.  Cap the ends of the cylinder.  If omitted, the ends of the cylinder will be capped (True).

blnExtrusion

Optional.  Boolean.  Create a lightweight extrusion. The default is to create a surface (uncapped) or a polysurface (capped) (False).

Returns

String

The identifier of the new object if successful.

Null

If not successful, or on error.

Example

Dim arrBase, arrHeight, dblRadius

dblRadius = 5.0

arrBase = Rhino.GetPoint("Base of cylinder")

If IsArray(arrBase) Then

arrHeight = Rhino.GetPoint("Height of cylinder", arrBase)

If IsArray(arrHeight) Then

Rhino.AddCylinder arrBase, arrHeight, dblRadius

End If

End If

Also See

AddBox

AddCone

AddSphere

AddTorus