How do I calculate the average direction of two vectors
Posted
by Mike Broughton
on Stack Overflow
See other posts from Stack Overflow
or by Mike Broughton
Published on 2009-02-19T18:02:19Z
Indexed on
2010/04/29
16:57 UTC
Read the original article
Hit count: 184
Hi,
I am writing and opengl based iphone app and would like to allow a user to translate around a view based on the direction that they move two fingers on the screen. For one finger I know I could just calculate the vector from the start position to the current position of the users finger and then find the unit vector of this to get just the direction, but I don't know how I would do this for two fingers, I don't think adding the components of the vectors and calculating the average would work so I'm pretty much stuck...
thanks in advance
© Stack Overflow or respective owner