the following picture depicts the wrong matrix that is used to transform normal vector. this is the common example when describe the reason why we introduce tangent space.
tangent space
the right formula scales double for y axis of the point (0,1,0). the result is (0,2,0).
it we scale double for all the point of edge AB, we will get edge A’B.

then let’s look at the center point of edge AB, the normal vector for point P, is PP’.
if we use the the same matrix to transform the normal vector PP’, we will get the result vector QQ’.

let ‘s think, P is the center point of AB, Q is the center point of A’B. Q is the result of scale by double of point P. but we see the result normal QQ’ is not the right normal for point Q.

this is clearly show that the transform matrix for point is not right for normal vector transformation.

the following chapter is to introduce the right method to get the right normal vector.

the reference website:
http://blog.csdn.net/christina123y/article/details/5963679
http://www.lighthouse3d.com/tutorials/glsl-12-tutorial/the-normal-matrix/
http://blog.csdn.net/liu_if_else/article/details/73604356

the first is clearly describe the transform matrix is not the effect the normal vector.
the second is the English version for the first.
the third is describe how to transform bump texture mapping. the second method is to transform the coordinate of bump texture that is in tangent space to world space. this website’s illusion is very clear, a good article.

相关文章: