Light is lighting opposite side of object,opposite if its pl

   5062   3   2
User Avatar
Member
58 posts
Joined: July 2005
Offline
Light is lighting opposite side of object,opposite if its placement to that object

Hi
I noticed something very annoying.
Sometimes when I have some object/character in my scene and create a light I notice that back of my character is enlightined and not his face though a light is in front
of it
As I move light forward/backward so he is is enlightened but everytime opposite
Light is in front of him, his back is lightened,light behind him his face is lightened.
weird,very weird
BTW,Is there any issue if that happen if I import fbx from MB through Wings as .obj?
Best regards,
Ben
Best regards,
Ben
User Avatar
Member
941 posts
Joined: July 2005
Offline
Ben Lumumba
Light is lighting opposite side of object,opposite if its placement to that object

Hi Ben,

This is usually due to your object's normals being reversed.
If the N attribute is defined for your object, you can use a point sop and reverse them by “Adding Normals” and typing -$NX, -$NY, -$NZ in the fields.

If they are not being set explicitly, then it means the primitives have the wrong orientation, so add a primitive sop and reverse vertex orders.

One of those two methods should lead to proper enlightenment.

Cheers!
Mario Marengo
Senior Developer at Folks VFX [folksvfx.com] in Toronto, Canada.
User Avatar
Member
252 posts
Joined: July 2005
Offline
I had the same problem with importing .obj files made in Maya.

The geometry had Normal (N) attributes and when I turned on normals they visibly showed to pointing in the correct direction (outward), but they were rendering as if the face was pointing backwards.

Perhaps the primitives are oriented backwards, but the normal attribute is correct. I am not sure, but I would like to know the answer to this too.

I had to reverse the normals with the Point SOP to get them to render correctly, but if I remember correctly it messed up the GL shaded view. I didn't try the reversing vertex orders with a primitive SOP…

-Craig

PS: Another idea is to build a VOP to shade with and turn on the “Ensure Face Forward” option.
User Avatar
Member
4140 posts
Joined: July 2005
Offline
What Mario suggested should work - yup definitely when importing data it's quite common to have primitive and/or point normals somewhat munged. Probably because these differ that would explain why you're getting different results in the render and the GL port…fiddling with the Point, Primitive, and Facet SOPs will eventually get them right. It's definitely a good idea to get them “proper” rather than merely using the ensure face forward option. It may work fine, but when you start fiddling other problems could show up…

Cheers,

J.C.
John Coldrick
  • Quick Links