Hi Guys
I´m having a small light problem. The problem is that light shines through faces. In the following example the lightsource is a small sphere near the surface - and this lightsource emits light onto the shown face on top of the tower - through the tower walls:
The light code used is more or less the light code from example 8. Could you pleae tell me where to look for this error?
Regards StickyBit
Light problem
Light problem
Last edited by StickyBit on Tue May 09, 2006 7:58 pm, edited 1 time in total.
It seems the tower mesh is set to unlit ???
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
Hi Acki
Thanks for your answer - but I must say that I do not understand it. If you look at this picture you will see that the tower is lit by the sphere:
I´ve set the EMF_FOG_ENABLE material fog for the tower mesh and it´s working fine along with the general lightning - except the problem with light going though the mesh faces, and cuz´s of that - faces that shouldn´t be lit, is now beeing lit.
Regards StickyBit
Thanks for your answer - but I must say that I do not understand it. If you look at this picture you will see that the tower is lit by the sphere:
I´ve set the EMF_FOG_ENABLE material fog for the tower mesh and it´s working fine along with the general lightning - except the problem with light going though the mesh faces, and cuz´s of that - faces that shouldn´t be lit, is now beeing lit.
Regards StickyBit
Last edited by StickyBit on Tue May 09, 2006 7:58 pm, edited 1 time in total.
-
- Posts: 602
- Joined: Sat Aug 23, 2003 2:03 am
- Location: Pottstown, PA
- Contact:
You can see the water is litten by the light node but the tower doesn't change its surfaces on the light node...
Also the ground and bridge doesn't lit up by the light...
(if I see right )
Did you set up the nodes with node->setMaterialFlag(EMF_LIGHTING, true) ???
With (EMF_LIGHTING, false) they will not be affected by the light node...
Also the ground and bridge doesn't lit up by the light...
(if I see right )
Did you set up the nodes with node->setMaterialFlag(EMF_LIGHTING, true) ???
With (EMF_LIGHTING, false) they will not be affected by the light node...
while(!asleep) sheep++;
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
IrrExtensions:
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
The EMF_LIGHTING flag is set to true .. and lightning does work "fine". The reason for that it´s hard to see the bridge and grass being lit - is that it´s lit all the time. This is all happening cuz´ the tower faces both reflect light and lets light pass through.
This means that the bridge and grass is lit even when the sphere is located behind the tower.
I guess that the real question is: How do I stop light from passing through the tower?
By the way .. The Irrlicht SpecialFX example is having the same problem. In the following screenshot you can see the water being lit through walls:
Regards StickyBit
This means that the bridge and grass is lit even when the sphere is located behind the tower.
I guess that the real question is: How do I stop light from passing through the tower?
By the way .. The Irrlicht SpecialFX example is having the same problem. In the following screenshot you can see the water being lit through walls:
Regards StickyBit
Last edited by StickyBit on Tue May 09, 2006 7:59 pm, edited 1 time in total.