Beispiel #1
0
        static void AddRound(DesignFace designFace, List <Round> roundSet, List <DesignFace> remainingFaces, Queue <DesignEdge> edgesToVisit)
        {
            remainingFaces.Remove(designFace);
            Round round = new Round(designFace);

            roundSet.Add(round);

            DesignFace otherFace  = null;
            Round      otherRound = null;

            foreach (DesignEdge newEdge in designFace.Edges)
            {
                edgesToVisit.Enqueue(newEdge);
                if (AddInHelper.TryGetAdjacentDesignFace(designFace, newEdge, out otherFace) && Round.TryGetRound(otherFace, out otherRound))
                {
                    round.AddAdjacentRound(otherRound);
                    otherRound.AddAdjacentRound(round);
                }
            }
        }