Tangent Matrices
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?
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 :-)
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 :-)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement