Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Gaming > Development Programming Algorithms > Re: How to tell...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 8 Topic 579 of 675
Post > Topic >>

Re: How to tell if a 4th pt is coplanar with the other 3.

by Erik Max Francis <max@[EMAIL PROTECTED] > Sep 13, 2006 at 07:53 PM

Miss Elaine Eos wrote:

> Ooop, this was the part I'm missing.  Ok, I've got my normal for the 
> triangle, "normal".  And my point, "xPoint" (your "n" and "x") -- so, my

> distance is...
> 
>    double distance   = (pointX - p) * dotProduct (unitize(normal))
> 
> ...right?  What's p?

P (position vector p) is any point on the plane.  That means any one of 
your points A, B, or C (position vectors a, b, or c).

The dot product is an operation between two vectors, so if it's a 
standalone function, that would be

	dotProduct(x - a, unitize(n)),

or if it's a method on a vector, it would be

	(x - a).dotProduct(unitize(n)).

-- 
Erik Max Francis && max@[EMAIL PROTECTED]
 && http://www.alcyone.com/max/
  San Jose, CA, USA && 37 20 N 121 53 W && AIM, Y!M erikmaxfrancis
   And I'd rather be damned if I don't.
    -- Robert S. MacNamara
 




 8 Posts in Topic:
How to tell if a 4th pt is coplanar with the other 3.
Miss Elaine Eos <Misc@  2006-09-12 02:02:45 
Re: How to tell if a 4th pt is coplanar with the other 3.
Erik Max Francis <max@  2006-09-11 19:49:21 
Re: How to tell if a 4th pt is coplanar with the other 3.
Miss Elaine Eos <Misc@  2006-09-14 02:39:45 
Re: How to tell if a 4th pt is coplanar with the other 3.
Erik Max Francis <max@  2006-09-13 19:53:00 
Re: How to tell if a 4th pt is coplanar with the other 3.
Tom Plunket <gamedev@[  2006-09-17 17:58:10 
Re: How to tell if a 4th pt is coplanar with the other 3.
Miss Elaine Eos <Misc@  2006-09-18 05:22:24 
Re: How to tell if a 4th pt is coplanar with the other 3.
Tom Plunket <gamedev@[  2006-09-21 15:56:32 
Re: How to tell if a 4th pt is coplanar with the other 3.
Miss Elaine Eos <Misc@  2006-09-22 01:59:40 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Jul 9 4:50:04 CDT 2008.