// 墙的生成
let path: Path3D = new Path3D();
path.moveTo(-5, 0);
path.lineTo(5, 0);
path.lineTo(5, 10);
path.lineTo(11, 10);
// path.lineTo(11, 15);
path.quadraticCurveTo(13,12.5,11, 15);
path.lineTo(-5, 15);
path.lineTo(-5, 0);
let wallGeometry = new WallGeometry(path, 0.6, 2,10,2);
地板的生成:
const shapeFloor = new THREE.Shape().moveTo(-5, 0).lineTo(5, 0).lineTo(5, 10).lineTo(11, 10).quadraticCurveTo(13,12.5,11, 15).lineTo(-5, 15).lineTo(-5,0);
let floorGeometry: THREE.ShapeGeometry = new THREE.ShapeGeometry(shapeFloor);
半圆墙壁视角1 半圆墙壁视角2
网友评论