Ejemplo n.º 1
0
    // Returns true if at least one face matches the facesel rule but all of them
    public bool FaceSelectionIsValid(ConwayPoly.FaceSelections facesel)
    {
        if (ConwayOperators.Count == 0 && PolyType > 0)
        {
            _conwayPoly = new ConwayPoly(WythoffPoly);                                                      // We need a conway poly
        }
        int includedFaceCount = Enumerable.Range(0, _conwayPoly.Faces.Count).Count(x => _conwayPoly.IncludeFace(x, facesel));

        return(includedFaceCount > 0 && includedFaceCount < _conwayPoly.Faces.Count);
    }