private void Init() { int i; count = 0; minBucket = 0; hash = new HalfEdge[hashSize]; // dummy Halfedge at the top of each hash for (i = 0; i < hashSize; ++i) { hash[i] = HalfEdge.CreateDummy(); hash[i].NextInPriorityQueue = null; } }
public EdgeList(float xMin, float deltaX, int sqrtSiteCount) { this.xMin = xMin; this.deltaX = deltaX; hashSize = 2 * sqrtSiteCount; hash = new HalfEdge[hashSize]; LeftEnd = HalfEdge.CreateDummy(); RightEnd = HalfEdge.CreateDummy(); LeftEnd.EdgeListLeftNeighbor = null; LeftEnd.EdgeListRightNeighbor = RightEnd; RightEnd.EdgeListRightNeighbor = null; RightEnd.EdgeListLeftNeighbor = LeftEnd; hash[0] = LeftEnd; hash[hashSize - 1] = RightEnd; }