public static BoundingBoxInt16 Merge(BoundingBoxInt16 box1, BoundingBoxInt16 box2) { return(new BoundingBoxInt16( Vector3Int16.Minimize(box1.Minimum, box2.Minimum), Vector3Int16.Maximize(box1.Maximum, box2.Maximum) )); }
public static Vector3Int16 Maximize(Vector3Int16 vec1, Vector3Int16 vec2) { return(new Vector3Int16( Math.Max(vec1.X, vec2.X), Math.Max(vec1.Y, vec2.Y), Math.Max(vec1.Z, vec2.Z) )); }
public static BoundingBoxInt16 Merge(BoundingBoxInt16 box1, BoundingBoxInt16 box2) { if (box1 == Invalid) { return(box2); } if (box2 == Invalid) { return(box1); } return(new BoundingBoxInt16( Vector3Int16.Minimize(box1.Minimum, box2.Minimum), Vector3Int16.Maximize(box1.Maximum, box2.Maximum) )); }
public bool Equals(Vector3Int16 that) => X == that.X && Y == that.Y && Z == that.Z;
public BoundingBoxInt16(Vector3Int16 min, Vector3Int16 max) { Minimum = min; Maximum = max; }