measure angle between 2 vectors

   7538   2   0
User Avatar
Member
64 posts
Joined: 10月 2009
Offline
I would like to measure the angle between 2 vectors, is there a node to do that ? thanks
User Avatar
Member
192 posts
Joined: 11月 2008
Offline
You want to take the dot product. Make sure your vectorz are normalized.

gl dude.

http://www.sidefx.com/docs/houdini10.0/expressions/dot [sidefx.com]

http://www.sidefx.com/docs/houdini10.0/vex/functions/dot [sidefx.com]

edit: oh yea, the result is the cosine of the angle so your angle would be the arcosine of the dot product.
Edited by - 2010年10月7日 23:35:01
User Avatar
Member
1909 posts
Joined: 11月 2006
Online
To get the angle between two vectors you'll need to perform some operations using the dot (scalar) product between the vectors.

http://en.wikipedia.org/wiki/Dot_product [en.wikipedia.org]

You could do this using hscript, HOM, or VOPs.
Graham Thompson, Technical Artist @ Rockstar Games
  • Quick Links