
Reflection of a Vector
I am thinking about writing a raytracing engine ("just for fun") but I have one major problem -> I don''t know the math to ''reflect'' the light rays when they hit things. I''ve been asking people and everything can tell me the ''theory'' (as I allready knew), but noone can tell me the math! I would appriciate it a lot if someone could help me on this.
Thanks, ~SPH

AIM ME: aGaBoOgAmOnGeR
R = 2(N.L)N - L
Where N is the normal and L is pointing towards the incoming light. R would be the resultant reflection vector.
Where N is the normal and L is pointing towards the incoming light. R would be the resultant reflection vector.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement