Version 0.60.0

cylinder

A cylinder with circular or elliptical basis.

Signatures

  •   cylinder()
  •   cylinder( float height, float radius )
  •   cylinder( float height, float radius, vector position )
  •   cylinder( float height, float radiusX, float radiusY )
  •   cylinder( float height, float radiusX, float radiusY, vector position )
  •   cylinder( vector direction, float radius )
  •   cylinder( vector direction, vector radial )
  •   cylinder( vector direction, vector radialA, vector radialB )
  •   cylinder( vector direction, vector radialA, vector radialB, vector position )

Details

Constructors (1), (2), (3), (6) and (7) create cylinders with a circular basis. The basis radius is 0.5 for constructor (1), radius for constructors (2), (3) and (6) or the length of vector radial for constructor (7).

Constructors (4), (5), (8) and (9) can have an elliptical basis with two radii. The radii values are radiusX and radiusY in X and Y directions (constructors (4) and (5)) or the length of vectors radialA and radialB (constructors (8) and (9)).

For constructors (1) to (6) the basis planes are orthogonal to the cylinder direction (i.e. the plane normals are parallel to the direction vector) whereas constructors (7) to (9) allow a tilting of the basis planes. This is defined by vectors radial, radialA and radialB that are in-plane vectors of the basis.

The cylinder height is either given by parameter height or by the length of vector direction. direction can also be used to align the cylinder within an arbitrary direction.

Casts To

solid

Parameters

height

Height of the cylinder (in Z direction).

radius

Basis radius of the circular cylinder.

radiusX

Basis radius in X direction of an elliptical cylinder.

radiusY

Basis radius in Y direction of an elliptical cylinder.

direction

Vector defining the axis direction and length of a cylinder that is aligned along an arbitrary direction.

radialA

Vector defining direction and length of one basis radius of an elliptical cylinder with arbitrarily aligned base plates.

radialB

Vector defining direction and length of another basis radius of an elliptical cylinder with arbitrarily aligned base plates.

position

Translation vector that is applied to the cylinder.

🗙

Search results for