public void Add(IVector2 a, IVector2 b, IBufferedVector2D result) { a.GetCoords(aux); double x = aux.X; double y = aux.Y; b.GetCoords(aux); x += aux.X; y += aux.Y; result.SetCoords(x, y); }
public static void Add(IVector2 a, IVector2 b, IBufferedVector2D result) { BufferedTuple2d aux = new BufferedTuple2d(); a.GetCoords(aux); double x = aux.X; double y = aux.Y; b.GetCoords(aux); x += aux.X; y += aux.Y; result.SetCoords(x, y); }