Hi,

You are overthinking. As the others have said the trick is to use the  
dot product with the normal.

Now in terms of CS code it is even simpler:

csPlane3 myPlane(point1,point2,point3);

if (myPlane.Classify(anotherPoint) < 0)
{ //then }
else
{ //otherwise }

-Marten

Quoting Scott Johnson <[EMAIL PROTECTED]>:

> Hi Everyone!
>
> This may seem like a basic question, but in the interest of time, I am
> going to ask it anyway rather than struggle with it.
>
> All of the sideness tests I have seen in 2D (i.e. the Area() function in
> triangulate.cpp in libcrystalspace, which is essentially a copy of
> AreaSide() in
> http://orion.math.iastate.edu/burkardt/c_src/orourke/tri.c) uses a
> matrix determinant to find whether a point is on one side or another of
> a line, (essentially uses cross products).   The problem I have is that
> these are all assuming that the planes in which the vectors lie are
> parallel to the XY plane.  That is, the Z component can essentially be
> disregarded.  Of course, when I take cross products of 3D vectors, I
> obtain another 3D vector.  This happens in 2D of course, but there is a
> matrix which can be used to obtain a determinant telling the side on
> which a point lies, given a vector.
>
> Now, my question is this: Given two vectors (three points), we know they
> are all coplanar, so is there a way to utilize a matrix determinant
> trick similar to in 2D which will give us the side of the line the point
> lies on (i.e. negative or positive - it doesn't really mean 'right' or
> 'left', as these don't have meanings in arbitrary 3-dimesions).
>
> My initial intuition was to determine the angle the vector makes with
> the XY plane, in X and Y dimensions, then rotate all points by this, to
> ensure that we are parallel to the XY plane, then utilize the same
> method.  Would this be too much work?  I am wondering if I am
> overthinking the problem.
>
> Any suggestions would be helpful.  Thanks!
>
> ~Scott
>
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> _______________________________________________
> Crystal-main mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/crystal-main
> Unsubscribe:   
> mailto:[EMAIL PROTECTED]
>



-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Crystal-main mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/crystal-main
Unsubscribe: mailto:[EMAIL PROTECTED]

Reply via email to