Beispiel #1
0
 public Rect(Dot a, Dot b, Dot c, Dot d)
 {
     this.a = a;
     this.b = b;
     this.c = c;
     this.d = d;
 }
Beispiel #2
0
 public Elips(Dot a, Dot b, Dot c, Dot d)
     : base(a, b , c ,d)
 {
     this.a = a;
     this.b = b;
     this.c = c;
     this.d = d;
 }
Beispiel #3
0
 public Round(Dot a, Dot b, Dot c, Dot d)
     : base(a, b, c, d)
 {
     this.a = a;
     this.b = b;
     this.c = c;
     this.d = d;
     radius = a.getLengthTo(b) / 2;
     if(a.getLengthTo(b)!=c.getLengthTo(d))
         throw new System.ArgumentOutOfRangeException("Sides can't be different");
 }
Beispiel #4
0
 public double getLengthTo(Dot b)
 {
     return Math.Sqrt(Math.Pow((b.x1 - x1), 2) + Math.Pow((b.y1 - y1), 2));
 }