Refactored all the GUI and rotation stuff out, colour links are working

feature-faces
Mike Lynch 2023-07-29 16:52:00 +10:00
parent 0b78ea2939
commit efb4cf7608
2 changed files with 3 additions and 1 deletions

1
gui.js
View File

@ -39,6 +39,7 @@ class FourDGUI {
this.gui.add(this.params, 'yRotate', [ 'XZ', 'XY', 'XW' ]);
this.gui.add(this.params, 'damping');
this.gui.add(this.params, 'copy link');
}

View File

@ -65,7 +65,8 @@ const gui = new FourDGUI(
(c) => { scene.background = new THREE.Color(c) },
);
material.color = new THREE.Color(gui.params.color);
scene.background = new THREE.Color(gui.params.background);
const dragK = 0.005;
const damping = 0.99;