mirror of
https://github.com/seigler/webgl-threejs-hello
synced 2025-07-27 09:46:13 +00:00
⚡ Add post processing
This commit is contained in:
parent
f6494780c3
commit
c6580a8fe7
8 changed files with 123 additions and 45 deletions
|
@ -0,0 +1,20 @@
|
|||
import props from 'js/core/props';
|
||||
|
||||
class Ground extends THREE.Object3D {
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
const material = new THREE.MeshPhongMaterial({ color: 0xffffff, specular: 0x050505 });
|
||||
material.color.setHSL(0.095, 1, 0.75);
|
||||
const geometry = new THREE.PlaneBufferGeometry(10000, 10000);
|
||||
let mesh = new THREE.Mesh(geometry, material);
|
||||
|
||||
mesh.rotation.x = -Math.PI/2;
|
||||
mesh.position.y = -1;
|
||||
mesh.receiveShadow = true;
|
||||
|
||||
this.add(mesh);
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = Ground;
|
Loading…
Add table
Add a link
Reference in a new issue