[page:Geometry] →

[name]

Creates a torus knot, the particular shape of which is defined by a pair of coprime integers, p and q. If p and q are not coprime, the result will be a torus link.

Example

var geometry = new v3d.TorusKnotGeometry(10, 3, 100, 16); var material = new v3d.MeshBasicMaterial({ color: 0xffff00 }); var torusKnot = new v3d.Mesh(geometry, material); scene.add(torusKnot);

Constructor

[name]([param:Float radius], [param:Float tube], [param:Integer tubularSegments], [param:Integer radialSegments], [param:Integer p], [param:Integer q])

Properties

.parameters

An object with a property for each of the constructor parameters. Any modification after instantiation does not change the geometry.

[sourceHint]