Drawing a 2d shape from a 3d object

I don’t have much experience with THREE.JS.
I am not asking for a ready code, but for pointing me at what I’m looking for and telling me if I am thinking properly.
I’ve seen a lot of topics, but I can’t deal with it.

  1. Well, I’m loading the external .OBJ model. It is as bufferGeometry. I would like to get the shape of a 3d model and draw it in a second Canvas as 2d. I got to the position - geometry.attributes.position.array. I know that they work on the basis of x1, y1, z1, x2, y2 … My idea was to take points X and Y and draw them in the second Canvas as 2D. Only is it possible to convert these points to make them suitable for the 2d plane in the new canvas?

Thank you in advance for your reply and sorry if I repeated the topic.


You need more information to go from 3D to 2D.
First would be the direction you want to look at the 3D model from.
Assuming you have that you can use Plane.projectPoint to project vertices on to the plane.
These projections can be used to construct a 2D shape, however its usefulness I’m not sure.
If we are talking about dealing with arbitrary 3D shapes stored as BufferGeometry the only useful 2D projection I can imagine is a convex hulled silhoutte.
If you have more information stored for the vertices you could start doing some meaningful 2D reconstructions.

1 Like