calculating vector with specific angle against another vector 2004-03-22 - By Lucas Meijer
Back Roman Bl?th wrote:
> Hi folks, > > > alas, vector-math is the matter: > > I've got a normal vector : vector(0, 1, 0) > I've got an angle (degrees): 25.0 degrees > > What I'm missing is the vector in the x/y-plane that has the angle X > against the normal vector. Someone can show me how to achieve this?
There are two:
vVector = vector(0,1,0) t=transform() t.rotate(0,0,25) -- rotate around z, as vector(0,0,1) is the normal of the x/y plane you mentioned. vAnswer1 = t*vVector t=transform() t.rotate(0,0,-25) vAnswer2 = t*vVector
Bye, Lucas __ ____ ____ ____ ____ ____ ____ ____ ____ ____ Dir3d-l mailing list Dir3d-l@(protected) http://nuttybar.drama.uga.edu/mailman/listinfo/dir3d-l
|
|