public static XVector2 Lerp(XVector2 v1, XVector2 v2, XReal lerp) { return(new XVector2(v1.X + (v2.X - v1.X) * lerp, v1.Y + (v2.Y - v1.Y) * lerp)); }
public static XReal Distance(XVector2 v1, XVector2 v2) { return((v1 - v2).Length); }
public static XReal DistanceSquared(XVector2 v1, XVector2 v2) { return((v1 - v2).LengthSquared); }
public static XReal Cross(XVector2 v1, XVector2 v2) { return(v1.X * v2.Y - v1.Y * v2.X); }
public static XReal Dot(XVector2 v1, XVector2 v2) { return(v1.X * v2.X + v1.Y * v2.Y); }
public bool Contains(XVector2 pnt) { return(pnt.X >= Left && pnt.Y >= Top && pnt.X < Right && pnt.Y < Bottom); }