diff --git a/src/renderers/webgl/WebGLPrograms.js b/src/renderers/webgl/WebGLPrograms.js index 211798c66a93d1a9d9b3b33348addeccc31f542b..46aa013f950397b99d3f06ad16abe56c35b79467 100644 --- a/src/renderers/webgl/WebGLPrograms.js +++ b/src/renderers/webgl/WebGLPrograms.js @@ -77,8 +77,6 @@ THREE.WebGLPrograms = function ( renderer, capabilities ) { var light = lights[ l ]; - if ( light.visible === false ) continue; - if ( light instanceof THREE.DirectionalLight ) dirLights ++; if ( light instanceof THREE.PointLight ) pointLights ++; if ( light instanceof THREE.SpotLight ) spotLights ++; @@ -99,7 +97,7 @@ THREE.WebGLPrograms = function ( renderer, capabilities ) { var light = lights[ l ]; - if ( ! light.castShadow ) continue; + if ( light.castShadow === false ) continue; if ( light instanceof THREE.SpotLight || light instanceof THREE.DirectionalLight ) maxShadows ++; if ( light instanceof THREE.PointLight ) {