问题
http://jsfiddle.net/8e8mvx09/
I've looked at a few examples of how to implement shadows, but they all seem to use older versions of three.js. Using r72, I'm not able to make a simple example work. (Fiddle attached)
Did I miss something silly or do they work in a different way now?
Maybe something to do with perhaps?
spotlight.shadowCameraNear
回答1:
- Add your spotlight to the scene:
scene.add( spotlight );
- Increase the shadow Camera far plane because your scene is huge:
spotlight.shadowCameraFar = 600;
- Get shadows: http://jsfiddle.net/8e8mvx09/1/
来源:https://stackoverflow.com/questions/32791254/shadows-not-working-in-r72