Basic reflection vector help

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

Recommended Posts

I know the formula for calculating the reflection vector given the incident and normal vector, but the example that I've seen have only been where the angle between the incident and normal vector have been < 90degrees, like so:

But what is the reflection vector if the incident vector approaches from behind the surface plane, like in my example:

Is the reflection vector i denoted "roughly" the angle of the reflection vector?

Sorry if this seems like a stupid question, i just want to know what kind of reflection vector i will get if the light in my shader shines it's incident vector onto the back face of a surface.

Share on other sites

The situation you've described, illuminating a back surface, isn't really defined. The purpose for defining a normal used in lighting calcs is to determine if the surface is illuminated at all - which it would not be - and, if so, then how it's illuminated. So...

Is the reflection vector i denoted "roughly" the angle of the reflection vector?

... if you want to define a "reflection" vector in that way, you can. If you want a "back" face to be illuminated as a reflective surface in a way you can consider to be "proper," then reverse the normal (i.e., multiply it by -1) and use the law of reflection.

Edited by Buckeye

Share on other sites

Thanks.

I realize the problem now, i just didn't know how the reflection actually works.

• Game Developer Survey

We are looking for qualified game developers to participate in a 10-minute online survey. Qualified participants will be offered a \$15 incentive for your time and insights. Click here to start!

• 16
• 9
• 15
• 9
• 11