Jump to content
  • Advertisement
Sign in to follow this  
RuilMalvar

Tangent Matrices

This topic is 4974 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 am having lighting issues utilizing per-pixel lighting using a normal map. Things are just not looking right. It seems only the one side of my cube is being lit. And when I rotate the cube, still only one side is being lit. I was wondering if it is possible to rotate tangent matrices by the model-view matrix. Or would I have to do something like create the tangent matrix within the vertex program utilizing current updated vertex positions (There so has to be a better way). As it is currently I am creating the tangent matrix utilizing object space vertices, so since this doesn’t work for rotating objects what can be done to make this dynamic for objects?

Share this post


Link to post
Share on other sites
Advertisement
Huh?? Don't rotate the tangent matrix. I have no idea what you are talking about :-)

When you are computing your light vectors are you using the light position or the view position? If your light position isn't moving... it will always light one side of the object :-)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!