Pass:cylinder

Edit

Draws a cylinder.





Arguments

NameTypeDefaultDescription
xnumber0 The x coordinate of the center of the cylinder.
ynumber0 The y coordinate of the center of the cylinder.
znumber0 The z coordinate of the center of the cylinder.
radiusnumber1 The radius of the cylinder.
lengthnumber1 The length of the cylinder.
anglenumber0 The rotation of the cylinder around its rotation axis, in radians.
axnumber0 The x component of the axis of rotation.
aynumber1 The y component of the axis of rotation.
aznumber0 The z component of the axis of rotation.
cappedbooleantrue Whether the tops and bottoms of the cylinder should be rendered.
angle1number0 The angle of the beginning of the arc.
angle2number2 * math.pi angle of the end of the arc.
segmentsnumber64 The number of circular segments to render.

Returns

Nothing

Arguments

NameTypeDefaultDescription
positionVec3 The position of the center of the cylinder.
radiusnumber1 The radius of the cylinder.
lengthnumber1 The length of the cylinder.
orientationQuat The orientation of the cylinder.
cappedbooleantrue Whether the tops and bottoms of the cylinder should be rendered.
angle1number0 The angle of the beginning of the arc.
angle2number2 * math.pi angle of the end of the arc.
segmentsnumber64 The number of circular segments to render.

Returns

Nothing

Arguments

NameTypeDefaultDescription
transformMat4 The transform of the cylinder.
cappedbooleantrue Whether the tops and bottoms of the cylinder should be rendered.
angle1number0 The angle of the beginning of the arc.
angle2number2 * math.pi angle of the end of the arc.
segmentsnumber64 The number of circular segments to render.

Returns

Nothing

Arguments

NameTypeDefaultDescription
p1Vec3 The starting point of the cylinder.
p2Vec3 The ending point of the cylinder.
radiusnumber1 The radius of the cylinder.
cappedbooleantrue Whether the tops and bottoms of the cylinder should be rendered.
angle1number0 The angle of the beginning of the arc.
angle2number2 * math.pi angle of the end of the arc.
segmentsnumber64 The number of circular segments to render.

Returns

Nothing

Notes

The local origin is in the center of the cylinder, and the length of the cylinder is along the z axis.

See also