How to use the TetrahedronGeometry function from three

Find comprehensive JavaScript three.TetrahedronGeometry code examples handpicked from public code repositorys.

38
39
40
41
42
43
44
45
46
47
for (var i = 0, j = lines.length; i < j; i++) {
  group.add(lines[i]);
  inTweens.push(this.getInTween(lines[i]));
}

var triangleGeometry = new THREE.TetrahedronGeometry(3);
var triangleMaterial = new THREE.MeshLambertMaterial({ shading: THREE.FlatShading });
var triangleMesh = new THREE.Mesh(triangleGeometry, triangleMaterial);

var follow = this.getFollow(triangleMesh, subs);
fork icon57
star icon254
watch icon10

+ 7 other calls in file

40
41
42
43
44
45
46
47
48
49
// Array geometries (the platonic solids!)
const geoms = [
  new THREE.IcosahedronGeometry(size),
  new THREE.BoxGeometry(size, size, size),
  new THREE.OctahedronGeometry(size),
  new THREE.TetrahedronGeometry(size),
  new THREE.DodecahedronGeometry(size)
]

// Loop through meshes
fork icon0
star icon3
watch icon1

19
20
21
22
23
24
25
26
27
this.circle = new THREE.Object3D()
this.geometry = []
this.geometrySleeve = []
this.geometryLength = 100
this.geometryType = [
  new THREE.TetrahedronGeometry(50, 0),
  new THREE.IcosahedronGeometry(40, 0),
  new THREE.OctahedronGeometry(40, 0)
]
fork icon11
star icon0
watch icon1

44
45
46
47
48
49
50
51
52
53
this.minSize = randomRange(1,3) + randomRange(0,9) * 0.01;
this.maxSize = randomRange(1,3) + randomRange(0,9) * 0.05;
this.particleCount = randomRange(5, 10) * stargazerMultiplier;

const planetDetail = randomRange(2, 5);
const planetGeometry = new THREE.TetrahedronGeometry(planetRadius, planetDetail);


const planetVerticieNoise = randomRange(1, 5);
for (var i=0; i < planetGeometry.vertices.length; i++){
fork icon0
star icon5
watch icon2

+ 3 other calls in file

67
68
69
70
71
72
73
74
75
76

}



var geometry = new THREE.TetrahedronGeometry(1.735);

var exporter = new THREE.OBJExporter();

console.log(geometry);
fork icon0
star icon0
watch icon1

Other functions in three

Sorted by popularity

function icon

three.Vector3 is the most popular function in three (22341 examples)