Keeping a node from rendering its shadow on itself

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
Anteater

Keeping a node from rendering its shadow on itself

Post by Anteater »

OK, I have a scene node for a character in my game that has a somewhat high poly-count. It needs a shadow, though, but the shadow renders itself on the node that's casting the shadow, resulting in slower performance. How do I make it so a node can cast but NOT receive shadows?
needforhint
Posts: 322
Joined: Tue Aug 30, 2005 10:34 am
Location: slovakia

Post by needforhint »

it would look really strange if shadow was not rendered on it, every thing that casts a shadow must be shadowed itself somewhere :idea: but you can set it by node->setMaterialFlag(video::EMF_LIGHTING , false);
what is this thing...
Soy1Bonus
Posts: 31
Joined: Mon Jun 21, 2004 8:41 am
Location: Spain (Cantabria)
Contact:

Post by Soy1Bonus »

I tried to do the same on my project, but disabling the lighting doesn't stop the object to cast shadows on itself.

In my case, I had a very low poly model, and the shadow looked ok on the ground, but on the model had some artifacts. So I think this is an interesting feature to implement (if anyone knows how).
GueZt

Post by GueZt »

Hi, I also have this problem, i want only the terrain
to received shadow.

I WISH the NODES has some properties like

NODE->recieveShadow(false);

so that only selected node will received shadow.

I wish someone can make this.
Post Reply