Exemple #1
0
 public override Line[] Split(Line L, bool Nullable)
 {
     //if (!IsInside(P)) return null;
     Point P = IntersectionPoint(L);
     Line[] lines;
     if (P == null) return null;
     if(P == Origin)
     {
         if(Nullable) return null;
      		lines = new Line[1];
         lines[0] = this;
         return lines;
     }
     lines = new Line[2];
     lines[0] = new LineSegment(Origin, P);
     lines[1] = new Ray(P, Director);
     return lines;
 }
Exemple #2
0
 public override Line[] Split(Line L,bool Nullable)
 {
     Point P = IntersectionPoint(L);
     LineSegment[] lines;
     if (P == null) return null;
     if(P != Origin && P != B)
     {
         lines = new LineSegment[2];
         lines[0] = new LineSegment(Origin, P);
         lines[1] = new LineSegment(P, B);
         return lines;
     }
     if(Nullable) return null;
     lines = new LineSegment[1];
     lines[0] = this;
     return lines;
 }
Exemple #3
0
 public LineSegment(LineSegment L)
     : base(L)
 {
 }