AddCone

Adds a cone-shaped polysurface to the document.

Syntax

rhinoscriptsyntax.AddCone (base, height, radius, cap=True)

rhinoscript.surface.AddCone (base, height, radius, cap=True)

Parameters

base

Required.  The 3-D origin point of the cone or a plane with an apex at the origin and normal along the plane's zaxis

height

Required.  The 3-D height point of the cone if base is a 3D point.  The height point defines the height and direction of the cone. If base is a plane, then height is a numeric height value

radius

Required.  Number.  The radius at the base of the cone.  Note, tan(cone_angle) = radius/ height.

cap

Optional.  Boolean.  Cap the base of the cone.  The default is to cap the cone (True).

Returns

Guid

The identifier of the new object if successful.

None

If not successful, or on error.

Example

import rhinoscriptsyntax as rs

radius = 5.0

base = rs.GetPoint("Base of cone")

if base:

    height = rs.GetPoint("Height of cone", base)

    if height: rs.AddCone(base, height, radius)

Also See

AddBox

AddCylinder

AddSphere

AddTorus