lovr.graphics.cylinder

Draws a cylinder.

lovr.graphics.cylinder(x1, y1, z1, x2, y2, z2, r1, r2, capped, segments)

Arguments

NameTypeDefaultDescription
x1numberThe x coordinate of the top of the cylinder.
y1numberThe y coordinate of the top of the cylinder.
z1numberThe z coordinate of the top of the cylinder.
x2numberThe x coordinate of the bottom of the cylinder.
y2numberThe y coordinate of the bottom of the cylinder.
z2numberThe z coordinate of the bottom of the cylinder.
r1number1The radius of the top of the cylinder.
r2number1The radius of the bottom of the cylinder.
cappedbooleantrueWhether the top and bottom should be rendered.
segmentsnumbernilThe number of radial segments to use for the cylinder. If nil, the segment count is automatically determined from the radii.

Returns

Nothing

See also