| | |
| | | import { extend } from '@react-three/fiber'; |
| | | import { Geometry, Base, Subtraction, Addition } from '@react-three/csg'; |
| | | import { TextGeometry } from 'three/examples/jsm/geometries/TextGeometry'; |
| | | import { DEBUG } from '../config/setting'; |
| | | extend({ TextGeometry }); |
| | | |
| | | const House = (props) => { |
| | | const { |
| | | wallThickness = 2, |
| | | width = 1400, |
| | | length = 1200, |
| | | height = 400, |
| | | width = DEBUG ? 14000 : 1400, |
| | | length = DEBUG ? 12000 : 1200, |
| | | height = DEBUG ? 4000 : 400, |
| | | aside_width = 130, |
| | | aside_length = 130, |
| | | position = new THREE.Vector3(200, 0, 0), |
| | |
| | | const texture = new THREE.TextureLoader().load( |
| | | `/textures/wall_pic5.jpg` |
| | | ); |
| | | console.log('env', process.env.NODE_ENV); |
| | | |
| | | texture.wrapS = THREE.RepeatWrapping; // 水平方向重复 |
| | | texture.repeat.set(0.02, 0.02); |