55 inline void build(laPoint3 &a, laPoint3 &b, laPoint3 &c) {
58 normal = v1.cross( v2 );
67 double len = normal.lenght();
76 d = -1 * normal.dot(a);
82 return normal.dot(p) +
d;
86 inline double side(laPoint3 &p){
92 #endif //#ifndef M_PLANE3
laPlane3(void)
Default constructor.
void build(laPoint3 &a, laPoint3 &b, laPoint3 &c)
Build laPlane3 from three points ( laPoint3 objects )
double d
Distance from the origin of the coordinate system.
laPoint3 normal
Normal vector.
laPlane3(laPoint3 &a, laPoint3 &b, laPoint3 &c)
Build laPlane3 from three points ( laPoint3 objects )
double side(laPoint3 &p)
Return {+1; -1}, depending on the side of the plane where the specified point lies.
#define M_SIGN(a)
Return sign (+1 or -1)
double distance(laPoint3 &p)
Find the shortest distance between a point and the plane.