Parallel() public method

public Parallel ( PointD point ) : Line
point PointD
return Line
示例#1
0
        public static Line ProjectionLine(Puck p, Line reference)
        {
            PointD ij    = reference.IntersectionWith(reference.Perpendicular(p.Location));
            double dist  = p.Location.DistanceTo(ij);
            double scale = p.Radius / dist;
            PointD projection_line_point = ij.Offset((p.Location.X - ij.X) * scale, (p.Location.Y - ij.Y) * scale);

            return(reference.Parallel(projection_line_point));
        }
示例#2
0
 public static Line ProjectionLine(Puck p, Line reference)
 {
     PointD ij = reference.IntersectionWith(reference.Perpendicular(p.Location));
     double dist = p.Location.DistanceTo(ij);
     double scale = p.Radius / dist;
     PointD projection_line_point = ij.Offset((p.Location.X - ij.X) * scale, (p.Location.Y - ij.Y) * scale);
     return reference.Parallel(projection_line_point);
 }