0
$\begingroup$

I learned recently while studying the Blinn-Phong lighting model that you can obtain the vector "halfway" between two other vectors by simply adding them together and normalizing the result. By "halfway", I mean halfway between the two in rotation. So for instance if one of them is pointing directly along the x-axis and the other is pointing directly upwards along the y-axis, the halfway vector would be pointing diagonally at an angle of 45 degrees to the x-axis.

I'm very curious as to why this actually works. Intuitively, it seems similar to getting the mean of two numbers by adding them together and dividing them by two but that doesn't really explain why dividing the vector sum by its magnitude gives the vector halfway between the two.

$\endgroup$
  • 1
    $\begingroup$ Vector addition can be visualized as a parallelogram, as you probably know. For Binn-Phong, the vectors to be added (the vector ponting to the light source and the vector pointing to the observer) are normalized (both length $1$), hence we have a rhoombus instead of a parallelogram. As the diagonal of a rhombus always halfes the corner angles, this gives you the halfway vector in Blinn-Phong. The normalizing of course only changes the length to one but does not affect the direction. This is only made because it makes further computations much simpler. $\endgroup$ – PattuX Nov 18 '17 at 14:35
  • $\begingroup$ Oh, that makes sense. Thanks. $\endgroup$ – Andrew Hung Nov 18 '17 at 14:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.