/// <summary> /// Объединяем дыры /// </summary> /// <param name="a"></param> /// <param name="edges"></param> public void CombineHole(HolPG a, List <EdgePH> edges = null) { foreach (var i in a.allPoint) { if (!allPoint.Contains(i)) { allPoint.Add(i); } } for (int i = 0; i < a.allEdge.Count; i++) { if (!(a.allEdge[i] < 0)) { if (!allEdge.Contains(a.allEdge[i])) { allEdge.Add(a.allEdge[i]); } else { edges[a.allEdge[i]].inEdge = true; } } } a.allEdge.Clear(); a.allPoint.Clear(); }
public HolPG(HolPG a) { allPoint = new List <int>(a.allPoint); startedIteration = a.startedIteration; endIteration = a.endIteration; allPoint = new List <int>(a.allPoint); }
/// <summary> /// Если все точки входной дыры находятся в текущей то Тру /// </summary> /// <param name="hole2"></param> /// <returns></returns> public bool HoleInHole(HolPG hole2) { foreach (var i in hole2.allPoint) { if (!allPoint.Contains(i)) { return(false); } } return(true); }