Tetrahedron rotation by points

I am drawing a tetrahedron by coordinates. I have 4 vertex coord. I’m trying to get the right rotation from these points. I tried unsuccessfully with

const edge = points[0].distanceTo(points[2]);
const plane = new THREE.Plane();
const point = getPointInBetweenByLen(points[0], points[2], edge / 2);
plane.setFromCoplanarPoints(point, points[1], points[3]);

[http://jsfiddle.net/kirill321592/Lg91v2xd/42/](full code here)


What do you mean with this? Any explanatory picture of the desired result?

The vertices of the shape should be on points, these will be dynamic coordinates from xml, just like you helped me with the cone, only now there are 4 points

Is it not an option to build a tetrahedron, having these 4 points?
An example: Tetrahedron (non-indexed buffer geometry)

Thanks, you best. Maybe you have some resource where I can read more about BufferGeometry besides the official documentation?

As an option: Three.js Custom BufferGeometry

1 Like