What's New in Director 8.5 > Working with Models and Model Resources > Primitives > Cylinder properties

 

Cylinder properties

Cylinders have a type property of #cylinder. Director generates a cylinder's surface by sweeping a 2D line around the Z axis in the XY plane from startAngle to endAngle. If startAngle = 0.0 and endAngle = 360.0, a full cylinder is generated. If startAngle = 180.0 and endAngle = 360.0, a half cylinder is generated. These properties can be modified or animated at run time.

Property

Access

Description

Value Range

topRadius

Get and set

Radius of the top of the cylinder. Setting this value to 0 produces a cone.

Positive floating-point value. The default is 25.0.

bottomRadius

Get and set

Radius of the bottom of the cylinder.

Positive floating-point value. The default is 25.0.

numSegments

Get and set

Number of polygonal segments from bottom to top.

An integer value greater than 0.

resolution

Get and set

Number of polygonal segments around the circumference of the circle. Controls the smoothness of the cylinder's appearance.

An integer value greater than 1.

height

Get and set

Height of the cylinder along the Z axis.

Positive floating-point value. The default is 50.0.

topCap

Get and set

Value indicating whether the top of the cylinder is closed or open. TRUE = closed.

TRUE or FALSE. The default is TRUE.

bottomCap

Get and set

Value indicating whether the bottom of the cylinder is closed or open. TRUE = closed.

TRUE or FALSE. The default is TRUE.