/// <summary> /// Retourne la liste des points de croisement avec la forme donnée /// </summary> /// <param name="shape">Forme à tester</param> /// <returns>Liste des points de croisement</returns> public virtual List <RealPoint> GetCrossingPoints(IShape shape) { List <RealPoint> output = new List <RealPoint>(); if (shape is RealPoint) { output = LineWithRealPoint.GetCrossingPoints(this, shape as RealPoint); } else if (shape is Segment) { output = LineWithSegment.GetCrossingPoints(this, shape as Segment); } else if (shape is Polygon) { output = LineWithPolygon.GetCrossingPoints(this, shape as Polygon); } else if (shape is Circle) { output = LineWithCircle.GetCrossingPoints(this, shape as Circle); } else if (shape is Line) { output = LineWithLine.GetCrossingPoints(this, shape as Line); } return(output); }