8:30 – 2:30
- Well, I was hoping to use the MODELVIEW_Matrix to determine the orientation vector of the camera, but no luck. Time for classical spherical coordinate transforms. Transposing Y and Z, since OpenGl likes to have Y as the up vector.
- phi = angle from vertical, theta = angle from x axis
- z = cos(theta)*sin(phi)
- x = -sin(theta)*sin(phi)
- y = cos(theta)
- And that is now working. Note that we had to multiply the x component of the view vector by -1.
- Oooo – new shader book: http://www.packtpub.com/opengl-4-0-shading-language-cookbook/book
- Started on the HandControlUi fltk class.