7 public readonly
short X;
9 public readonly
short Y;
33 public static Point16 Max(
int firstX,
int firstY,
int secondX,
int secondY)
35 return new Point16((firstX > secondX) ? firstX : secondX, (firstY > secondY) ? firstY : secondY);
40 return new Point16((
X > compareX) ?
X : compareX, (
Y > compareY) ?
Y : compareY);
45 return new Point16((
X > compareTo.
X) ?
X : compareTo.
X, (
Y > compareTo.
Y) ?
Y : compareTo.
Y);
50 if (first.X == second.X)
52 return first.Y == second.Y;
59 if (first.X == second.X)
61 return first.Y != second.Y;
66 public override bool Equals(
object obj)
69 if (
X != point.
X ||
Y != point.
Y)
78 return (
X << 16) | (ushort)
Y;
83 return $
"{{{X}, {Y}}}";
static bool operator!=(Point16 first, Point16 second)
static bool operator==(Point16 first, Point16 second)
override string ToString()
Point16 Max(Point16 compareTo)
Point16(short X, short Y)
static Point16 NegativeOne
override bool Equals(object obj)
static Point16 Max(int firstX, int firstY, int secondX, int secondY)
override int GetHashCode()
Point16 Max(int compareX, int compareY)