[fixed]MS3D animated mesh not lit correctly

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
hey_i_am_real
Posts: 44
Joined: Thu Sep 28, 2006 2:27 pm
Location: Europe

[fixed]MS3D animated mesh not lit correctly

Post by hey_i_am_real »

Hi.

Linux, SVN1063, OpenGL.

The light is at the same position than the camera.
When the mesh rotates (the rotation is part of the animation of the mesh. This is just a rotation of the root bone), the back of the ninja should be lit but is not.

Image
I like working with rank-outsiders, as long as they give themselves the means to achieve their ambitions.
Luke
Admin
Posts: 449
Joined: Fri Jul 14, 2006 7:55 am
Location: Australia
Contact:

Post by Luke »

try:

((ISkinnedMesh*)mesh)->updateNormalsWhenAnimating(true);
hey_i_am_real
Posts: 44
Joined: Thu Sep 28, 2006 2:27 pm
Location: Europe

Post by hey_i_am_real »

Thanks for this tip.

ISkinnedMesh is not documented in the online API documentation.

Unfortunately, I need to reorganize my code before being able to test the effect of updateNormalsWhenAnimating(true); ...
I like working with rank-outsiders, as long as they give themselves the means to achieve their ambitions.
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

I have changed the default state to animate normals. Since we also have lighting enabled by default this seems to make more sense, even if it's slower.
Post Reply