0
votes

I have a problem using Mesh Lambert Material with Three.js, I have a plane with different height points, but when trying to apply light the higher points are the ones that look darker, and it should be the other way around, my code looks like the following:

var geometry = new THREE.PlaneBufferGeometry(7500, 7500, worldWidth - 1, worldDepth -1);
geometry.computeFaceNormals();
geometry.applyMatrix(new THREE.Matrix4().makeRotationX(- Math.PI / 2));

texture = THREE.ImageUtils.loadTexture('img/grass.png');
mesh = new THREE.Mesh(geometry, new THREE.MeshLambertMaterial({ map: texture }));
scene.add(mesh);

var pointLight = new THREE.PointLight(0xffffff, 100, 0);
pointLight.position.set(5, 50, 5);
scene.add(pointLight);

And the result looks like the following:

enter image description here

Thank you so much in advance.

1
Have you tried changing the position of your light?2pha

1 Answers

0
votes

In your call to

THREE.PointLight(0xffffff, 100, 0);

you are specifying intensity to be 100 when the normal range is 0.0 - 1.0 so your scene comes out over-lit.