//Create a light source //I think GL_LIGHT0 is used by processing!
// MTLight light = new MTLight(pa, GL.GL_LIGHT3, new Vector3D(0,0,0));
MTLight light = new MTLight(pa, GL.GL_LIGHT3, new Vector3D(pa.width/5f,-pa.height/10f,0));
//Set up a material to react to the light
GLMaterial material = new GLMaterial(Tools3D.getGL(pa));
material.setAmbient(new float[]{ .1f, .1f, .1f, 1f });
material.setDiffuse(new float[]{ 1.0f, 1.0f, 1.0f, 1f } );
material.setEmission(new float[]{ .0f, .0f, .0f, 1f });
material.setSpecular(new float[]{ 1.0f, 1.0f, 1.0f, 1f }); // almost white: very reflective
material.setShininess(127);// 0=no shine, 127=max shine
//Create the earth
earth = new MTSphere(pa, "earth", 40, 40, 80, TextureMode.Projected); //TextureMode.Polar);
earth.setLight(light);
earth.setMaterial(material);