primitiveCone operation

Syntax

  • primitiveCone()
  • primitiveCone(sides)
  • primitiveCone(sides, radius, height)

Parameters

  1. sidesfloat
    Number of subdivisions of the cone surface. There must be at least 3 sides. The default value is 16.
  2. radiusfloat
    Radius of the cone.
  3. heightfloat
    Height of the cone.

Description

The primitiveCone operation inserts a cone geometry into the scope of the current shape.

  • If no radius and height are given the bounding box coincides with the scope. Zero scope sizes are handled the same way as in the i operation.
  • If dimensions are specified the cone is positioned in the xz-center of the scope lying on y=0.

The cone has texture coordinates on the first texture layer (COLORMAP).

Related

Examples

The inserted cone has 16 sides and is fit into the current scope. The scope's zero size is modified relative to the average of the two non-zero sizes.

Lot-->
   primitiveCone()
   texture("builtin:uvtest.png")
Cone with 16 sides

The inserted cone has 8 sides, a radius of 10, a height of 15 and is positioned in the xz center.

Lot-->
   primitiveCone(8,10,15 )
   texture("builtin:uvtest.png")
Cone with 8 sides