How to use the Water function from three
Find comprehensive JavaScript three.Water code examples handpicked from public code repositorys.
GitHub: zDawnING/MyLearnWebGL
139 140 141 142 143 144 145 146 147 148
* @param {[type]} light [description] * @return {[type]} [description] */ export const createWater = (light, objs) => { let geometry = new THREE.PlaneBufferGeometry(1000, 1000) return new THREE.Water(geometry, { textureWidth: 2048, textureHeight: 2048, waterNormals: new THREE.TextureLoader().load( waterNormalImg,
0
0
1
three.Vector3 is the most popular function in three (22341 examples)