|
|
@ -30,7 +30,7 @@ animate(); |
|
|
|
function configureScene(data) { |
|
|
|
function configureScene(data) { |
|
|
|
// Add geometry for the rooms
|
|
|
|
// Add geometry for the rooms
|
|
|
|
for (var room of data.rooms) { |
|
|
|
for (var room of data.rooms) { |
|
|
|
let roomGeo = new THREE.BoxGeometry(room.w, room.h, 2) |
|
|
|
let roomGeo = new THREE.BoxGeometry(room.w, room.h, room.d) |
|
|
|
let roomColor = new THREE.Color(room.color) |
|
|
|
let roomColor = new THREE.Color(room.color) |
|
|
|
let roomMaterial = new THREE.MeshPhysicalMaterial({ color: roomColor }) |
|
|
|
let roomMaterial = new THREE.MeshPhysicalMaterial({ color: roomColor }) |
|
|
|
let roomMesh = new THREE.Mesh(roomGeo, roomMaterial) |
|
|
|
let roomMesh = new THREE.Mesh(roomGeo, roomMaterial) |
|
|
|