Shadows problem

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
virious
Posts: 11
Joined: Wed Aug 22, 2007 8:16 am
Location: Poland, Cracow

Shadows problem

Post by virious »

Hi, i created my scene in irrEdit, all meshes are static. All of them are set to "ReceivesShadows" and there is one source of light, "Point" light, which is flying around the scene. Light is configured to "Cast shadows". When i load the scene from my application i can't see any shadows on the floor or any of the walls. Why? I set the stencil buffer to true when creating device. I can see light moving around but i can't see any shadows. I will be thankful for any help.
Sorry for my english.
Virion
Competition winner
Posts: 2148
Joined: Mon Dec 18, 2006 5:04 am

Post by Virion »

did you enable lighting?
virious
Posts: 11
Joined: Wed Aug 22, 2007 8:16 am
Location: Poland, Cracow

Post by virious »

Yes, lighting is enabled on every static mesh on the scene. Do I have to write something in my sources to force shadows to show up?
Sorry for my english.
Virion
Competition winner
Posts: 2148
Joined: Mon Dec 18, 2006 5:04 am

Post by Virion »

hmm i'm not sure then, wait for other users to reply, or ask this question at irrEdit forum (http://www.ambiera.com/forum.php?f=2) as the creator of irrlicht and irredit is there to answer your quesion

oh by the way our names are so similar :lol:
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

You either have to calculate the lightmapping shadows from within irrEdit, and bake them to the meshes. Or you have to add ShadowVolumes to the meshes, which will create the necessary stuff for shadowing. A last option, for better performance with dynamic lights, is to use ShadowMapping with XEffects. This is not possible from within irrEdit AFAIK.
virious
Posts: 11
Joined: Wed Aug 22, 2007 8:16 am
Location: Poland, Cracow

Post by virious »

I'd rather avoid lightmaps. I wanted to have dynamic shadows. I'll try to use addShadowVolumeSceneNode() on every node from scene. If that doesn't work I will try that XEffects which you mentioned.
Sorry for my english.
arras
Posts: 1622
Joined: Mon Apr 05, 2004 8:35 am
Location: Slovakia
Contact:

Post by arras »

I'll try to use addShadowVolumeSceneNode() on every node from scene.
You will slow down your application considerably. This creates stencil shadows, which are quit slow. XEffects use shaders which is bit faster.
virious
Posts: 11
Joined: Wed Aug 22, 2007 8:16 am
Location: Poland, Cracow

Post by virious »

But what about quality? Which do you think will end up with better looking results?
Sorry for my english.
virious
Posts: 11
Joined: Wed Aug 22, 2007 8:16 am
Location: Poland, Cracow

Post by virious »

It worked without using addShadowVolumeSceneNode(). I've just changed all scene meshes to "Animated Mesh" and it went ok without any modifications in my source code :D . Anyways, thanks for your help :) .
Sorry for my english.
Post Reply