Game Development Community

Vector perpindicular to a given axis?

by Kevin Johnson · in Torque Game Engine · 08/04/2004 (6:19 am) · 3 replies

I'm working on a little resource on adding normal map support to TGE using CG, To get my effecting light vector I'm using mDirection, if the
Light is near the object (mWorldSphere.isIntersecting(lightSphere)) - (borrowed from brett's stencil resource). It seems to be working but when i move the light around, the vector i'm getting back is relative to the objects center. (ie always pointing to the center of the object). Is there a quick or not so quick way to get a vector perpedicular to a given axis ?

#1
08/11/2004 (7:56 pm)
Cross product?
#2
08/12/2004 (1:41 pm)
Yah... i found that:)
lol, thanx
#3
08/12/2004 (2:37 pm)
Glad you solve the problem. :)