math & physics
I am having hard time understanding the camera (view) matrix:
Ux Vx Nx 0
Uy Vy Ny 0
Uz Vz Nz 0
-E.U -E.V -E.Z 1
How is this matrix constructed?
Why are there dot products in the translation section of this matrix?
How is rotation and translation actually achieved by this matrix?
U, V and N are generally known as the camera vectors. U is your view vector. the camera looks into this direction. the V vector is a vector you choose. it has to be orthogonal to the U vector. finally the N vector is the cross product of U and V, thus forming a cartesian coordinate system. all that is left is to find out is the translation part... usually it is just the negative of the camera's position.
i don't know what E and Z are... could you clarify on that ? i assume that E is the eye or camera position ?
assuming that the last part of the translation is actually -E.N your are technically rotating E from camera to world coordinates, taking the negative of each component
yep, you are right it should be -E.N. Thank you for the reply.