Pass:torus

Edit

Draws a torus.




Arguments

NameTypeDefaultDescription
xnumber0 The x coordinate of the center of the torus.
ynumber0 The y coordinate of the center of the torus.
znumber0 The z coordinate of the center of the torus.
radiusnumber1 The radius of the torus.
thicknessnumber1 The thickness of the torus.
anglenumber0 The rotation of the torus 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.
tsegmentsnumber64 The number of toroidal (circular) segments to render.
psegmentsnumber32 The number of poloidal (tubular) segments to render.

Returns

Nothing

Arguments

NameTypeDefaultDescription
positionVec3 The position of the center of the torus.
scaleVec3 The size of the torus (x and y scale the radius, z is the thickness).
orientationQuat The orientation of the torus.
tsegmentsnumber64 The number of toroidal (circular) segments to render.
psegmentsnumber32 The number of poloidal (tubular) segments to render.

Returns

Nothing

Arguments

NameTypeDefaultDescription
transformMat4 The transform of the torus.
tsegmentsnumber64 The number of toroidal (circular) segments to render.
psegmentsnumber32 The number of poloidal (tubular) segments to render.

Returns

Nothing

Notes

The local origin is in the center of the torus, and the torus forms a circle around the local Z axis.

See also