How to crop a 3d modal

I have a glb modal but I want it to be cut in half and the cropped half disappears.
How to perform this action, to be clear this is what I want:


For example this is my 3d modal and after applying the operations:

Screenshot 2024-02-19 at 2.47.57 PM
Something like this

Try with clipping planes.

Demo:

https://boytchev.github.io/etudes/threejs/capping-clipping.html

image

2 Likes

so will it remove the cropped part out of the scene or will it be there even after clipping?

It only crops the rendering. The whole 3D model will exist in the scene, but only part of it will be drawn. If you want to crop the model and to remove part of its geometry, you have to use some CSG.

2 Likes

You got any in mind, I don’t want anything fancy all hardcoded stuff, I dont even want the user to take any input or something.