Last commit before refactor
This commit is contained in:
@ -17,32 +17,18 @@ import staticGIF from './../../images/static.gif';
|
||||
const CUBES = [
|
||||
{
|
||||
size: [1, 1, 1],
|
||||
pos: [-4,-0.3,1],
|
||||
pos: [-4,-1,1],
|
||||
velocity: [0.3, 0.1, 0],
|
||||
color: 0xFFFFFF,
|
||||
pvm: true
|
||||
},
|
||||
{
|
||||
size: [1, 1, 1],
|
||||
pos: [1,-0.8,-0.3],
|
||||
pos: [0.5,-0,-0.3],
|
||||
velocity: [-0.3, 0.05, 0.1],
|
||||
color: 0xCCFFFF,
|
||||
pvm: true
|
||||
},
|
||||
{
|
||||
size: [1, 1, 1],
|
||||
pos: [-0.8,0.4,-5],
|
||||
velocity: [0, -0.1, 0.1],
|
||||
color: 0xf7ffb7,
|
||||
pvm: true
|
||||
},
|
||||
{
|
||||
size: [1, 1, 1],
|
||||
pos: [6,1,-2],
|
||||
velocity: [0.2, 0.5, 0],
|
||||
color: 0xffb7ee,
|
||||
pvm: true
|
||||
},
|
||||
{
|
||||
size: [1, 1, 1],
|
||||
pos: [-3,1,0.3],
|
||||
@ -52,7 +38,7 @@ const CUBES = [
|
||||
},
|
||||
{
|
||||
size: [0.8, 0.8, 0.8],
|
||||
pos: [2.2,1,0.3],
|
||||
pos: [3.4,-0.6,0.3],
|
||||
velocity: [1, 0.1, -0.1],
|
||||
color: 0xff66ab,
|
||||
pvm: true
|
||||
|
@ -26,15 +26,15 @@ class ThreeSection extends React.Component {
|
||||
|
||||
this.camera.position.z = 5;
|
||||
|
||||
this.ambient1 = new THREE.AmbientLight(0xFFCCFF, 0.2);
|
||||
this.scene.add(this.ambient1);
|
||||
this.ambient2 = new THREE.AmbientLight(0xFFFFFF, 0.5);
|
||||
this.scene.add(this.ambient2);
|
||||
//this.ambient1 = new THREE.AmbientLight(0xFFCCFF, 0.2);
|
||||
//this.scene.add(this.ambient1);
|
||||
//this.ambient2 = new THREE.AmbientLight(0xFFFFFF, 0.5);
|
||||
//this.scene.add(this.ambient2);
|
||||
|
||||
this.light = new THREE.DirectionalLight(0x22BBFF, 0.5);
|
||||
this.light = new THREE.DirectionalLight(0x22BBFF, 0.3);
|
||||
this.light.position.x = this.camera.position.x;
|
||||
this.light.position.y = this.camera.position.y;
|
||||
this.light.position.z = this.camera.position.z + 8;
|
||||
this.light.position.z = this.camera.position.z + 5;
|
||||
this.scene.add(this.light);
|
||||
|
||||
if(typeof this.props.onSetup !== typeof undefined) {
|
||||
@ -75,7 +75,7 @@ class ThreeSection extends React.Component {
|
||||
this.renderer.render(this.scene, this.camera);
|
||||
this.lastTime = now;
|
||||
|
||||
requestAnimationFrame(this.onFrame.bind(this));
|
||||
//requestAnimationFrame(this.onFrame.bind(this));
|
||||
}
|
||||
|
||||
render() {
|
||||
|
Reference in New Issue
Block a user