static public Face CreatePointsAndInsidePoint(Vector2 v0, Vector2 v1, Vector2 inside) { Face face = CreatePoints(v0, v1); if (face.IsInside(inside)) { return(face); } return(face.GetFlipped()); }
static public bool TryCreateTriangle(this Face item, Face face, out Triangle2 triangle) { if (item.v1 == face.v0) { if (item.IsInside(face.v1)) { triangle = new Triangle2(item.v0, face.v0, face.v1); return(true); } } triangle = default(Triangle2); return(false); }