public static double CalcStructDistanceDouble(StructDouble point1, StructDouble point2) { double x = point1.X - point2.X; double y = point1.Y - point2.Y; return(Math.Sqrt((x * x) + (y * y))); }
public void GetDistanceFromStructDouble() { var pointEnd = new StructDouble() { X = setX_double, Y = setY_double }; var pointStart = new StructDouble() { X = 42.6498, Y = 42.12385612 }; CalcStructDistanceDouble(pointStart, pointEnd); }