public Line(Point origin, Point direction) : this() { Origin = origin; Direction = direction; Normal = direction.Perp(); Ax = Normal.X; By = Normal.Y; C = Point.Dot(-PointAtDistance((Real)1.0), Normal); }
public static int DetermineSide(Line line, Point normal, Point point) { Real value = Point.Dot(line.Normal, point) + line.C; if (Math.Abs(value) < MathHelper.Epsilon) { return(0); } else if (value < 0) { return(-1); } else //if (value > 0) { return(1); } }