参考:webgl_clipping_intersection.html
// 裁剪点
var clipPlanes = [
new THREE.Plane( new THREE.Vector3( 1, 0.5, 0 ), 0 ),
new THREE.Plane( new THREE.Vector3( 0, - 1, 0 ), 0 ),
new THREE.Plane( new THREE.Vector3( 0, 1, - 1 ), 0 ),
new THREE.Plane( new THREE.Vector3( -1, 1, -2 ), 0 )
];
// renderer
renderer.localClippingEnabled = true; // 必须的
var geometry = new THREE.BoxGeometry( i / 15, 24, 12 );
var material = new THREE.MeshLambertMaterial( {
color: new THREE.Color().setHSL( Math.random(), 0.5, 0.5 ),
clippingPlanes: clipPlanes, // 裁剪平面对象,必须的
clipIntersection: params.clipIntersection
} );