Light issue

Hi, I’m having a strange light issue with my project. On one computer the light is perfect, but on all other computers the light isn’t shining far enough… My first guess is it’s hardware related, but who knows I’m wrong… (I hope I am actually)



for the light I’m currently using directional light, I tested it with ambient light also, but it gave the same result



normal:



bad:

It looks to me like the upper isnt lighted at all. I guess the upper one is running on fallback opengl1 while the lower is whats really there.

Try add a white ambient Light, if both lock same then its probably what Normen said.

I deleted the light from code, and the result stayed the same on both computers (top screenshot is from the best computer) and as I see it now it’s like the camera is surrounded with light and all of the other light we added before didn’t come through…



edit: I added the white ambient light, but result stayed the same on the “bad” computer.

We just thought of the fact that we have a geometry surrounding our world (so we cant fall off the world), could it be that the geometry isn’t letting the light through?

You are aware that light only affects geometry that is attached to the same or a sub node of the node the light is attached to? In other words, to have light affect everything it has to be attached to the rootnode.

this is the code we use for the light



[java] AmbientLight ambLight = new AmbientLight();

ambLight.setColor(ColorRGBA.White);

rootNode.addLight(ambLight);[/java]

What material definition are you using? I’m thinking it can’t be Lighting.j3md or it wouldn’t render anything at all if you didn’t have any lights.



Or do you have other lights?

For NVIDIA cards you must set the shininess parameter on the lighting.j3md material to any value other than 0. It is a known driver bug, I tried to fix it but it just too strong