Archived

This topic is now archived and is closed to further replies.

This lighting is driving me crazy, could someone help me?

This topic is 6278 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I want to use a light to light a scene. I have a ground plane which get''s lit well. And I have an object which I load from a .3ds file. I calculate the vertex normals by using the cross product and then aplying this to all vertices of a face. So basically I should get a flat shaded object. But the object doesn''t look right. Some faces get lit others don''t. There''s no transition. Either fully lighted face or no lighting at all (totally black). So when I make the light move around the object it looks really weird, like the faces turning on and off. could someone please tell me what I have to do to correct this? I''ve tried everything I could think of

Share this post


Link to post
Share on other sites
That''s because you are using a per vertex lighting algo. To avoid that, take the object further from the light source, or do a per pixel lighting (to time consuming for real-time rendering, not even the newest cards do it), or use lightmaps.

Sorry for not going into details, it''s saturday''s night, and i''m going out


Share this post


Link to post
Share on other sites