strafe???

can some one help me with how to formulate new coords that allow the camera to strafe from side to side?

i know what needs to be gone… i just cant remember from high school how to do it.

i am using gluLookAt for a first person view and i know i just need to move the position and the view coords perpendicular to the slope of position-to-view.

here is a diagram i made if it helps at all:

thank you!

Vector multiplication of view vector and up vector gives you one strafe direction. Multiply it with -1 for another direction.

so you are saying that if my position is (7,17) and my view is (8, 16), i multiply to get the scalar product?

example:

( 7, 17 ) · ( 8, 16 )
( 7 x 8 + 17 x 16 )
(56 + 272) = 328

ok so now i have a scalar product of 328, now what do i do with it… i am stuck again?

try cross product, not dot product

http://en.wikipedia.org/wiki/Cross_product