title: Three.js ShaderMaterial issue with lights
body: <p>Helo, here's part of my code - earth globe :)</p>
  
  <pre><code>    function createGlobe(){
          var normalMap = THREE.ImageUtils.loadTexture("images/earth_normal_2048.jpg");
          var surfaceMap = THREE.ImageUtils.loadTexture("images/earth_surface_2048.jpg");
          var specularMap = THREE.ImageUtils.loadTexture("images/earth_specular_2048.jpg");
  
          var shader = THREE.ShaderLib["phong"];
          var uniforms = THREE.UniformsUtils.clone(shader.uniforms);
  
          uniforms["tNormal"] = {type:"t", value:normalMap};
          uniforms["tDiffuse"] = {type:"t", value:surfaceMap};
          uniforms["tSpecular"] = {type:"t", value:specularMap};
  
          //uniforms["enableDiffuse"] = true;
          //uniforms["enableSpecular"] = true;
  
          var shaderMaterial = new THREE.ShaderMaterial({
              fragmentShader:shader.fragmentShader,
              vertexShader:shader.vertexShader,
              uniforms:uniforms,
              lights:false
              });
  
          var globeGeometry = new THREE.SphereGeometry(1,32,32);
  
          //tangents are needed for the shader
          globeGeometry.computeTangents();
  
          globe = new THREE.Mesh(globeGeometry, shaderMaterial);
  
          globe.rotation.z = 0.41;
  
          earthgroup.add(globe);
  
          }
  </code></pre>
  
  <p>The problematic spot is at ShaderMaterial parameter "lights:true", when set there is following error</p>
  
  <pre><code>Uncaught TypeError: Cannot set property 'value' of undefined three.js:23875
  refreshUniformsLights three.js:23875
  setProgram three.js:23593
  renderBuffer three.js:22018
  renderObjects three.js:22689
  render three.js:22563
  render Earth-clouds.html:100
  wrappedCallback
  </code></pre>
  
  <p>which is</p>
  
  <pre><code>function refreshUniformsLights ( uniforms, lights ) {
  
          uniforms.ambientLightColor.value = lights.ambient;
                  ....
  }
  </code></pre>
  
  <p>and that seems to me that lights are not defined? Well I got them.
  When I set lights:false it renders the globe with the default material. It looks like a bug  that could by in my code :-)</p>