title: Three.js: how to use a plane to cut objects in 2 parts?
body: <p>I have a complex object, i.e. a box, and I would like to cut it dynamically. This jsFiddle is a very simple example:<a href="https://jsfiddle.net/uncoke/jekmp52r/" rel="nofollow noreferrer">jsFiddle</a></p>
  
  <p><strong>Very simple plane</strong></p>
  
  <pre><code>var plane = new THREE.Mesh( geometry, material3 );
  plane.rotation.x =1.3; // -Math.PI / 2;
  gui.add(plane.rotation, "x", 0.1, Math.PI / 2).name("angle");
  gui.add(plane.position, "y", -1, 1).name("h");
  scene.add( plane );
  </code></pre>
  
  <p>I would like to remove from my object the upper part. Just like to cut off a piece from an apple using a knife.</p>
  
  <p>The plane is the knife: In my example, you can play with 2 controls to move the plane up and down or change the angle.</p>
  
  <p><a href="https://i.stack.imgur.com/3qiB3.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/3qiB3.png" alt="example"></a></p>
  
  <p>Can you help me to hide the removed part from the object? </p>